Skip to content

Commit

Permalink
Add more logging for mode changing.
Browse files Browse the repository at this point in the history
  • Loading branch information
g4klx committed Dec 4, 2023
1 parent b63381a commit 1b27774
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions MMDVMHost.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2033,6 +2033,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("D-Star");
LogMessage("Mode set to D-Star");
break;

case MODE_DMR:
Expand Down Expand Up @@ -2081,6 +2082,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("DMR");
LogMessage("Mode set to DMR");
break;

case MODE_YSF:
Expand Down Expand Up @@ -2125,6 +2127,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("System Fusion");
LogMessage("Mode set to System Fusion");
break;

case MODE_P25:
Expand Down Expand Up @@ -2169,6 +2172,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("P25");
LogMessage("Mode set to P25");
break;

case MODE_NXDN:
Expand Down Expand Up @@ -2213,6 +2217,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("NXDN");
LogMessage("Mode set to NXDN");
break;

case MODE_M17:
Expand Down Expand Up @@ -2257,6 +2262,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("M17");
LogMessage("Mode set to M17");
break;

case MODE_POCSAG:
Expand Down Expand Up @@ -2301,6 +2307,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("POCSAG");
LogMessage("Mode set to POCSAG");
break;

case MODE_FM:
Expand Down Expand Up @@ -2350,6 +2357,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.start();
m_cwIdTimer.stop();
createLockFile("FM");
LogMessage("Mode set to FM");
break;

case MODE_LOCKOUT:
Expand Down Expand Up @@ -2399,6 +2407,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.stop();
m_cwIdTimer.stop();
removeLockFile();
LogMessage("Mode set to Lockout");
break;

case MODE_ERROR:
Expand Down Expand Up @@ -2448,6 +2457,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_modeTimer.stop();
m_cwIdTimer.stop();
removeLockFile();
LogMessage("Mode set to Error");
break;

default:
Expand Down Expand Up @@ -2506,6 +2516,7 @@ void CMMDVMHost::setMode(unsigned char mode)
m_mode = MODE_IDLE;
m_modeTimer.stop();
removeLockFile();
LogMessage("Mode set to Idle");
break;
}
}
Expand Down

0 comments on commit 1b27774

Please sign in to comment.