HardwareFault on erase_user_flash with emWin

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

HardwareFault on erase_user_flash with emWin

1,100件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by dennisyeung on Wed Apr 23 23:35:24 MST 2014
Hi All,

I use LPC1788 with emWin. When I call erase_user_flash, everything is OK.
But with emWin in this way:
         GUI_Init();
         erase_user_flash();

This gives HardwareFault when calling     prepare_sector(USER_START_SECTOR,MAX_USER_SECTOR,cclk);
inside erase_user_flash();

Do anyone have the solution about it?

BR
Dennis
ラベル(1)
0 件の賞賛
返信
2 返答(返信)

1,080件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by dennisyeung on Thu Apr 24 04:03:09 MST 2014
Hi All,

After searching from internet, here is the link that giving the solution:

http://host.lpcware.com/content/forum/lpc1788-matrixarb-register-not-working-properly

BR
Dennis
0 件の賞賛
返信

1,080件の閲覧回数
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by dennisyeung on Thu Apr 24 03:30:57 MST 2014
Hi NXP FAE,

I found the fact that causing the HardFault Error without knowing the reason.

Inside the GUI_Init, it access the code MATRIX_ARB = 0xD, this causes the erase_user_flash to generate HardFault Error.
That is:
             MATRIX_ARB = 0xD;
             erase_user_flash();                  // Running this code with MATRIX_ARB is accessed, it will generate the error code.
With the MATRIX_ARB = 0xD is removed inside the _Initlcdcontroller, that is:
             GUI_Init();                                 // No MATRIX_ARB access inside the _Initlcdcontroller
             erase_user_flash();                  // It works well

Can anyone know why accessing MATRIX_ARB will causes the erase_user_flash() to generate the HardFault Error?

BR
Dennis
0 件の賞賛
返信