This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Adding new driver in segger embedded studio

Hello everyone !!!

I've recently started working with Segger Embedded studio for nfr52840. I want to add a new driver into an existing projects.Let's say GPIOTE

  1. I added nrf_drv_gpiote.c in nrf_Drivers folder
  2. Enabled driver in sdk_config.h

Still when I include "nrf_drv_gpiote.h" in main.c file, compiler couldn't find it.

what else need to be done to add this driver?

Parents
  • You must add the path to the nrf_drv_gpiote.h file to the compiler include directories: In Embedded Studio right click the solution or project and select Code->Preprocessor then User Include Directories and add the path to the file. The file is located in "components/drivers_nrf/gpiote". Depending on where your project file is located relative to the nRF5 SDK you will need to edit the path. Look at the other User Include Directories for help.

Reply
  • You must add the path to the nrf_drv_gpiote.h file to the compiler include directories: In Embedded Studio right click the solution or project and select Code->Preprocessor then User Include Directories and add the path to the file. The file is located in "components/drivers_nrf/gpiote". Depending on where your project file is located relative to the nRF5 SDK you will need to edit the path. Look at the other User Include Directories for help.

Children
Related