This post’s for self doc only. Went to work full day, furiously, in front of My Mac, from Saturday morning to about 7 pm because of single line of warning.
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
Yeah, maybe it’s not worth my time but still...
Anyway, I use my arduino Nano as ISP programmer, to upload the new firmware to USBASP.
On Arduino IDE, open file, example, ArduinoISP.
Upload arduinoISP sketch to Nano.
Connect the pins.
Arduino Nano — USBASP
5V — 2
GND — 10
13 — 7
12 — 9 (MISO)
11 — 1 (MOSI)
10 — 5 (RESET)
Don’t forget to connect the jumper J2 or JP2 to enable self programming on USBASP.
Don’t use 2011’s firmware version, use 2009’s instead
I have two example of command, for windows
avrdude -C ../etc/avrdude.conf -c avrisp -P COM3 -b 19200 -p m8 -v
avrdude -C ../etc/avrdude.conf -c avrisp -P COM3 -b 19200 -p m8 -U flash:r:original_firmware.bin:r
avrdude -C ../etc/avrdude.conf -c avrisp -P COM3 -b 19200 -p m8 -U flash:w:original_firmware.bin
avrdude -C ../etc/avrdude.conf -c avrisp -P COM3 -b 19200 -p m8 -U flash:w:c:\usbasp.atmega8.2011-05- 28.hex
and
avrdude -p m8 -b 19200 -c avrisp -P com2 -U flash:r:usbasp.atmega8.hobbyking.hex
avrdude -p m8 -b 19200 -c avrisp -P com2 -U flash:w:usbasp.atmega8.2009-02-28.hex
Have to modify that to satisfy my Mac environment
I’m sure my Mac have no COM port, and my successful avrdude command is like this
avrdude -p attiny13A -P usb -c usbasp -n
avrdude -p t13 -c usbasp -P usb -U flash:w:template.hex
so maybe I have to use -P usb
avrdude -c avrisp -P usb -b 19200 -p m8 -v
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : usb
Using Programmer : avrisp
Overriding Baud Rate : 19200
avrdude: ser_open(): can't open device "usb": No such file or directory
avrdude done. Thank you.
Nugrohos-MacBook-Air:firmware nugroho$
#
no
OK
again
Nugrohos-MacBook-Air:firmware nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -v
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : /dev/cu.wchusbserial1420
Using Programmer : avrisp
Overriding Baud Rate : 19200
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x15
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x15
AVR Part : ATmega8
Chip Erase delay : 10000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 128 0 no 512 4 0 9000 9000 0xff 0xff
flash 33 10 64 0 yes 8192 64 128 4500 4500 0xff 0x00
lfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
lock 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500
Description : Atmel AVR ISP
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x14
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x02
avrdude: stk500_getparm(): (a) protocol error, expect=0x14, resp=0x10
Hardware Version: -1597263620
Firmware Version: 3296192.-1597263620
Topcard : STK502
Vtarget : 1.8 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: stk500_initialize(): (b) protocol error, expect=0x10, resp=0x01
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x10
avrdude done. Thank you.
Nugrohos-MacBook-Air:firmware nugroho$
avrdude -p m8 -b 19200 -c avrisp -P /dev/cu.wchusbserial1420
-U flash:r:usbasp.atmega8.original.hex
Press reset on Arduino Nano before enter command above
Nugrohos-MacBook-Air:firmware nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -v
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : /dev/cu.wchusbserial1420
Using Programmer : avrisp
Overriding Baud Rate : 19200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
AVR Part : ATmega8
Chip Erase delay : 10000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 128 0 no 512 4 0 9000 9000 0xff 0xff
flash 33 10 64 0 yes 8192 64 128 4500 4500 0xff 0x00
lfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
lock 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500
Description : Atmel AVR ISP
Hardware Version: 2
Firmware Version: 1.18
Topcard : Unknown
Vtarget : 0.0 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.13s
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
Nugrohos-MacBook-Air:firmware nugroho$
Using -F option
Nugrohos-MacBook-Air:firmware nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -v -F
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : /dev/cu.wchusbserial1420
Using Programmer : avrisp
Overriding Baud Rate : 19200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
AVR Part : ATmega8
Chip Erase delay : 10000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 128 0 no 512 4 0 9000 9000 0xff 0xff
flash 33 10 64 0 yes 8192 64 128 4500 4500 0xff 0x00
lfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
lock 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500
Description : Atmel AVR ISP
Hardware Version: 2
Firmware Version: 1.18
Topcard : Unknown
Vtarget : 0.0 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.13s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.13s
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATmega8 is 1E 93 07
avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: Fuses OK (H:FF, E:00, L:00)
avrdude done. Thank you.
Nugrohos-MacBook-Air:firmware nugroho$
Now backup
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:r:original_firmware.hex:r -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.13s
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATmega8 is 1E 93 07
avrdude: reading flash memory:
Reading | ################################################## | 100% 15.04s
avrdude: writing output file "original_firmware.hex"
avrdude: safemode: Fuses OK (H:FF, E:00, L:00)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$ ls
blinkLED_A coba2 firmware.hex original_firmware.hex usbasp.atmega8.2009-02-28.hex
coba1 coba3 lcdNO tn13Adef.inc
Nugrohos-MacBook-Air:attiny13a nugroho$
And upload new firmware
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:firmware.hex -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x000000 (retrying)
Reading | ################################################## | 100% 0.13s
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATmega8 is 1E 93 07
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "firmware.hex"
avrdude: input file firmware.hex auto detected as Intel Hex
avrdude: writing flash (3966 bytes):
Writing | ################################################## | 100% 9.16s
avrdude: 3966 bytes of flash written
avrdude: verifying flash memory against firmware.hex:
avrdude: load data flash data from input file firmware.hex:
avrdude: input file firmware.hex auto detected as Intel Hex
avrdude: input file firmware.hex contains 3966 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 7.29s
avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x0000
0x00 != 0x3b
avrdude: verification error; content mismatch
avrdude: safemode: Fuses OK (H:FF, E:00, L:00)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$
try it
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -v
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : usb
Using Programmer : usbasp
AVR Part : ATtiny13
Chip Erase delay : 4000 us
PAGEL : P00
BS2 : P00
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 5 4 0 no 64 4 0 4000 4000 0xff 0xff
flash 65 6 32 0 yes 1024 32 32 4500 4500 0xff 0xff
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
calibration 0 0 0 0 no 2 0 0 0 0 0x00 0x00
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e9007
avrdude: safemode: lfuse reads as 6A
avrdude: safemode: hfuse reads as FF
avrdude: safemode: lfuse reads as 6A
avrdude: safemode: hfuse reads as FF
avrdude: safemode: Fuses OK (H:FF, E:FF, L:6A)
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -U flash:w:coba3.s.hex
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e9007
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: reading input file "coba3.s.hex"
avrdude: input file coba3.s.hex auto detected as Intel Hex
avrdude: writing flash (34 bytes):
Writing | ################################################## | 100% 0.05s
avrdude: 34 bytes of flash written
avrdude: verifying flash memory against coba3.s.hex:
avrdude: load data flash data from input file coba3.s.hex:
avrdude: input file coba3.s.hex auto detected as Intel Hex
avrdude: input file coba3.s.hex contains 34 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 0.03s
avrdude: verifying ...
avrdude: 34 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:FF, L:6A)
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
try 2011 version
Nugrohos-MacBook-Air:attiny13a nugroho$ ls
blinkLED_A firmware.hex usbasp.atmega8.2009-02-28.hex
coba1 lcdNO usbasp.atmega8.2011-05-28.hex
coba2 original_firmware.hex
coba3 tn13Adef.inc
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -v -F
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : /dev/cu.wchusbserial1420
Using Programmer : avrisp
Overriding Baud Rate : 19200
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
AVR Part : ATmega8
Chip Erase delay : 10000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 128 0 no 512 4 0 9000 9000 0xff 0xff
flash 33 10 64 0 yes 8192 64 128 4500 4500 0xff 0x00
lfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
lock 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500
Description : Atmel AVR ISP
Hardware Version: 2
Firmware Version: 1.18
Topcard : Unknown
Vtarget : 0.0 V
Varef : 0.0 V
Oscillator : Off
SCK period : 0.1 us
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x1e9307
avrdude: safemode: lfuse reads as 9F
avrdude: safemode: hfuse reads as D9
avrdude: safemode: lfuse reads as 9F
avrdude: safemode: hfuse reads as D9
avrdude: safemode: Fuses OK (H:FF, E:D9, L:9F)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w: -F
.DS_Store coba3/ tn13Adef.inc
blinkLED_A/ firmware.hex usbasp.atmega8.2009-02-28.hex
coba1/ lcdNO/ usbasp.atmega8.2011-05-28.hex
coba2/ original_firmware.hex
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:usbasp.atmega8.2011-05-28.hex -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x1e9307
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "usbasp.atmega8.2011-05-28.hex"
avrdude: input file usbasp.atmega8.2011-05-28.hex auto detected as Intel Hex
avrdude: writing flash (4700 bytes):
Writing | ################################################## | 100% 10.94s
avrdude: 4700 bytes of flash written
avrdude: verifying flash memory against usbasp.atmega8.2011-05-28.hex:
avrdude: load data flash data from input file usbasp.atmega8.2011-05-28.hex:
avrdude: input file usbasp.atmega8.2011-05-28.hex auto detected as Intel Hex
avrdude: input file usbasp.atmega8.2011-05-28.hex contains 4700 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 8.70s
avrdude: verifying ...
avrdude: 4700 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:D9, L:9F)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$
It's way promising
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -n
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -P usb
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
not
go to original 2009 version
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:usbasp.atmega8.20 -F
usbasp.atmega8.2009-02-28.hex usbasp.atmega8.2011-05-28.hex
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:usbasp.atmega8.2009-02-28.hex -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x1e9307
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "usbasp.atmega8.2009-02-28.hex"
avrdude: input file usbasp.atmega8.2009-02-28.hex auto detected as Intel Hex
avrdude: writing flash (3826 bytes):
Writing | ################################################## | 100% 8.86s
avrdude: 3826 bytes of flash written
avrdude: verifying flash memory against usbasp.atmega8.2009-02-28.hex:
avrdude: load data flash data from input file usbasp.atmega8.2009-02-28.hex:
avrdude: input file usbasp.atmega8.2009-02-28.hex auto detected as Intel Hex
avrdude: input file usbasp.atmega8.2009-02-28.hex contains 3826 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 7.05s
avrdude: verifying ...
avrdude: 3826 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:D9, L:9F)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
back to patched 2009 version
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:firmware.hex -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.11s
avrdude: Device signature = 0x1e9307
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "firmware.hex"
avrdude: input file firmware.hex auto detected as Intel Hex
avrdude: writing flash (3966 bytes):
Writing | ################################################## | 100% 9.16s
avrdude: 3966 bytes of flash written
avrdude: verifying flash memory against firmware.hex:
avrdude: load data flash data from input file firmware.hex:
avrdude: input file firmware.hex auto detected as Intel Hex
avrdude: input file firmware.hex contains 3966 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 7.29s
avrdude: verifying ...
avrdude: 3966 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:D9, L:9F)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
trying to upload using arduino nano as isp to ATTiny13A
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c avrisp -P /dev/cu.wchusbserial1420
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
^C
.
hm, maybe the ATTiny’s broken
here the -v -vv and -vvv
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -v
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : usb
Using Programmer : usbasp
AVR Part : ATtiny13
Chip Erase delay : 4000 us
PAGEL : P00
BS2 : P00
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 5 4 0 no 64 4 0 4000 4000 0xff 0xff
flash 65 6 32 0 yes 1024 32 32 4500 4500 0xff 0xff
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
calibration 0 0 0 0 no 2 0 0 0 0 0x00 0x00
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -vv
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : usb
Using Programmer : usbasp
avrdude: seen device from vendor ->www.fischl.de<- data-blogger-escaped--="" data-blogger-escaped-avrdude:="" data-blogger-escaped-product="" data-blogger-escaped-seen="">USBasp<- data-blogger-escaped------------="" data-blogger-escaped----------="" data-blogger-escaped-------="" data-blogger-escaped------="" data-blogger-escaped-----="" data-blogger-escaped--="" data-blogger-escaped--c="" data-blogger-escaped--f="" data-blogger-escaped--p="" data-blogger-escaped--vvv="" data-blogger-escaped-0="" data-blogger-escaped-0x00="" data-blogger-escaped-0x53="" data-blogger-escaped-0xff="" data-blogger-escaped-100="" data-blogger-escaped-1024="" data-blogger-escaped-16="" data-blogger-escaped-17:26:24="" data-blogger-escaped-1="" data-blogger-escaped-2000-2005="" data-blogger-escaped-2007-2009="" data-blogger-escaped-200="" data-blogger-escaped-2013="" data-blogger-escaped-25="" data-blogger-escaped-2="" data-blogger-escaped-32="" data-blogger-escaped-3="" data-blogger-escaped-4000="" data-blogger-escaped-4500="" data-blogger-escaped-4="" data-blogger-escaped-5="" data-blogger-escaped-6.0.1="" data-blogger-escaped-64="" data-blogger-escaped-65="" data-blogger-escaped-6="" data-blogger-escaped-:="" data-blogger-escaped-a="" data-blogger-escaped-again="" data-blogger-escaped-ages="" data-blogger-escaped-and="" data-blogger-escaped-answer.="" data-blogger-escaped-at="" data-blogger-escaped-attiny13="" data-blogger-escaped-auto="" data-blogger-escaped-avr="" data-blogger-escaped-avrdude.conf="" data-blogger-escaped-avrdude:="" data-blogger-escaped-avrdude="" data-blogger-escaped-avrduderc="" data-blogger-escaped-because="" data-blogger-escaped-block="" data-blogger-escaped-brian="" data-blogger-escaped-bs2="" data-blogger-escaped-bytedelay="" data-blogger-escaped-c="" data-blogger-escaped-calibration="" data-blogger-escaped-check.="" data-blogger-escaped-check="" data-blogger-escaped-chip="" data-blogger-escaped-cmdexedelay="" data-blogger-escaped-compiled="" data-blogger-escaped-configuration="" data-blogger-escaped-connections="" data-blogger-escaped-copyright="" data-blogger-escaped-dean="" data-blogger-escaped-dec="" data-blogger-escaped-dedicated="" data-blogger-escaped-delay="" data-blogger-escaped-description="" data-blogger-escaped-detail="" data-blogger-escaped-device="" data-blogger-escaped-disposition="" data-blogger-escaped-does="" data-blogger-escaped-doesn="" data-blogger-escaped-done.="" data-blogger-escaped-double="" data-blogger-escaped-eeprom="" data-blogger-escaped-enable:="" data-blogger-escaped-equals="" data-blogger-escaped-erase="" data-blogger-escaped-error:="" data-blogger-escaped-etc="" data-blogger-escaped-exist="" data-blogger-escaped-failed="" data-blogger-escaped-file="" data-blogger-escaped-flash="" data-blogger-escaped-from="" data-blogger-escaped-given="" data-blogger-escaped-hfuse="" data-blogger-escaped-http:="" data-blogger-escaped-indx="" data-blogger-escaped-initialization="" data-blogger-escaped-is="" data-blogger-escaped-joerg="" data-blogger-escaped-lfuse="" data-blogger-escaped-local="" data-blogger-escaped-lock="" data-blogger-escaped-maxw="" data-blogger-escaped-memory="" data-blogger-escaped-minw="" data-blogger-escaped-mode="" data-blogger-escaped-no="" data-blogger-escaped-not="" data-blogger-escaped-nugroho="" data-blogger-escaped-nugrohos-macbook-air:coba3="" data-blogger-escaped-null="" data-blogger-escaped-on="" data-blogger-escaped-or="" data-blogger-escaped-override="" data-blogger-escaped-p00="" data-blogger-escaped-page="" data-blogger-escaped-paged="" data-blogger-escaped-pagel="" data-blogger-escaped-parallel="" data-blogger-escaped-part="" data-blogger-escaped-period="" data-blogger-escaped-poll="" data-blogger-escaped-polled="" data-blogger-escaped-pollindex="" data-blogger-escaped-pollvalue="" data-blogger-escaped-port="" data-blogger-escaped-program="" data-blogger-escaped-programm="" data-blogger-escaped-programmer="" data-blogger-escaped-pulse="" data-blogger-escaped-rc="-1" data-blogger-escaped-readback="" data-blogger-escaped-regular="" data-blogger-escaped-reset="" data-blogger-escaped-retry="" data-blogger-escaped-rosspack-avr-20131216="" data-blogger-escaped-sck="" data-blogger-escaped-seen="" data-blogger-escaped-serial="" data-blogger-escaped-sers="" data-blogger-escaped-set="" data-blogger-escaped-signature="" data-blogger-escaped-size="" data-blogger-escaped-skipping="" data-blogger-escaped-stabdelay="" data-blogger-escaped-syncloops="" data-blogger-escaped-system="" data-blogger-escaped-t13="" data-blogger-escaped-t="" data-blogger-escaped-target="" data-blogger-escaped-thank="" data-blogger-escaped-this="" data-blogger-escaped-timeout="" data-blogger-escaped-to="" data-blogger-escaped-try="" data-blogger-escaped-type="" data-blogger-escaped-us="" data-blogger-escaped-usb="" data-blogger-escaped-usbasp="" data-blogger-escaped-usbasp_open="" data-blogger-escaped-use="" data-blogger-escaped-user="" data-blogger-escaped-using="" data-blogger-escaped-usr="" data-blogger-escaped-vendor="" data-blogger-escaped-version="" data-blogger-escaped-wide="" data-blogger-escaped-wunsch="" data-blogger-escaped-www.bdmicro.com="" data-blogger-escaped-www.fischl.de="" data-blogger-escaped-yes="" data-blogger-escaped-you.="">www.fischl.de<- data-blogger-escaped--="" data-blogger-escaped-avrdude:="" data-blogger-escaped-product="" data-blogger-escaped-seen="">USBasp<- data-blogger-escaped------------="" data-blogger-escaped----------="" data-blogger-escaped-------="" data-blogger-escaped------="" data-blogger-escaped-----="" data-blogger-escaped-0.00savrdude:="" data-blogger-escaped-0="" data-blogger-escaped-0x00="" data-blogger-escaped-0x53="" data-blogger-escaped-0xff="" data-blogger-escaped-100="" data-blogger-escaped-1024="" data-blogger-escaped-1="" data-blogger-escaped-200="" data-blogger-escaped-25="" data-blogger-escaped-2="" data-blogger-escaped-32="" data-blogger-escaped-3="" data-blogger-escaped-4000="" data-blogger-escaped-4500="" data-blogger-escaped-4="" data-blogger-escaped-5="" data-blogger-escaped-64="" data-blogger-escaped-65="" data-blogger-escaped-6="" data-blogger-escaped-:="" data-blogger-escaped-accept="" data-blogger-escaped-ages="" data-blogger-escaped-and="" data-blogger-escaped-attiny13="" data-blogger-escaped-auto="" data-blogger-escaped-avr="" data-blogger-escaped-avrdude:="" data-blogger-escaped-because="" data-blogger-escaped-block="" data-blogger-escaped-bs2="" data-blogger-escaped-bytedelay="" data-blogger-escaped-calibration="" data-blogger-escaped-chip="" data-blogger-escaped-cmdexedelay="" data-blogger-escaped-dedicated="" data-blogger-escaped-delay="" data-blogger-escaped-description="" data-blogger-escaped-detail="" data-blogger-escaped-device="" data-blogger-escaped-disposition="" data-blogger-escaped-eeprom="" data-blogger-escaped-equals="" data-blogger-escaped-erase="" data-blogger-escaped-flash="" data-blogger-escaped-given="" data-blogger-escaped-hfuse="" data-blogger-escaped-http:="" data-blogger-escaped-indx="" data-blogger-escaped-initialized="" data-blogger-escaped-instructions="" data-blogger-escaped-lfuse="" data-blogger-escaped-lock="" data-blogger-escaped-maxw="" data-blogger-escaped-memory="" data-blogger-escaped-minw="" data-blogger-escaped-mode="" data-blogger-escaped-no="" data-blogger-escaped-null="" data-blogger-escaped-p00="" data-blogger-escaped-page="" data-blogger-escaped-paged="" data-blogger-escaped-pagel="" data-blogger-escaped-parallel="" data-blogger-escaped-part="" data-blogger-escaped-period="" data-blogger-escaped-poll="" data-blogger-escaped-polled="" data-blogger-escaped-pollindex="" data-blogger-escaped-pollvalue="" data-blogger-escaped-program="" data-blogger-escaped-programmer="" data-blogger-escaped-pulse="" data-blogger-escaped-readback="" data-blogger-escaped-reading="" data-blogger-escaped-ready="" data-blogger-escaped-reset="" data-blogger-escaped-retry="" data-blogger-escaped-sck="" data-blogger-escaped-serial="" data-blogger-escaped-set="" data-blogger-escaped-signature="" data-blogger-escaped-size="" data-blogger-escaped-stabdelay="" data-blogger-escaped-syncloops="" data-blogger-escaped-timeout="" data-blogger-escaped-to="" data-blogger-escaped-type="" data-blogger-escaped-us="" data-blogger-escaped-usbasp="" data-blogger-escaped-usbasp_cpi_cmd="" data-blogger-escaped-usbasp_initialize="" data-blogger-escaped-usbasp_program_enable="" data-blogger-escaped-usbasp_spi_set_sck_period="" data-blogger-escaped-www.fischl.de="" data-blogger-escaped-x30="" data-blogger-escaped-yes=""> 0x01, 0x31, 0x01, 0x01
avrdude: usbasp_cpi_cmd(0x30, 0x00, 0x01, 0x00) => 0x00, 0x31, 0x00, 0x01
Reading | ################# | 33% 0.00savrdude: usbasp_cpi_cmd(0x30, 0x00, 0x02, 0x00) => 0x00, 0x61, 0x00, 0x03
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x010103
avrdude: Expected signature for ATtiny13 is 1E 90 07
Double check chip, or use -F to override this check.
avrdude: usbasp_close()
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
Search the forums, its like the culprit is auto set sck on the new firmare. (http://openrcforums.com/forum/viewtopic.php?f=10&t=1363#p29615)
avrdude: auto set sck period (because given equals null)
got
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m8 -c avrisp -b 19200 -P /dev/cu.wchusbserial1420 -U flash:w:main.hex -F
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.12s
avrdude: Device signature = 0x1e9307
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "main.hex"
avrdude: input file main.hex auto detected as Intel Hex
avrdude: writing flash (3758 bytes):
Writing | ################################################## | 100% 8.72s
avrdude: 3758 bytes of flash written
avrdude: verifying flash memory against main.hex:
avrdude: load data flash data from input file main.hex:
avrdude: input file main.hex auto detected as Intel Hex
avrdude: input file main.hex contains 3758 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 6.93s
avrdude: verifying ...
avrdude: 3758 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:D9, L:9F)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$
no
uh, I don’t want to be back to old locked firmware. The forum suggest that i have to jumper four resistor
curious
connect it to my arduino pro mini
and voila…
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m328 -c usbasp -P usb -n
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e950f
avrdude: Expected signature for ATmega328 is 1E 95 14
Double check chip, or use -F to override this check.
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$ avrdude -p m328 -c usbasp -P usb -b 1920 -U flash:r:ArProMini.bin:r -v -F
avrdude: Version 6.0.1, compiled on Dec 16 2013 at 17:26:24
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "/usr/local/CrossPack-AVR-20131216/etc/avrdude.conf"
User configuration file is "/Users/nugroho/.avrduderc"
User configuration file does not exist or is not a regular file, skipping
Using Port : usb
Using Programmer : usbasp
Overriding Baud Rate : 1920
AVR Part : ATmega328
Chip Erase delay : 9000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 65 20 4 0 no 1024 4 0 3600 3600 0xff 0xff
flash 65 6 128 0 yes 32768 128 256 4500 4500 0xff 0xff
lfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
efuse 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
lock 0 0 0 0 no 1 0 0 4500 4500 0x00 0x00
calibration 0 0 0 0 no 1 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : usbasp
Description : USBasp, http://www.fischl.de/usbasp/
avrdude: auto set sck period (because given equals null)
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e950f
avrdude: Expected signature for ATmega328 is 1E 95 14
avrdude: safemode: lfuse reads as FF
avrdude: safemode: hfuse reads as DA
avrdude: safemode: efuse reads as 5
avrdude: reading flash memory:
Reading | ################################################## | 100% 8.43s
avrdude: writing output file "ArProMini.bin"
avrdude: safemode: lfuse reads as FF
avrdude: safemode: hfuse reads as DA
avrdude: safemode: efuse reads as 5
avrdude: safemode: Fuses OK (H:05, E:DA, L:FF)
avrdude done. Thank you.
Nugrohos-MacBook-Air:attiny13a nugroho$ ls -l
total 232
-rw-r--r-- 1 nugroho staff 32670 May 16 17:52 ArProMini.bin
drwxr-xr-x 8 nugroho staff 272 May 15 21:50 blinkLED_A
drwxr-xr-x 8 nugroho staff 272 May 16 00:30 coba1
drwxr-xr-x 8 nugroho staff 272 May 15 21:50 coba2
drwxr-xr-x 8 nugroho staff 272 May 16 09:16 coba3
-rw-r--r--@ 1 nugroho staff 11182 May 16 13:29 firmware.hex
drwxr-xr-x 4 nugroho staff 136 May 15 21:50 lcdNO
-rw-r--r--@ 1 nugroho staff 10597 May 16 15:19 main.hex
-rw-r--r-- 1 nugroho staff 8192 May 16 15:27 original_firmware.bin
-rw-r--r-- 1 nugroho staff 8192 May 16 13:42 original_firmware.hex
-rw-r--r-- 1 nugroho staff 15784 May 11 23:23 tn13Adef.inc
-rw-r--r--@ 1 nugroho staff 10785 Feb 28 2009 usbasp.atmega8.2009-02-28.hex
-rw-r--r--@ 1 nugroho staff 13248 May 16 14:05 usbasp.atmega8.2011-05-28.hex
Nugrohos-MacBook-Air:attiny13a nugroho$
its very weird and then
ugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -P usb -n -F
avrdude: error: programm enable: target doesn't answer. 1
avrdude: initialization failed, rc=-1
avrdude: AVR device initialized and ready to accept instructions
avrdude: Device signature = 0x000000 (retrying)
avrdude: Device signature = 0x000000 (retrying)
avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATtiny13 is 1E 90 07
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
sigh, my usbasp is ok
On the bright side: the update firmware warning is gone, using main.hex, a self compiled 2009 firmware
######
wait, ….
found another solution from http://forum.arduino.cc/index.php?topic=262150.0 and http://forum.arduino.cc/index.php?topic=282330.0
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -B4 -n
avrdude: set SCK frequency to 187500 Hz
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e9007
avrdude: safemode: Fuses OK (H:FF, E:FF, L:6A)
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
Nugrohos-MacBook-Air:coba3 nugroho$ avrdude -p t13 -c usbasp -P usb -B4 -U flash:w:coba3.s.hex
avrdude: set SCK frequency to 187500 Hz
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e9007
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: set SCK frequency to 187500 Hz
avrdude: reading input file "coba3.s.hex"
avrdude: input file coba3.s.hex auto detected as Intel Hex
avrdude: writing flash (34 bytes):
Writing | ################################################## | 100% 0.04s
avrdude: 34 bytes of flash written
avrdude: verifying flash memory against coba3.s.hex:
avrdude: load data flash data from input file coba3.s.hex:
avrdude: input file coba3.s.hex auto detected as Intel Hex
avrdude: input file coba3.s.hex contains 34 bytes
avrdude: reading on-chip flash data:
Reading | ################################################## | 100% 0.02s
avrdude: verifying ...
avrdude: 34 bytes of flash verified
avrdude: safemode: Fuses OK (H:FF, E:FF, L:6A)
avrdude done. Thank you.
Nugrohos-MacBook-Air:coba3 nugroho$
.
the coba.s is PB0, PB1, PB2 is connected to LED each. PB0 and PB is always on whilst PB2 blink every 1s.
.include "../tn13Adef.inc"
.org 0
init:
ldi r16,0b00000111
out DDRB,r16 ; PB2 as output
sbi PORTB,1
sbi PORTB,0
loop:
sbi PORTB,2
rcall timer
cbi PORTB,2
rcall timer
rjmp loop
timer:
ldi r16,0 ; these are timer counters
ldi r17,0
ldi r18,5
timer2:
inc r16 ; do 256 iterations
brne timer2
inc r17 ; do 256 times
brne timer2
dec r18
brne timer2 ; do 5 times
ret ; return
for me it’s enough for this day,
.
.
.
Actually, not enough (still want to fiddling with the Tiny :p )