Skip to content

Commit

Permalink
corrected GPS DMS field for Nextion
Browse files Browse the repository at this point in the history
  • Loading branch information
on7lds committed Dec 12, 2017
1 parent 1ad3c67 commit 54b6f5a
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Nextion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ void CNextion::writeDMRGPSInt(unsigned int slotNo, float latitude, float longitu
int minutesLon = (int)((longitude - (float)degreeLon) * 60.0);
float secondsLon = (float)((longitude - (float)degreeLon - (float)minutesLon / 60.0) * 60.0 * 60.0);

::sprintf(text, "%d°%d'%.2f\"%c %d°%d'%.2f\"%c",degreeLat,minutesLat,secondsLat,Lat,degreeLon,minutesLon,secondsLon,Lon);
::sprintf(text, "t%d.txt=\"%d%c%d'%.2f\\\" %c %d%c%d'%.2f\\\" %c\"",2*slotNo+7,degreeLat,176U,minutesLat,secondsLat,Lat,degreeLon,176U,minutesLon,secondsLon,Lon);

if (slotNo == 1U) {
sendCommand(text);
Expand Down
Binary file modified Nextion_ON7LDS/NX4832T035-L3.HMI
Binary file not shown.
2 changes: 1 addition & 1 deletion Nextion_ON7LDS/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ are activated.

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). All layout processing can and should be done in the display ittself.
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 ittself.

More information about the layouts can be found in
* README-L2 for the screenLayout 2 setting
Expand Down

0 comments on commit 54b6f5a

Please sign in to comment.