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

nordic52840 Some GPIO cannot be controlled

Hi:

I noticed, P0.18 P0.19 P0.21 P0.22 P0.23 P1.00,recommended as QSPI. 

nrf_gpio_cfg_output(NRF_GPIO_PIN_MAP(0,22));
nrf_gpio_pin_set(NRF_GPIO_PIN_MAP(0,22));

There is no way to raise the P0.22 pin using this code.

But my own board must use P0.22 as a normal GPIO. What should I do to control these IO ports?

sdk version: 15.0

Best,

ching

  • Hi

    P0.22 should be set as a regular GPIO by default. The fact that it is recommended to be used for QSPI is just a recommendation and nothing else.

    P0.18 however, is by default the reset pin and is the only pin that can be used like this. 

    To configure a pin as output this should be sufficient: nrf_gpio_cfg_output(pin_number);

    Best regards,

    Simon

Related