• Welcome to 009 Society Members Forum.

Arduino Projects

Started by Neil McGrath, November 29, 2018, 21:36

Previous topic - Next topic

Dave Cooper

Hi Graeme - thanks for the reply.

I'm thinking that I might get the incline working 'mechanically' to start with using a simple motor /gearbox drive, battery-powered and controlled by a DPDT switch plus a couple of limit switches at either end of the line.

The Arduino would then automate the switch positions under program control. That's the theory anyway. As always, the devil is in the detail ! Do you know what power supply the Arduino needs ? It would be nice to be able to choose between 'manual' and 'computer' control without complicating the wiring too much.       
"High Water" Diorama ("Dŵr Uchel")
- the inveterate tinkerer

Graeme Dunbar

#16
Hi Dave,

Power supply options are pretty flexible -

1. for learning and development work it can be powered through the USB cable used to programme and communicate with it.
2. it has an on-board voltage regulator that tolerates quite a wide range of DC supply. Many Starter Kits come with a PP3 battery clip. A 9 V or 12 V "wall wart" mains adaptor is ideal. It has the commonly found barrel connector compatible with wall warts.
3. (more for experienced users) an external regulated 5 V supply can be applied directly to the board.

I introduce my students to programming and interfacing by giving each one (for a returnable deposit) a kit very much like this:
https://www.banggood.com/Basic-Starter-Kit-UNO-R3-Mini-Breadboard-LED-Jumper-Wire-Button-For-Arduino-With-Box-p-1161006.html?rmmds=search&cur_warehouse=CN

Less expensive kits are available as are much more expensive "Christmas present" style ones.
https://www.robotshop.com/uk/arduino-starter-kit.html?gclid=Cj0KCQiAk-7jBRD9ARIsAEy8mh7GsHsDDJUdVRh5x7RmdkdESWBc6UFu-z6EwntB-4WziK2FxE6G2JoaAkZFEALw_wcB

https://www.banggood.com/UNO-Mega-Nano-Sensor-Relay-Bluetooth-Wifi-LCD-Beginner-Starter-Kit-For-Arduino-p-1132002.html?rmmds=search&cur_warehouse=CN

If you are familiar with soldering Veroboard circuits, then a quick and reliable way to build a permanent project is to use the more or less functionally equivalent Arduino Nano that can be soldered in (or preferably plugged into an IC socket) on the Veroboard. Clones can be ridiculously inexpensive.
https://www.banggood.com/ATmega328P-Nano-V3-Controller-Board-Compatible-Arduino-p-940937.html?rmmds=search&cur_warehouse=CN

(I see they are on special offer so I might just buy a dozen!)

Graeme Dunbar - 4441

Dave Cooper

Graeme - looks like quite a few affordable options here. You mention "students" - does this imply that you run programming /constructional courses ?

I have done some 'breadboarding' and built simple circuits on PCB's etc in the past and now have a 'scope (Tektronix) that I will use to debug radio control stuff. I understand that Arduino can output servo driver signals and this could be useful for my various bits and bobs mentioned in the previous post ?

Would be interested in more info' regarding courses for future learning...(PM maybe)
Dave
"High Water" Diorama ("Dŵr Uchel")
- the inveterate tinkerer

Graeme Dunbar

Hi Dave,

Yes, one of the things I do is teach a micrcontroller course to first year engineers. I'll be retiring at the end of the summer and am currently winding down. I hope to be a more active modeller then, including the local MERG (Model Electronic Railway Group) that I used to host. I'm happy to help with learning about Arduino.

Yes, controlling servos from an Arduino is straightforward. Depending on the servo and the load, it might be worth powering the servo from its own supply and not through the Arduino's onboard 5 V regulator.



Graeme Dunbar - 4441

Neil McGrath

I find that the onboard 5v regulator can get quite hot if you use an input of 12v. I tend to run my boards direct from an external 5v supply which can handle a bit more current.

Neil

Hugh Norwood

Quote from: GraemeD on March 04, 2019, 08:28
Yes, controlling servos from an Arduino is straightforward. Depending on the servo and the load, it might be worth powering the servo from its own supply and not through the Arduino's onboard 5 V regulator.
I have been advised to use a separate 5V line for servos as they can take quite a bit of current (and noise too?) (this is not arduino, I hasten to add)
Hugh Norwood
Angst-Lesspork

Graeme Dunbar

