0

I am facing the following problem. I need to connect a sensor to a pc via serial port. i know exactly the values of baud rate (38400), 8 data bits, 1 stop bit and no parity. So i connect the sensor to the computer and i am not seeing any data transmitted to the pc. Note: the sensor is read only. i mean that there is not any handshake.

Do you have any ideas about why i don't get any data?

the connections are ok because i am connecting another device and in the other device i am able to read data.

Thanks everybody in advance!

  • Possible duplicate of [SerialPort not receiving any data](http://stackoverflow.com/questions/8907490/serialport-not-receiving-any-data) – Hans Passant Oct 09 '15 at 15:01

1 Answers1

0

it could be HW problem. Can you test it on different computer? From where is the sensor getting power? Some parasitic powering on DRT,RTS lines?

The easiest way is using oscilloscope/digital analyzer to see what's going on the line. With sound card oscilloscope like https://www.zeitnitz.eu/scope_en you should be able to see at least some bursts albeit it's sampling frequency is to low to see the data.

Libor Tomsik
  • 668
  • 7
  • 24
  • hey...thanks for the advice. i got an oscilloscope to test what happens in the line and as i connected both channels A and B i found out that despite the fact that we have an rs232 cable, the signals were rs485 because they were differential. I could not see that before because i was connecting one signal at a time. Now i suppose i have to get an rs485 to rs232 converter in order to read bits in a hyper terminal right?? – Dimitrios Evangelopoulos Oct 14 '15 at 08:32
  • I'm using $18 USB to RS485/RS422 from dx.com sku:26098, works fine with RbPI and Linux as well as Windows. – Libor Tomsik Oct 15 '15 at 14:27
  • thanks for the suggestion Libor. I have already ordered something similar. i will have it from day to day....can't wait – Dimitrios Evangelopoulos Oct 15 '15 at 18:57