Friday, March 25, 2011

The wide world of LCB's.

Layout Control Buses that is.

As with any efforts to produce standards, particularly open ones, their has been an attrition of projects in recent years. Layout Control Buses for model railroads are not new, but those that exist now are often based on simplistic and not greatly flexible schemes. Possibly the classic is Dr Bruce Chubbs C/MRI which first appeared in Model Railroader magazine in February of 1985. Based on a simple microprocessor module with an RS-485 or RS-422 interface, connected to a PC, the C/MRI system then uses a series of IO expansion cards to connect to pretty much anything. Updated fairly regularly the Chubb designs are now starting to show their age but are still a viable control system. Information and parts can be found at the JLC Enterprises website.

From the ever industrious MERG group in the UK comes Gordon Hopkins RPC system. Of similar vintage and technology to the Chubb system RPC relies on a series of interconnected interface boards. Having the pleasure of meeting Gordon I can only attest to his keen modelling interest and his designs reflect that. However like the Chubb system it is now getting dated, much of the work on it having been done in the late 90's.

In 2007 or so their again emerged from MERG the CBUS system conceived and developed by Mike Bolton in the UK and Gil Fuchs in California. Based on CAN bus this comparatively new system marks the beginning of the new LCB era. General purpose modules, well connected, using something akin to the producer/consumer model of operation. CBUS has a Yahoo Group as well. The boards are based on PIC controllers with CAN bus. The early boards had some issues with ground bounce and offset, but the later 12V board versions are reported to be somewhat more stable. However the practicve of sharing ground and power for the communications and operation power does detract form the stability of larger layouts. CBUS is a credit to its developers and certainly deserves a look.

OpenLCB arrived on the scene also in 2007 but began life in 2005 when I designed a DCC and accessory system that never saw the light of production. Discussions surrounding this approach stimulated Dr. David Harris and myself to explore further and through our acquaintance with Alex Shepherd in New Zealand we started devising what was at first an object oriented network which transitioned to a producer consumer network as we developed. The principal developers for OpenLCB are myself, David Harris, Bob Jacobsen (of J/MRI) and Alex Shepherd. Their is also an active Yahoo Group. Some hardware has been designed and is in use but much OpenLCB development was done on the Silicon Railway LEDuino (which includes CAN bus, DCC decoder input and rudimentary response signalling, LocoNet interface and the usual serial and USB interfaces) and other Arduino type boards. John Plocher has an Arduino model railway shield.

Don Voss proposed an RS-485 based system (as I recall) which he later moved to CAN bus in 2008 or so. Very little data has been published, but what has can be found linked on the largely outdated NMRAnet website as the S9.5 system.

There have been others, but quite honestly the details are rather vague in my mind right now and I would have to dig back into history. I should also say that I am directly involved with OpenLCB, and I have been a part of the NMRAnet community since essentially before it existed!

Tune in again for some technical discussion very soon.

Monday, March 14, 2011

As Time Goes By...

A beautiful song, but should it be appropriate to look back on a post that is nearly two and a half years old (April 2008) and realise that nothing has really changed?

Back then I wrote about the NMRA (National Model Railroad Association) and the various attempts at a model railroad layout control bus (LCB) standards formulation. And as I look back over it all I find that nothing has really changed. The on guy who hijacked the process is still trying to bully other participants to his way of thinking whilst at the same time refusing to expose any of his design work, code, or draft standards. His brother happens to be the corporate officer responsible for the standards and compliance process. What a lovely cozy position to be in.

I meant to post these remarks a few days ago, but they got forgotten. However in light of what I wrote earlier today they remain no less appropriate.

If at first you dont succeed, just wait, they will kick you again!

As of today it seems the news is out. The board did actually consider the matter, and now we know officially. The NMRAnet working group hasn't been told yet, nor have the authors of the document submitted.

NMRANET standard adopted
The board reviewed two versions of S-9.x.1 for the definition of the physical layer of the
layout control bus called NMRANET. The version modified by Didrik Voss, manager of
the Standards & Conformance Dept., was adopted. With this approval, the sponsors for
the other version will be invited to present their concerns to the Board at the Sacramento
meeting. S-9.x.1 was re-designated as S-9.5.1 and will be posted on the NMRA web site.
Several manufacturers of electronics for model railroading have been waiting for this
new NMRA standard so they can adopt it for their product line.

The actual BOD meeting report summary can be found online here.

As well as not being informed even informally about the BOD meeting considerations and vote we have yet to receive our invitation to address the board in Sacramento in July. Let's hope it arrives soon, we need to dust off all the material that we guess wasn't presented to the board in February. But why does it have to be this way?

We don't know in any detail what happened at the BOD meeting, today is the first we know of anything other than the appearance of the S9.5.1 document on the NMRA web site. What is even more galling is that we now know that the NMRA board has sanctioned a document which is a derivative work from material where copyright is claimed by its authors. No permission was sought or granted, no acknowledgement given. It is as though the NMRA feels it is above the provisions of copyright law in the US and Canada (two of the authors are either Canadian or Canadian residents) and the DMCA in the USA. Pretty shabby treatment really when all things are considered.

Back in December 2010 I responded to a help wanted ad placed with Gerry Leone, communications director for the NMRA, for electronics engineers to help with the development of NMRAnet. This request was never sent to the NMRAnet working group list, nor to the DCC working group list. But it was in the NMRA magazine and so I responded. The day after Gerry acknowledged my email I received this response form Di Voss:

