question

gootch avatar image
gootch asked

GPS via ModBus

Hi,

I have a Cerbo GX which is connected to a router which is able acquire a position via GPS. The Router has a external GPS antenna which makes sure the position is very precise.
The router is able to provide the location information via ModBus.
To test everything I installed the Venus OS on a RaspberryPi.
I managed to write a Python script which gets the position via Ethernet Modbus from the Router.
The script runs as a service and provides the date to the dbus.
I also get a device instance for gps via the Settings/Device entry.
Everything looks actually fine. I get the all the information in the GUI as expected.
But the position is not transmitted to the VRM Portal.
I also recognized that the little location (right next to the time) icon doesn't show up in the GUI.
Is there anything else beside getting the device instance and providing the data on the dbus at /com.victronenergy.gps?

If I connect a USB GPS Receiver everything seems to work and I cannot find any differences on the dbus. The same if I use the NMEA2k CAN Messages. This would also be my alternative. But I want to avoid adding a raspberryPi which reads the ModBus position and sent it on the CAN as the Cerbo is allready connected to the same Ethernet.

would be awesome if someone could point me to the missing piece.

Regards Joachim

Venus OSgps
2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

3 Answers
bathnm avatar image
bathnm answered Ā·

maybe share the two dbus outputs. If they are identical then everything should work.

Have you looked under com.victronenergy.settings and the devices paths to see if there is anything there?

Have you looked under com.victronenergy.system, and seen if there is a service mapping?


Would you are to share your python script with the community. Maybe talk with @Kevin Windrem and see if you can package it up using his package manager scripts.

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

gootch avatar image
gootch answered Ā·

Hi @Bathnm,

thank you for your quick answer.
Both path where OK. I got the Device Instance ID back and I also saw the service mapping.

I think I found the issue. I created some of the dbus entries later when I actually got the fix.
After some more tests ans just adding random values to the position it seems to work now when I create all the entries at the beginning and just leave them empty and fill them with the actual values after I get the Fix.

Regards Joachim

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

pau1phi11ips avatar image
pau1phi11ips answered Ā·

Would you mind sharing the Python script please?

2 |3000

Up to 8 attachments (including images) can be used with a maximum of 190.8 MiB each and 286.6 MiB total.

Related Resources

Additional resources still need to be added for this topic

Victron Venus OS Open Source intro page

Venus OS GitHub (please do not post to this)