9 years, 5 months ago.

LPC824 GPIO trouble

Team, I am using LPC824 for my project and we are not able to use the DigitalOut function on many pins.

Ex: We tried to use P0_12 (using the following definition). We didnt connect the pin to anything and checked the voltage after setting it to 1 and then to 0 and the voltage out on this pin was always zero

<code> DigitalOut var1(P0_12,1);

int main(){ var1 = 1 wait(5); vat1=0; wait(5); } </code>

We were wondering if the soldering was bad on our own board. So we changed the pin to P0_6/P0_1/P0_4/P0_0 and that didnt work either. We knew it wasnt a soldering problem because we use these pins for uart and the uart putc and getc are all working fine when use them (as uart)

Any suggestions?

What is worse is the LPCMAX 824 board is working perfectly. Its just our custom board thats not working.

Appreciate your help

Best regards

1 Answer

9 years, 5 months ago.

Try DigitalOut with only one parameter in declaration:

DigitalOut var1(P0_12);

Maybe some powersupply issue on your board, is your GND connected properly when you measure the pin voltage.