fixed a hang on 2nd run of IMU test
we should not try to initialise the ISR handlers twice
This commit is contained in:
parent
483bef35e5
commit
dd9f3a3fa6
@ -451,8 +451,6 @@ static int8_t
|
|||||||
test_adc(uint8_t argc, const Menu::arg *argv)
|
test_adc(uint8_t argc, const Menu::arg *argv)
|
||||||
{
|
{
|
||||||
print_hit_enter();
|
print_hit_enter();
|
||||||
isr_registry.init();
|
|
||||||
timer_scheduler.init( &isr_registry );
|
|
||||||
adc.Init(&timer_scheduler);
|
adc.Init(&timer_scheduler);
|
||||||
delay(1000);
|
delay(1000);
|
||||||
Serial.printf_P(PSTR("ADC\n"));
|
Serial.printf_P(PSTR("ADC\n"));
|
||||||
@ -503,8 +501,6 @@ static int8_t
|
|||||||
test_imu(uint8_t argc, const Menu::arg *argv)
|
test_imu(uint8_t argc, const Menu::arg *argv)
|
||||||
{
|
{
|
||||||
//Serial.printf_P(PSTR("Calibrating."));
|
//Serial.printf_P(PSTR("Calibrating."));
|
||||||
isr_registry.init();
|
|
||||||
timer_scheduler.init( &isr_registry );
|
|
||||||
imu.init(IMU::COLD_START, delay, flash_leds, &timer_scheduler);
|
imu.init(IMU::COLD_START, delay, flash_leds, &timer_scheduler);
|
||||||
|
|
||||||
print_hit_enter();
|
print_hit_enter();
|
||||||
@ -566,8 +562,6 @@ test_mag(uint8_t argc, const Menu::arg *argv)
|
|||||||
report_compass();
|
report_compass();
|
||||||
|
|
||||||
// we need the DCM initialised for this test
|
// we need the DCM initialised for this test
|
||||||
isr_registry.init();
|
|
||||||
timer_scheduler.init( &isr_registry );
|
|
||||||
imu.init(IMU::COLD_START, delay, flash_leds, &timer_scheduler);
|
imu.init(IMU::COLD_START, delay, flash_leds, &timer_scheduler);
|
||||||
|
|
||||||
int counter = 0;
|
int counter = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user