Closed quantenschaum closed 2 months ago
The heart of OpenPlotter is SignalK. You should rather use the corresponding SignalK plugin https://github.com/SignalK/set-system-time
P.S. settime.sh is a part of avnav-raspi package, which is not for OpenPlotter available ( only for AvNav Images)
OK, why? The settings could be available on OP but disabled by default.
I started with OP because it contains SK and AvNav, to try them out and are now "stuck" on it with the o-charts. But I have to say, I do not like SK, the idea is good, but AvNav is much more usable.
Most probably I should be more clear in the docs for that part. On OpenPlotter we consider SignalK to be the main data handler. On AvNav images this is AvNav. And as OP/SignalK have their own handling of system time we do not want AvNav to interfere with it. At the end it's not enough to set the system time - you potentially need to restart some services. If you still want AvNav to set the system time you can copy the script from the avnav-raspi package and configure it as settime command.
configure it as settime command.
OK, but how, the settings are not present? - But I can also let SK to this.
I would recommend to go with the SignalK approach - it's more natural for OpenPlotter. But at the end I'm not sure if it will handle all services correctly (mdns/avahi does not like setting the system time...).
If you really would like to use AvNav, you must configure the settimecmd at AVNConfig (https://www.wellenvogel.net/software/avnav/docs/hints/configfile.html) - can only be done directly in the xml as it is not intended for "normal" users ;-) - (you can use the update plugin to edit the xml). Afterwards you will see all the other configs. The command from avnav-raspi: https://github.com/wellenvogel/avnav/blob/master/raspberry/settime.sh
OK, after setting
<AVNConfig expiryTime="10.0" settimecmd="foo"/>
the other config options did appear, the settimecmd
option itself is not available, though.
BTW, what is avahi used for? Are there devices that auto discover AvNav?
Yes, settimecmd will never be visible in the UI - as I wrote. Avahi: Sure - refer to the docs. Especially BonjourBrowser. But also other devices can use this (like my m5 - esp32 stuff).
Version: 20240708-0907 on OpenPlotter
The options for setting system time from GPS as described in the docs (AVNConfig) are are not present in the UI.
When running the Pi offline, the system clock does not seem to get set to GPS time.
I noticed that because the track NMEA logs are recorded with wrong time stamps and the track does not get displayed on the map (browser on tablet has correct time).
Am I missing something here or is this bug?