Skip to main content

Reply to "TMCC Control With Arduino"

"Hi Charlie,

I am pretty much an expert when it comes to the TMCC and Legacy command structure since I am a Lionel LCS Partner who has been writing software for years.  I also have many years of Hex experience.  I can help you out if you want."

********************

Hi Harvey,

I'm glad for the chance to talk to a Legacy command expert.  I'd like to program my Arduino to send serial commands to the Legacy base to blow a diesel horn, or a steam whistle, in a prescribed pattern -- such as long, long, short, long for a grade crossing.  Yet the Legacy "blow horn" command (command 28) gives a very short toot and that's it.

The only solution I've been able to think of is to send a constant stream of "blow horn" commands, every n milliseconds.  However that timing, and the length of the blow, seems to be a little different for each loco.  I did a little testing and the whistle sounded choppy -- sometimes it sounded okay and other times it would stutter.

At worst, I could come up with the maximum delay between "blow" commands that sounds okay, and just spray out hundreds of commands.  But this is complicated by the fact that my Arduino is busy doing a lot of other things, including sending commands to several other locos concurrently, and abiding by a rule suggested by Prof Chaos that transmit bursts should be separated by at least 30ms (and sent in triplicate, which isn't a problem in this case.)

And if I have two or three engines that want to blow their horns at the same time...ugh.  There must be a better way, isn't there?

Have you figured out a way to do this, or does your software rely on the Legacy's built-in record option?

If you're using the brute-force method (per above) kindly share any details such as the delay between subsequent "blow" commands to keep it sounding, and the delay between subsequent any-kind-of commands.  Maybe I'm sending my "blow" commands too rapidly rather than too slowly...???  What is the minimum delay between serial bursts to the Legacy base, in your experience?

Thanks!

Randy

OGR Publishing, Inc., 1310 Eastside Centre Ct, Suite 6, Mountain Home, AR 72653
800-980-OGRR (6477)
www.ogaugerr.com

×
×
×
×
×