Solder a lead directly from the negative power terminal on the shield to the negative of the battery holder. 3




Download 22.85 Mb.
Pdf ko'rish
bet9/106
Sana27.06.2022
Hajmi22.85 Mb.
#24472
1   ...   5   6   7   8   9   10   11   12   ...   106
Bog'liq
Arduino-Android ProjectsfortheEvilGenius-SimonMonk

2. Solder a lead directly from the negative power terminal on the shield to the negative of the battery
holder.
3. Solder a longer lead to the center connection on the switch to the positive battery terminal.
4. Solder a shorter lead to one side of the switch (it does not matter which) and fit the other end into the
positive screw terminal.
Step 7. Test the Motors
We now need to set up our Arduino environment so we can install a program to test the motors before
going ahead and linking it all up with Bluetooth.
The Arduino board we are using (Arduino Uno) uses a special-purpose development environment
that allows us to send programs, or “sketches” as they are called in the Arduino world, to the board
through the USB lead.
We need to install the Arduino environment, and rather than repeat instructions given elsewhere,
please refer to the official Arduino site (
www.arduino.cc
) and follow the instructions there for installing
the Arduino environment on your computer. You will find separate instructions there for Windows, Linux,
and Mac. This book uses version 22 of the Arduino software and the Arduino Uno interface board;
however, you should have no problem using later versions of Arduino.
Once your Arduino environment is set up, you need to install the test sketch for the project. In fact,
all the sketches for the projects in this book are available in a single zip file that can be downloaded from
www.duinodroid.com
.
Unzip the file and move the whole Arduino Android folder to your sketches folder. In Windows,
your sketches folder will be in My Documents/Arduino. On the Mac, you will find it in your home
directory, Documents/Arduino/, and on Linux it will be in the Sketchbook directory of your home
directory.
After installing the library, restart the Arduino software. Then, from the File menu, select Sketches,
followed by Arduino Android, and then ch01_motor_test. This will open the motor test sketch, as shown
in 
Figure 1-12
.
www.ECA.ir ﮏﯾﻧورﺗﮑﻟا و قرﺑ ﯽﺻﺻﺧﺗ تﯾﺎﺳ بو
@ECAir مارﮕﻠﺗ لﺎﻧﺎﮐ رد تﯾوﺿﻋ



Download 22.85 Mb.
1   ...   5   6   7   8   9   10   11   12   ...   106




Download 22.85 Mb.
Pdf ko'rish

Bosh sahifa
Aloqalar

    Bosh sahifa



Solder a lead directly from the negative power terminal on the shield to the negative of the battery holder. 3

Download 22.85 Mb.
Pdf ko'rish