6 years, 1 month ago.

How to send uBit.accelerometer.getX() from microbit to microbit using uBit.radio.datagram.send()?

while(1) { if(c==0) { x=uBit.accelerometer.getX(); }

uBit.radio.datagram.send(x);

uBit.sleep(20);

}

it seems that x is int and so cannot be accepted by radio.datagram.send..... what should i do to make this work?

Be the first to answer this question.