Wayne Roderick, 3rd Division, PNR, NMRA (life)
12/01/04 rev 11/13/2008
Bruce Chubbs Computer/Model Railroad Interface, C/MRI, is a total system of control for everything on your model railroad except the locomotives on the track. When I chose to adopt it for the Teton Short Lines Layout Control Bus (LCB), I was faced with a couple of challenges because our computer system DOES process CAB control prior to handing it off the the EasyDCC system and we run a slave PC to provide the MFJ Yardmaster with some control and monitoring. These two aberations would have to be retained and integrated with C/MRI. C/MRI hardware is shown in MAGENTA. The rest is carry-over from our home-built system.
The simple fix would be to purchase an extension card for the computer that would give us two more serial ports but that was rejected because it immediatly killed the concept a generic IBM standard PC.
The Teton Short Line called upon the old semi-retired designer of the CAB BUSS (me) to build an interface that would look like C/MRI INPUT & OUTPUT cards. Not being that smart with PICS and micros, he used some RAM and TTL to link the two systems. Two circuit cards, one to read the CAB BUS, store the data and hand it off to C/MRI when polled. The second card accepts data from C/MRI, stores it and pokes it out onto the CAB BUS at the proper time. We're not posting the schematic because, I supect, that very few would be interested. If you are so inclined, just ask.
The Yardmasters PC has live graphic display very similiar to the dispatchers display He can, control mainline switches in APB mode, and DCC setup capability. The result is that one person can run the Teton Short Line from Malfunction Junction. The remote PC has all the brains we need to emulate a C/MRI SUSIC, so a little software massaging and use of another C/MRI RS232/485 interface took care of that.
There is one little bugaboo that has to be addressed. The C/MRI RS232/485 convertor was intended for the HOST computer. It's SEND line is always connected sourcing a HIGH or LOW.
The RECEIVE input is expecting only one SUSIC or SMINI to connect and transmit when polled. At other times, the SUSIC/SMINI goes into a tri-state mode where it simply is not connected to the line.
When we use the economical converter for a remote PC, there is no way to make it get off the line while SUSIC/SMINIs transmit, so we have the classic case of bus contention. Surprisingly, it's real easy to fix. A simple modification and another wire from the remote PC serial port and we can tell it to go tri-state when not sending. Here is the fix:
Done, now just add these two lines to your Port access routine
OUT Port + 4, 3 'DTR & RTS is on Port=address of the port
'send your data and when done:
OUT Port + 4, 0 'DTR & RTS is off. Interface is now tri-state
With those two challenges met, I made the ancient TSL INPUT/OUTPUT cards interface with the C/MRI SUSIC. I integrated Bruce Chubbs I/O software with ours and we're up and running again.
The Teton Short Line like most home layouts continues to evolve and the hybrid LCB/CMRI bus is part of that evolution. We've brought other devices unique to our needs onto the bus. The staging yards, formerly using there own processor, now ride the bus as we simplify and standardize to the CMRI protocol. Under developement is a device I'm calling the SMICRO @, a very limited I/O card with only a byte or two of I/O for an occasional local situation, that does not justify adding another SMINI or SUSIC. The SMICRO will be cheap but not be rugged like Chubbs CMRI hardware and not for the timid i.e goof and you blow it! When I'm comfortable with it, I'll post some DIY info on this site. Like the rest of the TSL circuitry, nothing is for sale and it goes into the public domain, however, I claim the copyright to the term SMICRO as used with the TSL's LCB and CMRI system. 11/13/2008
A HAPPY UNION
One other observation: The marriage of two publicly documented systems, CVPs EasyDCC and Chubbs C/MRI, via the common computer is a beautiful union. A few days ago, I decided a very simple cab would be useful for the Staging yards, freeing up one of the more complex ones. One hour later it was up an running! Read about the Ultra Simple Cab-3
Teton Short Line Home Page