Examples using UISP:
First of all, please note that in the following examples, /dev/avr is a symbolic
link to the serial port device where the programmer is connected. (eg: /dev/ttyS0).
Also, dont forget to change the -dpart argument if you are not using an AVR Atmega8.
Programming the fuses bytes on an atmega8:
# uisp -dprog=stk500 -dpart=atmega8 -dserial=/dev/avr --wr_fuse_h=0xc9 --wr_fuses_l=0x9f
Programming an hex file into an atmega8:
# uisp -dprog=stk500 -dpart=atmega8 -dserial=/dev/avr --erase --upload --verify if=n64_to_wii.hex
Note: --erase is for erasing the flash memory BEFORE programming the new file. --verify provides
a way to read back the flash content and compare it with the original file to making sure no
errors occured.
Examples using AVRDUDE and an USB ISP mkII:
Programming the fuses bytes on an Atmega8:
# avrdude -p m8 -P usb -c avrispmkII -Uhfuse:w:0xc9:m -Ulfuse:w:0x9f:m
Note: The -p option is used to specify which type of AVR you are programming. To
display a list of supported device, try 'avrdude -p list -P usb -c avrispmkII' (since
'list' is not a valid type, avrdude lists supported types).
Programming an hex file into an atmega8:
# avrdude -p m8 -P usb -c avrispmkII -Uflash:w:n64_to_wii.hex -B 1.0
Note: The -B argument controls the ISP bit clock period (in microseconds).
This frequency must not be higher than 1/4 of the MCU clock.
Up
|