diff --git a/src/boards.c b/src/boards.c index 3b03081..6c99fe4 100644 --- a/src/boards.c +++ b/src/boards.c @@ -115,6 +115,15 @@ void board_teardown(void) // Stop LF clock NRF_CLOCK->TASKS_LFCLKSTOP = 1UL; + + // make sure all pins are back in reset state + for (int i = 0; i < 32; ++i) + { + NRF_P0->PIN_CNF[i] = 2; +#ifdef NRF_P1 + NRF_P1->PIN_CNF[i] = 2; +#endif + } } static uint32_t _systick_count = 0;