system
1
Hi guys!
I have problem with uploading sketches to Arduino Leonardo manually (without IDE) on Ubuntu 12.04 64bit. Uploading sketches with IDE works great.
- I downloaded Makefile from here: ::[ edam ]:: » Arduino Makefile
- Set proper port: /dev/ttyACM0
- Set proper board: Leonardo (atmega32u4)
- Compiled sketch.
- After uploading I got next error message:
make upload
Uploading to board...
stty -F /dev/ttyACM0 hupcl
/usr/share/arduino/hardware/tools/avrdude -C /usr/share/arduino/hardware/tools/avrdude.conf -DV -p atmega32u4 -P /dev/ttyACM0 -c avr109 -b 57600 -U flash:w:test.hex:i
Connecting to programmer: .avrdude: butterfly_recv(): programmer is not responding
make: *** [upload] Error 1
While uploading process RX LED blinks 2 or 3 times.
What I tried to do?
- Reseting Arduino with the button
- Unplugging usb
- Rebooting
- Changing -b parameter
Please, note: IDE with the same settings and hardware works like a charm.
Where can be my fault? Thanks!
system
2
Wow! It's became clear to me that IDE uses uisp
tool to upload sketches.
Maybe someone have an example how to use uisp
from command line?
system
3
I did it!!!
I have added upload.verbose=true
to preferences.txt
and checked output
So, to upload sketch to Arduino Leonardo I need next command:
/usr/share/arduino/hardware/tools/avrdude -C/usr/share/arduino/hardware/tools/avrdude.conf -patmega32u4 -cavr109 -P/dev/ttyACM0 -b57600 -D -Uflash:w:sketch.hex:i
Also I have to press reset
button on the board before uploading.
Now I have another question. How to upload sketch without pressing reset
button?
system
4
Great! It works!!!
I have found great tool - ino.
http://inotool.org/
It can make and upload sketches. Works like a charm!
There is a good tutorial for beginners.
Now I have really cool IDE:
Sublime Text 2 + ST2-Arduino plugin + Ino.
Very-very cool solution which can make, clean, upload sketches from Sublime Text 2 window. Also it has syntax highlighting and autocomplete.