Quote from: hughn on March 07, 2019, 15:54
Quote from: GraemeD on March 04, 2019, 08:28
Yes, controlling servos from an Arduino is straightforward. Depending on the servo and the load, it might be worth powering the servo from its own supply and not through the Arduino's onboard 5 V regulator.
I have been advised to use a separate 5V line for servos as they can take quite a bit of current (and noise too?) (this is not arduino, I hasten to add)

Yes. There can be quite a big current spike as the servo starts to move. A load such as driving point blades against their stops and stalling the servo will also draw a hefty current. I remember a Lynxmotion 6-legged walking robot that had two servos per leg would misbehave as the batteries ran down. It would "get up" and the effort was enough to pull the voltage down so much that the microcontroller did a low voltage reset, the robot would collapse as the microcontroller output turned off, it would restart and the whole thing repeat over and over.

It is probably wise only to run no more than a simple test or practice program with a small servo and with no load if powered directly off the Arduino.
Graeme Dunbar - 4441

Graeme Dunbar

Quote from: Neil McGrath on March 06, 2019, 20:54
I find that the onboard 5v regulator can get quite hot if you use an input of 12v. I tend to run my boards direct from an external 5v supply which can handle a bit more current.

Neil

Yes, if I was expecting the Arduino to run a project such as control a something on a model railway for an extended period of time I would not be happy with it getting so hot even though the Arduino web site says the board can handle it.
Graeme Dunbar - 4441

Steve Lomax

Hi. Arduino controlled point motors:
I'll try to be brief...
I have a DCC++  (Arduino based DCC) layout and have point (turnout) triggers from  JMRI software running the layout on a PC. This allows me to access unused pins on the main Arduino base station. I use an Arduino mega for this so that I can get 50 pins to control points and receive sensor triggers for point and train running automation. I also have a conventional switch panel for points. Although my points are controlled by DCC, the DCC is converted to analog switch control and each point switch on the panel is 3 position, Closed, Thrown or Auto controlled. So I could list the arduino sketches I use, but the code that handles the DCC would need to be removed. 
it is easier to start again.
I use SG90 mini servos controlled by Arduino Pro Mini (small and cheap) but any arduino should work
I recon the easiest way is to use 1 arduino to control up to 6 points. They're only

Steve Lomax

I have some other model railway related arduino projects on my thingiverse page.
There's a 3 servo crane, children's playground and turntable.
https://www.thingiverse.com/bluetobits/designs

Dave Cooper

Hi All

I hope this isn't too far 'off-thread' but I've just been looking at the "Sparkfun Inventors Kit". Seems to be Arduino-based and, I believe programming is C# /C++.

You get a 'de-luxe' arduino, breadboard plus bags of components etc for making circuits and projects...

Seems like it might make a nice Xmas present if I can persuade certain family members !

Anyone tried it ?
Dave
"High Water" Diorama ("Dŵr Uchel")
- the inveterate tinkerer

Graeme Dunbar

No, but Sparkfun have a good reputation and I've got individual parts from them. There are less expensive kits, but I think you can be certain that the individual bits will be reliable and go together well which is not always the case with cheap kits.
Graeme Dunbar - 4441

Dave Cooper

Hi Graeme

Just read a review on the Sparkfun IK and the main complaint seems to be the wire gauge used on the low-value resistors (1/4 watt and below) are too 'thin' for the supplied breadboard. This leaves them flopping about in the holes and unable to make a proper connection.

Maybe one could 'double-over' the free ends to make them a tighter fit, or, solder a thicker pin on to suit ?

Otherwise, seems like the reviewers were happy...Kit is around
"High Water" Diorama ("Dŵr Uchel")
- the inveterate tinkerer

Neil McGrath

I tend to just buy the Chinese clone Arduinos together with the components and accessory boards that I need. I will always look for the accessory modules on Ebay that are due to finish their auction at a low price, so I can build up a decent stock of spares that I can dip into. A good supplier is Banggood.com. They have a decent selection of low cost parts and will generally deliver free within a couple of weeks.

Graeme Dunbar

Quote from: Dave Cooper on August 30, 2019, 12:04
Hi Graeme

Just read a review on the Sparkfun IK and the main complaint seems to be the wire gauge used on the low-value resistors (1/4 watt and below) are too 'thin' for the supplied breadboard. This leaves them flopping about in the holes and unable to make a proper connection.

Maybe one could 'double-over' the free ends to make them a tighter fit, or, solder a thicker pin on to suit ?

Otherwise, seems like the reviewers were happy...Kit is around
Graeme Dunbar - 4441