Don't worry about the flashers, the family comes before play time. I wish him well and hope he makes a full recovery.
|
Don't worry about the flashers, the family comes before play time. I wish him well and hope he makes a full recovery.
Dear rtr12
I hope that the family is well now.
Dear All
I went out and purchase the Arduino cook book and Uno R3 started broad. Since the hobby is going into electronics more and more all the time I figured the now was a good time to start. This will be my first independent project after I learned how to use the Uno R3 board.
Once you get the Arduino working, here's what you need for the project board. $4.39 and free shipping. It loads with the mini-USB and is small enough to embed in rolling stock or locomotives.
In looking, here's one even cheaper with no cable, no big loss, $2.97
Thanks for the kind words, he's home (yesterday afternoon) and doing better. May not be for long, but he is home where he wants to be. He refused further treatment (open heart surgery among other things). At 86, I would be doing the same thing he is. From my experience with others I have known, intervention like this at this age usually makes things worse and the end result is the same, possibly much sooner too.
Now I need to go order some of these latest gadgets just posted...
Here are the revised flasher drawings. I think 10k was satisfactory for the trim pot. That seemed pretty slow to me. If anyone wants it slower, they can use something larger.
If you order any trimmer pots, make double sure you check the number of turns needed for full scale. Some are 20 turns and some are 220 degrees (don't ask how I know that).
Here is some Arduino code for the Knight Rider Flasher. 330 ohm resistors were used for the LEDs.
/* Knight Rider Flasher Operates LED's in Sequence as in the Knight Rider car in the TV Show
This example code is in the public domain. */
// Pin 13 has an LED connected on most Arduino boards.
// give it a name:
int redledA = 8;
int redledB = 9;
int redledC = 10;
int redledD = 11;
int redledE = 12;
int redledF = 13;
// the setup routine runs once when you press reset:
void setup() {
// initialize the digital pin as an output.
pinMode(redledA, OUTPUT);
pinMode(redledB, OUTPUT);
pinMode(redledC, OUTPUT);
pinMode(redledD, OUTPUT);
pinMode(redledE, OUTPUT);
pinMode(redledF, OUTPUT);
}
// the loop routine runs over and over again forever:
void loop() {
// Flash LED 1
digitalWrite(redledA, HIGH); // turn on red LED 1 (HIGH is voltage level)
digitalWrite(redledB, LOW); // turn off red LED 2 turn off other LED's by making voltage LOW
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(150); // redled 1 for 150 miliseconds (1000 miliseconds = 1 second)
// Flash LED 2
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, HIGH); // turn on red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 2 for 75 miliseconds
// Flash LED 3
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, HIGH); // turn on red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 3 for 75 miliseconds
// Flash LED 4
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, HIGH); // turn on red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 4 for 75 miliseconds
// Flash LED 5
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, HIGH); // turn on red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 5 for 75 miliseconds
// Flash LED 6
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, HIGH); // turn on red LED 6
delay(150); // redled 6 for 150 miliseconds
// Flash LED 5 - Reverse Direction
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, HIGH); // turn on red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 5 for 75 miliseconds
// Flash LED 4
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, HIGH); // turn on red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 4 for 75 miliseconds
// Flash LED 3
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, LOW); // turn off red LED 2
digitalWrite(redledC, HIGH); // turn on red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 3 for 75 miliseconds
// Flash LED 2
digitalWrite(redledA, LOW); // turn off red LED 1
digitalWrite(redledB, HIGH); // turn on red LED 2
digitalWrite(redledC, LOW); // turn off red LED 3
digitalWrite(redledD, LOW); // turn off red LED 4
digitalWrite(redledE, LOW); // turn off red LED 5
digitalWrite(redledF, LOW); // turn off red LED 6
delay(75); // redled 2 for 75 miliseconds
// Flash LED 1 Go Back to Top - ReStart
}
HI rtr12
Sorry to hear about the father in law. I hope is is resting comfortably and in good spirits.
Dear rtr12
Thanks for the code. I just got the Arduino starter kit yesterday and I am going to start playing with it.
Dear John
Thanks for the information about the Arduino nano. I ordered one of them and I am waiting for it to arrive.
Thanks, I was just over there this morning, my wife is staying with him until Thursday when her sister relieves her. He is doing pretty good for his condition. The hospital got us in touch with Hospice and they are great, got all the stuff he needs, hospital bed, walker, oxygen, etc. They make it all very easy. They really are a lot of help during times like this.
Let me know if those Arduino projects work out for you. They are pretty basic. The Arduino is a lot easier than using all the IC's and component parts, at least for me anyway. There is a whole lot more you can do with the Arduino than what I have posted here.
Dear rtr12
My mother in law turned 65 last July 4th. Two weeks later she was not feeling well and three months later she had passed on of cancer. It is a tough time on the whole family. We were shocked because she was so young. We are still grieving over her passing. So I know how hard it can be on everyone. My mother in law lived in Europe and they did not has Hospice like they do here.
That was pretty fast and she was still pretty young at only 65, that would be much harder to deal with especially when it was so unexpected. Takes a long time to get over that, it's a big adjustment for everyone. Cancer can be bad too, I hope she didn't suffer with it. I am kind of surprised that Europe doesn't have something like Hospice? I thought they were way ahead of us in many things and that sure would have been one of them. Hospice is a great organization if you ever need them, I have been really impressed with them.
My father-in-law has had this condition for a few years now and he is much older, so this wasn't totally unexpected. Fortunately for him, (and the family) he has been getting around quite well up until they started trying to repair him recently. That has only made things worse.
Dear rtr12
In something Europe is ahead of us but not the whole of Europe. We were making arrangement for her to go to Hospice but there was a waiting list. I is still hard to believe that she is gone.
Kind of surprised about the waiting list too? Unfortunately it will just take a long time to make the adjustments of losing a loved one so suddenly. One has to do a lot of mental processing. My grandmother died at age 87 in 1976 and out of all my family members that are gone (including my parents), I still think about her the most.
One thing the Europeans are ahead of us on is passenger trains. I bet that would really be something to see over there. I have never been there, wanted to go when I was younger. I travelled a lot for work (4 state area around where we live), now that I'm retired I no longer want to travel since I don't have to.
I made that suggestion to slow down the eBay 555+4017 module for a traffic-light application. Aren't you using this for the Knight-Rider where the lights advance more quickly?
I suggest you apply power to the module as-is and see if the LEDs advance at a suitable speed for what your want. It appears that you have some speed adjustment with the on-board trimpot.
As for mods, for the Knight-Rider don't you want the lights sweeping back and forth? To get this effect you probably need to add some diodes after the 4017 as shown in the schematics earlier in this thread.
Dear Stan
Never mind I goofed. I am building a new Knight Rider circuit from scratch based on rtr12 design. I tried the Chinese part and did not like the way it looked and worked.
Dear rtr12
Was the February 15, 2015 9:40 PM posting of the design the final out come or was there a final revision? I already ordered the parts I was missing from Digikey. I realy want to get this project going. As Gunrunnerjohn stated "stop designing and start build it" more or less.
I believe it is with one exception. The only other change that was made (I think) was making the 500k ohm pot a 10k ohm pot per GRJ's later suggestions. I fiddles with that a little more and came up with the 10k ohm pot being a smaller range that is probably all that would be needed. The 500k ohm pot will work, it is just a bit larger range than is actually needed as GRJ pointed out. It was also all I had at the time. I will post the revised schematic here.
I believe the traffic signal schematic is correct with stan2004's suggestion of the opto- coupler relay added. I will post my current schematic of that one also just in case. Since Stan's post and the schematic revision I ordered some of the opto-couplers, but I have not tried them with this circuit and crossing gates yet.
Whatever works for you, but out of curiosity what about how it looks and works don't you like.
In any event, not that anyone else on OGR has expressed interest but I see you can also buy an un-assembled kit. This makes it a lot easier to modify the circuit to perform the traffic-light or Knight-Rider circuits since you don't have to remove tiny surface-mount components...you just don't install them in the first place!
Dear Stan
The original item for $1.27 just did not work correctly and I just gave up. I did see the other that you are suggesting. But I do not have the knowledge base you have. I will also value your expert knowledge and wisdom on this topic. I will give the new design a try and see what happens. Could you modify this design for traffic lights as well or do you suggest something else?
Kris, could you be more specific on what you mean by it not working correctly?
I see there are dozens of eBay sellers offering these modules, and while I do NOT have one myself these have been sold for a while so I've got to believe they work!
I believe you can save time using either version (assembled or kit) to build either traffic signal or Knight Rider....relative to wiring up the parts from scratch. If the eBay boards are defective or just plain wrong then all bets are off of course. But if they perform as described, the are easily modified to match what rtr12 shows in his pdf schematics.
Don't suppose you have a reference number for the kits (my email is in my profile)? The idea of having a PCB already made is too good to pass up (plus I can't resist these things). Also, I don't think you can buy just the parts alone for the kit price either? We also need to compare their schematic to the one we have been working on here...just to see how they did of course.
I found this youtube of the eBay module with how I'd think it works. Yours does not do this? The speed should be adjustable with the trimpot.
I sometimes have trouble embedding youtube so here's the link:
The problem may be that it only goes in one direction, doesn't oscillate? I have a couple of the pre-made ones above, but I don't remember exactly how they worked (been a while)? I'll hook one up and see.
Here's a sample, it is uni-directional and not bi-directional.
Search "555 4017" on eBay and you'll see the assembled (about $1.27) and kit (about $1.52) versions with free shipping for both.
I understand what you're saying about one-direction. But what I'm saying is the eBay module replaces the "core" timing (555 chip) and sequencing (4017 chip) functions. The "magic" of both applications is done with diodes (1N4148 in your schematic). To get the oscillating back-and-forth sweeping of Knight-Rider, you use the right hand part of the schematic (outside the box). To get the longer red/green timing vs. shorter yellow timing of the traffic signal, you use the right hand part of the schematic (outside the box).
I don't know the range of timing the eBay modules provide using the trimpot control so I suspect for the traffic signals you may need to change the timing capacitor. The eBay module also does not have an attachment point to force/hold the sequencing that you are considering for the opto-isolator but with the kit version it's easy to simply bend the relevant pin on the 4017 chip to attach the Reset signal (with capacitor/resistor)...or cut a printed-wire trace on the board itself to patch in the Reset signal.
Dear Stan
Here what I mean the POT does not work correctly, either damage in transit or before. It does work as a waterfall as you stated. It does not work in my scheme because the length of the board is wider than the flat car, it will hit on coming train traffic with a board that long. I was hoping that would fit but for a dollar 1.27 all is not lost. If you do not try you will never know or learn anything. The new idea is to place all the electronics in box car for the MP player by the sliding door. The electronics for the Led circuit (Knight Rider)will go in the nose of the box car. There will be two tethers one from the Caboose powering the box car and all the electronics. The other tether would power the led (Knight Rider) on the flat car. It just got to crowd in the caboose with AC/DC buck, IR remote, its own led lighting, RED, led roof lights and red side led. It looked like NYC subway car at rush hour. The box car will have the MP player, amp, speaker, DC/DC step up for the Knight Rider circuit. It is better to fail and try again then never tried at all. It is all part of the learning curve. Thank you for your patients, guidance and advise.
Thanks, Stan. I was also thinking that having the kit would allow some easier modifications if needed. All those tiny little electronic gizmos on the one I have in the video are really tiny, and pretty small too.
I think having the PCB would be a big plus though, or at least a good start at putting something together and modifying to suit one's needs as you suggest. Thank you for the search, I am going to order a few as soon as I find them.
If you want to learn a new skill, you can have a custom circuit board with all the stuff on it for $36.
I use DipTrace to generate circuit boards, it is a schematic capture and board layout package that's free for small boards. You can order small quantities of boards, basically about 15 square inches total, for $36 shipped. The smaller the board, the more you get for the price. Ordering my 1.1 x 1.2" Super-Chuffer boards when I was prototyping them, I used to get 10-12 boards on the prototype order. For the 1.1" x 2" sound board I'm working on, I got eight boards for the $36.
Here what I mean the POT does not work correctly, either damage in transit or before.
I'm assuming once you set the POT value (speed of waterfall) you won't change it. That said, didn't you buy a resistor kit with dozen of values? You could experiment by simply putting the 2 leads of a resistor into circuit-board holes of the POT until you find a suitable speed and then just solder that resistor in place of the POT. Obviously you could just buy another POT - that looks like a standard component though I don't know the DigiKey number.
It does work as a waterfall as you stated. length of the board is wider than the flat car, it will hit on coming train traffic with a board that long.
I though the car lights are mounted in the grille? I don't understand why you need to mount the board that way? I always assumed the electronics would be mounted under the flat-car and wires (7 or so) run to an LED assembly under the hood. Can you post a photo of the model car showing how you plan to mount the row of LEDs?
The new idea is to place all the electronics in box car for the MP player by the sliding door. The electronics for the Led circuit (Knight Rider)will go in the nose of the box car. There will be two tethers one from the Caboose powering the box car and all the electronics. The other tether would power the led (Knight Rider) on the flat car.
If you run a tether from the box-car to the flat-car with the LED signals this would make for a somewhat clumsy 7+ wire tether; obviously this can be done but I figured you could just run a 2-wire tether that only has DC power to the waterfall electronics circuit board.
The box car will have the MP player, amp, speaker, DC/DC step up for the Knight Rider circuit.
Did you try running the waterfall circuit board at JUST 5V DC? I realize rtr12's schematic shows 9V but it should operate at 5V too. The circuit only powers one Red LED at a time and a Red LED only takes about 2V. With modern Red LEDs you don't need much current to lots of light - as stated earlier I figured you have to mount the Red LEDs separately from the circuit board so you'd need to choose and possibly buy them separately based on what would fit in the car rather than hacking up the car to fit 3mm LEDs. In other words, I'm not sure you need the DC/DC stepup module so you could just tether 5V to the flat-car.
I was also thinking that having the kit would allow some easier modifications if needed.
Right. In the case of the kit version, several things become easier if you start with the bare-board and loose parts.
1. It comes with a socket for the 4017 IC chip. The board is also "single-sided" meaning there are printed-wires only on one side. This means you could bend pin 15 of the socket so that it doesn't go thru the hole. This allows you to attach the optoisolator reset signal...and still have the ability to plug-in/take-out the IC chip.
2. No matter if used for Knight-Rider or the traffic signal, the circuit board has resistors on each 4017 output. In the schematics these resistors are not used. Instead diodes are in their place. So the same holes can be used to mount the 1N4148 diodes (100 for 99 cents on eBay with free shipping). This is an amazing coincidence. So the kit version means you don't have to bother removing resistors which in the case of the tiny surface mount parts can be a bother.
3. No matter if Knight-Rider or traffic-signal I don't think you want the LEDs mounted on the circuit board. Hence by having the kit version you just don't install them which of course means you don't have the hassle of removing them from the assembled version. And now the LED holes on the circuit board become convenient solder points to attach the wires to go to the external LEDs.
In both circuits it also appears to need a few external resistors (those shown outside the boxes in my earlier post).
I just tried the light board in the video I posted above and it works from about 2.2-2.3 vdc to 12 vdc (didn't try any higher than that). The only thing is the flash rate (waterfall) goes faster at 12 vdc at the slowest setting. As would probably be expected with increased voltage.
I have ordered a bunch of the kits and although I have some diodes, I took advantage of one of the 100 packs too. There was a different kit with the PCB laid out a little differently that I got a few of also (can one ever have too many of these things?)
And Although it's probably over my head, I am going to look at GRJ's PCB layout and design program he posted above. I think that would be neat to be able to do, just in case I ever learn enough to actually make something on my own. Probably won't happen, but as the saying goes, even a blind hog gets a piece of corn every now and then.
rtr12, are you building both the Knight-Rider and the traffic-signal projects? I'm getting myself confused on who is doing what and don't want to send you off on a wild-goose chase! That is, I know Kris has a MP3 sound module for his Knight-Rider and it's going on rolling stock so what I suggest for his application may not apply to yours.
If you're doing the traffic light I'm pretty sure you want to replace the 1uF capacitor supplied with the kit with a 10uF capacitor since the lights change every so many seconds rather than several times per second in the Knight Rider. This value difference is shown in your schematics but again if you are starting with the assembled waterfall board it may not be obvious since the capacitor is one of those surface mount parts too small to have its value printed on it.
Hi Stan
It can get really confusing very fast. The victim for the Knight Rider is a Hotwheels 1:43 scale car. I can not open the hood, I was thinking of putting the led lights under the car in the front. The Chinese waterfall will not fit under the car. See attached photos. From Rtr12 circuit it stated need a 9 volts DC but you say I use 5 VDC I will try it out and see if it works. It make sense to use less wiring with sound engineering.
rtr12, are you building both the Knight-Rider and the traffic-signal projects? I'm getting myself confused on who is doing what and don't want to send you off on a wild-goose chase! That is, I know Kris has a MP3 sound module for his Knight-Rider and it's going on rolling stock so what I suggest for his application may not apply to yours.
If you're doing the traffic light I'm pretty sure you want to replace the 1uF capacitor supplied with the kit with a 10uF capacitor since the lights change every so many seconds rather than several times per second in the Knight Rider. This value difference is shown in your schematics but again if you are starting with the assembled waterfall board it may not be obvious since the capacitor is one of those surface mount parts too small to have its value printed on it.
Sorry, I didn't mean to confuse. My writing is not always the best either, I confuse myself sometimes when re-reading things I have previously written a day or two before. The old brain goes faster than the fingers and it also abbreviates and skips a lot.
I am just getting the kits for experimenting and possible future use. I have some needs and ideas that are far from well defined like Kris's are. I am also interested in the mp3 stuff you all are working on, but I am just following along on that one, trying not to get in the way. Some of the things you and GRJ were talking about in his sound player thread were way above my pay grade.
As you stated earlier, the fact that the kits have the PCB really opens up a lot of possibilities for different things when I finally pin them down. I will probably try to make at least one of each in a few weeks when the kits arrive. I got plenty of kits just in case there is an oops somewhere during construction.
I really like fiddling with all this stuff and learn something with each new post from you and GRJ and some of the other electronics folks here. I think some of it is actually starting to stick and even make sense too.
I really do appreciate all the help you guys offer here too.
Kris, I really think Stan was suggesting that you not try to stuff the board under the hood, but rather remote the board and run wires to a smaller LED array, probably constructed from either small LED's or perhaps using fiber optic cable.
Hi Stan
It can get really confusing very fast. The victim for the Knight Rider is a Hotwheels 1:43 scale car. I can not open the hood, I was thinking of putting the led lights under the car in the front. The Chinese waterfall will not fit under the car. See attached photos. From Rtr12 circuit it stated need a 9 volts DC but you say I use 5 VDC I will try it out and see if it works. It make sense to use less wiring with sound engineering.
Hi Kris,
I did try the waterfall in your picture above at 2.2 or 2.3 vdc to 12 vdc and it worked throughout the range. I only tried it for Stan as he mentioned it should work at 5 volts in a post above and also said in an even earlier post that he didn't have one. Just trying to help out there.
I haven't tried other voltages on the other schematics above. To be honest I never even thought to try different voltages with any of them. Stan can tell by looking at the circuit (he knows what he is doing), without having to try it like I would. I can't tell by looking. Trial and error is my method for a lot of these things, unless someone here helps me with it.
Kris, how is the model assembled? I see that these go for $50 so I'd understand the reluctance to perform surgery. But it seems like the interior is molded plastic and hence at some point the chassis of the car was separate from the body. It looks like the hood was cast as part of the body so that's no fun. But it looks like the red light grille is a piece of plastic snapped in place after the fact? In other words, what I'm thinking is you can separate the body (shell) from the chassis and access the space behind the red grille. You may not be able to fit a small LED board (just the LEDs) but as GRJ notes you might be able to run a bundle of 6 fiber optic strands to driven by 6 LEDs placed below the flat car. As GRJ says I was assuming you could mount the circuit board in whatever orientation needed to fit on the flat car. The LEDs would be mounted separately (either under the hood if space is available) or elsewhere with fiber optic strands relaying the light up to the front grille.
So I guess my question is whether you are willing/able to separate the body from the under-chassis. And if so, what does the space look like behind the light grille.
Dear gentlemen
Thank you for your suggestions. I never even though of using fiber optic cable. I will take a look at car/model and see what is the story, pictures to follow shortly. Thanks again for all the help and suggestions.
Background on the picture taking, the three old though it was my toy and want me to share it so he could play with it. Also the wife saw the suggested retail price and gave me a dirty look I will never forget. I had a Lucy moment had a lot of explaining to do with both them. So if the pictures come slowly you know why.
Dear Gentlemen
Here are the picture you have requested. The bottom of the car comes off with two screws. However the grill where the led should go is made of metal. There is no plastic to hook up the leds. It is space molded in the car body and painted red. Also there is a stud mount in the same area where the led should go. Any suggestion would greatly appreciated.
The solid metal grille makes it a challenge. Do you have tools to drill/grind such small parts? I see Aoshima made a 1:43 diecast Knight Rider that comes with an LED scanner. Over $100 so kind of pricey but perhaps you can make inquiries and someone has posted interior photos of how they did it - might give you some ideas. A simple web search amazed me on level of interest in these models including the LED scanner; in other words I'd think there are others out there who tackled the exact problem you're facing perhaps on a car-modeling forum? Here's a youtube I found showing the Aoshima LED scanner in action:
Access to this requires an OGR Forum Supporting Membership