You must be the only Electronics Engineer in Canada or, at least, the only one that responds to my help wanted ads.
Since you are already part of the effort, I do not need to provide you a summary of our work.

It seems that my work is to continue to provide soundly based, well argued professional work. Seems that my job is to accept being treated like a mushroom, kept in the dark and fed with .... well, I think you know the answer (at least any self respecting Aussie would). I am to toil diligently in the fields, submit my work, have it used to creative a derivative document without permission or acknowledgement, not be told what the considerations of the material submitted are and to just keep on taking it and liking it.

So disheartening, so disillusioning. No wonder nobody wants to play in the NMRAnet or NMRA-DCC sandboxes any more, if this is how we are to be treated. Onwards and upwards OpenLCB!

Friday, March 4, 2011

Why? He asked...

Would Don want to change the heavily discussed and argued OpenLCB physical layer standard (already voted and accepted within the OpenLCB community) and modify it?

Several of my colleagues at work and elsewhere have been heavily involved with CAN bus for some little time now. So over the last few days a couple of us have used our break time to kick around some ideas in an attempt to figure out why Don was so insistent that these changes be included. All of the comments that I recall related to increasing the number of nodes allowable on a given length network.

Three factors influence the length of the network.

  • The round trip propagation delay between the two most remote nodes.
  • Voltage changes due to the intrinsic resistance of the cable and the Rdiff of the individual receivers
  • Waveform distortion or signal level attenuation due to the effective distributed capacitance of the transmission line.
Cable: The specification as we established it calls for the use of CAT 5e cable, which according to the ISO11801 standard should have nominally 5.7ns/m delay. But this is purely for the cable, it does not include connectors, PCB's with their own intrinsic capacitance and the effects of any common mode chokes or ESD protection devices. Prudent manufacturers may choose to include common mode chokes, ESD clamping diodes or varistors for protection. All of these add capacitance which will increase Vp and reduce the maximum cable length as well as add waveform distortion as alluded to above.

Resistance: We are assuming, that despite their being no explanation of the derivation of the constant in the numerator of the equation, that the VossBros equation assumes a 90 ohm/kilometre resistance. And thats fine, but our concern here is that not only does the VossBros change actually not specify what Ri is, nor does it spell out how that constant was derived. That equation does not appear to take into account any parasitic or stray capacitance introduced by PCBs, connectors, ESD protection or whatever.

Waveforms: Anybody who knows anything about transmission lines knows that rise and fall times are a function of bandwidth. Compromising bandwidth with capacitance means that to get the performance we have to reduce capacitance, which means reducing cable length. If you are to allow users to calculate the maximum network length, or max number of nodes for a given length, then capacitive effects must be taken into account, but in the VossBros documents they are not.

The OpenLCB standard offered to the NMRA (but butchered by VossBros) specified the important maxima, length and number of nodes. Why was that so hard to understand? I have one possible hypothesis. At one point the concept of gateways and bridges was discussed with the S9.5/Voss group. It seems that in their own opinion bridges don't play well with their protocol. Of course we can't offer much more of an opinion because no details of their protocol have ever been published. But that could explain the obsession with maximising the number of nodes. So an S9.5/Voss based LCB could be limited to the 111 or 112 or whatever number of nodes. OpenLCB/S9.6 on the other hand can use bridges and gateways to create much larger LCB's.

Tuesday, March 1, 2011

de Javu all over again.

When I wrote a day or so back about the NMRA process for standardising the very first part of their desired NMRAnet little did I know that a decision had already been made. Of course, the usual dictums of common courtesy seemed to have escaped the NMRA Board of Directors and the Standards and Compliance Manager. The working group was not informed. The authors of the document were not informed. The standard merely appeared at some point. The next line on the index page points to the as yet non-existent technical note.

At least in the version finally published some of the material so offended the Standards department manager was restored. But the sad part is that the changes which remain are just as offensive to the technical community. Even more amusing is that what we have asked for over so many months, something that supports the assertions of Don Voss, still hasn't been supplied, nor is it included either in the standard as published, or in the draft TN (the real one we dont know).

The standard suggests that we can adopt CAN bus yet vary it. I wonder if somebody, like Robert Bosch the inventors of CAN bus, has copyright control! The bastardised CAN bus we are presented with sinmply is not CAN bus. The Voss brothers ask that we accept that CAN bus certification of a component is required, but that an essential CAN bus specification, Rdiff(min), must be >20kohm. But Rdiff(min) is only tested to be >10kohm for CAN bus certification. A transceiver manufacturer may, but is not compelled to, state what Rdiff actually is, or the range that may be encountered.

All of this when they went to such lengths to try and justify this variation using data and application notes designed to sell specific products. By including a formula in the standard for determining the maximum theoretical under ideal conditions network length WHICH INCLUDES Rdiff AS A PARAMETER! Well, they sneakily dont say that, they include 20,000 as a constant. When in reality the maximum langth of the network, under those same conditions (or the maximum number of nodes) could be longer or larger if the original equation from NXP were used and the effective Rdiff left in place. Of course, after FOUR years of discussion it is hard to expect such rigour to be part of the standard isn't it?

Like I said, what did we really expect? Procedural fairness? Honesty and technical integrity? Openess of process and procedure? Well, this is the NMRA after all.