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

Unable to use gpio reset pin as a gpio in nrf connect sdk

Hi,

I am not able to use the gpio pin p0.18 as a gpio with nrf connect sdk.

I have tried to toggle the pin using "gpio_pin_toggle" and gpio_pin_set" functions but it is not working. (These functions returns 0)

I want to use it as a chip select pin for my peripheral, all other lines are working except the gpio p0.18.

I have disabled the reset functionality  from the manuconf option. I have also tried to add CONFIG_GPIO_AS_PINRESET=n to the project config file but no luck.

As i can see in the zephyr.dts file, qdec interrupt pin also have the same number. (qdec is in disabled state in board.dts file). Would this be causing the problem ?

fyi, i have made sure the hardware is working by running sdk5 based code.

8863.zephyr.dts

I have tested it using the blinky example from zephyr samples.

Board: custom board based on nrf52840.

  • Hi Rico!

    You can use the terminal commands described above (eg. west flash --softreset). Unfortunately this isn't possible using the UI in Visual Studio Code, but you could do it using a terminal in the IDE. A launch.json task can be created as well, if it needs to be frequently called.

    Btw, keep in mind that this is an older case. You might want to create a new support ticket if you don't get much help on an older one.

    Regards,

    Elfving

Related