Skip to main content

Restoring P89V51RD2 's Bootloader

If you have used P89V51RD2 a lot, you would have realised that many times it happens that the microcontroller refuses to be recognized by FlashMagic and then you have to resort to replacing the microcontroller with a new one. Assuming that your hardware circuitry and computer are free from any problems, there are only two things that could have gone wrong - your microcontroller has suffered an internal hadware failure (maybe because of overvoltage or ESD) or the bootloader residing inside the microcontroller has got corrupted. Microcontrollers with spoilt bootloaders can easily be fixed by re-programming the bootloader into their flash memories. So before dunking those seemingly dead micros into the waste baskets, try to resuscitate them by reprogramming their bootloaders. Heres how you can do this using a Universal Programmer:

Step 1:
Acquire a "Universal Programmer". UC Micro System's UNIPro 110u is one such programmer. The photos below explains the process of restoring the bootloader using this programmer. The procedure for doing the same using a different brand of universal programmer would be similar.



Step 2:
Download and install the universal programmer's PC frontend software. In case of UNIPro 110u you can get the latest version from here (as of the day of posting this blog, the latest version was 4.20 and it did not yet work on Windows 7).
Step 3:
  1. Visit the "P89V51RB2_RC2_RD2 Product Information Page" at NXP here.
  2. At the bottom of this page, you will find a link: "P89V/LV51RD2 Boot Loader update V5" (Direct link to ZIP file)
  3. Download this ZIP archive (p89v_lv51rd2_bl_upd.zip). It contains the bootloader HEX file.
  4. Within this ZIP archive, you will find two HEX files. We are interested only in P89V51RD2_BL_V05.hex. (The other HEX file is for updating the bootloader via flashmagic in cases where the original bootloader is still intact inside the microcontroller)

Step 4:
Select the microcontroller in the programmer frontend software.


Step 5:
Select the HEX file: P89V51RD2_BL_V05.hex


Step 6
Press the program button! (In case of UNIPro 110u, ignore the "Need AC Adaptor message" - USB power is enough to program P89V51RD2)


If the microcontroller gets programmed successfully, then the bootloader would now reside in the flash memory of the microcontroller. The microcontroller will now work again with FlashMagic.

NOTE regarding updated bootloader:
An updated version for the bootloader for P89V51RD is available from FlashMagic's website. Direct link here. Read the enclosed PDF file in the ZIP archive to know how to use it.

NOTE for microcontrollers manufactured by SST:
This process will also work with
SST89E516RD (manufactured by SST) whose bootloaders are corrupted.
EasyIAP (which is equivalent in functionality to FlashMagic) is used to communicate with SST89E516RD and download program into it.
While operating the Universal Programmer, you will need to select the microcontroller as "SST89E516RD". The bootloader for this microcontroller is available here. Download the ZIP archive named "IntMode_x5xx.zip" (direct link here). The bootloader is in form of a BIN file (instead of a HEX file) named "F51MBLL5.BIN".
The "IntMode_x5xx.zip" archive also contains the setup file for EasyIAP which is similar in functionality as FlashMagic but is instead used for programming SST's microcontrollers.

Comments

  1. Hey Lare,
    i see that you are using p89v51rd.
    i was using p89c51. and lately i bought p89v51rd.
    i am burning p89c51 through RS232.
    but when i changed the chip to p89v51rd(as i know is the same.. but bigger memory.) Flash magic program cant burn the program.
    what do you think the problem..
    thank you!!

    p.s my email is michael.oks@gmail.com

    ReplyDelete
  2. its very informative, i was wondering for the RD2 bootloader and got help from this site only........................great Blog....


    ----Arun Barman
    Development Engineer(R&D Dept.)
    Mumbai

    ReplyDelete
  3. Hi,
    I went through the blog, do you by chamce have programmer software for unipro110u.
    My email:divyu.gups@gmail.com

    ReplyDelete

Post a Comment