hi,
we’re using an Arduino Nano board to control a Pololu Mini Maestro 24 channel board which in turn controls a few servos to do our bidding
we’ve created a procedure in the Arduino code which sends a byte of data with the 0xAE command through designated pins(in Arduino - software RX TX pins, in Maestro - hardware RX TX pins) to the Maestro board and returns what the Maestro is telling us.
it worked until a few days ago, sending 0’s and 1’s as it should, but now it returns only “255”, no matter if the script stopped or not
anybody knows what is wrong?
attached is the short proc we wrote and needed variables
//SERVO_CONTROLLER_RX_PIN & SERVO_CONTROLLER_TX_PIN are 2 & 3
SoftwareSerial ServoController = SoftwareSerial(SERVO_CONTROLLER_RX_PIN, SERVO_CONTROLLER_TX_PIN);
int getScriptStatus ()
{
byte serialBytes[1];
byte serialBytesReturnValue[1];
serialBytes[0]=0xAE;
ServoController.write(serialBytes, sizeof(serialBytes));
serialBytesReturnValue[0]=ServoController.read();
return serialBytesReturnValue[0];
}