From 552f4352e198b864f82474259afb827cc54bd55a Mon Sep 17 00:00:00 2001 From: Josh Pieper Date: Wed, 12 Jun 2024 13:28:29 -0400 Subject: [PATCH] Wait a bit before sampling the version pins --- fw/power_dist.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/fw/power_dist.cc b/fw/power_dist.cc index 907d5db..667f3b6 100644 --- a/fw/power_dist.cc +++ b/fw/power_dist.cc @@ -1099,10 +1099,14 @@ int main(void) { __HAL_RCC_ADC12_CLK_ENABLE(); __HAL_RCC_ADC345_CLK_ENABLE(); + fw::MillisecondTimer timer; + DigitalIn hwrev0(HWREV_PIN0, PullUp); DigitalIn hwrev1(HWREV_PIN1, PullUp); DigitalIn hwrev2(HWREV_PIN2, PullUp); + timer.wait_ms(2); + const uint8_t this_hw_pins = 0x07 & (~(hwrev0.read() | (hwrev1.read() << 1) |