I am trying to write in system moudle configuration register(PCR), and while in simulator mode, i am getting this error: *** error 65: access violation at 0xFFFFF70C: no 'write' permission
code is as follows
main(void) { pSM->PCR = CLKDIV_2; pSM->GCR = ZPLL_CLK_DIV_PRE_1; pSM->PCR |= PENABLE; }
pSM is pointer to System module structure having all registors at corresponding address.
I think problem might be because i am in user mode, so also let me know how to switch between user mode and supervisor mode.
--Deepak
Refer to http://www.keil.com/support/docs/814.htm
Jon