Revert "Merge branch 'unblock_i2c' into develop"
This reverts commit275a84b323
, reversing changes made to9fb3755088
.
This commit is contained in:
parent
f1346f098e
commit
7e92577c14
15
src/main.cpp
15
src/main.cpp
|
@ -5,7 +5,6 @@
|
||||||
#include <libraries/gpiote/app_gpiote.h>
|
#include <libraries/gpiote/app_gpiote.h>
|
||||||
#include <libraries/timer/app_timer.h>
|
#include <libraries/timer/app_timer.h>
|
||||||
#include <softdevice/common/nrf_sdh.h>
|
#include <softdevice/common/nrf_sdh.h>
|
||||||
#include <nrf_delay.h>
|
|
||||||
|
|
||||||
// nimble
|
// nimble
|
||||||
#define min // workaround: nimble's min/max macros conflict with libstdc++
|
#define min // workaround: nimble's min/max macros conflict with libstdc++
|
||||||
|
@ -306,20 +305,6 @@ int main(void) {
|
||||||
|
|
||||||
nrf_drv_clock_init();
|
nrf_drv_clock_init();
|
||||||
|
|
||||||
// Unblock i2c?
|
|
||||||
nrf_gpio_cfg(pinTwiScl,
|
|
||||||
NRF_GPIO_PIN_DIR_OUTPUT,
|
|
||||||
NRF_GPIO_PIN_INPUT_DISCONNECT,
|
|
||||||
NRF_GPIO_PIN_NOPULL,
|
|
||||||
NRF_GPIO_PIN_S0D1,
|
|
||||||
NRF_GPIO_PIN_NOSENSE);
|
|
||||||
nrf_gpio_pin_set(pinTwiScl);
|
|
||||||
for (uint8_t i = 0; i < 16; i++) {
|
|
||||||
nrf_gpio_pin_toggle(pinTwiScl);
|
|
||||||
nrf_delay_us(5);
|
|
||||||
}
|
|
||||||
nrf_gpio_cfg_default(pinTwiScl);
|
|
||||||
|
|
||||||
debounceTimer = xTimerCreate("debounceTimer", 200, pdFALSE, (void*) 0, DebounceTimerCallback);
|
debounceTimer = xTimerCreate("debounceTimer", 200, pdFALSE, (void*) 0, DebounceTimerCallback);
|
||||||
debounceChargeTimer = xTimerCreate("debounceTimerCharge", 200, pdFALSE, (void*) 0, DebounceTimerChargeCallback);
|
debounceChargeTimer = xTimerCreate("debounceTimerCharge", 200, pdFALSE, (void*) 0, DebounceTimerChargeCallback);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue