[SOLVED] J-Link Flash Loader: erase and program maximum times in FlashDevice

This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

  • [SOLVED] J-Link Flash Loader: erase and program maximum times in FlashDevice

    I'm creating a Flash Loader for a SPI Flash connected to a SPI peripheral of LPC1788. After issuing sector erase command, you can know when the erase is complete by polling busy bit in the STATUS register.

    How do J-Link know when a sector erase is complete? In FlashDevice structure there are two members: TimeoutProg and TimeoutErase. Does it mean that J-Link waits for this maximum timeout to know when the erase is complete?

    Another question. Should the function EraseSector() return only after the erase is complete (i.e. after busy flag of SPI Flash comes back to zero)? Could EraseSector() return just after issuing the erase command?
  • EraseSector() must only return when the erase of the sector is complete.
    The timeout is a value that must not exceeded by an EraseSector() call.
    Please read the forum rules before posting.

    Keep in mind, this is *not* a support forum.
    Our engineers will try to answer your questions between their projects if possible but this can be delayed by longer periods of time.
    Should you be entitled to support you can contact us via our support system: segger.com/ticket/

    Or you can contact us via e-mail.