Download all the files
run detect_GPIO_BASE.sh to set the $GPIO_BASE environment variable
Read the example .c files (such as test_in_out.c), the header contains instructions to compile and run the file.
Reuse the example source code for your own program.
- don't forget to initialise the desired pins with PI_GPIO_config(pin_number, IO_mode);
- GPIO_SET_N(pin_number); set the selected pin
- GPIO_CLR_N(pin_number); clears the selected pin
- GPIO_LEV_N(pin_number); reads the selected pin
Share the code and the bug reports !