APRS address and routing fix. (#77)

* Update config.h

Added note to APRS_RELAYS line.

* Update ax25.h

source_ssid and destination_ssid did not match. Uint8_t was used in function definition within ax25.c file. Now all should match.

* Update ax25.c

source_ssid and destination_ssid are both defined the same in config.h and in ax25.h.  Both are inserted to memory by adjusting a pointer. Therefore both should require moving the pointer back 7 bytes to place in correctly addressed position. I am puzzled that the header definition and the cast in this code line are both needed.
main
Randy Pratt 2024-01-03 04:11:26 -06:00 zatwierdzone przez GitHub
rodzic 149141fb46
commit 9b4c19c101
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
3 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -89,7 +89,7 @@ uint16_t ax25_encode_packet_aprs(char *source, uint8_t source_ssid, char *destin
call_length = strlen(destination);
memset(header->destination, ' ', sizeof(header->destination));
memcpy(header->destination, destination, call_length < 6 ? call_length : 6);
header->destination_ssid = destination_ssid;
header->destination_ssid = (uint8_t) destination_ssid >= 'A' ? destination_ssid - 7 : destination_ssid);;
char *digipeater_addresses_start = ((char *) header) + 1 + 14;
uint16_t digipeater_addresses_length = ax25_encode_digipeater_path(digipeater_addresses, digipeater_addresses_start);

Wyświetl plik

@ -13,7 +13,7 @@ typedef struct _ax25_packet_header {
char destination[6];
uint8_t destination_ssid;
char source[6];
char source_ssid;
uint8_t source_ssid;
} ax25_packet_header;
typedef struct _ax25_packet_header_end {

Wyświetl plik

@ -275,7 +275,7 @@
#define APRS_SYMBOL_TABLE '/' // '/' denotes primary and '\\' denotes alternate APRS symbol table
#define APRS_SYMBOL 'O'
#define APRS_COMMENT "RS41ng radiosonde firmware test"
#define APRS_RELAYS "WIDE1-1,WIDE2-1"
#define APRS_RELAYS "WIDE1-1,WIDE2-1" //Do not include any spaces in the APRS_RELAYS
#define APRS_DESTINATION "APZ41N"
#define APRS_DESTINATION_SSID '0'
// Generate an APRS weather report instead of a position report. This will override the APRS symbol with the weather station symbol.