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

Custom board based on nrf52832 s132 pin input P0.09

Hi,

we are using a custom board, with codes tested on a NRF52 DK. We reconfigured the pins and when using pin P0.09 (by default NFC) as an input "active_high" and with "internal pull_down", we get some voltage in it.

We had defines the macro for the pre processor CONFIG_NFCT_PINS_AS_GPIOS

in custom_board.h

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#define BUTTONS_NUMBER 3
#define BUTTON_1 16 // Not Connected
#define BUTTON_2 14 //signal button 14
#define BUTTON_3 9 //enable button 9
#define BUTTON_PULL NRF_GPIO_PIN_PULLDOWN
#define BUTTONS_ACTIVE_STATE 0
#define BUTTONS_LIST { BUTTON_1, BUTTON_2, BUTTON_3}
#define BSP_BUTTON_0 BUTTON_1 // Not Connected
#define BSP_BUTTON_1 BUTTON_2 //signal button
#define BSP_BUTTON_2 BUTTON_3 //enable button
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

in bsp.c

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
#ifdef BSP_BUTTON_0
{BSP_BUTTON_0, APP_BUTTON_ACTIVE_HIGH, BUTTON_PULL, bsp_button_event_handler},
#endif // BUTTON_0
#ifdef BSP_BUTTON_1
{BSP_BUTTON_1, APP_BUTTON_ACTIVE_HIGH, BUTTON_PULL, bsp_button_event_handler},
#endif // BUTTON_1
#ifdef BSP_BUTTON_2
{BSP_BUTTON_2, APP_BUTTON_ACTIVE_HIGH, BUTTON_PULL, bsp_button_event_handler},
#endif // BUTTON_2
En fin, los otros boton
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

the other button works without problem, but it seems we are missing something in the configuration for button P0.09 that we can't get right, if we short P0.09 to ground with a wire at release it reads the push button correctly

TLDR: Pin P0.09 has 2.28V when configurated as GPIO input, why?

Regards