Customize the IDE
All of the software is in place
now and the hardware
connection taken care of, but
there are a couple configuration
things to attend to before you can
start programming and Flashing
memory. This took some detective
work to untangle, but the steps
turned out to be pretty easy.
Double-click the shortcut to
open the GCB@SYN IDE for the
first time. Then, load in the file
flashAVR.bat which you’ll find in
the GCB@Syn\G@Stools folder.
This batch file is invoked automatically whenever you
compile and Flash a program. In the editor, it’ll look
something like that shown in Figure 4.
There are several options already listed in the file for
other burners. Go ahead and REM them out, then add this
line as your only live option:
“AVRdude\avrdude.exe” -c arduino -P com3 -p AT%2
Just so you know, here’s what it all means:
• “AVRdude\avrdude.exe” is the name of the software
invoked to Flash the program.
• -c arduino is the hardware burner you’re connected to
• -P com3 is the COM port; change it to whichever one
you spotted earlier.
• -p AT% 2 is the chip within the Arduino.
• -U flash:w:%1: indicates you wish to Flash a program
whose name is given.
Digital Special Uses Name Analog Name
In case you’re wondering, avrdude.exe is already
included in the package you installed earlier. Also, %1 and
0 RX D.0 0 C.0
1 TX D.1 1 C.1
2 are replaceable parameters supplied automatically by
the IDE. The doodad is smart enough to automatically
provide them based on your source file.
2 D. 2 2 C. 2
3 PWM D. 3 3 C. 3
One final thing and we’ll be done. The IDE includes a
useful tool for reading, writing, and checking programs in
the Arduino, as well as spying on memory and so forth.
4 D. 4 4 C. 4
5 PWM D. 5 5 C. 5
We need to point it in the right direction. From the
menu bar, choose Run/AVR Dude. You’ll see a GUI screen
6 PWM D. 6
7 D. 7
9 PWM B.1
10 PWM B. 2
Great Cow Basic does an admirable job of handling both PIC
and AVR microcontrollers (hence the Arduino) with essentially
the same source code for either. It does this while supporting
just about every chip within those two families. About all you'll
ever need to do is change a few pin assignments.
11 PWM B. 3
The pins on the Arduino are labeled in a unique sequential
fashion, falling under two categories: digital and analog input.
12 B. 4
13 LED B. 5
Table 1 shows how to call them out in Great Cow Basic using
the standard PIC port name nomenclature.
60 SERVO 09.2014