lpcware

LPC4078 LQFP100: GPIO p0.28 not working

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by gjwep on Fri Nov 06 10:00:27 MST 2015
Hello,

I am trying to configure P0.27 and P0.28 as output ports on a LPC4078 LQFP100 (custom board). Per UM these two are "Type I IOCON registers" which inherit some behavior from the I2C functions available on them. I configured P0.27 according to UM table 88 and can change its pin state as expected. However, P0.28 doesn't want to play and neither SETing it through code nor changing it manually in the debugger affects the PIN state of 0 (verified with voltmeter). There is no external pull-down attached to the pin. Behavior confirmed with a second board of the same build (LPC4078 LQFP100).

Initializations and toggling of pin state shown for both P0.27 (which works) and P0.28 (which doesn't):


...
Chip_GPIO_Init(LPC_GPIO);
Chip_IOCON_Init(LPC_IOCON);

//p0.27
Chip_IOCON_PinMuxSet(LPC_IOCON, 0, 27, (IOCON_FUNC0));      
Chip_GPIO_SetPinDIR(LPC_GPIO, 0, 27, true);
Chip_GPIO_SetPinOutLow(LPC_GPIO, 0, 27);      //stays low (default)
Chip_GPIO_SetPinOutHigh(LPC_GPIO, 0, 27);     //switches to high OK

//p0.28
Chip_IOCON_PinMuxSet(LPC_IOCON, 0, 28, (IOCON_FUNC0));
Chip_GPIO_SetPinDIR(LPC_GPIO, 0, 28, true);
Chip_GPIO_SetPinOutLow(LPC_GPIO, 0, 28);      //stays low (default)
Chip_GPIO_SetPinOutHigh(LPC_GPIO, 0, 28);     //STAYS LOW
...


What am I missing?

Thanks in advance,
gj

Outcomes