Need help with bootloader for m328p


i'm trying upload boot loader blank atmega328p.
but process sooo confusing me.

im using usbtiny programmer atmel target board,
on linux system.
i'm gonna using external crystal clock, 16mhz.
as far process this:
unlock fuse bits, set new fuse bits, upload boot loader, lock fuse bits.
but how avrdude confused.
getting high , low fuse bits form m328 pretty easy
code: [select]
avrdude -c usbtiny -p m328p -v
hfuse d9 , lfuse 62 , extended ff.
but value use lock , unlock fuses?

also tried using fuse calculator new fuse values
http://www.engbedded.com/fusecalc/
but it's confusing, think i'm suppose use 0xda hfuse ,
0xff lfuse, 1 suggested me. never got
those values calculator.

not sure think code like:
code: [select]
avrdude -c usbtiny -p m328p -u lock:w:0xff:m -u lfuse:w;0xff:m -u hfuse:w:0xda:m
not sure "-u lock" value.
then bootloader be:
code: [select]
avrdude -c usbtiny -p m328p -u flash:w:path/to/bootloader
then re-lock fuse bit:
code: [select]
avrdude -c usbtiny -p m329p -u lock 0xff
again not sure lock fuse bit value.
so how did do? close?
is lock fuse bit same extended fuse bit??

forgive me if stupid question, want right , not end bricked chip.

i wish there easier way calculate fuses,
that calculator linked bit daunting new guys.
any insight , constructive criticism helpful.

you can program 328 bootloader using usbtiny programmer directly inside arduino ide in tools menu. should handle finding correct hex code , fuse requirements of processor type select in board menu in tools menu.

lefty


Arduino Forum > Forum 2005-2010 (read only) > Software > Syntax & Programs > Need help with bootloader for m328p


arduino

Comments

Popular posts from this blog

CAN'T INSTALL MAMBELFISH 1.5 FROM DIRECTORY - Joomla! Forum - community, help and support

error: expected initializer before 'void'

CPU load monitoring using GPIO and leds - Raspberry Pi Forums