PICAN-M: NMEA 2000 on the Raspberry Pi for Marine Applications Made Possible
If you ever worked with a GPS location module in close proximity with the hardware, you might have an idea about the direction we are taking today, as you had to deal with NMEA strings. NMEA 2000 (or NMEA2K or even N2K) is something among those lines but emphasizes a bit more on the hardware than the former. It intends to be a plug-and-play protocol to connect devices inside marine vehicles, including sensors and display units. Electrically, it is compatible with the CAN protocol. Typical data exchanges within the NMEA 2000 protocol include position, GPS status, steering commands with autopilots, wind sensor data, among other important variables in the aquatic environment. Now that you have a vague idea of what it is, let us introduce you to an interesting HAT for the Raspberry Pi, the PICAN-M.
The PICAN-M is a Raspberry Pi HAT for location, which can be connected through NMEA 2000 or NMEA 0813. Along with the expected location functionalities, it provides you with a 3 A switch-mode PSU, so that you can power both the HAT and the Raspberry Pi from an on-board 12 V power source. Now, if you know anything about the Raspberry Pi hardware, your first question (like mine) is going to be: “how do I communicate with the HAT?”, because the communication on the Raspberry Pi is limited to UART, I2C, and SPI. There is no CAN. The easy answer is they added a CAN controller to the HAT (more specifically, the MCP2515 part) which communicates via SPI, so all you need is the CAN utils package and you are good to go. But you are not limited there, the NMEA 0183 allows communication via UART. It requires some extra effort, but if your application requirements leave you with no choice, you can still use it.
Let us take a look at its specifications:
- CAN bus connection via Micro-C connector
- SocketCAN driver (appears as can0 to application)
- NMEA 0183 (RS422) connection via 5-way screw terminal (appears as ttyS0 to application)
- Qwiic (I2C) connector for extra sensors
- 3A Switch Mode Power Supply
- Compatible with OpenCPN, OpenPlotter, SignalK, and CANBoat
Now, we will take a look at the module in action. Of course, we will not go crazy and drive a boat. Firstly, we cannot, lockdown. Then, we have no module or boat license (or boat). So, we dove through its manual. It is not a bad experience, does not give you nausea from the sea and the documentation is actually pretty good. The image you are seeing is of the OpenCPN. There are more options, and the module only shines further if you put the I2C port to good use (by plugging a barometric pressure, humidity, and temperature sensor, like the BME280, from SparkFun). Lastly, the pricing of $98.85 is acceptable, considering the functionalities it provides you with.
PICAN-M link: https://copperhilltech.com/pican-m-nmea-0183-nmea-2000-hat-for-raspberry-pi/
Thanks for your insight for your fantastic posting. I’m glad I have taken the time to see this
HI
I have bought this PICAN-M board is there still a way to use any of the GPIO pins of the board (ie to add temperature activated Fan)?
Thanks
Brgs
Stuart
I have the PICAN-M board and it is piggybacked on my raspberry pi 3b. I cannot find any info on whether all GPIO pins are now not available or how to connect other devices to specific GPIO pins?
I wonder if possible to inject GPS data to NMEA 2000 network (GPS is connected to Raspberry Pi) a