Add callsign from config file to idle screen
This commit is contained in:
parent
09a16a37a6
commit
aae5060f80
10 changed files with 14 additions and 13 deletions
|
@ -28,7 +28,7 @@ public:
|
|||
|
||||
virtual bool open() = 0;
|
||||
|
||||
virtual void setIdle() = 0;
|
||||
virtual void setIdle(const char* callsign) = 0;
|
||||
|
||||
virtual void setLockout() = 0;
|
||||
virtual void setError(const char* text) = 0;
|
||||
|
|
|
@ -63,12 +63,12 @@ bool CHD44780::open()
|
|||
return true;
|
||||
}
|
||||
|
||||
void CHD44780::setIdle()
|
||||
void CHD44780::setIdle(const char* callsign)
|
||||
{
|
||||
::lcdClear(m_fd);
|
||||
|
||||
::lcdPosition(m_fd, 0, 0);
|
||||
::lcdPuts(m_fd, "MMDVM");
|
||||
::lcdPrintf(m_fd, "MMDVM %s", callsign);
|
||||
|
||||
::lcdPosition(m_fd, 0, 1);
|
||||
::lcdPuts(m_fd, "Idle");
|
||||
|
|
|
@ -32,7 +32,7 @@ public:
|
|||
|
||||
virtual bool open();
|
||||
|
||||
virtual void setIdle();
|
||||
virtual void setIdle(const char* callsign);
|
||||
|
||||
virtual void setError(const char* text);
|
||||
virtual void setLockout();
|
||||
|
|
|
@ -692,7 +692,8 @@ void CMMDVMHost::setMode(unsigned char mode, bool logging)
|
|||
if (m_mode == MODE_DMR && m_duplex)
|
||||
m_modem->writeDMRStart(false);
|
||||
m_modem->setMode(MODE_IDLE);
|
||||
m_display->setIdle();
|
||||
std::string callsign = m_conf.getCallsign();
|
||||
m_display->setIdle(callsign.c_str());
|
||||
m_mode = MODE_IDLE;
|
||||
m_modeTimer.stop();
|
||||
break;
|
||||
|
|
|
@ -48,12 +48,12 @@ bool CNextion::open()
|
|||
::sprintf(command, "dim=%u", m_brightness);
|
||||
sendCommand(command);
|
||||
|
||||
setIdle();
|
||||
setIdle("");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void CNextion::setIdle()
|
||||
void CNextion::setIdle(const char* callsign)
|
||||
{
|
||||
sendCommand("page MMDVM");
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ public:
|
|||
|
||||
virtual bool open();
|
||||
|
||||
virtual void setIdle();
|
||||
virtual void setIdle(const char* callsign);
|
||||
|
||||
virtual void setError(const char* text);
|
||||
virtual void setLockout();
|
||||
|
|
|
@ -31,7 +31,7 @@ bool CNullDisplay::open()
|
|||
return true;
|
||||
}
|
||||
|
||||
void CNullDisplay::setIdle()
|
||||
void CNullDisplay::setIdle(const char* callsign)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ public:
|
|||
|
||||
virtual bool open();
|
||||
|
||||
virtual void setIdle();
|
||||
virtual void setIdle(const char* callsign);
|
||||
|
||||
virtual void setError(const char* text);
|
||||
virtual void setLockout();
|
||||
|
|
|
@ -71,12 +71,12 @@ bool CTFTSerial::open()
|
|||
|
||||
setForeground(COLOUR_BLACK);
|
||||
|
||||
setIdle();
|
||||
setIdle("");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void CTFTSerial::setIdle()
|
||||
void CTFTSerial::setIdle(const char* callsign)
|
||||
{
|
||||
// Clear the screen
|
||||
clearScreen();
|
||||
|
|
|
@ -32,7 +32,7 @@ public:
|
|||
|
||||
virtual bool open();
|
||||
|
||||
virtual void setIdle();
|
||||
virtual void setIdle(const char* callsign);
|
||||
|
||||
virtual void setError(const char* text);
|
||||
virtual void setLockout();
|
||||
|
|
Loading…
Reference in a new issue