Daisy chaining serial devices

gtslabs

Member
I have made an 8 position temperature logger using the 28x1. It uses a serial cable to send the readings to my computer.
I need to have multiple loggers but I only want to tie up 1 com port. So I thought an input and output serial port is needed on each of my logging boards.
I believe I would have to assign each board an address and then send any serial info to the next board in series and do this along the daisy chain until it reaches my com1 port.

So device 1 would send:
SOD,1,T0,T1,T2,T3,T4,T5,T6,T7,EOD

And device “N” would send:
SOD,N,T0,T1,T2,T3,T4,T5,T6,T7,EOD
SOD,N-1,T0,T1,T2,T3,T4,T5,T6,T7,EOD
.....

Perhaps I would need a termination dip switch so the system knew the last device and the closest device to the com1 port would know how much data to expect.
Just thinking out loud. Any ideas on how to do this efficiently?
 

womai

Senior Member
I can see several options. Also do a forum search, such topics have been discussen numerous times (look for e.g. "network").

For receiving (i.e. PC --> Picaxe), you could simply hook up all Picaxe RX inputs in parallel on the PC's transmit line. Then use qualifiers in the serin command to react only to commands for that particular unit. That cuts down processing load on the dataloggers to a minimum.

For output I am assuming each unit only answers when it got a command - that way there will never be two units trying to drive data at the same time: The PC sends a command, waits for the answer, sends the next command, and so on. In this case, again hook up all units in parallel, but with a "diode-OR", i.e. connect the TX output of the Picaxe to a diode, going the the receive line of the PC.


Another option, if you use the inexpensive Rev-Ed USB-to-serial converters you could hook up each datalogger to its very own USB port.

Wolfgang
 

craig008

New Member
the 18x data logger may have some useful information on this, it is not quite the same but does use a qualifier/addressing idea in it, it iwll not send the data until it has received the letter G from the computer, you may have to eleporate a little but its bsically the same idea
________
Subaru Ef Engine History
 
Last edited:
Top