I don't understand why the program counter JUMPS. Only the register shall be read. If I would change R2 into 0x0000 0034 manually, the behaviour is ok.
What flag do I have to set or clear in any register to get access to this LPC_SYSCTL->PDRUNCFG?
Hi,
You can access all the register in SYSCON module without any condition, for your case, you can access the SYSCON->PDRUNCFG0 directly without any restriction.
But for exampler if you access the ADC0 register, you have to enable gated clock for ADC0
set AHBCLKCTRL0[ADC0] bit
If you want to ADC work, you have to do:
set the ADC power by configuring the PDRUNCFG0
configure the correct ADC clock with ADCCLKDIV reg and ADCCLKSEL reg.
Hope it can help you
BR
XiangJun Rong
That is the strange behaviour. If you look at my video you can see at the disassembler site that the register LPC_SYSCTL->PDRUNCFG shall be load in a register. And in that step something strange happenes. The question is, why?
Hi,
When a module is powered off, it can not be read. If you access the registers of module, you must power the module.
Hope it can help you
BR
XiangJun Rong
I understand what you mean. But this register LPC_SYSCTL->PDRUNCFG is powered. I can edit it with the debugger.
Hi,
could you clarify your question so that I can understand your issue clearly?
BR
Xiangjun Rong