From 098c4fc6b4634e0d570fd39e5a70206ed5b0653f Mon Sep 17 00:00:00 2001 From: Chipster Date: Fri, 17 Feb 2023 06:20:09 -0600 Subject: [PATCH] Add mode type to APRS string. Make APRS band/offset string a bit more consistent. --- DGIdGateway/APRSWriter.cpp | 16 ++++++++-------- YSFGateway/APRSWriter.cpp | 16 ++++++++-------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/DGIdGateway/APRSWriter.cpp b/DGIdGateway/APRSWriter.cpp index a4beeea..2d88b35 100644 --- a/DGIdGateway/APRSWriter.cpp +++ b/DGIdGateway/APRSWriter.cpp @@ -234,19 +234,19 @@ void CAPRSWriter::sendIdFrameFixed() char desc[200U]; if (m_txFrequency != 0U) { float offset = float(int(m_rxFrequency) - int(m_txFrequency)) / 1000000.0F; - ::sprintf(desc, "MMDVM Voice %.5LfMHz %c%.4lfMHz%s%s", + ::sprintf(desc, "MMDVM Voice (C4FM) %.5LfMHz %c%.4lfMHz%s%s", (long double)(m_txFrequency) / 1000000.0F, offset < 0.0F ? '-' : '+', ::fabs(offset), m_desc.empty() ? "" : ", ", m_desc.c_str()); } else { - ::sprintf(desc, "MMDVM Voice%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); + ::sprintf(desc, "MMDVM Voice (C4FM)%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); } const char* band = "4m"; if (m_txFrequency >= 1200000000U) - band = "1.2"; + band = "23cm/1.2GHz"; else if (m_txFrequency >= 420000000U) - band = "440"; + band = "70cm`"; else if (m_txFrequency >= 144000000U) band = "2m"; else if (m_txFrequency >= 50000000U) @@ -332,19 +332,19 @@ void CAPRSWriter::sendIdFrameMobile() char desc[200U]; if (m_txFrequency != 0U) { float offset = float(int(m_rxFrequency) - int(m_txFrequency)) / 1000000.0F; - ::sprintf(desc, "MMDVM Voice %.5LfMHz %c%.4lfMHz%s%s", + ::sprintf(desc, "MMDVM Voice (C4FM) %.5LfMHz %c%.4lfMHz%s%s", (long double)(m_txFrequency) / 1000000.0F, offset < 0.0F ? '-' : '+', ::fabs(offset), m_desc.empty() ? "" : ", ", m_desc.c_str()); } else { - ::sprintf(desc, "MMDVM Voice%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); + ::sprintf(desc, "MMDVM Voice (C4FM)%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); } const char* band = "4m"; if (m_txFrequency >= 1200000000U) - band = "1.2"; + band = "23cm/1.2GHz"; else if (m_txFrequency >= 420000000U) - band = "440"; + band = "70cm"; else if (m_txFrequency >= 144000000U) band = "2m"; else if (m_txFrequency >= 50000000U) diff --git a/YSFGateway/APRSWriter.cpp b/YSFGateway/APRSWriter.cpp index d7feea1..622b4d5 100644 --- a/YSFGateway/APRSWriter.cpp +++ b/YSFGateway/APRSWriter.cpp @@ -234,19 +234,19 @@ void CAPRSWriter::sendIdFrameFixed() char desc[200U]; if (m_txFrequency != 0U) { float offset = float(int(m_rxFrequency) - int(m_txFrequency)) / 1000000.0F; - ::sprintf(desc, "MMDVM Voice %.5LfMHz %c%.4lfMHz%s%s", + ::sprintf(desc, "MMDVM Voice (C4FM) %.5LfMHz %c%.4lfMHz%s%s", (long double)(m_txFrequency) / 1000000.0F, offset < 0.0F ? '-' : '+', ::fabs(offset), m_desc.empty() ? "" : ", ", m_desc.c_str()); } else { - ::sprintf(desc, "MMDVM Voice%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); + ::sprintf(desc, "MMDVM Voice (C4FM)%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); } const char* band = "4m"; if (m_txFrequency >= 1200000000U) - band = "1.2"; + band = "23cm/1.2GHz"; else if (m_txFrequency >= 420000000U) - band = "440"; + band = "70cm"; else if (m_txFrequency >= 144000000U) band = "2m"; else if (m_txFrequency >= 50000000U) @@ -331,19 +331,19 @@ void CAPRSWriter::sendIdFrameMobile() char desc[200U]; if (m_txFrequency != 0U) { float offset = float(int(m_rxFrequency) - int(m_txFrequency)) / 1000000.0F; - ::sprintf(desc, "MMDVM Voice %.5LfMHz %c%.4lfMHz%s%s", + ::sprintf(desc, "MMDVM Voice (C4FM) %.5LfMHz %c%.4lfMHz%s%s", (long double)(m_txFrequency) / 1000000.0F, offset < 0.0F ? '-' : '+', ::fabs(offset), m_desc.empty() ? "" : ", ", m_desc.c_str()); } else { - ::sprintf(desc, "MMDVM Voice%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); + ::sprintf(desc, "MMDVM Voice (C4FM)%s%s", m_desc.empty() ? "" : ", ", m_desc.c_str()); } const char* band = "4m"; if (m_txFrequency >= 1200000000U) - band = "1.2"; + band = "23cm/1.2GHz"; else if (m_txFrequency >= 420000000U) - band = "440"; + band = "70cm"; else if (m_txFrequency >= 144000000U) band = "2m"; else if (m_txFrequency >= 50000000U)