Problems Sending Mavlink Commands to Pixhawk

I currently have a Pixhawk attached to an RC car that I am trying to send Mavlink commands to. This configuration works great in Mission Planner. I am reading and writing to and from the Pixhawk using JavaScript and I am implementing the node-mavlink library and the serialport library. I can receive and read all messages from the Pixhawk, but am having a hard time sending messages effectively.

Is there some configuration/verification commands I have to send the Pixhawk before it allows my other commands to be written onto the Pixhawk? Am I just not using serial port correctly? Are the commands I'm creating not viable commands? 

The code I am trying to get working is attached. The confrimMessageSent function indicates that the write to the port is successful, however the Pixhawk does not respond. I have tried sending and receiving many commands.

index.js

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Activity