News:

Let's find out together what makes a PIC Tick!

Main Menu

How best way ?

Started by Mapo, Dec 03, 2023, 07:06 PM

Previous topic - Next topic

Mapo

Hi, I'm looking for the best way to solve a communication problem.
I have a control board and various display units connected via rs422.
They have been working for years, the control board transmits data at 9600 baud once per second and the displays show everything correctly.
Now I would like to implement a control over how many displays are connected.
On the rs422 the displays are connected in parallel.
I was thinking of sending data from the displays after receiving the data from the control board, but if they are connected in parallel on the RS422 and the firmware is the same for all the displays, a big mess would happen. All displays would transmit together.
So I said to myself, if I read a free pin (not connected, floating) with ADC, the value I read should be different for each display and I can use this "adjusted" value as a delay for sending the response. Obviously before transmitting check if there is already a transmission on the rs422.
Is this the right way? Am I complicating my life?

Thanks

Mapo

John Drew

Hi Mapo,
Do the displays have a local PIC driving them or are they dumb?
What distances?
I don't understand how the 'free' pin is to operate
Cheers
John

tumbleweed

Quoteif I read a free pin (not connected, floating) with ADC, the value I read should be different for each display
It doesn't really work out that way, at least not reliably enough to use as some random number.

In any case you can't tie the RS422 TX outputs of multiple displays together to a single RX in.

Mapo

Quote from: John Drew on Dec 03, 2023, 10:01 PMHi Mapo,
Do the displays have a local PIC driving them or are they dumb?
What distances?
I don't understand how the 'free' pin is to operate
Cheers
John

Hi John,
the displays are driving with pic18f26k80
the distance is about 100/150mt

Quote from: tumbleweed on Dec 03, 2023, 10:14 PMIn any case you can't tie the RS422 TX outputs of multiple displays together to a single RX in.

Hi tumbleweed,
I supposed  :(

thanks for answer

Mapo

JonW

A while ago, I built a similar system for a large digital scoreboard, had one master PCB and the rest were slaves running the same FW and I just addressed each display; it does slow everything down but it is much more robust, and you can then change each display individually. 

John Drew

Hi Mapo,
As you are using separate driver devices then a modification to the code at both ends to use a system as described by Jon.
You would just need to send an address byte along with the data. The micro at the device end then responds or not depending on the address byte.
Cheers
John

RGV250

Hi,
Sort of like Jon & John are pointing to, if you can change to RS485 (which should use the same wiring) you should be able to get a reply from each device individually if you can alter the software.

Bob

Mapo

Thanks again,
now I'll see if I can modify the hardware for the rs485
otherwise I will create custom firmware for each display

Mapo