I want to upload an .hex file to an Atmega8 chip (SMD). I want to use the Arduino IDE and an Uno as the ISP program. But I'm unable to find any details on how to load a sketch which is in .hex format.

Following is the batch file I created to use with avrdude. I would like to know if the Command is correct?

C:\Users\Pranay\Desktop\DIY\arduino-1.0.1!\hardware\tools\avr\bin/avrdude -CC:\Users\Pranay\Desktop\DIY\arduino-1.0.1!\hardware\tools\avr\etc/avrdude.conf -v -v -v -v -patmega8 -cstk500
 -P\\.\COM4 -b19200 -Uflash:w:C:\Users\Pranay\Desktop\DIY\arduino-1.0.1!\hexFiles\Heart.hex:i

pause
share|improve this question
    
It looks okay. Have you tried running it? It can't do any harm if it's wrong; you just get an error message. – Gerben Jan 16 '16 at 13:27
    
When i run the batch file it says "C:\Users\Pranay " is not recognised as internal or external command, operable program or Batch file. In the next line it says the system cannot find the path specified. – Pranay Jan 16 '16 at 14:48
1  
I think that means you got the file-path wrong. – Gerben Jan 16 '16 at 15:52
    
Thanks for your help @Gerben. figured out the mistake and finally sucedded in uploading sketch. – Pranay Jan 17 '16 at 14:38
    
That good to hear. Could you share your solutions, so others might learn from it? – Gerben Jan 17 '16 at 16:35

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.