Download Print this page

Using Motors - Intel Galileo Hardware Manual

Biobots
Hide thumbs Also See for Galileo:

Advertisement

Hardware

4: Using Motors

4.1: What is a motor
We are going to be working with electric motors.
movement, generally by spinning in a circle. Motors are used in robots, printers, electric bicycles, factory
machinery, electric cars basically anything that moves and is powered by electricity.
Motors exploit a property of
Motors loop wires thousands of times so that the magnetic field is a lot stronger than it would be with just
one wire. Magnets can push or pull things – they can create a force on something metal or magnetic. If you
arrange several wire loops in a circle and put something metal in the middle, you can apply electricity, caus-
ing the the metal thing to spin. The spinning thing can be used as the spinning part of the motor. Look back
at the resources in the Circuits & Motors lessons for help.
The important thing to remember when making robots is not to know exactly what is happening inside the
motor, but how to make the motor what you want to do.
In order to use motors with the Galileo, we have to use something called a
processor world, a shield is a separate chip which allows you to do more with your Galileo, instead of wiring
up your own complicated circuit. The motor shield's purpose is to allow a separate power supply to be used
for the motor, and to make moving the motor backwards and forwards easier. A separate power supply is
needed because motors use a lot more power than the Galileo can supply by itself.
The maximum electricity a motor will use is usually labeled as a stall current, small motors usually have stall
current of around 2Amps. The maximum the Galileo can supply before breaking is around 0.3Amps.
4.2: Installing the Motor Library
In order to control a motor in the way we want to do, it is much easier to make the microprocessor program
do a lot of the work for us. In programming there are things called
that someone else has written. Libraries allow us to simply tell something to "go forward", instead of worrying
about all the things required.
The motor shield that is most commonly used is the
shield you have, it is most likely the adafruit. There are different layouts for the chip, and perhaps different
labels, use your best judgement, and don't turn it on until you double checked it. Adafruit was nice and wrote
their own library for their motor shield, which is available here:
tor-shield/library-install
4.3: Wiring up a DC Motor
A DC motor is simple and the most common type of electric motor. DC motors can spin in both directions,
and the speed can be changed. DC motors usually spin very fast, but often do not have the torque (power)
to turn anything significant or heavy. Gears, or gear boxes, are often used in order to lower the speed and
increase the torque. Using a DC motor without any gearing can cause the motor to burn out, and become
unusable. Turn off/unplug the motor quickly if it is on but cannot turn. Be careful, because the motor will
magnetism
. By running electricity through a wire, a magnetic field is created.
(Lesson 4, Figure 1, next page)
Electric motors
libraries
Adafruit motor shield
https:/ /learn.adafruit.com/adafruit-mo-
convert electricity into mechanical
motor shield
, which contain a lot of code
. If you're not sure what motor
. In the micro-
Hardware 22

Advertisement

loading