how to unlock PIC18f4685

Discussion in 'Embedded Systems and Microcontrollers' started by mik3, Jul 19, 2008.

  1. mik3

    Thread Starter Senior Member

    Feb 4, 2008
    4,846
    63
    I have a PIC18f4685, i think i set the code protection by fault and now i cant change the code. Is there a way to erase the configuration bits and repair the microcontroller?
     
  2. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Hello mik3,

    I don't know how to unlock it, but perhaps someone on the microchip forum encountered the same problem.
    http://forum.microchip.com/
    Perhaps a search over there already hepls.

    Greetings,
    Bertus
     
  3. n9352527

    AAC Fanatic!

    Oct 14, 2005
    1,198
    4
    Erase the (entire) chip first. Then you can write new codes in.
     
  4. mik3

    Thread Starter Senior Member

    Feb 4, 2008
    4,846
    63
    I did it but it didnt work. What to do? If i set the configuration bits to the protected mode by fault can i erase them and unlock the chip?
     
  5. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Hello,

    The protection bits can only be earsed with "bulk erase".
    This is described in the attached document in chapter 3, page 16.

    Greetings,
    Bertus
     
  6. sonnyboy82368

    New Member

    Mar 20, 2009
    2
    0
    i thinik if you are using pickit2 you can erase it then unprotect code and enter it again (code).
     
Loading...