Fix autoswitch mode beetwen APRS/PACKET MODES

master
US1GHQ 2021-09-14 21:37:36 +03:00
parent c0c509cabf
commit e135238393
4 changed files with 22 additions and 15 deletions

View File

@ -1,10 +1,10 @@
#ifndef BUILD_NUMBER
#define BUILD_NUMBER "40"
#define BUILD_NUMBER "57"
#endif
#ifndef VERSION
#define VERSION "v0.3.2.40-cf9ad1d - 2021-09-14 11:14:16.765429"
#define VERSION "v0.4.0.57- - 2021-09-14 21:33:46.282660"
#endif
#ifndef VERSION_SHORT
#define VERSION_SHORT "v0.3.2.40-cf9ad1d"
#define VERSION_SHORT "v0.4.0.57-"
#endif

View File

@ -27,4 +27,4 @@
//Data control frames, ported from Direwolf
#define T_PKT 0x03
#define R_PKT 0xa6
#define R_PKT 0x03

View File

@ -34,11 +34,18 @@ String decapsulateKISS(const String &frame);
*/
String encode_kiss(const String &tnc2FormattedFrame, bool &pktFrame) {
pktFrame = tnc2FormattedFrame.charAt(1) == R_PKT;
String TNC2Frame = "";
String ax25Frame = "";
if (!pktFrame) {
for (int i = 0; i <= tnc2FormattedFrame.indexOf(','); i++)
{
char currentChar = tnc2FormattedFrame.charAt(i);
if (currentChar == ',')
{
pktFrame = true;
}
}
if (pktFrame) {
if (validateTNC2Frame(tnc2FormattedFrame)) {
String address = "";
bool dst_addres_written = false;
@ -127,7 +134,7 @@ String decode_kiss(const String &inputKISSTNCFrame, bool &dataFrame, bool &pktFr
if (validateKISSFrame(inputKISSTNCFrame)) {
dataFrame = inputKISSTNCFrame.charAt(1) == CMD_DATA;
for (int i = 0; i < inputKISSTNCFrame.length(); ++i)
for (int i = 15; i < inputKISSTNCFrame.length(); ++i)
{
char currentChar = inputKISSTNCFrame.charAt(i);
if (currentChar == (char) T_PKT)

View File

@ -1,6 +1,6 @@
FILENAME_BUILDNO = '.pio/versioning'
FILENAME_VERSION_H = 'include/version.h'
version = 'v0.4.0.'
version = 'v0.4.1.'
import datetime
from subprocess import *