1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

ChirpChat demod: auto message length for FT messages

This commit is contained in:
f4exb 2024-04-05 02:00:35 +02:00
parent 3c9f74aeb5
commit 788df1eda3
2 changed files with 16 additions and 1 deletions

View File

@ -327,6 +327,21 @@ bool ChirpChatDemod::handleMessage(const Message& cmd)
m_lastMsgSyncWord = msg.getSyncWord();
m_lastMsgTimestamp = msg.getMsgTimestamp();
m_lastMsgString = msg.getMessage(); // for now we do not handle message components (call1, ...)
int nbSymbolBits = m_settings.m_spreadFactor - m_settings.m_deBits;
m_lastMsgNbSymbols = (174 / nbSymbolBits) + ((174 % nbSymbolBits) == 0 ? 0 : 1);
if (m_settings.m_autoNbSymbolsMax)
{
ChirpChatDemodSettings settings = m_settings;
settings.m_nbSymbolsMax = m_lastMsgNbSymbols;
applySettings(settings);
if (getMessageQueueToGUI()) // forward to GUI if any
{
MsgConfigureChirpChatDemod *msgToGUI = MsgConfigureChirpChatDemod::create(settings, false);
getMessageQueueToGUI()->push(msgToGUI);
}
}
if (m_settings.m_sendViaUDP)
{

View File

@ -723,7 +723,7 @@
<item>
<widget class="QCheckBox" name="messageLengthAuto">
<property name="toolTip">
<string>Set message length in symbols automatically to provided message length (LoRa only)</string>
<string>Set message length in symbols automatically to provided message length (LoRa and FT only)</string>
</property>
<property name="text">
<string>Auto</string>