I would like to get a Json interface running to access the Venus dbus data from an Ajax client but have so far failed.
Background
I have a working Ajax implementation of a GUI this was written a few years back and easy to customise and serve from the inbuilt Venus web server - Hiawatha. I would like to make calls to access the data in Venus OS running on my Rpi 3B+. The UI Being Ajax and Javascript, the interface should be REST/Json. I could write a Json server to interface to dbus but I realised this is just what Signalk offers. So I took a look at how to get it installed.
Going forward an Ajax UI could be easier to customise within the community than the current pages, would be lightweight as much of the processing is in the client end - not the server, and should integrate well with the signalk service/
Getting Signal k running:
I tried following this instruction: from https://github.com/victronenergy/venus/wiki/Signal-K
"Note for the raspberrypis that it is not necessary, nor recommended to reinstall a full image on an sdcard. Doing so will also remove all configuration and stored data.
Latest available files:
- Venus GX: venus-swu-beaglebone-20191221131757-v2.50~2-signalk-1.swu.
- RaspberryPis: venus-swu-raspberrypi2-20191221133738-v2.50~2-signalk-1.swu"
The SWU is found own the SDcard and selecting it says installing. But when the install is complete going to [IP address]:3000 does not display a dashboard and I can't find any installed files with include signal k in the filename.
Either:
I have version Venus OS 2.51 running already so perhaps the SWU which is for 2.50 is ignored.
or
I do need to do the full sdimg install first as per this instruction:
"To install Venus OS + Signalk on an sdcard for a rasperrypi; follow these instructions; but then using below file instead of the one mentioned in the instructions:
And If I do this then how do I go for future version updates (2.6 being around the corner).
Or could Signalk be made available as a opkg install?
Does signal k have much dependency on the Venus OS version?