Signalk-send-n2k

Hey Gang, I am looking for some help with using Node Red to send data to SignalK and then onwards to NMEA2K.

I am running OpenPlotter on a PI 4B - this in turn is running SignalK and Node Red (signalk-node-red 3.0.3)

I am getting battery voltage data into Node Red via MQTT from a Victron GX Node Red instance, and I want to push this data out onto the NMEA2K Network. I am running a PICAN-M NMEA Hat that connects to the NMEA 2K Network on my boat PICAN-M - NMEA 0183 & NMEA 2000 HAT For Raspberry Pi

I have this function that converts the voltage value coming in via MQTT to an actisense formatted string

var voltage = msg.payload.toFixed(2); // Round to two decimal places

// Create Actisense-formatted string for PGN 127508
msg.payload = {
    pgn: 127508,
    fields: [
        { "Battery Voltage": voltage, "SID": 1 } // SID (Source Instance) can be any valid value
    ]
};

return msg;

ADMIN EDIT: Wrap code ↑ in triple backticks

This is successfully generating a pgn message, with the Battery Voltage, and a SID of 1

I am then trying to use the "send NMEA2000 node" to send this pgn data onto the NMEA2K network, but cannot get it to work. The fields in the node are:

Name
NMEA2000 Event (default value is nmea2000out)
NMEA2000 Jason Event (default value is nmea2000JsonOut)

Any help getting this working would be greatly appreciated

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.