switch PIO on and of

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

switch PIO on and of

1,573 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by irven on Thu Jun 28 07:11:28 MST 2012
hi i m new and i don't know much.
i work with a lpcexpresso 1343 and the base board.
the demo programs are working good.
now i want to switch some ports on and off on my own.
do i need all the headers or is it possible to write direct on the registers?
please help
0 Kudos
Reply
3 Replies

1,567 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bruno on Thu Jun 28 07:24:21 MST 2012
Yes, Like Example:

/* use port0_1 as input event, interrupt test. */
  GPIOSetDir( PORT0, 1, 0 );
  /* port0_1, single trigger, active high. */
  GPIOSetInterrupt( PORT0, 1, 0, 0, 0 );
  GPIOIntEnable( PORT0, 1 );

You can write direct.
Or put #defines for don't stay confusion for you.
0 Kudos
Reply

1,567 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Ex-Zero on Thu Jun 28 07:21:12 MST 2012

Quote: irven
... is it possible to write direct on the registers?



Of course :)
0 Kudos
Reply

1,567 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by bruno on Thu Jun 28 07:20:45 MST 2012
Hello,

I want change of ports of GPIO??

Bruno Braga
0 Kudos
Reply