ATMEL HVPP Fusebit Doctor

Embed Size (px)

Citation preview

  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    1/6

    Atmega fusebit doctor (HVPP+HVSP)

    fix the fusebits

    3 May 2010 | Posted by manekinen

    Atmega fusebit doctor, as name says it, device for repairing dead Atmega

    (and Attiny from v2.04) family AVRs by writing correct fusebits. Most common mistakesor problems are a wrong clock source (CKSEL fusebits), disabled SPI programming

    (SPIEN fuse) or disabled reset pin (RSTDISBL fuse). This simple and cheap circuit will fix

    you uC in a fraction of a second. If in first case we can help ourself with clock generator,

    then in 2nd and 3rd cases bring uC back to life is impossible with standard serialprogrammer. Most of people do not decide to build parallel programmer because its

    inconvenient and its cheaper and faster to buy new uC.

    This circuit uses the parallel and serial high-voltage programming method. With thosemethods, we can talk to our dead chips which have reset or isp disabled:

    HVPP = high voltage parallel programming.

    HVSP = high voltage serial programming.

    Supported chips list:

    Code to this point supports 145 chips, but not all have been tested. Tested are lighted green.

    Report a problem and i make a fix :)

    1kB:

    AT90s1200, Attiny11, Attiny12, Attiny13/A, Attiny15

    2kB:

    Attiny2313/A, Attiny24/A, Attiny26, Attiny261/A, Attiny28, AT90s2333, Attiny22,

    Attiny25, AT90s2313, AT90s2323, AT90s2343

    4kB:

    Atmega48/A, Atmega48P/PA, Attiny461/A, Attiny43U, Attiny4313, Attiny44/A, Attiny48,

    AT90s4433, AT90s4414, AT90s4434, Attiny458kB:

    Atmega8515, Atmega8535, Atmega8/A, Atmega88/A, Atmega88P/PA, AT90pwm1,

    AT90pwm2, AT90pwm2B, AT90pwm3, AT90pwm3B, AT90pwm81, AT90usb82,Attiny84, Attiny85, Attiny861/A, Attiny87, Attiny88, AT90s8515, AT90s8535

    16kB:

    Atmega16/A, Atmega16U2, Atmega16U4, Atmega16M1, Atmega161, Atmega162,

    Atmega163, Atmega164A, Atmega164P/PA, Atmega165A/P/PA, Atmega168/A,

    http://diy.elektroda.eu/atmega-fusebit-doctor-hvpp/?lang=enhttp://diy.elektroda.eu/atmega-fusebit-doctor-hvpp/?lang=enhttp://diy.elektroda.eu/wp-content/uploads/2010/05/mega_fusebit_doctor_1.jpghttp://diy.elektroda.eu/atmega-fusebit-doctor-hvpp/?lang=enhttp://diy.elektroda.eu/atmega-fusebit-doctor-hvpp/?lang=en
  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    2/6

    Atmega168P/PA, Atmega169A/PA, Attiny167, AT90pwm216, AT90pwm316,

    AT90usb162

    32kB:

    Atmega32/A, Atmega32C1, Atmega323/A, Atmega32U2, Atmega32U4, Atmega32U6,

    Atmega32M1, Atmega324A, Atmega324P, Atmega324PA, Atmega325, Atmega3250,

    Atmega325A/PA, Atmega3250A/PA, Atmega328, Atmega328P, Atmega329,Atmega3290, Atmega329A/PA, Atmega3290A/PA, AT90can32

    64kB:

    Atmega64/A, Atmega64C1, Atmega64M1, Atmega649, Atmega6490, Atmega649A/P,Atmega6490A/P, Atmega640, Atmega644/A, Atmega644P/PA, Atmega645,

    Atmega645A/P, Atmega6450, Atmega6450A/P, AT90usb646, AT90usb647, AT90can64

    128kB:

    Atmega103, Atmega128/A, Atmega1280, Atmega1281, Atmega1284, Atmega1284P,AT90usb1286, AT90usb1287, AT90can128

    256kB:

    Atmega2560, Atmega2561

    About:

    Just put your dead mega in socket, press the START button, and enjoy your good-as-new

    processor. There are three slots on board, for most common AVRs, pins compatible with:

    Atmega8, Atmega16, Attiny2313. There is also an extra goldpin connector with allsignals so you can attach adapters:

    #1 adapter as HVPP extension, for 20pin Attiny26 compatible and 40pin Atmega8515

    compatible processors.HVSP adapter for 8pin and 14pin HVSP processors.

    Or make your own adapters for other types of processors, in trough-hole or surface-

    mounted, you can use the breadboard for this just connect signals to correct pins. How?

    Check your AVR datasheet, go to memory programming and then parallelprogramming check the signal names, all signals are described under the DIP40 slot. In

    doctor memory there is a lot of free space so project may be developed all the time. One

    sided PCB with 55mm x 92mm dimensions. On top side you need to solder severaljumpers, or, make this PCB as double sided choose yourself. Resistors from R7 to R23

    may be in 100ohm to 10K, but i suggest from 470ohm to 1K.

    ATTENTION! While mounting the DIP40 slot, you must to remove it pinsfrom 29 to 37. These pins must not have electrical contact with inserted uC pins, tracesruns there only to make the board smaller (onesided). Take a look at pic on the left, these

    you must remove from slot.

    Usage:

    The ALLOW ERASE jumper allows doctor to erase whole flash and eeprom memory, if itis open, doctor will newer erase memory but may not cure device if lockbits are enabled, so

    http://diy.elektroda.eu/wp-content/uploads/2010/04/pins-help.png
  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    3/6

  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    4/6

    But, source code is attached for this project, and with avr datasheet, it will be easy to

    understand this programming mechanism.

    Fusebits:

    Internal 1MHz clock, and enabled EESAVE bit see README file.

    If you use a brand new chips as doctor, you dont need to change anything 1MHz clock isalready set as default. EESAVE bit is optional. It disallows to erase the eeprom when

    firmware is actualized, eeprom is used to store the fixed chips counter which is send troughuart.

    UPDATE 2.1X ADDS NEW FUNCTIONALITY!

    Send your own fuses and locks trough terminal, talk with chips with broken signature. If

    you connect terminal Tx pin to PCB Rx pin manual mode will be enabled automatically.

    This requires Tx-terminal pin to be HIGH and OUTPUT when idle. It must pull up the 10K

    pulldown. If this condition is not met, doctor will work in normal automatic mode.

    HOWTO:

    First, doctor will read signature. And if fail, it will ask to type signature manually.

    Type two last bytes of signature in HEX (4 chars) and hit enter.

    Then, doctor will try to read the chip depending on given signature.When succeed, select an option:

    1 write fusebits this will perform a fuse write cycle with fuse-values from buffer

    (default).

    2 modify fusebits this will let you to type fuses manually, values in buffer will update.

    Type one byte in HEX (2 chars) and hit enter. Repeat for each byte (if exist).3 set lockbits type new lock value in HEX (2 chars) and hit enter do this with caution!

    Remember that unused bits are always 1! E.g. if want to enable LB1 and LB2, type FC(11111100)

    4 erase the chip this will just erase the chip and locks, it require allow erase jumper

    for safety.

    5 end exit programming and drop voltages, now you can safely remove the chip.

    See how Attiny13 with broken signature was repaired.

    See how the same chip was broken again.

    Do not suggest LEDs when in manual mode they just blinking randomly :)

    ATTENTION Firmware 2.1x NEED a pcb updated to version 2h!

    http://diy.elektroda.eu/wp-content/uploads/2010/05/fix_tiny13.pnghttp://diy.elektroda.eu/wp-content/uploads/2010/05/mess_tiny13.pnghttp://diy.elektroda.eu/wp-content/uploads/2010/05/fix_tiny13.pnghttp://diy.elektroda.eu/wp-content/uploads/2010/05/mess_tiny13.png
  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    5/6

    FAQ frequently asked Questions and Answers:

    P: No sign of life, no leds are working.

    O: Critical bugs on pcb, poorly programmed chip.

    P: Red led is on.O: Chip si not recognized. Make a voltage measurements. In idle, measure voltages on +12

    RESET and +5 SUPPLY at female goldpin connector you should get 0V or close to 0V

    on both. After the START button is pressed, you should get close to +12V and 5V for onesecond. If not, check transistors, if they are ok and if they are soldered ok.

    Q: Red led is on.

    A: Bugs on pcb, traces are packed densely and its very possible that you have invisible gap,

    shortcut, or dry joint. Check everything with multimeter, but PRECISELY.

    Q: Red led is on.

    A: Connect device to the terminal to get repair log. Press start to receive infos.

    Q: Received Init programming and nothing more OR received signature is 00 01

    02 or FF FF FF.

    A: Chip is broken, or there still are bugs on pcb look above.

    Q: Received signature is 1E 90 00, 1E 1E 1E, or something familiar (meaningful

    data).

    A: Chip is good, it initiates, look for shortcuts on DATA, BS, XA lines.

    Q: Green led is on / Verifying OK! received, but chips dont work with standard

    programmer.A: You can be 100% sure that fuses are fixes, chip have hardware ISP damaged or it have

    some other damage.

    Q: What are Read Signature FAIL! and Trying T2313 pinout OK doing in log?

    A: Alle the 20pin chips need to be threated individually. First, device tries to read chip with

    standard schematic, and if it fails (FAIL!), then it tries to use schematic for 20pin T2313

    compatible chips and then chip is read properly. This is normal behavior, this not a bug.

    Q: What are

  • 7/31/2019 ATMEL HVPP Fusebit Doctor

    6/6