Skip to content

bareboat-necessities/bbn-m5-s3-n2k-i2c

Repository files navigation

bbn-m5-s3-n2k-i2c

NMEA 2000 sensors for M5 atomS3-lite

BBN N2K Sender 1 BBN NMEA2000 Sensors 1

BBN N2K Sender 1 BBN NMEA2000 Sensors 2

Hardware

Accessories

Making Connections

For pins used in connections browse through the firmware code: https://github.com/bareboat-necessities/bbn-m5-s3-n2k-i2c

M5Stack connectors are well color coded and pins are labeled on m5stack portABC.

Building other sensors

This firmware is for env III sensor unit from m5stack. However by modifying the code you can easily create sensors you need. Take a look at the source code of BBN XDR sensors. That code and this example will give you enough pointers how to create your own N2K sensors (i2c, 1-wire, digital/analog etc).

For libraries used and their versions check .github/workflows/build.yaml

Loading Firmware

On Bareboat Necessities (BBN) OS (full)

Long press side button on atomS3-lite till you see green to enter the mode for uploading firmware.

NOTE: /dev/ttyACM0 in the script below is for example. In your case device name might be different. You can find out what it is by inspecting differences in output of

ls -ltr /dev/tty*

with the device unplugged from USB and plugged into USB.

Load the firmware:

# shutdown signalk
sudo systemctl stop signalk

if [ -f bbn-flash-m5-s3-n2k-i2c.sh ]; then rm bbn-flash-m5-s3-n2k-i2c.sh; fi
wget https://raw.githubusercontent.com/bareboat-necessities/my-bareboat/refs/heads/master/m5stack-tools/bbn-flash-m5-s3-n2k-i2c.sh
chmod +x bbn-flash-m5-s3-n2k-i2c.sh
./bbn-flash-m5-s3-n2k-i2c.sh -p /dev/ttyACM0

Unplug and plug the device into USB to reboot.

Reading serial port

stty -F /dev/ttyACM0 38400
socat stdio /dev/ttyACM0

Other Bareboat Necessities Devices

Project Home: https://bareboat-necessities.github.io/

About

NMEA 2000 sensors for M5 atomS3-lite

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors