# Module gpio.c (please LeonidM)

**URL:** <https://forums.digi.com/t/module-gpio-c-please-leonidm/4850>\
**Category:** Linux\
**Tags:** hardware\
**Created:** [February 26, 2010, 12:48pm UTC](https://forums.digi.com/t/module-gpio-c-please-leonidm/4850 "2010-02-26T12:48:16Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anagil](https://avatars.discourse-cdn.com/v4/letter/a/d6d6ee/32.png) [@anagil](https://forums.digi.com/u/anagil)\
**Post date:** [February 26, 2010, 12:48pm UTC](https://forums.digi.com/t/module-gpio-c-please-leonidm/4850/1 "2010-02-26T12:48:16Z")

</div>

Hello again. I already used the gpio.c module, which in my case the function is “ns9xxx\_gpio\_irq\_handler” but I get many errors “no such file or directory” of libraries "# include " " # include “,” # include “and many more and errors as " error: ‘GPIO\_CFG\_FUNC\_2’ undeclared here (not in a function)”. I’m reading the book LINUX DEVICE DRIVERS and places that you must have a current version of kernel (I have the 2.26). Do you think that it can be the version of the Kernel the problem that to compile that give me so many errors?

Thank you very much LeonidM.

---

<div class="post-metadata">

**Author:** ![LeonidM](https://avatars.discourse-cdn.com/v4/letter/l/d26b3c/32.png) [@LeonidM](https://forums.digi.com/u/LeonidM)\
**Post date:** [February 26, 2010, 8:35pm UTC](https://forums.digi.com/t/module-gpio-c-please-leonidm/4850/2 "2010-02-26T20:35:14Z")

</div>

Are you using DEL? What version? Create a new Uboot/Kernel/rootfs project ,go to kernel configuration screen and add gpio\_test application. It will also add a gpio module for you. Do not change anything else. Build the kernel and rootfs, install, load. It will compile with no errors. Follow instructions in online help to create nodes for GPIOs in example, load gpio module and run gpio\_test example. It runs fine, i’ve done it myself. Once al this is working for you you can start making changes to the example and the module.
