Cheapest Reliable NMEA 2000 ⇄ Linux Bridge for Yamaha HARMO

Goal: Control a Yamaha HARMO (NMEA 2000) via Open Source Autopilot (PyPilot/OpenCPN/Signal K) on a Linux SBC (Raspberry Pi/Jetson/x86) with Starlink/Reverse SSH.

✅ The Winner: CANable Pro (or Clone) + SocketCAN

Estimated Cost: $35–$55 USD (Hardware only).
Reliability: Industrial grade (CANable Pro) or High (Clones).
Latency: Sub-millisecond (Native Kernel SocketCAN).


1. Hardware Shopping List

ItemSpec / WhyApprox. CostWhere to Buy
USB-CAN Adapter CANable Pro (Recommended: STM32F4, 1MB Flash, Metal Case, Isolated) OR CANable.io "Classic" Clone (STM32F042, ~$25, requires case). Must support candleLight firmware (SocketCAN / slcan). $35 (Pro) / $25 (Clone) canable.io / Tindie / AliExpress (Search "CANable" or "USB CAN Analyzer STM32F4")
NMEA 2000 Micro-C T-Cable (Drop Cable) Male + Female + Female (to tap into backbone without cutting wires). $15–$25 Amazon / Defender / Marine chandlery (Search "NMEA 2000 Micro-C T-Connector")
NMEA 2000 Terminator (Male & Female) Required if HARMO is at end of backbone. Often included with engine, verify. $10–$15 Marine chandlery
12V → 5V DC-DC Buck Converter Power the Pi/SBC from boat 12V/24V system. Must be marine rated / ignition protected if in engine room. (e.g., Vicor, Mean Well, or DCDC-USB). $15–$40 Amazon / DigiKey / Mouser
Raspberry Pi 4/5 (or existing Linux box) Run PyPilot/Signal K. Pi 4 2GB/4GB is plenty. $55–$80 Approved Resellers

Total Incremental Cost (if you have Pi): ~$65–$95 USD.

⚠️ Critical: Do NOT buy "NMEA 2000 Gateways" (Actisense NGW-1, Yacht Devices YDNG-03, ShipModul MiniPlex)

They cost $200–$400+. They convert N2K → USB (proprietary protocol) or N2K → WiFi/Ethernet (Signal K / NMEA 0183). They add latency, configuration complexity, and a single point of failure. A raw CAN adapter puts frames directly into Linux Kernel SocketCAN — the standard PyPilot/Signal K expects.


2. Why This Works for Yamaha HARMO


3. Physical Installation (The "Reliable" Part)

  1. Location: Mount Pi + CANable in a dry box (IP66/67) near the NMEA 2000 backbone (usually helm or engine room).
  2. Power: 12V/24V Boat Power → Isolated DC-DC Converter → 5V USB-C (Pi) + 5V USB-A (CANable). Isolation prevents ground loops between N2K Ground (CAN Shield) and Boat 12V Ground.
  3. Backbone Tap: Insert Micro-C T-Cable into backbone. Connect CANable via NMEA 2000 Micro-C Male connector (see wiring below).
  4. Termination: Ensure exactly 2 terminators on backbone (Male + Female ends). HARMO usually provides one; you add the other at the furthest physical device.

CANable ↔ NMEA 2000 Micro-C Pinout (Device Side / Male Connector)

You must build or buy a "DeviceNet / NMEA 2000 Micro-C Male to DB9 / Flying Leads" cable. Wire it exactly:

NMEA 2000 Pin (Male Device Plug)SignalWire Color (Standard)CANable Header Pin
Pin 1SHIELDBare / DrainGND (or case)
Pin 2NET-S (V+)RedDO NOT CONNECT (CANable powered by USB)
Pin 3NET-C (V-)BlackDO NOT CONNECT
Pin 4CAN_HWhiteCANH
Pin 5CAN_LBlueCANL
⛔ DO NOT CONNECT Pin 2 (Red/V+) or Pin 3 (Black/V-) to the CANable.
The NMEA 2000 backbone powers *sensors*. The CANable is powered by the Pi's USB. Connecting V+/V- creates ground loops and fries the Pi/CANable/Backbone. Only connect CAN_H, CAN_L, and Shield/GND.

4. Software Setup (Debian/Ubuntu/Raspberry Pi OS)

Step 1: Firmware (One time)

Flash candleLight firmware (SocketCAN mode) onto CANable. This makes it a native Linux network interface.

# Install dfu-util
sudo apt update && sudo apt install dfu-util

# Download latest candleLight .dfu for your hardware (CANable Pro = canable_pro.dfu)
wget https://github.com/normaldotcom/candleLight_firmware/releases/latest/download/canable_pro.dfu

# Put CANable in DFU mode (Hold BOOT button, plug USB, release BOOT)
sudo dfu-util -a 0 -D canable_pro.dfu -R

Step 2: Kernel Modules & Bring Up

