2017-12-05 19:50:56 +00:00
|
|
|
Nextion Display Layouts by ON7LDS (for MMDVMHost)
|
|
|
|
=================================================
|
|
|
|
|
|
|
|
####################################
|
|
|
|
# #
|
|
|
|
# screenLayout 3 & 4 files (-L3) #
|
|
|
|
# #
|
|
|
|
# DIY layouts #
|
|
|
|
# #
|
|
|
|
####################################
|
|
|
|
|
|
|
|
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
|
2017-12-10 20:50:47 +00:00
|
|
|
2 = ON7LDS layout (see README-L2)
|
|
|
|
3 = ON7LDS DIY layout (this README file)
|
|
|
|
4 = ON7LDS DIY layout Hig Speed (this README file)
|
2017-12-05 19:50:56 +00:00
|
|
|
|
|
|
|
screenLayout 3 and 4 are the same, but selecting 3, MMDVMHost wil 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.
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
How to set the default Nextion Display baudrate ?
|
|
|
|
You could use the Nextion editor, connect to your display with the debug
|
|
|
|
tool (do not forget to select your display and not the simulator) and
|
|
|
|
give the command 'bauds=115200'.
|
|
|
|
Another option is to set the command above in the Preinitialization Event
|
|
|
|
of the first page. Nextion recommends to do the latter in any case,
|
|
|
|
because 'on rare occasions bauds has become lost'
|
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
|
|
|
|
DIY layouts
|
|
|
|
-----------
|
|
|
|
When selecting this layout, all processing can and should be done in the
|
|
|
|
Nextion display itsself.
|
|
|
|
Whenever MMDVMHost sends new data to the screen, it also sends information
|
|
|
|
about wat was sent:
|
|
|
|
|
|
|
|
* global variable MMDVM.cmd will hold the number of the changed field
|
2017-12-10 20:50:47 +00:00
|
|
|
(not the object id ! 0 for t0, 1 for t1, etc.)
|
2017-12-05 19:50:56 +00:00
|
|
|
* global variable MMDVM.status will hold the status of the change
|
2017-12-10 20:50:47 +00:00
|
|
|
(the type of information sent - see further in this document)
|
2017-12-05 19:50:56 +00:00
|
|
|
|
|
|
|
Then MMDVMHost activates the Touch Press Event of object 'S0' of the
|
|
|
|
active page.
|
|
|
|
In this event procedure, all processing can be done.
|
|
|
|
|
|
|
|
Check the Touch Press Event of object 'S0' of the DMR page of the example
|
2017-12-10 20:50:47 +00:00
|
|
|
HMI file. As a straightforward example, the code there will:
|
|
|
|
- change colors and fonts of the TA on the DMR page when it arrives.
|
|
|
|
(TA length calculation is done in the display itsself !)
|
|
|
|
- display the GPS data (if received) in a new field (called 'GPS'),
|
|
|
|
by copying the GPS data form the field where MMDVMHost has
|
|
|
|
written to (t11 for GPS data from slot 2 in DMS format)
|
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
|
|
|
|
|
|
|
|
Status codes that will be sent:
|
|
|
|
-------------------------------
|
|
|
|
The status code gives more information about what was sent in the
|
|
|
|
changed field.
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
1 : page MMDVM
|
|
|
|
2 : page D-Star
|
|
|
|
3 : page DMR
|
|
|
|
4 : page YSF
|
|
|
|
5 : page P25
|
|
|
|
|
|
|
|
11 : IDLE
|
|
|
|
12 : CW
|
|
|
|
13 : ERROR text
|
|
|
|
14 : ERROR
|
|
|
|
15 : LOCKOUT
|
|
|
|
16 : IPaddress
|
|
|
|
17 : ID/Call
|
|
|
|
19 : END
|
|
|
|
|
|
|
|
21 : D-Star listening
|
|
|
|
22 : type/my1/my2
|
|
|
|
23 : your
|
|
|
|
24 : reflector
|
|
|
|
25 : RSSI
|
|
|
|
26 : ber
|
|
|
|
|
|
|
|
31 : DMR listening
|
|
|
|
32 : ID
|
|
|
|
33 : TA
|
|
|
|
34 : Call end
|
|
|
|
35 : GPS
|
|
|
|
36 : TG
|
|
|
|
37 : RSSI
|
|
|
|
38 : ber
|
|
|
|
|
|
|
|
41 : YSF listening
|
|
|
|
42 : src
|
|
|
|
43 : dest
|
|
|
|
44 : origin
|
|
|
|
45 : RSSI
|
|
|
|
46 : ber
|
|
|
|
|
|
|
|
51 : P25 listening
|
|
|
|
52 : source
|
|
|
|
53 : dest
|
|
|
|
54 : RSSI
|
|
|
|
55 : ber
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fields (and their numbers) on the pages, used by MMDVMHost
|
|
|
|
----------------------------------------------------------
|
2017-12-05 19:50:56 +00:00
|
|
|
|
|
|
|
MMDVM
|
2017-12-10 20:50:47 +00:00
|
|
|
t0 : owner call & ID / errortext LOCKOUT
|
2017-12-05 19:50:56 +00:00
|
|
|
t1 : status / ERROR
|
|
|
|
t2 : date & time
|
2017-12-10 20:50:47 +00:00
|
|
|
|
|
|
|
screenLayout >1 :
|
2017-12-05 19:50:56 +00:00
|
|
|
t3 : ip address
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
D-Star
|
|
|
|
t0 : type my1 my2
|
|
|
|
t1 : your
|
|
|
|
t2 : reflector
|
|
|
|
t3 : rssi
|
|
|
|
t4 : ber
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
DMR
|
|
|
|
t0 : src1 id / call / TA
|
|
|
|
t1 : dst
|
|
|
|
t2 : src2 id / call / TA
|
|
|
|
t3 : dst
|
|
|
|
t4 : rssi1
|
|
|
|
t5 : rssi2
|
|
|
|
t6 : ber1
|
|
|
|
t7 : ber2
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
screenLayout >1 :
|
|
|
|
t8 : GPS1 dec
|
|
|
|
t9 : GPS1 DMS
|
|
|
|
t10: GPS2 dec
|
|
|
|
t11: GPS2 DMS
|
|
|
|
t12: GPS1 err
|
|
|
|
t13: GPS2 err
|
|
|
|
|
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
YSF
|
|
|
|
t0 : type,source
|
|
|
|
t1 : dst
|
|
|
|
t2 : src
|
|
|
|
t3 : rssi
|
|
|
|
t4 : ber
|
|
|
|
|
2017-12-10 20:50:47 +00:00
|
|
|
|
2017-12-05 19:50:56 +00:00
|
|
|
P25
|
|
|
|
t0 : type,source
|
|
|
|
t1 : dst
|
|
|
|
t2 : rssi
|
|
|
|
t3 : ber
|
|
|
|
|
|
|
|
|