0

A RS-485 network consists of one master(micro server with RxTx) and 2 slave devices. One of slave device is actual device and another is simulator of previously mentioned device.

The simulator is made by not using RxTx and running on micro server. It reads /dev/ttySx by FileInput/OutputStream after set some options using stty command. And it behaves as if there is a number of devices.

The master requests slave to get some data in order cyclically.

The problem is that the master's unable to get data from actual device when running with simulator although the simulator does nothing when actual device's turn.

Uske
  • 173
  • 1
  • 1
  • 8
  • Not sure whether I can help with the problem, the last time I worked with RS485 is more than 20 years ago... There are lots of potential reasons. You should provide some additional information: Are you sure your slave device is actually sending data? What is your topology? Are your lines properly terminated? Does it work when you remove the simulator? Can your master talk to the simulator? Do you have a logic analyzer or something you can use to monitor the data? Does the simulator sit between your master and device? If so, check that it doesn't terminate the line. – Thomas Stets Jan 07 '15 at 12:03
  • Thank you for the early reply, Thomas. I confirmed that the actual slave device is sending data properly. and it's able to get data from it when the simulator is down. Unable to get data when it works with simulator in parallel anyway. Physical topology is bus. The simulator(micro server) was termination device actually. I've tried the actual device to be termination device. but, nothing changed. I guess it's not cause of software and physically something wrong(wiring or something like that)? – Uske Jan 08 '15 at 09:12
  • I found the cause of actual device doesn't reply data. The actual device doesn't work when the simulator is sending continuous bytes of 0x20. The actual device reply data properly when there's no 0x20 in stream. Therefore, I've changed simulator to send one byte of 0x20. But, continuous bytes of 0x20 appear in stream between another response telegram and request telegram. The actual device is actually testing device. I can't confirm where the continuous bytes of 0x20 come from. It might be sent by actual device? Btw, does 0x20 means something special in RS-485 protocol? – Uske Jan 13 '15 at 09:18
  • The RS-485 standard only defines the physical layer. What protocol to use is entirely up to you. – Thomas Stets Jan 13 '15 at 09:23
  • You are right. I think the simulator has another problem. Anyway, Thanks a lot! – Uske Jan 14 '15 at 03:53

0 Answers0