Section 8: Updating the Firmware

ArduinoTrack_Combined is designed for use with the Arduino 1.6.8+ development environment, as available from http://www.arduino.cc/.

 

 

The latest firmware can always be found on Custom Digital Services GitHub site.  Begin by downloading the firmware - you can clone the repository using Git, or you can just download the ArduinoTrack folder to your local PC.

Programming the Programmer

On a separate Arduino Uno or similar, install the Arduino ISP Example Sketch the the Uno. Program this as you would a normal sketch, by selecting the appropriate Arduino from the Tools-Boards list, and the Comm port as needed.

Plug the ArduinoTrack Shield into Arduino Uno that is programmed as an ISP programmer.

Preparing the IDE

In the Arduino IDE and go to File-Preferences.  In the Additional Boards Manager URLs field, add the URL to the Project: Traveler website .json file:

https://www.projecttraveler.org/downloads/package_projecttraveler_index.json

Edit the Arduino Boards Manager URL

 

Click OK to close the preferences dialog.  Then go to Tools-Boards-Boards Manager.

When the Boards Manager opens, select "Contributed" from the Type drop-down.  In the resulting list, you should find the ArduinoTrack by Project Traveler option.  Click the Install button in the lower-right corner.

 

Install the Project Traveler board into the Arduino IDE

 

Close out of the Boards Manager dialog, and the back under Tools-Board, you should see ArduinoTrack near the bottom of the list.

Setting the Controller Flags

If this is a brand new ArduinoTrack board that has never been programmed before, there are several commands that must be run from a DOS command prompt. If the ArduinoTrack was purchased as an assembled and tested kit, you can skip these steps.

Open a command prompt on the PC.

C:\> cd \Program Files (x86)\Arduino\hardware\tools\avr\bin
C:\Program Files (x86)\Arduino\hardware\tools\avr\bin> avrdude.exe -p m328p -b 19200 -c avrisp -C ..\etc\avrdude.conf -P comX* -U hfuse:w:0xD6:m -U lfuse:w:0xFF:m -U efuse:w:0x05:m 

This will write the fuses to the new processor.  To verify that the fuses have been written, run these commands:

C:\Program Files (x86)\Arduino\hardware\tools\avr\bin> avrdude.exe -p m328p -b 19200 -c avrisp -C ..\etc\avrdude.conf -P comX* -U hfuse:r:highfuse:h -U lfuse:r:lowfuse:h -U efuse:r:exfuse:h
C:\Program Files (x86)\Arduino\hardware\tools\avr\bin> cat highfuse
C:\Program Files (x86)\Arduino\hardware\tools\avr\bin> cat lowfuse C:\Program Files (x86)\Arduino\hardware\tools\avr\bin> cat exfuse

* Replace "comX" with whatever Com port your ArduinoISP is enumerating on.

Program the ArduinoTrack

To program the ArdunoTrack Shield, open the firmware downloaded earlier from GitHub in the Arduino IDE. 

Go to the Tools-Board menu, select the ArduinoTrack Shield from the list of targets. From the Tools-Port menu, select the appropriate comm port for the ISP programmer Arduino.

Verify that the correct #define variable is set (and the others are commented out), and go to Sketch-Upload Using Programmer. The Sketch will compile and will program to the ATMega328 processor similarly to how a normal Arduino with the bootloader is programmed. However, in this situation, no bootloader is required on the Shield.