Sunday, February 21, 2021

Arduino Power Supply Issues and Other Things

On Friday after some later than usual meetings, I headed over to George’s shop to inspect his level crossing display setup.  I tested it and after two of three activations, it went psycho.  I thought the Arduino was going to need to be flashed with the code again.   It was like it was going and doing things which it cannot do in the code.  On my way home I stopped off at Jaycar and picked up a lot of red, yellow and green LEDs and a packet of resistors for some lights assemblies I was going to make later this evening.

That evening Darren and I went to Geoff’s for a modelling night.  That started after 5:00pm.  I was working on cutting out some doors on my Kyogle Station building.  I also was working on a sleeper wall for Border Loop after I saw a photo on one of the Facebook sites for NSW railways.  I also had a plan to put two red LEDs together to form some cheap level crossing signals.  I soldered up two of these.  I then soldered up the red, yellow and green LED’s into a set of traffic lights and I made three of these.  I also took with me, my test level crossing track for some testing.  I plugged this into a power supply and it too also seemed to be operating strangely.  I could not believe that this too was having issues.  It got me thinking.

So on Saturday morning, I plugged my laptop into the Arduino on the test level crossing setup via a USB cable, and it worked perfectly.  Hang on – something is not right.  If I plug a power supply in via the 2.1mm plug, it goes weird.  So I am thinking that the power supply must be not getting a large enough load, and it is not operating within its specified tolerances.  It was supposed to be a 12V power supply.  Arduino can take a 12V power supply and actual supposedly can take up to a 20V input.  But I'd expect that it might run a bit hot.

So later that morning I went to George’s shop again, and plugged my laptop in via USB and everything worked perfectly.  I plugged the power supply via the 2.1mm plug and after two runs, it went weird.  I think I’m onto something here.  We will need a USB power supply for George's shop layout.

So on Saturday afternoon, I wired up my two level crossing lights to my test level crossing display setup and it works 100% if not connected via the 2.1mm power plug.  I can even plug a 9V battery into the Arduino and it works well.  Although I’m not certain how long a 9V battery will drive the Arduino and the level crossing setup for, before it runs out of juice.

The next task was to connect two sets of home made traffic lights up to another Arduino on a different test module.  So after dinner I flashed a new Arduino with my traffic lights code and plugged it in with 2 of my three traffic lights connected and it worked.  I came back to this project later on in the evening and added the third set of traffic lights to the Arduino.  Just like a bought one.  All ready for a future NMRA clinic day to show off.

On Sunday around lunchtime I started by watching the Dave Abeles operations - rail fanning session streamed from his basement to Facebook.  He also ha a set of level crossing gates mis-behaving at least 3 times in his session.  But his version is on two di-directional tracks.  My version only does a single bi-directional tracks or two uni-directions tracks (i.e. up and down).

This afternoon I made a sleeper stack for Border Loop and added some rails to my sleeper retaining wall also for Border Loop.  I have yet to install this wall - maybe next week.  I also have started preparing for a signalman's house that I will install also in Border Loop and I'm also looking at all the various items to be positioned around this house.  So planning will continue next week.

No comments:

Post a Comment