This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

mon51

I'm using PHILIPS 89C51RD2, it has 64K internal FLASH and ISP, how to modify MON51 program to fit this internal FLASH so that I can conect PHILIPS89C51RD2 chip with UV2 directly without external RAM expadation?

Parents
  • I'm using PHILIPS 89C51RD2, it has 64K internal FLASH and ISP, how to modify MON51 program to fit this internal FLASH so that I can conect PHILIPS89C51RD2 chip with UV2 directly without external RAM expadation?<br>
    <br>
    This will be difficult.<br>
    <br>
    RAM (rather than FLASH) is used because of the way the monitor sets breakpoints when you run and single-step thru your program.<br>
    <br>
    To set breakpoints (or single-step breakpoints), the monitor must replace instructions in your program with a jmp instruction (to branch to the monitor's breakpoint handler). This happens EVERY TIME you single-step.<br>
    <br>
    If you have only FLASH memory, then everytime you single-step, the monitor would have to read an entire FLASH page (however big that is), save it, erase the page, and re-program the page with the modified instruction.<br>
    <br>
    Not only is this complex, but it is incredibly slow, and will (eventually) exhaust the write cycles of the FLASH memory (OK, maybe not before we all die).<br>
    <br>
    If you still want to do this, take a look at the INSTALL.A51 file in the MON51 directory. There are routines in this file that read and write downloaded code. You can make your FLASH changes there.<br>
    <br>
    Jon<br>
    <br>

Reply
  • I'm using PHILIPS 89C51RD2, it has 64K internal FLASH and ISP, how to modify MON51 program to fit this internal FLASH so that I can conect PHILIPS89C51RD2 chip with UV2 directly without external RAM expadation?<br>
    <br>
    This will be difficult.<br>
    <br>
    RAM (rather than FLASH) is used because of the way the monitor sets breakpoints when you run and single-step thru your program.<br>
    <br>
    To set breakpoints (or single-step breakpoints), the monitor must replace instructions in your program with a jmp instruction (to branch to the monitor's breakpoint handler). This happens EVERY TIME you single-step.<br>
    <br>
    If you have only FLASH memory, then everytime you single-step, the monitor would have to read an entire FLASH page (however big that is), save it, erase the page, and re-program the page with the modified instruction.<br>
    <br>
    Not only is this complex, but it is incredibly slow, and will (eventually) exhaust the write cycles of the FLASH memory (OK, maybe not before we all die).<br>
    <br>
    If you still want to do this, take a look at the INSTALL.A51 file in the MON51 directory. There are routines in this file that read and write downloaded code. You can make your FLASH changes there.<br>
    <br>
    Jon<br>
    <br>

Children
No data