Skip to main content
Visitor II
May 16, 2005
Question

Accessing Flash Registers

  • May 16, 2005
  • 3 replies
  • 835 views
Posted on May 16, 2005 at 06:39

Accessing Flash Registers

    This topic has been closed for replies.

    3 replies

    Visitor II
    May 13, 2005
    Posted on May 13, 2005 at 16:26

    I've bootloaded some code to reprogram the ST10 Flash, but when the code attempts to access the Flash registers an exception occurrs. I've enabled XFLASh in XPERCON and XBUS in SYSCON and have declared a flash register as *( unsigned int huge *)(0x000E0000).

    What else am I missing?

    Visitor II
    May 16, 2005
    Posted on May 16, 2005 at 06:08

    Check also that ROMEN bit in SYSCON register is set.

    [ This message was edited by: Najoua on 20-12-2006 16:29 ]

    Visitor II
    May 16, 2005
    Posted on May 16, 2005 at 06:39

    For example;

    _huge unsigned int* FCR0H_reg;

    FCR0H_reg = (_huge unsigned int*)(0x000E0002);

    *FCR0H_reg=0x2000; //word program

    Are you doing in this way? If so and you have enabled XFLASH, XBUS and ROMEN=1, it should be working. Remember that if you want to write B0F0, B0F1, B0F2, B0F3 in bootstrap mode you have to address them through 0x01xxxx addresses.