My previous question, Android cannot talk to Arduino using AVRDUDE, has been resolved. I can now connect my Nexus 7 to my Arduino Uno. The full command I am running is this:
/system/xbin/su (getting root here)
/data/data/jackpal.androidterm/local/bin/avrdude -F -V -c arduino -p ATMEGA328P -P /dev/bus/usb/002/002 -b 115200 -C /data/data/jackpal.androidterm/local/etc/avrdude.conf -U flash:w:led.hex
Here I am trying to put the hex file on the Arduino. I do however get the following error:
avrdude: ser_open():can't set attributes for device "/dev/bus/usb/002/002": Inappropriate ioctl for device ioctl("TIOCMGET"): Bad file desriptor
HansStam
It turns out I was using the wrong port. I used /dev/bus/usb/002/002
while I should have used ttyACM0
.
来源:https://stackoverflow.com/questions/15598179/avrdude-android-arduino-ioctl-error