After some (many) hours of sane sleeping and two meals, my brain did accepted a clear jump start, again.
Despite I wasn't able to find any schematic for the Single Relay Board (#27115) at product's page, based on its description (Single-Relay-Board-Guide-v1.0.pdf) and the fact that it has a transistor (base connected to Signal input???), used to control relay coil, I'm almost sure its Signal input can be safelly controled by a 3.3V Prop pin, while being regularly fed by a +5V, at +Supply.
So, if my interpretation can be confirmed by yourself, or someone else (with a sound knowledge about using #27115), by re-routing the +Supply connection to +5V, you can spare ~85mA of current consumption/waste from the 3.3V regulator.
Another thought: in order to avoid lefting some (dangerous, from the rest of the circuit standpoint) residual charge at C2 (50V, 6800uF), if and when something goes haywire, IMHO, it's wiser to mount a ~1K bleeding resistor, in parallel with its terminals (alternativelly, ~820R + red led). Proof of concept: at the (R + Led)-circuit, you can tweak the series resistor value a little bit, to ensure the led lits off, just a little BEFOREat the same time PAB's power leds goes off, when FS1 or FS2 are removed.
Despite I wasn't able to find any schematic for the Single Relay Board (#27115) at product's page, based on its description (Single-Relay-Board-Guide-v1.0.pdf) and the fact that it has a transistor (base connected to Signal input???), used to control relay coil, I'm almost sure its Signal input can be safely controlled by a 3.3V Prop pin, while being regularly fed by a +5V, at +Supply.
So, if my interpretation can be confirmed by yourself, or someone else (with a sound knowledge about using #27115), by re-routing the +Supply connection to +5V, you can spare ~85mA of current consumption/waste from the 3.3V regulator.
The parallax relay works great with 5v on the side that is controlled (I use it to power my 5v LGB smoker in my smoke stack, and it pulls around 200ma)
I control it with the prop pin, and power the relay control logic with 3.3v. It works fine.
I think you are saying hook it to 5v instead of 3.3, I could do that, but the 5v still pulls the juice from the PAB.
No real way to win here unless I install an external 5v regulator on the motor supply cap,
but then I am potentially making an easy short to motor voltage through that relay transistor,
I will just have to deal with it pulling the PAB power.
If this becomes a real issue, I will just wire up the engine wheel pickups also.
Another thought: in order to avoid lefting some (dangerous, from the rest of the circuit standpoint) residual charge at C2 (50V, 6800uF), if and when something goes haywire, IMHO, it's wiser to mount a ~1K bleeding resistor, in parallel with its terminals (alternativelly, ~820R + red led). Proof of concept: at the (R + Led)-circuit, you can tweak the series resistor value a little bit, to ensure the led lits off, just a little BEFOREat the same time PAB's power leds goes off, when FS1 or FS2 are removed.
Sure putting a bleed resistor on the caps might be a good idea.
I have had the engine under test all day, even in the hot sun, and it performed perfectly, it does need some rubber on the wheels, the wheel slip is off the charts!
IMHO you're killing the boards with your capacitance overkill. Just adding capacitance because you can doesn't make a good design!
I didn't do it just because I can, have you ever used an engine on a dcc track? (with all the dirt, momentary shorts, rail gaps, switches, crossings, crossovers, etc)
Keep in mind im feeding the entire PAB board with those caps, the PAB board has multiple regulators on it, misc chips, a2d, d2a, usb, leds, A ESP wifi etc...
That esp needs those caps, have you ever had an ESP on a breadboard and didn't put fairly large caps near its supply. drops like mad.
Do you mean this about the SUPERCAPS? or the 6800uf cap and the 2200uf cap?
I wouldn't say my design is good at all, what in this world is? (lol) oh sorry.
Both.
Without doing any calcs or a close look at the circuit, it is quite unusual to require anything more than 1000uF unless you’re keeping a circuit such as an RTC running without power.
So this is a generalised comment. There may very well be a valid reason, but with the discussion I’ve skimmed i would think it very unlikely. You’re much more likely to cause problems with the discharge when the power is removed.
Computer power supplies of 40-50 years ago needed 100,000uF but they were delivering 100A or more.
So this is a generalised comment. There may very well be a valid reason, but with the discussion I’ve skimmed i would think it very unlikely. You’re much more likely to cause problems with the discharge when the power is removed.
I see, in many circuits, its not needed (generalized)....
They actually sell supercap addons to use with DCC decoders.
They are a needed addition, they advertise them to be used with sound decoders mostly. https://www.digitrax.com/products/power-xtenders/
(i cut one of the power extenders open, and they have supercaps, like 6 of them (2.7v) in series to match 14v)
I did disconnect the supercaps for now, if you look at the schematic.
They are very common. The switches really cause issues with power.. (and reverse loops)
The wheels cause momentary SHORTS between the two rails, no resistance shorts. AMPS of power disappear from the track rails. (for very short periods)
Even with multiple wheel pickups, it won't help, because the entire track is shorted.
DCC is one of the most abusive things you can design electronics for. It does start to become a nightmare.
"I think you are saying hook it to 5v instead of 3.3, I could do that, but the 5v still pulls the juice from the PAB."
From the PAB +5V: yes. But, then, you will be also sparing the 3.3V regulator output (and the logic it feds, P1 included) from any chance of damage, in case the diode, that "tries to rule out" flyback pulses coming from relay coil de-energisation, starts to malfunction, during its lifetime.
in case the diode, that "tries to rule out" flyback pulses coming from relay coil de-energisation, starts to malfunction, during its lifetime.
Hmm, that could be ok i guess. Probably a good suggestion... I would think Q1 would fail before that big old diode?
I will add a 3.6v tvs on the propeller supply just in case, and more tvs for the other powers.
I also added TVS diodes due to all these motor coils, relay coils, SMOKER (no idea if its inductive, it is a HEATER) and what not, not to mention rail voltage spikes from who knows what....
Was that an UN-intentional "gecko's tail", left behind?
It IS! DARNIT!!!! Now I gotta fix that and do another re-upload. lol..
Thanks for pointing that out. That was before I decided what to use in place of some odd ball resistor value, I later chose two 470ohm resistors in series because that value is common and two of them are above the 1/4 watt minimum needed for 940ohm at 16v @ 0.272 watt, I don't want heater resistors!
Thanks, you have a sharp eye! I miss stuff staring at the same thing for a while... it all starts to blend...
If I need to use opto isolators on all the motor pins, I will need this larger breadboard, lol, but that won't fit in my tender...
I could really use a long breadboard like that. That's a great idea. I don't know why I've never thought about a long breadboard. I want to test a circuit with a minimum of 16 optoisolators. I've stacked boards side by side but never end to end.
You can just remove the small one on the activity board, its only held down by sticky foam tape, which is good so it can be inspected for holes or damage from years of use.
I think you would only need to remove ONE of the power strip bars on each side to fit it nicely.
I think they come with foam tape already on the bottom, but you may want a piece of cardboard or thin balsa wood under the part that sticks out, the foam can easily be pushed out when you put in a wire or part, also with some rubber feet on the end, its very awkward.
Interestingly, I have not needed the SUPERCAPS at all.
The 6800uf cap and the 2200uf PAB cap have worked fine, however I do not have complicated trackwork, and don't have any ZONES. I am powering the entire track with 13.8v DC.
I have yet to try out DCC (i don't have a command station anymore... )
My next goals will be to code the A2D feedback from the current on the motor drive, and show it on the webpage. (i keep saying im going to do this, lol)
And another next goal is to connect the RFID reader below the tender and place some tags along the track.
Then push the tag output to the web page for testing of its reliability to detect the tags at max speed.
I can then install a RR CROSSING (with lights and arms, which I will need to make out of wood(that will take some time to sand and whittle the wood), i don't own a 3d printer (is there ever enough money?)
The arms operated by the Parallax Standard SERVO and another propeller chip connected via WIFI.
The RFID tags can trigger the arms and lights when the train approaches the crossing, and it will need a bell, which means a amplifier and speaker.
( i guess another full rotation servo could operate a REAL bell, hmm, need to look into that), but this one can have the propchip also play the sound since its only one wave file repeated (a rr crossing bell).
So the circuit will be similar to the tender circuit minus the motor board, it will be powered from the track.
I will need to connect all wifi devices to a private WIFI router at that point due to having 3 wifi devices, which is easily done, plus its all password protected wifi interfaces then.
And since its OUTDOORS, I will need to put it all in a water tight box that is dug partly into the ground.
(The real bell could be outside if the axle of the servo can be run out a hole in the box, that would be good reason for a real bell, (speakers and water not good), unless i get a marine speaker)
I updated the schematics to remove that extra resistor!
(great idle sound, good chuff, car wheel clacks, good clean RR crossing bell sound )
I will need to contact some of these authors for sound clip permission.
(so i can include the clips with the audio prop)
They even have typical circuits in the datasheet.
Looks like digikey doesn't have them, unless you want to buy 1,000 of them.
Other sites have them tho.
To have a more exciting layout that has steeper grade, I have epoxied rubber bands onto the rear wheels of the engine.
I have yet to find out how well this works, the epoxy needs to dry, and I don't know how well it will do in bonding to metal, perhaps good enough.
I don't expect it to bond perfectly, and I don't want it to, so I can replace the rubber if it gets worn.
I have fat black rubber bands that were sitting around, so i cut them in half to sit on the flat part of the wheels.
I made sure to not get any excess epoxy or overlapping rubber on the flange because in MODEL railroading the flange is what keeps the train on the track.
In real full size railroads, the flat side of the wheel is tapered, that along with the weight of the engine and rail cars are what keep the trains on the track.
Many do not know the wheel flange is only there for safety and if it were the main thing that keeps a train on the track, it would wear out and need to constantly be replaced.
ALL HAIL FEYNMANN
In model railroading, the weight is not enough to keep them on the tracks, so the flange is required, but does not wear out that bad because models are not that heavy.
In real steam engines, the reason they don't need rubber on their wheels is because they have a kind of "fictitious" measurement called Tractive_force. https://en.wikipedia.org/wiki/Tractive_force
Basically they increase the weight of the locomotive so much that its metal on metal wheels on rail, don't slip that much.
I will test it later today when the epoxy has bonded a bit more. You may want to put TAPE over the wheel hub so you don't get epoxy on it like I did, i will need to clean that off later.
I could also take advantage of the Tractive Force with my g-scale engine and put some weights in the engine empty spaces, I may do that if this doesn't work good enough.
This engine does have some pretty large empty spaces in its body
Well, that didn't work. Eventually one of the rubber bands came off the wheel, AND it still didn't have enough weight to pull all the cars over a modest grade.
But it did show promise at first, it pulled MUCH more weight than ever, and the wheels didn't slip.
It even looked like I may need to up the track voltage to 16v to get any kind of speed out of the engine with the weight of cars.
Perhaps I didn't wait long enough for the epoxy to bond (it is 1 minute epoxy and I waited a few hours.)
I probably need different epoxy. I do see that the engine will need some serious weights to do any good.
Time to visit the fishing section of the local store for some cheap metal weights.
The rubber came off the epoxy, and left all the epoxy on the metal wheel... I guess rubber needs a special epoxy.
I also found a problem with grades, going DOWN a grade causes the engine to speed up, with all the car weight behind it, which isn't good, it gets out of control and can/will derail.
Now is the time to start dealing with complicated PID loops, ARGH! I am not looking forward to that. (just kiddin, you know we all love them)
So now I need to get the axle sensor working properly, the metal flap method is just not good at all,, sooo much bounce.,
That with the current feedback from the motor board and the pwm output to the motor board will help determine if the engine is starting to coast.
I have a color PAL, but I would need to drill a hole in the cast metal to use it, not ideal, and I am not sure if it can sense very fast.
I have a Piezo Film Vibra Tab, but thinking about making that work, gives me the idea that there will be too much play between the bend forward and backward.
Any thoughts on axle rotation sensor? I could mount multiple magnets on the inside of the wheel for better accuracy with the hall effect sensor.
I don't want to use a reed switch, that has BOUNCE,..,, no bounce, no play..... (I duddits)
To fit the LGB 5v smoker inside the smokestack I had to CAREFULLY drill out the smokestack with a 3/8th Inch drill bit.
I drilled a little bit, and checked for any holes in the outside to be sure I was not off-center. Once I achieved the depth I wanted, I stopped.
I allowed the 5v LGB smoker to stick out of the smokestack by a small amount so the gold trim and black color still shows a little bit.
I like how it looks. You can see it slightly sticking out in the attached picture.
BTW, I am not posting all this here to annoy anyone (sorry if it is annoying you), this is so if anyone wants to do this also with a G-scale Bachmann 2-6-0 steam engine.
(they are one of the cheapest steam engines in G-scale available)
This engine needs lots of TLC to get it up to a level that is decent. It is worth it though, because most steam engines for G-Scale are around $999-1,600 and even higher. https://www.amazon.com/Bachmann-Industries-North-Woods-Logger/dp/B00NUA2Y42
I actually may purchase another set just for the engine and cars, so i can have a double header!
And a double header might fix my grade issues. (i will have to wait till christmas on that one probably, hehe)
Then I will need to change the number on the second engine to 2.
I also installed a Luxeon Z Royal Blue (LXZ1-PR01) led in the REAR light of the tender. I used a 220ohm resistor and it looks bright enough.
(but i wouldn't recommend using the luxeon Z's they are TOO SMALL to solder (unless you can solder smt soic pitch leads), use a REBEL instead, even then the rebel pads are quite small) https://www.digikey.com/product-detail/en/lumileds/LXZ1-PR01/1416-1058-1-ND/
And in the front light I installed a Luxeon Rebel AMBER led, I used a 10ohm resistor to get the brightness I wanted, and it pulls around 25ma. (the prop can handle 40 ma) https://www.digikey.com/product-detail/en/lumileds/LXM2-PL01-0000/1416-1027-1-ND
I could probably use NO resistor, or 2 ohm or 1 ohm to get the most brightness out of it at 3.3v but I didn't want to risk such low resistance.
If I need more brightness, I will use a Solid State Relay with 5v and the proper resistor.
But both look pretty bright in full daylight, so in dusk, dawn, or at night, they should be excellent.
To get the leds out of the housing, you need to push the back of the led, through the wire hole, with a small tipped screwdriver till the lens and reflector pops out.
I really want more lighting in the CAB of the engine, and the firebox, so I am thinking about putting a propeller (and the motor drive) in the engine.
To control the motor, headlight, axle sensor, smoker, cab light, and firebox flickering light...
And possibly even some smoke stack leds to help accentuate the smoke(give it a hot ember look)
(i would put some luxeon Z leds in the space between the lgb smoker and the drilled out smokestack.)
As I get closer to making a sound prop I may do this since the activity board is too big to also put an amp into the tender.
I don't know what I am going to do, for now I will keep the activity board in the tender.
The more features I add, the more I need multiple props to handle it all.
I really don't want to run a bunch of wires between the engine and tender, that is kinda ugly.
And since I need to add a second prop anyway for the sound and need an amp board, its looking like I am getting closer to a revamp of the entire setup.
If I do that I will start a new schematic, and possibly call it v2.0 and put it all in a new thread.
For now I will continue with the activity board, and run extra wires for anything more so I can finish out this thread.
You know you have crammed a threads first post with content when you run out of characters.
I guess that means this thread could be considered a complete (enough) project and can be put into the "Customer Projects" forum category.
It is propeller related, but it involves more than just the propeller.
Feel free to move it moderator(s).
Postedit: Just checked and the P1 prop has an internal series resistance calculated to be 27 ohm, not 22 ohm. So, the calculations below will need to be re-done.
@clockloop,
You need to understand basic electronics to design LED circuits. I’m on an iPad so cannot draw this out so bear with me.
An LED will drop voltage across it. The specs will tell you if it’s 1v8, 2v2, 3v2 etc. Reds usually have the lowest drop. An LED will only pass current one way (for a normal LED).
From the prop we have either a 3v3 or GND supply in series with ~22 ohm ( IIRC Tubular calculated this years ago when we working out VGA and composite video resistors - need to check when I get home) (internal pin resistance Ri) to the pin.
Now connect a series resistor (Rs) and the LED to the opposite polarity of the prop pin when driving, respectively GND or 3v3.
Take prop driving LED from a high (LED to GND):
Circuit is now 3v3 to Ri=22R to Rs to LED (Vl) to GND.
If Vl (LED voltage drop from specs) is eg 2v2 then we have
E = I * R
E = 3V3 - 2v2 = 1v1
I = 20mA = 20 / 1000 (select the current for requirements - assumed 20mA but superbright LEDs might allow down to 1mA)
R = 22 + Rs (Rs to be calculated)
Rs = E / I = 1.1 / 20 / 1000 = 55 ohm
This calculation works the same for when the prop drives low GND and LED is connected to 3V3.
This is all well and good when the LED voltage is ~2v2 or less. But the problem arises if it’s around 3v - 3v2 (or even 2v7). Here there is insufficient voltage for the resistance calculation to work reliably. Let’s take a quick look...
E = 3v3 - 3v2 = 0.1v
Rs = 0.1 / 20 / 1000 = 5 ohm
BUT if the power supply varies by just 0.1v more...
E = 3v4 - 3v2 = 0.2v
And with 5 ohm we get
I = E / Rs = 0.2 / 5 = 40mA
You can now see the LED brightness can vary a lot depending on just the power supply variation!!! And it won’t take much to destroy the prop pin or LED by operating out of spec.
How do we avoid this? Quite simply.
Use the prop driving low (GND) and connect the LED to 5V instead of 3v3. This is fine since the LED will drop more than 1v7.
Now we can recalculate
E = 5V - Vled
And therefore calculate the series resistor value which will not vary current much when the power supply etc varies.
@"Clock Loop" - This is supposed to be the Parallax forum, isn't it? We have all tried to help but it seems you are more interested in having a long rant and in the process disrespecting the very ones who know how to help and have been patiently trying to help you.
Calm down before you derail. If you ask for help then be genuine about it or else just go off and do it all your own way and tell us all about it when you're done. It'll be a good read no matter which way it turns out.
. . . Since I don't understand basic electronics, lets have the entire forum take bets on the time frame the prop pin.... dies?
Or if you like better, bets on the led death time frame?
Any takers?"
[/quote]
The truth is, you really are a loser, spending your time with toy trains, placing tedious posts on a cutting-edge electronic forum at the same time professing to know nothing about basic electronics.
. . . *runs away*
. . . (if you aren't laughing so hard that you are crying right now, then you better be crying)
*turns pc off entirely, closes door to office, puts sign up on door that says,
DO NOT ENTER, BY ORDER OF FIRE MARSHAL*
[/quote]
Comments
A := B := C := 0
to zero all three
Mike
After some (many) hours of sane sleeping and two meals, my brain did accepted a clear jump start, again.
Despite I wasn't able to find any schematic for the Single Relay Board (#27115) at product's page, based on its description (Single-Relay-Board-Guide-v1.0.pdf) and the fact that it has a transistor (base connected to Signal input???), used to control relay coil, I'm almost sure its Signal input can be safelly controled by a 3.3V Prop pin, while being regularly fed by a +5V, at +Supply.
So, if my interpretation can be confirmed by yourself, or someone else (with a sound knowledge about using #27115), by re-routing the +Supply connection to +5V, you can spare ~85mA of current consumption/waste from the 3.3V regulator.
Another thought: in order to avoid lefting some (dangerous, from the rest of the circuit standpoint) residual charge at C2 (50V, 6800uF), if and when something goes haywire, IMHO, it's wiser to mount a ~1K bleeding resistor, in parallel with its terminals (alternativelly, ~820R + red led). Proof of concept: at the (R + Led)-circuit, you can tweak the series resistor value a little bit, to ensure the led lits off, just a little BEFORE at the same time PAB's power leds goes off, when FS1 or FS2 are removed.
https://digikey.com/en/resources/conversion-calculators/conversion-calculator-capacitor-safety-discharge
I control it with the prop pin, and power the relay control logic with 3.3v. It works fine.
I think you are saying hook it to 5v instead of 3.3, I could do that, but the 5v still pulls the juice from the PAB.
No real way to win here unless I install an external 5v regulator on the motor supply cap,
but then I am potentially making an easy short to motor voltage through that relay transistor,
I will just have to deal with it pulling the PAB power.
If this becomes a real issue, I will just wire up the engine wheel pickups also.
Sure putting a bleed resistor on the caps might be a good idea.
I have had the engine under test all day, even in the hot sun, and it performed perfectly, it does need some rubber on the wheels, the wheel slip is off the charts!
I didn't do it just because I can, have you ever used an engine on a dcc track? (with all the dirt, momentary shorts, rail gaps, switches, crossings, crossovers, etc)
Keep in mind im feeding the entire PAB board with those caps, the PAB board has multiple regulators on it, misc chips, a2d, d2a, usb, leds, A ESP wifi etc...
That esp needs those caps, have you ever had an ESP on a breadboard and didn't put fairly large caps near its supply. drops like mad.
Do you mean this about the SUPERCAPS? or the 6800uf cap and the 2200uf cap?
I wouldn't say my design is good at all, what in this world is? (lol) oh sorry.
Gotta stay optimistic.
Without doing any calcs or a close look at the circuit, it is quite unusual to require anything more than 1000uF unless you’re keeping a circuit such as an RTC running without power.
So this is a generalised comment. There may very well be a valid reason, but with the discussion I’ve skimmed i would think it very unlikely. You’re much more likely to cause problems with the discharge when the power is removed.
Computer power supplies of 40-50 years ago needed 100,000uF but they were delivering 100A or more.
They actually sell supercap addons to use with DCC decoders.
They are a needed addition, they advertise them to be used with sound decoders mostly.
https://www.digitrax.com/products/power-xtenders/
(i cut one of the power extenders open, and they have supercaps, like 6 of them (2.7v) in series to match 14v)
I did disconnect the supercaps for now, if you look at the schematic.
You can read about supercaps (large caps) use in DCC.
https://www.edn.com/supercaps-solve-diverse-niche-problems/
https://rajeshkovvuri.wordpress.com/2012/04/23/esu-dcc-decoder-supercaps/
https://www.dcctrainautomation.co.uk/youchoos-supercapacitor-17000uf-15v.html
https://www.newrailwaymodellers.co.uk/Forums/viewtopic.php?t=48840
They are very common. The switches really cause issues with power.. (and reverse loops)
The wheels cause momentary SHORTS between the two rails, no resistance shorts. AMPS of power disappear from the track rails. (for very short periods)
Even with multiple wheel pickups, it won't help, because the entire track is shorted.
DCC is one of the most abusive things you can design electronics for. It does start to become a nightmare.
Im sure I will fry this prop chip 5 more times, "500 miles before the day is done"
Kind of a revival of a long time unused part of my mind...
Thank you, so much!
From the PAB +5V: yes. But, then, you will be also sparing the 3.3V regulator output (and the logic it feds, P1 included) from any chance of damage, in case the diode, that "tries to rule out" flyback pulses coming from relay coil de-energisation, starts to malfunction, during its lifetime.
Hmm, that could be ok i guess. Probably a good suggestion... I would think Q1 would fail before that big old diode?
I will add a 3.6v tvs on the propeller supply just in case, and more tvs for the other powers.
I also added TVS diodes due to all these motor coils, relay coils, SMOKER (no idea if its inductive, it is a HEATER) and what not, not to mention rail voltage spikes from who knows what....
Now I just need to order the TVS parts.
https://forums.parallax.com/discussion/download/131941/Railroad-Engine-Controller.jpg
https://forums.parallax.com/discussion/download/131942/Railroad-Engine-Controller.pdf
I solely doesn't understood the objective of R8 (750R), paralleling the series associationf (R11 + R10 = 940R). This gives an equivalent ~417R.
Was that an intentional "gecko's tail", left behind?
It IS! DARNIT!!!! Now I gotta fix that and do another re-upload. lol..
Thanks for pointing that out. That was before I decided what to use in place of some odd ball resistor value, I later chose two 470ohm resistors in series because that value is common and two of them are above the 1/4 watt minimum needed for 940ohm at 16v @ 0.272 watt, I don't want heater resistors!
Thanks, you have a sharp eye! I miss stuff staring at the same thing for a while... it all starts to blend...
I could really use a long breadboard like that. That's a great idea. I don't know why I've never thought about a long breadboard. I want to test a circuit with a minimum of 16 optoisolators. I've stacked boards side by side but never end to end.
That is actually a breadboard from jameco,
https://www.jameco.com/z/WBU-202-R-830-Point-Solderless-Breadboard-6-5-x-2-125-_20723.html
but parallax has the same thing for half the price.
https://www.parallax.com/product/700-00078
You can just remove the small one on the activity board, its only held down by sticky foam tape, which is good so it can be inspected for holes or damage from years of use.
I think you would only need to remove ONE of the power strip bars on each side to fit it nicely.
I think they come with foam tape already on the bottom, but you may want a piece of cardboard or thin balsa wood under the part that sticks out, the foam can easily be pushed out when you put in a wire or part, also with some rubber feet on the end, its very awkward.
The 6800uf cap and the 2200uf PAB cap have worked fine, however I do not have complicated trackwork, and don't have any ZONES. I am powering the entire track with 13.8v DC.
I have yet to try out DCC (i don't have a command station anymore... )
My next goals will be to code the A2D feedback from the current on the motor drive, and show it on the webpage. (i keep saying im going to do this, lol)
And another next goal is to connect the RFID reader below the tender and place some tags along the track.
Then push the tag output to the web page for testing of its reliability to detect the tags at max speed.
I can then install a RR CROSSING (with lights and arms, which I will need to make out of wood(that will take some time to sand and whittle the wood), i don't own a 3d printer (is there ever enough money?)
The arms operated by the Parallax Standard SERVO and another propeller chip connected via WIFI.
The RFID tags can trigger the arms and lights when the train approaches the crossing, and it will need a bell, which means a amplifier and speaker.
( i guess another full rotation servo could operate a REAL bell, hmm, need to look into that), but this one can have the propchip also play the sound since its only one wave file repeated (a rr crossing bell).
So the circuit will be similar to the tender circuit minus the motor board, it will be powered from the track.
I will need to connect all wifi devices to a private WIFI router at that point due to having 3 wifi devices, which is easily done, plus its all password protected wifi interfaces then.
And since its OUTDOORS, I will need to put it all in a water tight box that is dug partly into the ground.
(The real bell could be outside if the axle of the servo can be run out a hole in the box, that would be good reason for a real bell, (speakers and water not good), unless i get a marine speaker)
I updated the schematics to remove that extra resistor!
https://forums.parallax.com/discussion/download/131966/Railroad-Engine-Controller.pdf
https://forums.parallax.com/discussion/download/131965/Railroad-Engine-Controller.jpg
https://forums.parallax.com/discussion/download/131973/GardenRR7.jpg
https://forums.parallax.com/discussion/download/131974/GardenRR11.jpg
This Northwoods Logger is a 2-6-0 steam engine.
Gonna need some audio clips.
(some ok chuffs)
(kinda noisy)
(great idle sound, good chuff, car wheel clacks, good clean RR crossing bell sound )
I will need to contact some of these authors for sound clip permission.
(so i can include the clips with the audio prop)
Im looking at using a KA2209 chip amp circuit.
https://www.digikey.com/product-detail/en/stmicroelectronics/TDA2822/497-3956-5-ND/715873
https://media.digikey.com/pdf/Data Sheets/ST Microelectronics PDFS/TDA2822.pdf
They even have typical circuits in the datasheet.
Looks like digikey doesn't have them, unless you want to buy 1,000 of them.
Other sites have them tho.
I have yet to find out how well this works, the epoxy needs to dry, and I don't know how well it will do in bonding to metal, perhaps good enough.
I don't expect it to bond perfectly, and I don't want it to, so I can replace the rubber if it gets worn.
I have fat black rubber bands that were sitting around, so i cut them in half to sit on the flat part of the wheels.
I made sure to not get any excess epoxy or overlapping rubber on the flange because in MODEL railroading the flange is what keeps the train on the track.
In real full size railroads, the flat side of the wheel is tapered, that along with the weight of the engine and rail cars are what keep the trains on the track.
Many do not know the wheel flange is only there for safety and if it were the main thing that keeps a train on the track, it would wear out and need to constantly be replaced.
ALL HAIL FEYNMANN
In model railroading, the weight is not enough to keep them on the tracks, so the flange is required, but does not wear out that bad because models are not that heavy.
In real steam engines, the reason they don't need rubber on their wheels is because they have a kind of "fictitious" measurement called Tractive_force.
https://en.wikipedia.org/wiki/Tractive_force
Basically they increase the weight of the locomotive so much that its metal on metal wheels on rail, don't slip that much.
I will test it later today when the epoxy has bonded a bit more. You may want to put TAPE over the wheel hub so you don't get epoxy on it like I did, i will need to clean that off later.
I could also take advantage of the Tractive Force with my g-scale engine and put some weights in the engine empty spaces, I may do that if this doesn't work good enough.
This engine does have some pretty large empty spaces in its body
But it did show promise at first, it pulled MUCH more weight than ever, and the wheels didn't slip.
It even looked like I may need to up the track voltage to 16v to get any kind of speed out of the engine with the weight of cars.
Perhaps I didn't wait long enough for the epoxy to bond (it is 1 minute epoxy and I waited a few hours.)
I probably need different epoxy. I do see that the engine will need some serious weights to do any good.
Time to visit the fishing section of the local store for some cheap metal weights.
The rubber came off the epoxy, and left all the epoxy on the metal wheel... I guess rubber needs a special epoxy.
I also found a problem with grades, going DOWN a grade causes the engine to speed up, with all the car weight behind it, which isn't good, it gets out of control and can/will derail.
Now is the time to start dealing with complicated PID loops, ARGH! I am not looking forward to that. (just kiddin, you know we all love them)
So now I need to get the axle sensor working properly, the metal flap method is just not good at all,, sooo much bounce.,
That with the current feedback from the motor board and the pwm output to the motor board will help determine if the engine is starting to coast.
I have a color PAL, but I would need to drill a hole in the cast metal to use it, not ideal, and I am not sure if it can sense very fast.
I have a Piezo Film Vibra Tab, but thinking about making that work, gives me the idea that there will be too much play between the bend forward and backward.
I was thinking of using a Melexis 90217 Hall-Effect Sensor and a small neodymium magnet.
https://www.parallax.com/product/605-00005
Any thoughts on axle rotation sensor? I could mount multiple magnets on the inside of the wheel for better accuracy with the hall effect sensor.
I don't want to use a reed switch, that has BOUNCE,..,, no bounce, no play..... (I duddits)
I drilled a little bit, and checked for any holes in the outside to be sure I was not off-center. Once I achieved the depth I wanted, I stopped.
I allowed the 5v LGB smoker to stick out of the smokestack by a small amount so the gold trim and black color still shows a little bit.
I like how it looks. You can see it slightly sticking out in the attached picture.
BTW, I am not posting all this here to annoy anyone (sorry if it is annoying you), this is so if anyone wants to do this also with a G-scale Bachmann 2-6-0 steam engine.
(they are one of the cheapest steam engines in G-scale available)
This engine needs lots of TLC to get it up to a level that is decent. It is worth it though, because most steam engines for G-Scale are around $999-1,600 and even higher.
https://www.amazon.com/Bachmann-Industries-North-Woods-Logger/dp/B00NUA2Y42
I actually may purchase another set just for the engine and cars, so i can have a double header!
And a double header might fix my grade issues. (i will have to wait till christmas on that one probably, hehe)
Then I will need to change the number on the second engine to 2.
I also installed a Luxeon Z Royal Blue (LXZ1-PR01) led in the REAR light of the tender. I used a 220ohm resistor and it looks bright enough.
(but i wouldn't recommend using the luxeon Z's they are TOO SMALL to solder (unless you can solder smt soic pitch leads), use a REBEL instead, even then the rebel pads are quite small)
https://www.digikey.com/product-detail/en/lumileds/LXZ1-PR01/1416-1058-1-ND/
And in the front light I installed a Luxeon Rebel AMBER led, I used a 10ohm resistor to get the brightness I wanted, and it pulls around 25ma. (the prop can handle 40 ma)
https://www.digikey.com/product-detail/en/lumileds/LXM2-PL01-0000/1416-1027-1-ND
I could probably use NO resistor, or 2 ohm or 1 ohm to get the most brightness out of it at 3.3v but I didn't want to risk such low resistance.
If I need more brightness, I will use a Solid State Relay with 5v and the proper resistor.
But both look pretty bright in full daylight, so in dusk, dawn, or at night, they should be excellent.
To get the leds out of the housing, you need to push the back of the led, through the wire hole, with a small tipped screwdriver till the lens and reflector pops out.
I really want more lighting in the CAB of the engine, and the firebox, so I am thinking about putting a propeller (and the motor drive) in the engine.
To control the motor, headlight, axle sensor, smoker, cab light, and firebox flickering light...
And possibly even some smoke stack leds to help accentuate the smoke(give it a hot ember look)
(i would put some luxeon Z leds in the space between the lgb smoker and the drilled out smokestack.)
As I get closer to making a sound prop I may do this since the activity board is too big to also put an amp into the tender.
I don't know what I am going to do, for now I will keep the activity board in the tender.
The more features I add, the more I need multiple props to handle it all.
I really don't want to run a bunch of wires between the engine and tender, that is kinda ugly.
And since I need to add a second prop anyway for the sound and need an amp board, its looking like I am getting closer to a revamp of the entire setup.
If I do that I will start a new schematic, and possibly call it v2.0 and put it all in a new thread.
For now I will continue with the activity board, and run extra wires for anything more so I can finish out this thread.
You know you have crammed a threads first post with content when you run out of characters.
I guess that means this thread could be considered a complete (enough) project and can be put into the "Customer Projects" forum category.
It is propeller related, but it involves more than just the propeller.
Feel free to move it moderator(s).
@clockloop,
You need to understand basic electronics to design LED circuits. I’m on an iPad so cannot draw this out so bear with me.
An LED will drop voltage across it. The specs will tell you if it’s 1v8, 2v2, 3v2 etc. Reds usually have the lowest drop. An LED will only pass current one way (for a normal LED).
From the prop we have either a 3v3 or GND supply in series with ~22 ohm ( IIRC Tubular calculated this years ago when we working out VGA and composite video resistors - need to check when I get home) (internal pin resistance Ri) to the pin.
Now connect a series resistor (Rs) and the LED to the opposite polarity of the prop pin when driving, respectively GND or 3v3.
Take prop driving LED from a high (LED to GND):
Circuit is now 3v3 to Ri=22R to Rs to LED (Vl) to GND.
If Vl (LED voltage drop from specs) is eg 2v2 then we have
E = I * R
E = 3V3 - 2v2 = 1v1
I = 20mA = 20 / 1000 (select the current for requirements - assumed 20mA but superbright LEDs might allow down to 1mA)
R = 22 + Rs (Rs to be calculated)
Rs = E / I = 1.1 / 20 / 1000 = 55 ohm
This calculation works the same for when the prop drives low GND and LED is connected to 3V3.
This is all well and good when the LED voltage is ~2v2 or less. But the problem arises if it’s around 3v - 3v2 (or even 2v7). Here there is insufficient voltage for the resistance calculation to work reliably. Let’s take a quick look...
E = 3v3 - 3v2 = 0.1v
Rs = 0.1 / 20 / 1000 = 5 ohm
BUT if the power supply varies by just 0.1v more...
E = 3v4 - 3v2 = 0.2v
And with 5 ohm we get
I = E / Rs = 0.2 / 5 = 40mA
You can now see the LED brightness can vary a lot depending on just the power supply variation!!! And it won’t take much to destroy the prop pin or LED by operating out of spec.
How do we avoid this? Quite simply.
Use the prop driving low (GND) and connect the LED to 5V instead of 3v3. This is fine since the LED will drop more than 1v7.
Now we can recalculate
E = 5V - Vled
And therefore calculate the series resistor value which will not vary current much when the power supply etc varies.
:P
BTW I didn't have access to specs at the time as I was out.
Calm down before you derail. If you ask for help then be genuine about it or else just go off and do it all your own way and tell us all about it when you're done. It'll be a good read no matter which way it turns out.
Hey Clockloop, you really need to get some manners.
You submit long rambling over-hyped posts and you are boorish and rude to other forum members.
Samples in your own words . . . Since I don't understand basic electronics, lets have the entire forum take bets on the time frame the prop pin.... dies?
Or if you like better, bets on the led death time frame?
Any takers?"
[/quote]
The truth is, you really are a loser, spending your time with toy trains, placing tedious posts on a cutting-edge electronic forum at the same time professing to know nothing about basic electronics.
Response in your own words . . . *runs away*
. . . (if you aren't laughing so hard that you are crying right now, then you better be crying)
*turns pc off entirely, closes door to office, puts sign up on door that says,
DO NOT ENTER, BY ORDER OF FIRE MARSHAL*
[/quote]