How could I make the bytes tactic?
//all this is just for the "Real-time" situation
//the hc-05 that sends
Serial.write(map(potentiometer1,0,1024,0,180));
Serial.write(map(potentiometer2,0,1024,0,180));
Serial.write(map(potentiometer3,0,1024,0,180));
Serial.write(map(potentiometer4,0,1024,0,180));
Serial.write(map(potentiometer5,0,1024,0,180));
//the hc-05 that receive
if (Serial.available() == 5)
{
motorA=Serial.read();
motorB=Serial.read();
motorC=Serial.read();
motorD=Serial.read();
motorE=Serial.read();
}
Is this right?