The P25 destination is an integer.
This commit is contained in:
parent
e2ec5292b5
commit
7171af365d
12 changed files with 19 additions and 23 deletions
|
@ -155,10 +155,9 @@ void CDisplay::clearFusion()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void CDisplay::writeP25(const char* source, bool group, const char* dest, const char* type)
|
void CDisplay::writeP25(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
assert(source != NULL);
|
assert(source != NULL);
|
||||||
assert(dest != NULL);
|
|
||||||
assert(type != NULL);
|
assert(type != NULL);
|
||||||
|
|
||||||
m_timer1.start();
|
m_timer1.start();
|
||||||
|
|
|
@ -44,7 +44,7 @@ public:
|
||||||
void writeFusion(const char* source, const char* dest, const char* type, const char* origin);
|
void writeFusion(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
void clearFusion();
|
void clearFusion();
|
||||||
|
|
||||||
void writeP25(const char* source, bool group, const char* dest, const char* type);
|
void writeP25(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
void clearP25();
|
void clearP25();
|
||||||
|
|
||||||
virtual void close() = 0;
|
virtual void close() = 0;
|
||||||
|
@ -65,7 +65,7 @@ protected:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin) = 0;
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin) = 0;
|
||||||
virtual void clearFusionInt() = 0;
|
virtual void clearFusionInt() = 0;
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type) = 0;
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type) = 0;
|
||||||
virtual void clearP25Int() = 0;
|
virtual void clearP25Int() = 0;
|
||||||
|
|
||||||
virtual void clockInt(unsigned int ms);
|
virtual void clockInt(unsigned int ms);
|
||||||
|
|
|
@ -730,10 +730,9 @@ void CHD44780::clearFusionInt()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void CHD44780::writeP25Int(const char* source, bool group, const char* dest, const char* type)
|
void CHD44780::writeP25Int(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
assert(source != NULL);
|
assert(source != NULL);
|
||||||
assert(dest != NULL);
|
|
||||||
assert(type != NULL);
|
assert(type != NULL);
|
||||||
|
|
||||||
#ifdef ADAFRUIT_DISPLAY
|
#ifdef ADAFRUIT_DISPLAY
|
||||||
|
@ -764,7 +763,7 @@ void CHD44780::writeP25Int(const char* source, bool group, const char* dest, con
|
||||||
::lcdPosition(m_fd, 0, 1);
|
::lcdPosition(m_fd, 0, 1);
|
||||||
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
||||||
|
|
||||||
::sprintf(m_buffer1, "%s%.10s", group ? "TG" : "", dest);
|
::sprintf(m_buffer1, "%s%u", group ? "TG" : "", dest);
|
||||||
::lcdPosition(m_fd, 0, 2);
|
::lcdPosition(m_fd, 0, 2);
|
||||||
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
||||||
} else if (m_rows == 4U && m_cols == 20U) {
|
} else if (m_rows == 4U && m_cols == 20U) {
|
||||||
|
@ -773,12 +772,12 @@ void CHD44780::writeP25Int(const char* source, bool group, const char* dest, con
|
||||||
::lcdPosition(m_fd, 0, 1);
|
::lcdPosition(m_fd, 0, 1);
|
||||||
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
||||||
|
|
||||||
::sprintf(m_buffer1, "%s%.10s", group ? "TG" : "", dest);
|
::sprintf(m_buffer1, "%s%u", group ? "TG" : "", dest);
|
||||||
::lcdPosition(m_fd, 0, 2);
|
::lcdPosition(m_fd, 0, 2);
|
||||||
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
||||||
} else if (m_rows == 2 && m_cols == 40U) {
|
} else if (m_rows == 2 && m_cols == 40U) {
|
||||||
char m_buffer1[40U];
|
char m_buffer1[40U];
|
||||||
::sprintf(m_buffer1, "%.10s > %s%.10s", source, group ? "TG" : "", dest);
|
::sprintf(m_buffer1, "%.10s > %s%u", source, group ? "TG" : "", dest);
|
||||||
|
|
||||||
::lcdPosition(m_fd, 0, 1);
|
::lcdPosition(m_fd, 0, 1);
|
||||||
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
::lcdPrintf(m_fd, "%.*s", m_cols, m_buffer1);
|
||||||
|
|
|
@ -110,7 +110,7 @@ protected:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
virtual void clearFusionInt();
|
virtual void clearFusionInt();
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type);
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
virtual void clearP25Int();
|
virtual void clearP25Int();
|
||||||
|
|
||||||
virtual void clockInt(unsigned int ms);
|
virtual void clockInt(unsigned int ms);
|
||||||
|
|
|
@ -233,10 +233,9 @@ void CNextion::clearFusionInt()
|
||||||
sendCommand("t2.txt=\"\"");
|
sendCommand("t2.txt=\"\"");
|
||||||
}
|
}
|
||||||
|
|
||||||
void CNextion::writeP25Int(const char* source, bool group, const char* dest, const char* type)
|
void CNextion::writeP25Int(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
assert(source != NULL);
|
assert(source != NULL);
|
||||||
assert(dest != NULL);
|
|
||||||
assert(type != NULL);
|
assert(type != NULL);
|
||||||
|
|
||||||
if (m_mode != MODE_P25)
|
if (m_mode != MODE_P25)
|
||||||
|
@ -249,7 +248,7 @@ void CNextion::writeP25Int(const char* source, bool group, const char* dest, con
|
||||||
::sprintf(text, "t0.txt=\"%s %.10s\"", type, source);
|
::sprintf(text, "t0.txt=\"%s %.10s\"", type, source);
|
||||||
sendCommand(text);
|
sendCommand(text);
|
||||||
|
|
||||||
::sprintf(text, "t1.txt=\"%s%.10s\"", group ? "TG" : "", dest);
|
::sprintf(text, "t1.txt=\"%s%u\"", group ? "TG" : "", dest);
|
||||||
sendCommand(text);
|
sendCommand(text);
|
||||||
|
|
||||||
m_clockDisplayTimer.stop();
|
m_clockDisplayTimer.stop();
|
||||||
|
|
|
@ -50,7 +50,7 @@ protected:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
virtual void clearFusionInt();
|
virtual void clearFusionInt();
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type);
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
virtual void clearP25Int();
|
virtual void clearP25Int();
|
||||||
|
|
||||||
virtual void clockInt(unsigned int ms);
|
virtual void clockInt(unsigned int ms);
|
||||||
|
|
|
@ -68,7 +68,7 @@ void CNullDisplay::clearFusionInt()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void CNullDisplay::writeP25Int(const char* source, bool group, const char* dest, const char* type)
|
void CNullDisplay::writeP25Int(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ protected:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
virtual void clearFusionInt();
|
virtual void clearFusionInt();
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type);
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
virtual void clearP25Int();
|
virtual void clearP25Int();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
4
OLED.cpp
4
OLED.cpp
|
@ -210,7 +210,7 @@ void COLED::clearFusionInt()
|
||||||
display.display();
|
display.display();
|
||||||
}
|
}
|
||||||
|
|
||||||
void COLED::writeP25Int(const char* source, bool group, const char* dest, const char* type)
|
void COLED::writeP25Int(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
m_mode = MODE_P25;
|
m_mode = MODE_P25;
|
||||||
display.fillRect(0, OLED_LINE1, display.width(), 10, BLACK);
|
display.fillRect(0, OLED_LINE1, display.width(), 10, BLACK);
|
||||||
|
@ -218,7 +218,7 @@ void COLED::writeP25Int(const char* source, bool group, const char* dest, const
|
||||||
display.printf("%s %.10s", type, source);
|
display.printf("%s %.10s", type, source);
|
||||||
display.fillRect(0, OLED_LINE2, display.width(), 10, BLACK);
|
display.fillRect(0, OLED_LINE2, display.width(), 10, BLACK);
|
||||||
display.setCursor(0,OLED_LINE2);
|
display.setCursor(0,OLED_LINE2);
|
||||||
display.printf(" %s%.10s", group ? "TG" : "", dest);
|
display.printf(" %s%u", group ? "TG" : "", dest);
|
||||||
OLED_statusbar();
|
OLED_statusbar();
|
||||||
display.display();
|
display.display();
|
||||||
}
|
}
|
||||||
|
|
2
OLED.h
2
OLED.h
|
@ -94,7 +94,7 @@ public:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
virtual void clearFusionInt();
|
virtual void clearFusionInt();
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type);
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
virtual void clearP25Int();
|
virtual void clearP25Int();
|
||||||
|
|
||||||
virtual void close();
|
virtual void close();
|
||||||
|
|
|
@ -311,10 +311,9 @@ void CTFTSerial::clearFusionInt()
|
||||||
displayText(" ");
|
displayText(" ");
|
||||||
}
|
}
|
||||||
|
|
||||||
void CTFTSerial::writeP25Int(const char* source, bool group, const char* dest, const char* type)
|
void CTFTSerial::writeP25Int(const char* source, bool group, unsigned int dest, const char* type)
|
||||||
{
|
{
|
||||||
assert(source != NULL);
|
assert(source != NULL);
|
||||||
assert(dest != NULL);
|
|
||||||
assert(type != NULL);
|
assert(type != NULL);
|
||||||
|
|
||||||
if (m_mode != MODE_P25) {
|
if (m_mode != MODE_P25) {
|
||||||
|
@ -333,7 +332,7 @@ void CTFTSerial::writeP25Int(const char* source, bool group, const char* dest, c
|
||||||
gotoPosPixel(5U, 70U);
|
gotoPosPixel(5U, 70U);
|
||||||
displayText(text);
|
displayText(text);
|
||||||
|
|
||||||
::sprintf(text, " %s%.10s", group ? "TG" : "", dest);
|
::sprintf(text, " %s%u", group ? "TG" : "", dest);
|
||||||
|
|
||||||
gotoPosPixel(5U, 90U);
|
gotoPosPixel(5U, 90U);
|
||||||
displayText(text);
|
displayText(text);
|
||||||
|
|
|
@ -49,7 +49,7 @@ protected:
|
||||||
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
virtual void writeFusionInt(const char* source, const char* dest, const char* type, const char* origin);
|
||||||
virtual void clearFusionInt();
|
virtual void clearFusionInt();
|
||||||
|
|
||||||
virtual void writeP25Int(const char* source, bool group, const char* dest, const char* type);
|
virtual void writeP25Int(const char* source, bool group, unsigned int dest, const char* type);
|
||||||
virtual void clearP25Int();
|
virtual void clearP25Int();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
Loading…
Reference in a new issue