diff --git a/Nextion.cpp b/Nextion.cpp index 5d95ee9..25a0fce 100644 --- a/Nextion.cpp +++ b/Nextion.cpp @@ -616,7 +616,7 @@ void CNextion::writeNXDNInt(const char* source, bool group, unsigned int dest, c if (m_mode != MODE_NXDN) { sendCommand("page NXDN"); - sendCommandAction(5U); + sendCommandAction(6U); } char text[30U]; @@ -625,11 +625,11 @@ void CNextion::writeNXDNInt(const char* source, bool group, unsigned int dest, c ::sprintf(text, "t0.txt=\"%s %.10s\"", type, source); sendCommand(text); - sendCommandAction(102U); + sendCommandAction(122U); ::sprintf(text, "t1.txt=\"%s%u\"", group ? "TG" : "", dest); sendCommand(text); - sendCommandAction(103U); + sendCommandAction(123U); m_clockDisplayTimer.stop(); @@ -649,7 +649,7 @@ void CNextion::writeNXDNRSSIInt(unsigned char rssi) char text[25U]; ::sprintf(text, "t2.txt=\"-%udBm\"", m_rssiAccum1 / NXDN_RSSI_COUNT); sendCommand(text); - sendCommandAction(104U); + sendCommandAction(124U); m_rssiAccum1 = 0U; m_rssiCount1 = 0U; } @@ -664,7 +664,7 @@ void CNextion::writeNXDNBERInt(float ber) char text[25U]; ::sprintf(text, "t3.txt=\"%.1f%%\"", m_berAccum1 / float(NXDN_BER_COUNT)); sendCommand(text); - sendCommandAction(105U); + sendCommandAction(125U); m_berAccum1 = 0.0F; m_berCount1 = 0U; } @@ -673,7 +673,7 @@ void CNextion::writeNXDNBERInt(float ber) void CNextion::clearNXDNInt() { sendCommand("t0.txt=\"Listening\""); - sendCommandAction(101U); + sendCommandAction(121U); sendCommand("t1.txt=\"\""); sendCommand("t2.txt=\"\""); sendCommand("t3.txt=\"\""); diff --git a/Nextion_ON7LDS/NX3224T024-L2.HMI b/Nextion_ON7LDS/NX3224T024-L2.HMI index 2053193..d3d4696 100644 Binary files a/Nextion_ON7LDS/NX3224T024-L2.HMI and b/Nextion_ON7LDS/NX3224T024-L2.HMI differ diff --git a/Nextion_ON7LDS/NX3224T024-L2.tft b/Nextion_ON7LDS/NX3224T024-L2.tft index 8a35f3f..081b5cf 100644 Binary files a/Nextion_ON7LDS/NX3224T024-L2.tft and b/Nextion_ON7LDS/NX3224T024-L2.tft differ diff --git a/Nextion_ON7LDS/NX3224T024-L3.HMI b/Nextion_ON7LDS/NX3224T024-L3.HMI index 454590a..8a610c6 100644 Binary files a/Nextion_ON7LDS/NX3224T024-L3.HMI and b/Nextion_ON7LDS/NX3224T024-L3.HMI differ diff --git a/Nextion_ON7LDS/NX3224T024-L3.tft b/Nextion_ON7LDS/NX3224T024-L3.tft index 500e9f1..b3f54aa 100644 Binary files a/Nextion_ON7LDS/NX3224T024-L3.tft and b/Nextion_ON7LDS/NX3224T024-L3.tft differ diff --git a/Nextion_ON7LDS/NX3224T028-L2.HMI b/Nextion_ON7LDS/NX3224T028-L2.HMI index 4e46f9d..88f02b7 100644 Binary files a/Nextion_ON7LDS/NX3224T028-L2.HMI and b/Nextion_ON7LDS/NX3224T028-L2.HMI differ diff --git a/Nextion_ON7LDS/NX3224T028-L2.tft b/Nextion_ON7LDS/NX3224T028-L2.tft index 1109cbe..a06d977 100644 Binary files a/Nextion_ON7LDS/NX3224T028-L2.tft and b/Nextion_ON7LDS/NX3224T028-L2.tft differ diff --git a/Nextion_ON7LDS/NX3224T028-L3.HMI b/Nextion_ON7LDS/NX3224T028-L3.HMI index 72d743d..a3ae328 100644 Binary files a/Nextion_ON7LDS/NX3224T028-L3.HMI and b/Nextion_ON7LDS/NX3224T028-L3.HMI differ diff --git a/Nextion_ON7LDS/NX3224T028-L3.tft b/Nextion_ON7LDS/NX3224T028-L3.tft index 1bd978c..6f033a4 100644 Binary files a/Nextion_ON7LDS/NX3224T028-L3.tft and b/Nextion_ON7LDS/NX3224T028-L3.tft differ diff --git a/Nextion_ON7LDS/NX4024T032-L2.HMI b/Nextion_ON7LDS/NX4024T032-L2.HMI index 0c2fe27..06d8ce2 100644 Binary files a/Nextion_ON7LDS/NX4024T032-L2.HMI and b/Nextion_ON7LDS/NX4024T032-L2.HMI differ diff --git a/Nextion_ON7LDS/NX4024T032-L2.tft b/Nextion_ON7LDS/NX4024T032-L2.tft index 7c8779a..4279d35 100644 Binary files a/Nextion_ON7LDS/NX4024T032-L2.tft and b/Nextion_ON7LDS/NX4024T032-L2.tft differ diff --git a/Nextion_ON7LDS/NX4832T035-L2.HMI b/Nextion_ON7LDS/NX4832T035-L2.HMI index 7cd8aeb..e49e748 100644 Binary files a/Nextion_ON7LDS/NX4832T035-L2.HMI and b/Nextion_ON7LDS/NX4832T035-L2.HMI differ diff --git a/Nextion_ON7LDS/NX4832T035-L2.tft b/Nextion_ON7LDS/NX4832T035-L2.tft index d4a4245..9b6642b 100644 Binary files a/Nextion_ON7LDS/NX4832T035-L2.tft and b/Nextion_ON7LDS/NX4832T035-L2.tft differ diff --git a/Nextion_ON7LDS/NX4832T035-L3.HMI b/Nextion_ON7LDS/NX4832T035-L3.HMI index 4070e5c..59f027e 100644 Binary files a/Nextion_ON7LDS/NX4832T035-L3.HMI and b/Nextion_ON7LDS/NX4832T035-L3.HMI differ diff --git a/Nextion_ON7LDS/NX4832T035-L3.tft b/Nextion_ON7LDS/NX4832T035-L3.tft index 479b42b..35ac4e7 100644 Binary files a/Nextion_ON7LDS/NX4832T035-L3.tft and b/Nextion_ON7LDS/NX4832T035-L3.tft differ diff --git a/Nextion_ON7LDS/README-L2 b/Nextion_ON7LDS/README-L2 index d3b4a48..46e799d 100644 --- a/Nextion_ON7LDS/README-L2 +++ b/Nextion_ON7LDS/README-L2 @@ -36,6 +36,6 @@ There are some other changes: to automatically change the font size, is activated. 0 = auto (future use, for now it's G4KLX layout) 1 = G4KLX layout - 2 = ON7LDS layout (this README file) - 3 = DIY by ON7LDS layout (see README-L3) - 4 = DIY by ON7LDS layout Hig Speed (see README-L3) + 2 = ON7LDS layout (this README file) + 3 = ON7LDS DIY layout (see README-L3) + 4 = ON7LDS DIY layout High Speed (see README-L3) diff --git a/Nextion_ON7LDS/README-L3 b/Nextion_ON7LDS/README-L3 index 16e391e..1bf6b98 100644 --- a/Nextion_ON7LDS/README-L3 +++ b/Nextion_ON7LDS/README-L3 @@ -5,7 +5,7 @@ Nextion Display Layouts by ON7LDS (for MMDVMHost) # # # screenLayout 3 & 4 files (-L3) # # # - # DIY layouts # + # ON7LDS DIY layouts # # # #################################### @@ -14,11 +14,11 @@ MMDVM.ini file under the Nextion section. This way, the extra functions are activated. 0 = auto (future use, for now it's G4KLX layout) 1 = G4KLX layout - 2 = ON7LDS layout (see README-L2) - 3 = ON7LDS DIY layout (this README file) - 4 = ON7LDS DIY layout Hig Speed (this README file) + 2 = ON7LDS layout (see README-L2) + 3 = ON7LDS DIY layout (this README file) + 4 = ON7LDS DIY layout High Speed (this README file) -screenLayout 3 and 4 are the same, but selecting 3, MMDVMHost wil communicate +screenLayout 3 and 4 are the same, but selecting 3, MMDVMHost will communicate at 9600bps with the display and selecting 4 will set the baudrate to 115200. If you select 4 (115200bps) *you* have to program your Nextion to default to that baudrate. @@ -32,8 +32,8 @@ Another option is to set the command above in the Preinitialization Event because 'on rare occasions bauds has become lost' -DIY layouts ------------ +ON7LDS DIY layouts +------------------ When selecting this layout, all processing can and should be done in the Nextion display itself. Whenever MMDVMHost sends new data to the screen, it also sends information @@ -48,7 +48,7 @@ Check the Touch Press Event of object 'S0' of the DMR page of the example HMI file. As a straightforward example, the code there will show you how to do some tasks when receiving data from MMDVMHost or NextionDriver: - change colors and fonts of the TA on the DMR page when it arrives. - (TA length calculation is done in the display itsself !) + (TA length calculation is done in the display itself !) - remove the slot number from t2.txt (since it's always 2) - in the middle of the DMR screen, the previous user is displayed for each slot (S1 at the left, S2 at the right) @@ -93,6 +93,7 @@ changed field. 3 : page DMR 4 : page YSF 5 : page P25 + 6 : page NXDN 11 : IDLE 12 : CW @@ -140,6 +141,12 @@ changed field. 104 : RSSI 105 : ber +121 : NXDN listening +122 : source +123 : dest +124 : RSSI +125 : ber + Fields (and their numbers) on the pages, used by MMDVMHost @@ -198,3 +205,9 @@ t2 : rssi t3 : ber +NXDN +t0 : type,source +t1 : dst +t2 : rssi +t3 : ber + diff --git a/Nextion_ON7LDS/README.md b/Nextion_ON7LDS/README.md index de739f6..83a8990 100644 --- a/Nextion_ON7LDS/README.md +++ b/Nextion_ON7LDS/README.md @@ -1,19 +1,19 @@ Nextion Display Layouts by ON7LDS (for MMDVMHost) ================================================= -The screenlayout has to be selected with the parameter ScreenLayout in the +The screenlayout has to be selected with the parameter **ScreenLayout** in the MMDVM.ini file under the Nextion section. This way, the extra functions are activated. 0 = auto (future use, for now it's G4KLX layout) 1 = G4KLX layout 2 = ON7LDS layout (see README-L2) - 3 = DIY layout - 4 = DIY layout High Speed + 3 = ON7LDS DIY layout + 4 = ON7LDS DIY layout High Speed Layout 2 is a no-nonsense layout. It is the original (G4KLX) layout with the Talker Alias added. TA color and fonts size can not be changed. At least not easily. -Layout 3 (as is 4) is a layout without any predefined layout options (color, fonts). It sends the fields *and* information about what was sent to the display, so all layout processing can and should be done in the display itself. +Layout 3 (as is 4) is a layout without any predefined layout options (color, fonts). It sends the fields **and** information about what was sent to the display, so all layout processing can and should be done in the display itself. More information about the layouts can be found in * README-L2 for the screenLayout 2 setting @@ -21,5 +21,5 @@ More information about the layouts can be found in When you want extra control over what has to be sent to the Nextion display, you could consider the program 'NextionDriver' at https://github.com/on7lds/NextionDriver as a companion to MMDVMHost. -This program sends extra information about the host to the display, can do callsign lookup with extended information (name, city, country) and can do more processing which would not be the task of MMDVMHost (for example: with the help of this program, it is possible to use buttons on the display). +This program sends extra information about the host to the display, can do callsign lookup with extended information (name, city, country) and can do more processing which would not be the task of MMDVMHost (for example: with the help of this program, it is possible to use buttons on the display to do actions on the host itself). In verbose mode, this program shows you all communication between MMDVMHost and the display.