Forum >Weather Station and Raspberry
Weather Station and Raspberry

I am interfacing the DF Robot weather station with a Raspberry pi 3Bv2 because I want the data on the internet but I am currently having a problem getting the data from the DF Robot board to the Raspberry via serial connection.
I have made the following connections from DF Robot to Raspberry.
Vcc --- 5v
tx --- rx
rx --- tx
Ground --- ground
I do get data when reading in C but the data looks like "�����������" which translates to repeated "EF BF BD".
The document that came with the weather station says 9600baud and I have set the Raspberry to 9600baud. Obviously something else is wrong. Please advise.
The Raspberry C program copied from wiringPi examples :-
I have made the following connections from DF Robot to Raspberry.
Vcc --- 5v
tx --- rx
rx --- tx
Ground --- ground
I do get data when reading in C but the data looks like "�����������" which translates to repeated "EF BF BD".
The document that came with the weather station says 9600baud and I have set the Raspberry to 9600baud. Obviously something else is wrong. Please advise.
The Raspberry C program copied from wiringPi examples :-
Code: Select all
#include <stdio.h> #include <string.h> #include <errno.h> #include <wiringSerial.h> int main () { int fd ; if ((fd = serialOpen ("/dev/ttyAMA0", 9600)) < 0) { fprintf (stderr, "Unable to open serial device: %s\n", strerror (errno)) ; return 1 ; } // Loop, getting and printing characters for (;;) { putchar (serialGetchar (fd)) ; fflush (stdout) ; } }
2020-12-27 00:32:36 The serial port on the DFRobot board is unlikely to be wrong as it works fine with Arduino Uno and as I am receiving data on the Raspberry Pi I do not understand your suggestion.
The point is I am getting data just not what is required.
anonymous
The point is I am getting data just not what is required.

2020-12-25 02:32:42 The serial port pin you selected may be wrong, you can try to find the pin after connecting
347945801
