I am not surprised.

Well this was a fail.

I burned out five of the eight white LEDs when I swapped in the voltage regulator so they’re all in the scrap pile (I’m collecting these now, maybe I can use dead LEDs as light diffusers or something). I tried using some yellow LEDs with resistors this time, and it just went haywire again. More additions to the scrap pile.

I just got a big hint on what the problem is with this method. When I tried powering it up with all of the lights on, everything turned on for a second then shut off completely (the hardwired power indicator and emergency stop button came in handy here). I think it has to do with power budgeting from the 24v supply. I’m already pretty sure the control circuits and the supply to the actual PLC modules are supposed to be separate. I think if I had a separate power source for these LEDs, I wouldn’t be having so many problems.

So now what?

Well, I’ve come to the decision not to go any further with my PLC trainer project. In fact, it’s being downgraded. It’ll pretty much revert to the first generation, more or less what you see in the PLC 101 post but with neater wiring. No more side panel LEDs. No more relay. No more additional output module.

The point of the PLC trainer was to have something physical I can play with to practice my programming on. When I accidentally ended up with extra parts, I wanted to run with it and pile on more into the trainer. It’s had problems and the bandaids were adding up. I’ve promised myself I will not pour any more money into this project. If I were to estimate, everything that has been purchased for the project is around $400. That’s way too much and I’ve been so distracted by upgrading the hardware that I’ve barely practiced programming on it. I don’t want to say I regret building this thing, but I wish I was more rational with my decisions for it.

Some day, I’d like to use it in a practical project or downsize even further, using small lights and toggle switches and buttons. Or sell the parts off. Whatever happens first.

So the PLC trainer isn’t exactly dead. I will be posting my practice programs whenever I get around to making a new one. The last one I worked on, but did not complete, was a mixing tank process but it relied on the side panel LEDs so…

Stay tuned for more. Thanks for reading!


Step down, please.

So as I explained in the last PLC trainer post, I used a voltage divider circuit to step down 24v to 5v to power the white LEDs. There were obvious current issues with that as one LED refused to light up when another one was on. The row of LEDs would also fade as more of them went on at the same time. I swapped out the voltage divider for a voltage regulator.

First, let me disconnect and get the area ready. Bye bye sketchy voltage divider circuit:


And a hello to my voltage regulator:


In my research on these voltage regulators, people were saying that their input of 12v (seems to be a common voltage for people’s applications) cause it to get significantly hot. Being my paranoid self, I’ve strapped two of these heat sink pieces to increase the surface area, hoping it will be sufficient since I’ll be putting 24v into it. I haven’t had it on long enough for it to get hot yet, but if what people are saying is as drastic as it sounds, I can’t imagine how hot the maximum 35v input must make it.

I’ve also used the LM317 (adjustable voltage regulator) in a school lab (I think that was the hilariously poorly written lab that made everyone burn a resistor, like it actually went poof in a small cloud of smoke). I didn’t think there was a point in using that since there were these (7805C, BTW) that would get me my 5v without any hassle.

Floating wires are a huge no no, but I figured it was alright for this quick picture, and there’s always the emergency stop button. Anyways, the test was a success and I am not on fire:

IMG_20130803_235546The moment of truth will come a little later as I have yet to connect it with the PLC and LEDs. Stay tuned.

[Re]wired up!

I hop from one project to another, so I do some work on the trainer and then not touch it for weeks. I finally felt it was time to rewire the panel because it was just a disaster. I used a smaller gauge wire solid core wire this time. The first time, I used a larger gauge because I had never really worked with any more than 12 volts and was paranoid something was going to happen. I checked the ratings of this wire and it’s just fine. The result was so much cleaner:



For that Arduino project that ended up selling, it was originally designed to use my PLC parts. Plans were changed so I was left with a couple of extra goodies. My trainer now has a proximity sensor…


… And an additional output module. I wired up 8 white 5mm LEDs. I know it’s horrible, but I used a voltage divider to step down 24v to 5v. (This is what my next modification will be.)

There was an issue with the new white LEDs. Whenever there was multiple white LEDs on, the second white LED would fade to almost off. I figure it’s probably a power issue with my sketchy voltage divider. At that point, I took the second white LED offline and connected it to a relay I picked up:

I did a video of all of the features just prior to getting the relay:

So as I mentioned, I’ll be working on that voltage divider crap I did. I’ll cover the progress here and hopefully all goes well. Stay tuned and thanks for reading!