Go Down

Topic: Trying to upload the program from anAtmega328p (Read 499 times) previous topic - next topic

april

Oct 04, 2012, 11:26 am Last Edit: Dec 01, 2012, 09:09 am by april Reason: 1
Can anyone tell me what I am doing wrong ?
I am sending this command line to avrdude
Code: [Select]
# avrdude -p m328p -P usb:2:/dev/ttyusb4 -c usbtiny -U flash:r:"/root/flash.bin":r  

and getting this response
Code: [Select]
avrdude: Error: Could not find USBtiny device (0x1781/0xc9f)
avrdude done.  Thank you.

When I program to the chip I use /dev/ttyusb4 and it goes well but it does not find the device here?

Lua rocks!
View Profile
WWW
Personal Message (Offline)
   
Insults
« Sent to: april on: Today at 06:35:05 AM »
   Reply with quoteQuote ReplyReply Remove this messageRemove
Quote
When i tell him to B... Offf I mean it
He then gets all reasonable and better for a while

I would just prefer he b...s off .

You are acting like a pack of dogs to his aid .

This sort of language is not acceptable.

The Arduino software is free, and the people on the forum are unpaid volunteers.

Post a public apology or I will ban you.

When you get free advice you don't get to choose who replies and who doesn't. You don't demand that certain people don't respond to you.

- Moderator
Get Fucked

pylon

Do you really have an USBtinyISP device as you specified on the command line? If yes, it will probably not be on /dev/ttyusb4, as it doesn't emulate a serial interface. The USBtinyISP are access through libusb and not by a kernel driver.

april

Thanks - You are right . When I unplug and replug the device I get
"usbdev2.9"
So what address do I use for that?

april

#3
Oct 04, 2012, 10:41 pm Last Edit: Oct 05, 2012, 10:25 pm by april Reason: 1
All good thanks found it with this
Code: [Select]
# avrdude -p m328p -c usbtiny -U flash:r:"/flash.hex":r

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x1e950f
avrdude: reading flash memory:

Reading | ################################################## | 100% 62.34s

avrdude: 1 retries during read


avrdude: writing output file "/flash.hex"

avrdude: safemode: Fuses OK

avrdude done.  Thank you.

#


The file saved is a binary file and not a hex file so now I need to convert it or get it in the hex format.
How do I do that ? OK realised that the last "r" stood for raw and changed that to "i" for Intel Hex
  avrdude -p m328p -c usbtiny -U flash:r:"/flash.hex":i

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy