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

How to use Buttons input as GPIO

Hi, i'am working on a custom board on which there is two led drive by a led driver.

The two leds are wiring to be drive by pins P0.14 and P0.15, but unfortunately these pins are consider to be button with:

uint32_t err_code = bsp_init(BSP_INIT_LED | BSP_INIT_BUTTONS, APP_TIMER_TICKS(100, APP_TIMER_PRESCALER), bsp_event_handler);

I've try to remplace BSP_INIT_LED | BSP_INIT_BUTTONS by BSP_INIT_NONE but now I can't control output with nrf_drv_gpiote_out_set or get an input with nrf_gpio_cfg_sense_input.

So i there a solution,for uninitalize button from P0.13 to P0.16 without lose gpiote ?

Thanks you !

Related