GPIO OF OMAP5912

w.b.b
2006-08-29T06:43:31Z

[-- Attachment #1: Type: text/plain, Size: 1007 bytes --]

hi:

i want to do some work about OMAP5912'GPIO.but I am failed to do that.

the following is a simple program:

test.c

-----------------------------------------------------

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>

#define GPIO3_OUT 0xfffbbc40 /* lp1 */

int main()
{
/* Get access to the ports */

/* Set the data signals (D0-7) of the port to all low (0) */
outb(0xffff, GPIO3_OUT);

/* Sleep for a while (100 ms) */
usleep(100000);
}
-----------------------------------------------------
arm-linux-gcc -g test.c -o test.out
----------------------------------------------------
I run the binary file on the omap:./test.out
-----------------------------------------------------
but i get the result:segmentation falt!
---------------------------------------------------
who can provide me with information? if you have done work related with gpio,would you like send me some examplefile?
thanks!

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]