# $Id: avrdude.conf.in,v 1.116 2006/12/22 22:52:34 joerg_wunsch Exp $
#
# AVRDUDE Configuration File
#
# This file contains configuration data used by AVRDUDE which describes
# the programming hardware pinouts and also provides part definitions.
# AVRDUDE’s “-C” command line option specifies the location of the
# configuration file. The “-c” option names the programmer configuration
# which must match one of the entry’s “id” parameter. The “-p” option
# identifies which part AVRDUDE is going to be programming and must match
# one of the parts’ “id” parameter.
#
# Possible entry formats are:
#
# programmer
# id = <id1> [, <id2> [, <id3>] …] ; # <idN> are quoted strings
# desc = <description> ; # quoted string
# type = par | stk500 | stk500v2 | stk500pp | stk500hvsp | stk500generic |
# avr910 | butterfly | usbasp | serjtag | ft245r |
# jtagmki | jtagmkii | jtagmkii_isp | jtagmkii_dw |
# dragon_dw | dragon_jtag | dragon_isp | dragon_pp |
# dragon_hvsp; # programmer type
# baudrate = <num> ; # baudrate for avr910-programmer
# vcc = <num1> [, <num2> … ] ; # pin number(s)
# reset = <num> ; # pin number
# sck = <num> ; # pin number
# mosi = <num> ; # pin number
# miso = <num> ; # pin number
# errled = <num> ; # pin number
# rdyled = <num> ; # pin number
# pgmled = <num> ; # pin number
# vfyled = <num> ; # pin number
# ;
#
# part
# id = <id> ; # quoted string
# desc = <description> ; # quoted string
# has_jtag = <yes/no> ; # part has JTAG i/f
# has_debugwire = <yes/no> ; # part has debugWire i/f
# devicecode = <num> ; # deprecated, use stk500_devcode
# stk500_devcode = <num> ; # numeric
# avr910_devcode = <num> ; # numeric
# signature = <num> <num> <num> ; # signature bytes
# chip_erase_delay = <num> ; # micro-seconds
# reset = dedicated | io;
# retry_pulse = reset | sck;
# pgm_enable = <instruction format> ;
# chip_erase = <instruction format> ;
# chip_erase_delay = <num> ; # chip erase delay (us)
# # STK500 parameters (parallel programming IO lines)
# pagel = <num> ; # pin name in hex, i.e., 0xD7
# bs2 = <num> ; # pin name in hex, i.e., 0xA0
# serial = <yes/no> ; # can use serial downloading
# parallel = <yes/no/pseudo>; # can use par. programming
# # STK500v2 parameters, to be taken from Atmel’s XML files
# timeout = <num> ;
# stabdelay = <num> ;
# cmdexedelay = <num> ;
# synchloops = <num> ;
# bytedelay = <num> ;
# pollvalue = <num> ;
# pollindex = <num> ;
# predelay = <num> ;
# postdelay = <num> ;
# pollmethod = <num> ;
# mode = <num> ;
# delay = <num> ;
# blocksize = <num> ;
# readsize = <num> ;
# hvspcmdexedelay = <num> ;
# # STK500v2 HV programming parameters, from XML
# pp_controlstack = <num>, <num>, …; # PP only
# hvsp_controlstack = <num>, <num>, …; # HVSP only
# hventerstabdelay = <num>;
# progmodedelay = <num>; # PP only
# latchcycles = <num>;
# togglevtg = <num>;
# poweroffdelay = <num>;
# resetdelayms = <num>;
# resetdelayus = <num>;
# hvleavestabdelay = <num>;
# resetdelay = <num>;
# synchcycles = <num>; # HVSP only
# chiperasepulsewidth = <num>; # PP only
# chiperasepolltimeout = <num>;
# chiperasetime = <num>; # HVSP only
# programfusepulsewidth = <num>; # PP only
# programfusepolltimeout = <num>;
# programlockpulsewidth = <num>; # PP only
# programlockpolltimeout = <num>;
# # JTAG ICE mkII parameters, also from XML files
# allowfullpagebitstream = <yes/no> ;
# enablepageprogramming = <yes/no> ;
# idr = <num> ; # IO addr of IDR (OCD) reg.
# rampz = <num> ; # IO addr of RAMPZ reg.
# spmcr = <num> ; # mem addr of SPMC[S]R reg.
# eecr = <num> ; # mem addr of EECR reg.
# # (only when != 0x3c)
#
# memory <memtype>
# paged = <yes/no> ; # yes / no
# size = <num> ; # bytes
# page_size = <num> ; # bytes
# num_pages = <num> ; # numeric
# min_write_delay = <num> ; # micro-seconds
# max_write_delay = <num> ; # micro-seconds
# readback_p1 = <num> ; # byte value
# readback_p2 = <num> ; # byte value
# pwroff_after_write = <yes/no> ; # yes / no
# read = <instruction format> ;
# write = <instruction format> ;
# read_lo = <instruction format> ;
# read_hi = <instruction format> ;
# write_lo = <instruction format> ;
# write_hi = <instruction format> ;
# loadpage_lo = <instruction format> ;
# loadpage_hi = <instruction format> ;
# writepage = <instruction format> ;
# ;
# ;
#
# If any of the above parameters are not specified, the default value
# of 0 is used for numerics or the empty string (“”) for string
# values. If a required parameter is left empty, AVRDUDE will
# complain.
#
# NOTES:
# * ‘devicecode’ is the device code used by the STK500 (see codes
# listed below)
# * Not all memory types will implement all instructions.
# * AVR Fuse bits and Lock bits are implemented as a type of memory.
# * Example memory types are:
# “flash”, “eeprom”, “fuse”, “lfuse” (low fuse), “hfuse” (high
# fuse), “signature”, “calibration”, “lock”
# * The memory type specified on the avrdude command line must match
# one of the memory types defined for the specified chip.
# * The pwroff_after_write flag causes avrdude to attempt to
# power the device off and back on after an unsuccessful write to
# the affected memory area if VCC programmer pins are defined. If
# VCC pins are not defined for the programmer, a message
# indicating that the device needs a power-cycle is printed out.
# This flag was added to work around a problem with the
# at90s4433/2333’s; see the at90s4433 errata at:
#
# http://www.atmel.com/atmel/acrobat/doc1280.pdf
#
# INSTRUCTION FORMATS
#
# Instruction formats are specified as a comma seperated list of
# string values containing information (bit specifiers) about each
# of the 32 bits of the instruction. Bit specifiers may be one of
# the following formats:
#
# ‘1’ = the bit is always set on input as well as output
#
# ‘0’ = the bit is always clear on input as well as output
#
# ‘x’ = the bit is ignored on input and output
#
# ‘a’ = the bit is an address bit, the bit-number matches this bit
# specifier’s position within the current instruction byte
#
# ‘aN’ = the bit is the Nth address bit, bit-number = N, i.e., a12
# is address bit 12 on input, a0 is address bit 0.
#
# ‘i’ = the bit is an input data bit
#
# ‘o’ = the bit is an output data bit
#
# Each instruction must be composed of 32 bit specifiers. The
# instruction specification closely follows the instruction data
# provided in Atmel’s data sheets for their parts.
#
# See below for some examples.
#
#
# The following are STK500 part device codes to use for the
# “devicecode” field of the part. These came from Atmel’s software
# section avr061.zip which accompanies the application note
# AVR061 available from:
#
# http://www.atmel.com/atmel/acrobat/doc2525.pdf
#
#define ATMEGA168 0x86
# Note that both lists contradict for the ATmega32 and the ATmega163.
# We go with the original AVR910 in these cases. As AVR910 still has
# the originally name ATmega83 for the ATmega8535, we use the AVR109
# code here.
#
# Overall avrdude defaults
#
default_parallel = “lpt1”;
default_serial = “com1”;
#
# PROGRAMMER DEFINITIONS
#
programmer
id = “avrispv2”;
desc = “Atmel AVR ISP V2”;
type = stk500v2;
;
# This is supposed to be the “default” STK500 entry.
# Attempts to select the correct firmware version
# by probing for it. Better use one of the entries
# below instead.
programmer
id = “stk500v2”;
desc = “Atmel STK500 Version 2.x firmware”;
type = stk500v2;
baudrate = 19200;
;
programmer
id = “stk500pp”;
desc = “Atmel STK500 V2 in parallel programming mode”;
type = stk500pp;
;
#
# PART DEFINITIONS
#
#————————————————————
# ATmega168
#————————————————————
part
id = “m168”;
desc = “ATMEGA168”;
has_debugwire = yes;
flash_instr = 0xB6, 0x01, 0x11;
eeprom_instr = 0xBD, 0xF2, 0xBD, 0xE1, 0xBB, 0xCF, 0xB4, 0x00,
0xBE, 0x01, 0xB6, 0x01, 0xBC, 0x00, 0xBB, 0xBF,
0x99, 0xF9, 0xBB, 0xAF;
stk500_devcode = 0x86;
# avr910_devcode = 0x;
signature = 0x1e 0x94 0x06;
pagel = 0xd7;
bs2 = 0xc2;
chip_erase_delay = 9000;
pgm_enable = “1 0 1 0 1 1 0 0 0 1 0 1 0 0 1 1”,
“x x x x x x x x x x x x x x x x”;
chip_erase = “1 0 1 0 1 1 0 0 1 0 0 x x x x x”,
“x x x x x x x x x x x x x x x x”;
timeout = 200;
stabdelay = 100;
cmdexedelay = 25;
synchloops = 32;
bytedelay = 0;
pollindex = 3;
pollvalue = 0x53;
predelay = 1;
postdelay = 1;
pollmethod = 1;
pp_controlstack =
0x0E, 0x1E, 0x0F, 0x1F, 0x2E, 0x3E, 0x2F, 0x3F,
0x4E, 0x5E, 0x4F, 0x5F, 0x6E, 0x7E, 0x6F, 0x7F,
0x66, 0x76, 0x67, 0x77, 0x6A, 0x7A, 0x6B, 0x7B,
0xBE, 0xFD, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00;
hventerstabdelay = 100;
progmodedelay = 0;
latchcycles = 5;
togglevtg = 1;
poweroffdelay = 15;
resetdelayms = 1;
resetdelayus = 0;
hvleavestabdelay = 15;
resetdelay = 15;
chiperasepulsewidth = 0;
chiperasepolltimeout = 10;
programfusepulsewidth = 0;
programfusepolltimeout = 5;
programlockpulsewidth = 0;
programlockpolltimeout = 5;
memory “eeprom”
paged = no;
page_size = 4;
size = 512;
min_write_delay = 3600;
max_write_delay = 3600;
readback_p1 = 0xff;
readback_p2 = 0xff;
read = ” 1 0 1 0 0 0 0 0″,
” 0 0 0 x x x x a8″,
” a7 a6 a5 a4 a3 a2 a1 a0″,
” o o o o o o o o”;
write = ” 1 1 0 0 0 0 0 0″,
” 0 0 0 x x x x a8″,
” a7 a6 a5 a4 a3 a2 a1 a0″,
” i i i i i i i i”;
loadpage_lo = ” 1 1 0 0 0 0 0 1″,
” 0 0 0 0 0 0 0 0″,
” 0 0 0 0 0 0 a1 a0″,
” i i i i i i i i”;
writepage = ” 1 1 0 0 0 0 1 0″,
” 0 0 x x x x x a8″,
” a7 a6 a5 a4 a3 a2 0 0″,
” x x x x x x x x”;
mode = 0x41;
delay = 5;
blocksize = 4;
readsize = 256;
;
memory “flash”
paged = yes;
size = 16384;
page_size = 128;
num_pages = 128;
min_write_delay = 4500;
max_write_delay = 4500;
readback_p1 = 0xff;
readback_p2 = 0xff;
read_lo = ” 0 0 1 0 0 0 0 0″,
” 0 0 0 a12 a11 a10 a9 a8″,
” a7 a6 a5 a4 a3 a2 a1 a0″,
” o o o o o o o o”;
read_hi = ” 0 0 1 0 1 0 0 0″,
” 0 0 0 a12 a11 a10 a9 a8″,
” a7 a6 a5 a4 a3 a2 a1 a0″,
” o o o o o o o o”;
loadpage_lo = ” 0 1 0 0 0 0 0 0″,
” 0 0 0 x x x x x”,
” x x a5 a4 a3 a2 a1 a0″,
” i i i i i i i i”;
loadpage_hi = ” 0 1 0 0 1 0 0 0″,
” 0 0 0 x x x x x”,
” x x a5 a4 a3 a2 a1 a0″,
” i i i i i i i i”;
writepage = ” 0 1 0 0 1 1 0 0″,
” 0 0 0 a12 a11 a10 a9 a8″,
” a7 a6 x x x x x x”,
” x x x x x x x x”;
mode = 0x41;
delay = 6;
blocksize = 128;
readsize = 256;
;
memory “lfuse”
size = 1;
min_write_delay = 4500;
max_write_delay = 4500;
read = “0 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0”,
“x x x x x x x x o o o o o o o o”;
write = “1 0 1 0 1 1 0 0 1 0 1 0 0 0 0 0”,
“x x x x x x x x i i i i i i i i”;
;
memory “hfuse”
size = 1;
min_write_delay = 4500;
max_write_delay = 4500;
read = “0 1 0 1 1 0 0 0 0 0 0 0 1 0 0 0”,
“x x x x x x x x o o o o o o o o”;
write = “1 0 1 0 1 1 0 0 1 0 1 0 1 0 0 0”,
“x x x x x x x x i i i i i i i i”;
;
memory “efuse”
size = 1;
min_write_delay = 4500;
max_write_delay = 4500;
read = “0 1 0 1 0 0 0 0 0 0 0 0 1 0 0 0”,
“x x x x x x x x x x x x x o o o”;
write = “1 0 1 0 1 1 0 0 1 0 1 0 0 1 0 0”,
“x x x x x x x x x x x x x i i i”;
;
memory “lock”
size = 1;
min_write_delay = 4500;
max_write_delay = 4500;
read = “0 1 0 1 1 0 0 0 0 0 0 0 0 0 0 0”,
“x x x x x x x x x x o o o o o o”;
write = “1 0 1 0 1 1 0 0 1 1 1 x x x x x”,
“x x x x x x x x 1 1 i i i i i i”;
;
memory “calibration”
size = 1;
read = “0 0 1 1 1 0 0 0 0 0 0 x x x x x”,
“0 0 0 0 0 0 0 0 o o o o o o o o”;
;
memory “signature”
size = 3;
read = “0 0 1 1 0 0 0 0 0 0 0 x x x x x”,
“x x x x x x a1 a0 o o o o o o o o”;
;
;