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

My GPIO is unable to see nrfsx_gpiote functions

I Have attached my project which is an SDK 15. project, starting with the simple twi sensor project and including some functions calls from gpio from SDK 14.0, porting gpio from 14.0. The project does not compile correctly on account it can not see the function calls to the nrfx_gpiote.h file located in the modules folder. The port has utilized the function call of the 15.0 and does not utilize any defines between 14.0 and 15.0. I utilize the command line and armgcc makefile inside the pca10040 directory. Can anyone see a problem with the port and makefile edits? MPUsimpleTWI.zip

  • Hello,

    I see that you have already included the nrfx_gpiote.c file in your makefile.

    Near the top of nrfx_gpiote.c there is a check whether gpiote is enabled or not (typically a define in the sdk_config.h file:

    //nrfx_gpiote.c
    
    #include <nrfx.h>
    
    #if NRFX_CHECK(NRFX_GPIOTE_ENABLED)
    
    ...
    //the rest of nrfx_gpiote.c file
    ...
    
    #endif // NRFX_CHECK(NRFX_GPIOTE_ENABLED)

     

    This was not defined in your sdk_config.h file.

    I took the nrfx_gpiote parts from another project, SDK\examples\peripheral\gpiote, and added it to your sdk_config.h file. You might want to look through the defines, and see if it suites your project. At least it should compile with the attached sdk_config.h file. The only changes are adding the nrfx_gpiote defines from line 487 to 563.

    (I also created my own custom_board.h file with the gpio defines that you use in the project to get to the point where you were having issues, but that should not impact your project)

     

    sdk_config.h

     

    Best regards,

    Edvin

  • Edvin,

    Yes, thank you! Yes, always scavenging examples to get my stuff up and running. Seems like the sdk_config.h would just be a full file with every options in it and they would get turned on, off or assigned the proper value.  

    You mentioned the make files, how are the example makefiles originated?

    Thank you for your quick and correct response, makes my day so much more productive!

Related