kopia lustrzana https://github.com/SP8EBC/ParaTNC
sending max_ok
rodzic
a7c4cc90c8
commit
35befecec5
|
@ -1039,7 +1039,7 @@ int main(int argc, char* argv[]){
|
|||
|
||||
if (main_config_data_basic-> beacon_at_bootup == 1) {
|
||||
#if defined(PARAMETEO)
|
||||
beacon_send_own(rte_main_battery_voltage, system_is_rtc_ok());
|
||||
beacon_send_own(rte_main_battery_voltage, system_is_rtc_ok(), max31865_ok);
|
||||
main_wait_for_tx_complete();
|
||||
delay_fixed(1500);
|
||||
#else
|
||||
|
|
|
@ -80,7 +80,7 @@ void packet_tx_configure(uint8_t meteo_interval, uint8_t beacon_interval, config
|
|||
|
||||
// if user selected aggressive powersave mode the meteo counter must be set back to zero
|
||||
// to prevent quirks with waking from sleep mode
|
||||
packet_tx_meteo_counter = 0;
|
||||
packet_tx_meteo_counter = meteo_interval - 1;
|
||||
|
||||
}
|
||||
|
||||
|
@ -216,7 +216,7 @@ void packet_tx_handler(const config_data_basic_t * const config_basic, const con
|
|||
|
||||
packet_tx_multi_per_call_handler();
|
||||
|
||||
beacon_send_own(0, 0);
|
||||
beacon_send_own(0, 0, 0);
|
||||
|
||||
packet_tx_beacon_counter = 0;
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ extern "C"
|
|||
{
|
||||
#endif
|
||||
|
||||
void beacon_send_own(uint16_t voltage, uint8_t rtc_ok);
|
||||
void beacon_send_own(uint16_t voltage, uint8_t rtc_ok, uint8_t max_ok);
|
||||
void beacon_send_on_startup(void);
|
||||
void beacon_send_from_user_content(uint16_t content_ln, char* content_ptr);
|
||||
|
||||
|
|
|
@ -26,6 +26,7 @@ typedef enum max31865_qf_t {
|
|||
extern uint8_t max31865_current_fault_status;
|
||||
extern uint8_t max31865_measurements_counter;
|
||||
extern int_average_t max31865_average;
|
||||
extern uint8_t max31865_ok;
|
||||
|
||||
void max31865_init(uint8_t rdt_type, uint8_t reference_resistor);
|
||||
void max31865_init_average(void);
|
||||
|
|
|
@ -14,13 +14,13 @@
|
|||
|
||||
#include <stdio.h>
|
||||
|
||||
void beacon_send_own(uint16_t voltage, uint8_t rtc_ok) {
|
||||
void beacon_send_own(uint16_t voltage, uint8_t rtc_ok, uint8_t max_ok) {
|
||||
main_wait_for_tx_complete();
|
||||
if (voltage == 0 && rtc_ok == 0) {
|
||||
main_own_aprs_msg_len = sprintf(main_own_aprs_msg, "=%s%c%c%s%c%c %s", main_string_latitude, main_config_data_basic->n_or_s, main_symbol_f, main_string_longitude, main_config_data_basic->e_or_w, main_symbol_s, main_config_data_basic->comment);
|
||||
}
|
||||
else {
|
||||
main_own_aprs_msg_len = sprintf(main_own_aprs_msg, "=%s%c%c%s%c%c %s [vbat: %d][rtc_ok: %d]", main_string_latitude, main_config_data_basic->n_or_s, main_symbol_f, main_string_longitude, main_config_data_basic->e_or_w, main_symbol_s, main_config_data_basic->comment, (int)voltage , (int)rtc_ok);
|
||||
main_own_aprs_msg_len = sprintf(main_own_aprs_msg, "=%s%c%c%s%c%c %s [vbat: %d][rtc_ok: %d][max_ok: %d]", main_string_latitude, main_config_data_basic->n_or_s, main_symbol_f, main_string_longitude, main_config_data_basic->e_or_w, main_symbol_s, main_config_data_basic->comment, (int)voltage , (int)rtc_ok, (int)max_ok);
|
||||
}
|
||||
main_own_aprs_msg[main_own_aprs_msg_len] = 0;
|
||||
ax25_sendVia(&main_ax25, main_own_path, main_own_path_ln, main_own_aprs_msg, main_own_aprs_msg_len);
|
||||
|
|
|
@ -636,7 +636,7 @@ void telemetry_send_chns_description_tatry(const config_data_basic_t * const con
|
|||
|
||||
// clear the output frame buffer
|
||||
memset(main_own_aprs_msg, 0x00, sizeof(main_own_aprs_msg));
|
||||
main_own_aprs_msg_len = sprintf(main_own_aprs_msg, ":%-6s :PARM.Spi,LastTempr,MaxTempr,Vbatt,PtSts,LSERDY,RTCEN,N,N,N,N,N,N", config_basic->callsign);
|
||||
main_own_aprs_msg_len = sprintf(main_own_aprs_msg, ":%-6s :PARM.Spi,LastTempr,MaxTempr,Vbatt,PtSts,LSERDY,RTCEN,MAX_OK,N,N,N,N,N", config_basic->callsign);
|
||||
|
||||
main_own_aprs_msg[main_own_aprs_msg_len] = 0;
|
||||
ax25_sendVia(&main_ax25, main_own_path, main_own_path_ln, main_own_aprs_msg, main_own_aprs_msg_len);
|
||||
|
@ -722,7 +722,7 @@ void telemetry_send_values_tatry() {
|
|||
pt_status,
|
||||
((RCC->BDCR & RCC_BDCR_LSERDY) > 0) ? '1' : '0',
|
||||
((RCC->BDCR & RCC_BDCR_RTCEN) > 0) ? '1' : '0',
|
||||
'0',
|
||||
(max31865_ok) ? '1' : '0',
|
||||
'0',
|
||||
'0',
|
||||
'0',
|
||||
|
|
Ładowanie…
Reference in New Issue