Signalk on Pi Zero 2w install hangs.

Ah.. Here you all are. I wondered where everyone had got to. I was wandering around the github discussion thinking it was awfully quiet and everyone is here having a party! Anyway: Hello I have been trying to install Signal K on a pi zero 2, just for testing and as an experiment. I have got to the actual installation part (sudo npm install -g signalk-server) and it appears to have hung my Pi zero 2. I can ping the Pi but get no response from my SSH sessions. The CPU seems to max out at 100% and no mouse response if I connect a screen/mouse to the HDMI output. I have left it like that for several hours with no progress. I am running the installation in a screen. Any thoughts or options? The last output from the installation is: (node:2245) ExperimentalWarning: CommonJS module /usr/lib/node_modules/npm/node_modules/debug/src/node.js is loading ES Module /usr/lib/node_modules/npm/node_modules/supports-color/index.js using require(). Support for loading ES Module in require() is an experimental feature and might change at any time (Use node --trace-warnings ...to show where the warning was created) ⠙ The progress dots seem not to have changed either.
14 Replies
Scott Bender
Scott Bender2mo ago
It’s probably going to take days on a pi zero?
jimseng
jimsengOP2mo ago
Ah. OK. I'll try again and leave it in a cupboard. It looked like I was never going to get there.
barnaclebill
barnaclebill2mo ago
+1 @Scott Bender ; you can do it but it takes a while. You might want to check your swap settings and allocate more swap on SD card because it swaps like mad during the install. Once it's running it works better. I think I once installed OS and SK on an SD card in a Pi4 and transferred it to Zero and that worked, if my memory isn't faulty.
Teppo Kurki
Teppo Kurki2mo ago
Pi zero w 2 is armv7 so installing on another more powerful machine and transferring to zero may work
Teppo Kurki
Teppo Kurki2mo ago
This blog claims docker installs, so you could try that route https://blog.alexellis.io/raspberry-pi-zero-2/amp/
Alex Ellis' Blog
First Impressions with the Raspberry Pi Zero 2 W
The Raspberry Pi Zero 2 W has just been released, it's now got three more cores just like the RPi 3, but what is it good for and should you get one?
free-x
free-x2mo ago
I had yesterday same trouble. After increasing of swap to 500mb ( /etc/dphys-swapfile + reboot) I was finally able to install/upgrade SK
jimseng
jimsengOP2mo ago
I thought about doing it on a Pi4, but I have set it off installing in a corner now. I wish I had thought about the swap bforehand, but I think I'll leave it for a couple of days and see what happens. I tried the docker route. It worked but I couldn't get it to persist between reboots, even though it is supposed to. Once running in docker, however, it seemed to run pretty well with my minimal tests simulating Seatalk and nmea/AIS data. KIP was fine on my phone and laptop It's just an experiment but things like the Shipmodul miniplex are quite pricey these days so for a hobbyist it is quite an interestingly cheap option maybe?
naugehyde
naugehyde2mo ago
My backup computer is a PiZero2W and yes, more swap was necessary to install SK. It is usable but a noticeably slower at providing data than a pi 4b. Note: I use the Zero2W as a SK server only. FWIW I use a CAN HAT from waveshare to talk to my NMEA 2k network https://www.waveshare.com/wiki/RS485_CAN_HAT I use a USB to RS-232 converter to send data to my NMEA 0183 autopilot. It's a barebones, minimal solution but totally viable.
jimseng
jimsengOP2mo ago
I have left my zero in the corner chuntering away, but I think I will interrupt it and increase the swap size and try again. However I just put the sd card from my other Pi Zero 2 into my Pi 4 to set up Signalk, which took about 5 minutes and now it is back in the Zero and is working fine. I actually use a Pi 5 as a full plotter on my boat but I think this would be great just running signalK. If I had OpenCPN on some separate plotter device (Android/Navionics) I think this would easily handle the Seatalk in and out + nmea to the auto helm. I made a "hat" to handle the IO including a 433MHz receiver so I can steer from the foredeck with a cheap garage key fob. Probably less than £50.00 and a lot less than a miniplex, which doesn't do direct Seatalk autopilot control.
naugehyde
naugehyde2mo ago
Is that key fob solution documented anywhere? I'd love to see what you did!
jimseng
jimsengOP2mo ago
I haven't documented it. It is a developing process. I am on my second iteration of my "hat" - see image- to which I have now added a Dolatek RXB6 receiver (£1.85 from Amazon). My hat has two nmea (RS485 to ttl) modules, an opto and a couple of transistors. (And an AD converter for my keel sensor) The opto is for Seatalk in and the transistors are for Seatalk out. The Seatalk out transmits Seatalk Datagrams onto the bus and I take one of the 4 codes from the key fob buttons and send a +-10 or +-1 to the Autohelm. Running on a python script on my PiZero I pretty much steered up the river successfully with the key fob. I'm happy to share it, but where?
No description
jimseng
jimsengOP2mo ago
No description
jimseng
jimsengOP2mo ago
The 433Mhz route can also work on a Pi Pico with PIO handling the Seatalk input/output if you want to go really, really cheap. Less than £20 if you already own a soldering iron.
naugehyde
naugehyde2mo ago
Fascinating. And remarkable! There are hardware projects like this documented on GitHub with Schematics etc. That's where I'd put it.
Want results from more Discord servers?
Add your server