lpcware

unreflected SYSAHBCLKCTRL register

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by Thucydides on Tue May 22 23:29:27 MST 2012
Hello,
Now I'm in trouble with a strange register setting behavior of LPC1343.
I set 6 bit of the SYSAHBCLKCTRL register of LPC1343 to use GPIO like this.
LPC_SYSCON->SYSAHBCLKCTRL |= (1<<6);

But some of ports couldn't toggle as quite normal GPIO.
In particular, P1.0, P1.1, P2.0, P0.11, P1.2.
So I checked set register value (LPC_SYSCON->SYSAHBCLKCTRL) by debugger and I found a quite strange behavior.
6 bit of the  SYSAHBCLKCTRL was clear and even I put writing code (set 6 bit) in a loop forcibly but the same.
Watched register value (lower byte of 32bits) was 0b10111111 in sum all 7 bits was set except 6 bit.
Then I tried to stop to feed clock to A/D function for sharing pins like this.

LPC_SYSCON->PDAWAKECFG |= (1<<4);
LPC_SYSCON->PDRUNCFG |= (1<<4);

But these 5 GPIOs didn't work meanwhile other some GPIOs work.
How could I toggle these GPIOs or are there any means to set??

Thanks,

Outcomes