Hi all, I appreciate any help you have on this.
I am attempting to send raw RC commands over MSP to a flight controller running betaflight. I am using this library, GitHub - fdivitto/MSP: Arduino MSP (MultiWii Serial Protocol) library. There is only one example given which details how to receive the rc channel values. I have gotten this to work fine and been able to print them to the serial monitor. However I would like to send raw RC commands over MSP to the flight controller. Within the .h file for the library is this struct
Below is my code.
#include <MSP.h>
MSP msp;
void setup()
{
Serial.begin(115200);
msp.begin(Serial);
}
void loop()
{
msp_set_raw_rc_t rc;
rc.channel[0] = 1300;
msp.command(MSP_SET_RAW_RC, &rc, sizeof(rc));
Serial.println(rc.channel[0]);
}
This code does not seem to work however. It does not change the RC values of the FC. Am I using the function right? Is there something I am missing? Thanks in advance for any help and sorry if I am not being clear in any way about what my issue is.