OpenSprinkler › Forums › OpenSprinkler Unified Firmware › Realtime Failures Ray and Samer please read. › Reply To: Realtime Failures Ray and Samer please read.
Ray
Hi Ed, sorry about my delayed response. I am currently traveling in China and it has been a pain to access gmail and lots of websites without a reliable VPN.
I assume you have been able to compile the firmware code. I actually typically use arduino-make in conjunction with an Arduino 1.0.6 installation. arduino-make allows you to compile the code without launching the Arduino IDE which is often more convenient. Also, it compiles the code into the local directory as opposed to into a temporary folder that’s difficult to find. The Github repository also contains a Makefile which is directly usable with arduino-make (you do however need to open that Makefile and change directories to match your installation).
Anyways, to upload a firmware, if you have Arduino IDE installed (assuming this is how you compiled the firmware). You can go to menu Tools -> Board, select your corresponding OpenSprinkler version. Then Tools -> Port, select the serial port (typically there is one obvious option). Then click on the Upload button.
If you prefer to upload in command line (without Arduino IDE) you can do so using avrdude:
avrdude -c arduino -p m1284p -P COM? -b 115200 -U flash:w:xxx.hex
In Windows, the COM? is the COM port associated with the device (the same as in Arduino IDE, and you can also go to Window’s Device Manager to find out). In Linux and Mac, the serial port shows up as a device under /dev/tty???, for example, in Linux it may be /dev/ttyUSB0, and you can do ‘ls /dev/tty*’ to find out). xxx.hex is the name of the compiled firmware. -p m1284p indicates it’s ATmega1284p microcontroller (assuming OS 2.3). If you have OS 2.2, change it to m644p.