This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Error using GPIOTE_IRQhandler

I'm having a problem adding the GPIOTE_IRQhandler() to my main.c file (see attached). I'm getting a compiler error that it is doubly defined in app_gpiote.o and main.o, but app_gpiote.h is not in the include path for my project. How can I use the GPIOTE_IRQHandler() in this project?

main.c

Parents
  • You are probably getting the error because the app_gpiote.c file is still compiled and linked in your project, even though you're not including the header-file. If you want to remove it from your project you can right-click "nRF_Libraries" -> Options, and remove app_gpiote, or use the run-time environment manager:

    image description

    Is there any particular reason why you don't want to use the app_gpiote library?

Reply
  • You are probably getting the error because the app_gpiote.c file is still compiled and linked in your project, even though you're not including the header-file. If you want to remove it from your project you can right-click "nRF_Libraries" -> Options, and remove app_gpiote, or use the run-time environment manager:

    image description

    Is there any particular reason why you don't want to use the app_gpiote library?

Children
  • Hey, thanks very much for the answer to my question. My experience is all embedded programming, so I'm used to writing my own ISRs and drivers, and haven't used an SDK too much. I was trying to do things as low level as possible. I tried out the app_gpiote library today and it works real well. One question though:

    Can I use the app_gpiote library and NOT have the nRF51 wakeup from sd_power_system_off() when the GPIO input pin changes state?

    I'm configuring the input pin like this: nrf_gpio_cfg_input(BTN_1, NRF_GPIO_PIN_PULLUP); which according to nrf_gpio.h disables port sensing. If I understand it, disabling Sense, should stop the pin interrupt from waking the device, but it doesn't work that way on my test system.

  • This is a different question that you started, can you please open another thread for that. We try to keep it that way so that others looking for similar problems could find a solution easily.

Related