LPC54102 reading GPIO pins

cancel
Showing results for 
Search instead for 
Did you mean: 

LPC54102 reading GPIO pins

200 Views
juliancrouch
Contributor I

Hey guys!

I am working on an embedded project and am relatively new to the mc world, so go easy.  I'd ask my teacher but he is of the "you only learn it if you teach yourself" mentality...

Anyway, this is an independent study project and is only loosely related to school, so don't feel as if there is any sort of cheating going on.

We are using a LPC 54102 board and I am working on getting digital in/out working.  I can send any of my arduino shield pins HIGH/LOW no problem, but I am having a problem reading from them.  Here is what I have:

My functions

My main

Lines 57 and 58 are basically debugging tests, but I still don't know why my pinState is always getting flagged to true when I call digitalRead()

Any pointers would be amazing!

0 Kudos
2 Replies

79 Views
martin_maurer
Contributor III

Sorry, just a quick look. You configure 0.6 and read from 0.8?

Otherwise please check if the used functions parameters are correct.

0 Kudos

79 Views
juliancrouch
Contributor I

Yeah, I fixed that shortly after making the post, so assume that this is the new file

Revised Main

0 Kudos