Login
or
Register
Subscriber & Member Login
Login, or register today to interact in our online community, comment on articles, receive our newsletter, manage your account online and more!
Login
Register
Home
»
Model Railroader
»
Forums
»
Electronics and DCC
»
Add 24 hour lighting - May MRR
Edit post
Edit your reply below.
Post Body
Enter your post below.
<p>Kevin,</p><p>The concept is pretty straightforward. The Basic Stamp's output pins can be turned on and off through program commands. The language is quite similar to Basic, with a number of added commands for doing electronic stuff. The program has to be linear, it's not capable of multi-tasking. </p><p>The Stamps output is only about 3V, enough to drive an LED, but not really sufficient for big layout lighting. I route each pin through a ULN2803, a neat and cheap little chip that is powered by a separate 12V source. When a Stamp pin is turned off, the ULN2803 pin it's matched to puts out 12V. (It's negative logic but it works.) The ULN2803 can power as many lights as its power source's can supply.</p><p>So what you do is turn lights on and off in the desired sequence useing timing loops. Even though I have to use some of the Stamp's pins for the dimming (more on that in a minute) I still have 14 separate pins to play with. I created a sequence where, as sunset approaches, some lights start to turn on (inside houses, stores) and then as it gets darker, street lights, security lights etc. Then stores start to close, and finally houses darken as the night grows long. As dawn approaches, house lights start to turn on, security lights off, etc. Then house lights off. All in all, it's pretty cool. I had it operating in our previous house, but don't have it installed yet in our new house (and train room.)</p><p>Now, for the dimming. The Stamp has commands for controling lights using the X-10 technology. There is a plug-in module, PL-513, that accepts a CAT cable and sends the X-10 signals through the house. The layout room lights all have an X-10 control module. </p><p>The program steps through a few dim signals, which lower the lights a bit, pauses, turns on a few lights, then steps down more, etc. It's an experiemental thing, depending on how fast you want the sequence to go. Dimming isn't absolutely smooth, but it isn't jarring either. Dawn is just the opposite, sending signals to increase the lights. The Stamp manual isn't real clear on the use of the X-10 commands, but they do work. It took me a while to figure out that it actually would work.</p><p>Below is a pic of the board. The big push button is what activates it. The Stamp is to the upper left, the two ULN2803's are on the right.</p><p>[img]http://www.ironpeng.com/pics/lightboard.JPG[/img]</p><p>This project is actually what got me started in my mrr business - I make special effects boards using a PIC (which is the actual chip driving the Stamp.) </p><p>Hope this helps.</p><p> Mike Tennent</p>
Tags (Optional)
Tags are keywords that get attached to your post. They are used to categorize your submission and make it easier to search for. To add tags to your post type a tag into the box below and click the "Add Tag" button.
Add Tag
Update Reply
Subscriber & Member Login
Login, or register today to interact in our online community, comment on articles, receive our newsletter, manage your account online and more!
Login
Register
Users Online
There are no community member online
Search the Community
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT
Model Railroader Newsletter
See all
Sign up for our FREE e-newsletter
and get model railroad news in your inbox!
Sign up