-
Some thoughts for discussion on how to do this on mac...I have not tried it yet.
|
Beta Was this translation helpful? Give feedback.
Replies: 14 comments 4 replies
-
Since the verbose output of Arduino IDE gives the path to the 'blink' hex file, I figured that would be a convenient location to place the 'firmware.hex' file. Because that way I can just copy the complex path. |
Beta Was this translation helpful? Give feedback.
-
I copied the verbose output parameters from Arudino IDE to see how I needed to control avrdude. Then I modified them in red to work with the ArduinoISP board being used as the uploader. (-cavrisp). After erase and unlock board, then set fuses, avrdude is directed to the firmware.hex file in the same directory where blink resides. Still working on this, so I have not yet added the commands to upload the default settings to eprom. |
Beta Was this translation helpful? Give feedback.
-
I ran the three avrdude program 3 times to 1) unlock the board, 2) set the fuses, and 3) write 'firmware.hex' and settings.hex.' Seemed to go OK but looking at the output it indicated an error setting fuses and they were all set to "00" I went back and tried to unlock the board again and all I get when I try "-Ulock:w:0x3F:m" is : avrdude: stk500_recv(): programmer is not responding avrdude done. Thank you. I tried to reload the 'ArduinoISP' to all three of my Nano boards and it seems to load ok, but when I try the -Ulock:w:0x3F:m command in avrdude, all I get is the above error. I have two more boards that just came in the mail. Will try those as the programmer and see what happens. |
Beta Was this translation helpful? Give feedback.
-
First of all, I don't understand why you uploading firmware blindly without assembled hardware to test it. Second, if you was able to upload 'Arduino ISP' to all three of your boards via USB cable, means that all boards weren't unlocked nor erased when you ran avrdude commands which change fuses. Note, that you cannon change fuses on a board connected via USB, only Arduino as ISP can change fuses on TARGET board. Commands you posted above seems fine, same as mine but with path added. Means you doing something wrong, and I cannot say what exactly with given information. |
Beta Was this translation helpful? Give feedback.
-
Thank you for the response. So, now I know the Arduino ISP is needed to set fuses. Will go back and try to get the ISP uploader to work again. It (Arduino ISP uploader) did work only once but after that it stopped responding. Don't know why. Will continue to experiment. Hardware is slow to build due to prolonged wait for the parts. So far almost 2 months. The LED was horribly non-functional (see below) so I ordered more from 2 different suppliers to get a good one. The rotary selector came without the two switch leads, so that needed to be re-ordered also. Nothing too serious, still moving forward with the build. OUTPUT FROM AVRDUDE:
|
Beta Was this translation helpful? Give feedback.
-
I retrieved the Terminal log and found out the first time I used the -Ulfuse:w:0xFF:m -Uhfuse:w:0xD7:m -Uefuse:w:0xFF:m commands with avrdude and my ISP Programmer I got the following reply:
Thereafter, every time I try to use my ISP Programmer board with avrdude I only get: |
Beta Was this translation helpful? Give feedback.
-
To test my ISP Programmer, I opened the Arduino IDE program used it to "Update Bootloader" on a board and I got the following response, which seems to indicate that it worked and my ISP Programmer and its connections are OK. I also checked the instructions to avrdude passed from Arduino IDE program for the fuse setting commands and found it is using "-cstk500v1" instead of "-carduino" so the next thing to try is to use "-cstk500v1" with my ISP Programmer.
|
Beta Was this translation helpful? Give feedback.
-
And one more thing. Please, don't get me wrong. I am here to help with the build, but not to teach how to solder or program arduinos. Arduino is the simplest among the microcontrollers and was designed for educational purposes. There are tons of educational videos and articles on internet how to program arduinos. You also can ask questions on https://forum.arduino.cc, it is great community always willing to help. |
Beta Was this translation helpful? Give feedback.
-
Ok, I can take the discussion over there. Rather than bothering you I was hoping another OSX user would chime it, realizing that I'm using UNIX version of avrdude and you instructions are windows based. I do want to get the burning sequence correct and document what did work before adding the steps to my "Build Thread" Just to answer where "STK500" came from, this is the entire instruction that Arduino IDE sent to avrdude to burn the bootloader:
|
Beta Was this translation helpful? Give feedback.
-
If you verified that your Arduino as ISP setup works, mean both boards connected correctly and avrdude can talk to them. If you are using Mac, only thing you have to do is run those commands from Wiki. Since you are using Arduino ISP instead of USBAsp programmer, you only have to replace 'usbasp' with 'avrisp' and port name, that's it. 'cd' to the folder where you downloaded firmware.hex file and run these commands: avrdude -p atmega328p -c avrisp -P /dev/cu.usbserial-14110 -e -U lock:w:0x3F:m |
Beta Was this translation helpful? Give feedback.
-
OK will try that. I was just using the long path to avrdude because that is what appears in Arduino IDE's verbose output. I'm pretty excited about the build two more packages came today. I have over 90% of the parts now. |
Beta Was this translation helpful? Give feedback.
-
OK, I see what might be an issue. I'm trying to run avrdude that was installed with Arduino IDE from the "Terminal" program in OSX. For example just typing "avrdude" yields the response "-bash: avrdude: command not found" So, I'll try installing MacPorts and load avrdude from that and then use the commands recommended above. |
Beta Was this translation helpful? Give feedback.
-
Thank you for your help on this!!! The baud rate command "-b57600" was causing the communication error. Below are the exact arguments I pasted into "Terminal" that worked for me:
|
Beta Was this translation helpful? Give feedback.
-
I'm always interested in backtracking the error. So, when I used the verbose output of Arduino IDE to get the (Path to avrdude) and (Path to config file) and (Comm Port) I inadvertently also copied the baud rate of 57600. |
Beta Was this translation helpful? Give feedback.
Thank you for your help on this!!!
The baud rate command "-b57600" was causing the communication error.
Below are the exact arguments I pasted into "Terminal" that worked for me:
/Users/daddy/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/bin/avrdude -C/Users/daddy/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/etc/avrdude.conf -v -V -patmega328p -cavrisp -P/dev/cu.usbserial-14110 -b19200 -e -Ulock:w:0x3F:m
/Users/daddy/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/bin/avrdude -C/Users/daddy/Library/Arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/etc/avrdude.conf -v -V -patmega328p -cavrisp -P/dev/cu.usbserial-14110 -b19200 -…