I am actually connecting my laptop and arduino using FPVDrone 3DR Radio Telemetry. My connection is
ARDUINO tx- FPV Air module rx
ARDUINO rx- FPV Air module tx
ARDUINO 5v- FPV Air module 5v
ARDUINO GND- FPV Air module GND
while my FPV ground module is connected to my laptop. I have an app running using node JS with the following script
const SerialPort = require('serialport');
const Readline = SerialPort.parsers.Readline;
const port = new SerialPort('COM3');
port.write('hello');
and my arduino code is
void setup() {
Serial.begin(57600);
}
void loop() {
if (Serial.available()) {
Serial.print((char) Serial.read());
delay(10);
}
}
i'm pretty sure they are communicating because my arduino is receiving some output, however the output is some characters i dont know,
can someone please tell me what I should do so that i can receive the string "hello" to my arduino?
Try setting the baudrate in the node.js script
characters get messed up is the sending and receiving baudrates are different.