Browse Source

uitask: screen and radio poweroff moved to board

pull/2976/head
Florent 4 days ago
parent
commit
c644720ea7
  1. 3
      examples/companion_radio/ui-new/UITask.cpp
  2. 2
      examples/companion_radio/ui-orig/UITask.cpp
  3. 2
      examples/companion_radio/ui-tiny/UITask.cpp
  4. 2
      examples/simple_repeater/UITask.cpp

3
examples/companion_radio/ui-new/UITask.cpp

@ -697,9 +697,6 @@ void UITask::shutdown(bool restart){
if (restart) {
_board->reboot();
} else {
// still necessary until all boards are refactored to use poweroff
_display->turnOff();
radio_driver.powerOff();
// Power off board including radio, display, GPS and components
_board->powerOff();
}

2
examples/companion_radio/ui-orig/UITask.cpp

@ -307,8 +307,6 @@ void UITask::shutdown(bool restart){
if (restart) {
_board->reboot();
} else {
_display->turnOff();
radio_driver.powerOff();
// Power off board including radio, display, GPS and components
_board->powerOff();
}

2
examples/companion_radio/ui-tiny/UITask.cpp

@ -566,8 +566,6 @@ void UITask::shutdown(bool restart){
if (restart) {
_board->reboot();
} else {
_display->turnOff();
radio_driver.powerOff();
// Power off board including radio, display, GPS and components
_board->powerOff();
}

2
examples/simple_repeater/UITask.cpp

@ -146,8 +146,6 @@ void UITask::loop() {
digitalWrite(LED_PIN, LED_STATE_ON); // switch on the led until poweroff
#endif
if (millis() > _powering_off_at) {
_display->turnOff();
radio_driver.powerOff();
_board->powerOff(); // should not return
}
}

Loading…
Cancel
Save