You can give me a hard time if you want, I don’t mind. In fact, I appreciate it. The proof is in the pudding as they say and I have all this working and it suits my needs so I’m quite happy with it.
I call it Xbee, I’m not sure why, it’s the series 1, with the default point to multipoint incarnation in it, no mesh or anything so I guess I just, uh, call it that. Don’t think it really matters much does it? I actually think it’s a silly name but whatever
The servo outs are for servos or ESCs. They both operate the same. Perhaps I wasn’t clear on the diagram. I am using $5, 20amp turnigy ESC from Hobby King. One day I would like to get a live steam locomotive too. I’m not sure how that will work out, I’ve never owned one before, but I would like to use servos to control it if I can. So I keep that option.
Yes, the relay is for switching direction, I am using 8A DPDTs ($3 from mouser). The coil is 5v, I’m switching them with 510 mosfets. I don’t have any problems with them and I get a real satisfying ‘click’ out of them too Not sure why you don’t like them, they are frequently used with other R/C type vehicles but whatever floats your boat.
As far as the decoder, I’m not really interested in anything in it except the sound. If I could get decent sound samples on my own (I’ve tried that route with not much success), I wouldn’t really be interested in it at all. But I can use a cheap Economi HO decoder for that, it will drive a pretty big speaker. Plus for my critters and some other incarnations of ‘vehicles’ I don’t need sound at all.
I’m not sure what you mean by reconcile? Perhaps you are missing the basic premise of what I am doing here. I am deconstructing the DCC stream, manipulating it at the byte level and then re-constructing it at the other end. So I can do anything I want with it. I pull the throttle data from the command, massage it just a bit and use it as a servo/esc output. I pull the direction bit out and use it to flip the relay. I intercept the function commands as well. I can also pass the DCC out verbatim (or altered) to the output stage to drive the decoder sound (and lights if I want) or whatever.
The xbee is in there just to get the data from one place to another without having to worry about the mechanics of getting it there. In fact, all I had to do from my other incarnation of Xbee control was to define another message type and insert the DCC data as the payload. The master did need some custom priority queue routines- I only send data that has changed over the network to keep the speed up. Plus only the Xbee with a particular address gets it’s own traffic, it doesn’t get the entire stream so it’s filtered that way too (although it doesn’t have to be)
I get flack about the Xbee, I don’t know why, I guess they are a bit expensive ($19) but they are industrial strength devices. You can put these little fellows in API mode, disable the network ACK and they scream. There is no ‘sync’ or anything, just power them up, they take a few seconds to find and construct the wireless network and then they just go. I’ve posted timing diagrams before, I’m getting 7ms packet times, that’s not too shabby. I also get a really really good range.
The diagram shows the Prodigy Express. I like the feel and the operation of it (I like knobs), but I don’t like the wire. I don’t like the advertised range of the ‘wireless’ systems either, so I will expand my handheld design for walk around control. The Prodigy is just a source for the DCC commands so I can reverse engineer the stream. I may get an NCE as well, just to see what they do. The prodigy sure spits out a ton of stuff that’s for sure
Actually, in normal circumstances, I don’t really need DCC. As Victor said, it is a pretty old moldy protocol, it’s dense at the packet level but chews up tons of bandwidth the way it’s transmitted. It also looks cobbled together from many revisions. Or something. But everybody and their brother speaks it, and if I want to leverage anything like JMRI or similar into my operations, I think it’s good I speak it on my network too. I didn’t give up any of my other control design, I just leveraged this on top of it, so I can stay very flexible. You are welcome to take a look at my designs and code, they are published on my controlwidgets site.
And, this last part is most important- I love doing this stuff and I am bored. I’m also bored waiting on the turkey so I typed in a long post
Happy Thanksgiving!