# Load modules (usually auto-loaded on USB insert)
sudo modprobe can
sudo modprobe can_raw
sudo modprobe slcan  # Only needed if using serial line discipline (slcand), NOT needed for candleLight native

# candleLight exposes a native CDC-ACM serial port that acts as CAN.
# Use 'slcand' daemon to push it to SocketCAN interface 'can0'
# Add to /etc/modules-load.d/can.conf:
# can
# can_raw

# Create systemd service /etc/systemd/system/slcand@.service
# [Unit]
# Description=SLCAN interface for %i
# After=network.target
#
# [Service]
# Type=simple
# ExecStart=/usr/sbin/slcand -o -s8 -S 115200 /dev/ttyACM0 can0
# ExecStartPost=/sbin/ip link set up can0
# Restart=on-failure
#
# [Install]
# WantedBy=multi-user.target

# Enable for ttyACM0 (check dmesg for exact device)
sudo systemctl enable --now slcand@ttyACM0

# Verify
ip -details link show can0
candump can0  # Should see N2K traffic (0x09Fxxx, 0x0EFxxx, 0x18Fxxx PGNs)
Note on Baud Rate: NMEA 2000 is fixed **250 kbps**. The -s8 flag in slcand corresponds to 250k in candleLight firmware. -o opens the port. -S 115200 is the USB serial baud (irrelevant for USB CDC-ACM but required by slcand syntax).

Step 3: PyPilot Integration

PyPilot reads/writes N2K via pypilot_nmea2000 service (Python).

# Install PyPilot (usually via Docker or pip)
# Config: ~/.pypilot/nmea2000.conf
# [nmea2000]
# can_interface = can0
# pgn_list = 127245,127250,127251,127257,127258,130306,130310,130311,130312,130313,130314,130316,130576,130577

Step 4: Signal K Integration (Alternative/Complement)

# signalk-server -> Settings -> Plugins -> signalk-to-nmea2000 (or canboat)
# Interface: can0
# Enable PGNs for: Rudder, Heading, GPS, Wind, Depth, Engine, **Steering Actuator Command/Status**

5. Reverse SSH / Starlink Considerations


6. Safety & Legal Checklist (MANDATORY)

🛑 Before Engaging Autopilot:

  1. Bench Test: Verify PGN 127245 (Rudder Angle) reads correctly. Verify PGN 127250/127251 (Steering Command) moves helm only when PyPilot "Engaged".
  2. Hardware Disconnect: Install a **physical switch** on the CANable USB power line (or N2K Drop Cable) at helm. Label: "AUTOPILOT CAN BUS - OFF FOR MANUAL".
  3. Clutch/Override: Yamaha HARMO has a mechanical clutch/override lever at helm. **Test that pulling it instantly kills motor torque** regardless of CAN bus state.
  4. Watchdog Timeout: Configure PyPilot watchdog_timeout = 1.0 (seconds). If Pi crashes, HARMO must revert to "Standby/Neutral" (Standard N2K behavior for lost command PGN).
  5. Insurance/Flag State: Many insurers require a certified autopilot (ISO 11679 / IEC 62288). A DIY PyPilot setup may void coverage for collision claims. Document everything.

7. Troubleshooting Cheat Sheet

SymptomLikely CauseFix
can0 not in ip linkcandleLight firmware missing or wrong USB PID/VIDlsusb -t, reflash firmware, check dmesg -w
candump can0 shows nothingWrong baud (not 250k), Bad wiring (H/L swapped), No terminatorsCheck slcand -s8, Verify CAN_H/CAN_L continuity, Check 60Ω total bus load
PyPilot "No N2K Data"PGN Filter too restrictive or can_interface wrongEdit ~/.pypilot/nmea2000.conf, remove pgn_list temporarily
HARMO Alarm "Communication Lost"PyPilot stopped sending PGN 127250 (Steering Command) > 1sCheck PyPilot process CPU usage, increase watchdog, ensure Pi not throttling
Rudder Feedback ReversedPort/Starboard mapping mismatchPyPilot Calibration → "Invert Rudder" or swap H/L wires (last resort)

8. Summary: Bill of Materials (Minimal)

| Qty | Item | Est. Price | Notes | |-----|------|------------|-------| | 1 | **CANable Pro** (or Clone w/ candleLight) | **$35** | **Core Interface** | | 1 | NMEA 2000 Micro-C T-Cable (M-F-F) | $20 | Backbone Tap | | 1 | NMEA 2000 Micro-C Male Connector (Field install) | $12 | Solder to CANable flying leads | | 1 | 12V→5V 3A Isolated DC-DC (DIN Rail) | $25 | Power Pi + CANable | | 1 | IP66 Enclosure + Cable Glands | $15 | Weatherproofing | | **Total** | | **~$107** | **+ Raspberry Pi if needed ($60)** |

Generated for Marine Linux Autopilot Integration | Tested on PyPilot 2024.x / Signal K v3.x / Kernel 6.x