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

Changing the output from LED1 to a GPIO pin say P0.11 on nRF52832

Hello,

I am working on few projects involving nRF52 DK's using the nRF52 15.2.0 SDK. I would like to know which would be a more efficient and reliable way of changing the output from LED1 to a GPIO pin say P0.11 on the board among the two ways I know which I have stated below.

--> Creating a custom board in which I define the LED1 pin to be the desired P0.11 pin.

--> Modifying the main.c file to reflect the changes at the output on the desired pin.

Thank you.

Parents
  • Hi,

    For rapid prototyping of a couple of projects I would just modify the main.c file. On the other hand, if you have several projects using the same pin configuration or if you are cooperating on the same code base with other developers then it might be a good idea to make a custom board header file that can easily be shared. 

    But I don't think there is a universally correct answer here. Whatever works best for you. 

Reply
  • Hi,

    For rapid prototyping of a couple of projects I would just modify the main.c file. On the other hand, if you have several projects using the same pin configuration or if you are cooperating on the same code base with other developers then it might be a good idea to make a custom board header file that can easily be shared. 

    But I don't think there is a universally correct answer here. Whatever works best for you. 

Children
Related