Hello all,
I'm working on a device using nRF52832, interfacing to another microcontroller. I was seeing higher than expected consumption, so started to reduce code to find where it was.
The nRF52 is now only configured as SPIS, based on the spis peripheral example. If I start OFF mode before doing spi_init() I see the expected ~0.4uA. But if I do spi_init() first I see a few uA. I checked for pull-up/down on either micro without success.
After chasing this I found that nrfx_spis_init() configures slave output as follows:
{
nrf_gpio_cfg(p_config->miso_pin,
NRF_GPIO_PIN_DIR_INPUT,
NRF_GPIO_PIN_INPUT_CONNECT,
NRF_GPIO_PIN_NOPULL,
p_config->miso_drive,
NRF_GPIO_PIN_NOSENSE);
miso_pin = p_config->miso_pin;
}
When I change NRF_GPIO_PIN_INPUT_CONNECT to NRF_GPIO_PIN_INPUT_DISCONNECT, I see a reduction in power consumption.
Is this expected? Is it a bug or am I breaking something?
I couldn't find a clear explanation or schematic of the GPIO so I can't really tell, does anyone know where to find it?
I'm a bit confused here...Any help is welcome
Thanks!!