AP_ICEngine: add support for starter relay

This commit is contained in:
Iampete1 2023-12-19 02:13:25 +00:00 committed by Andrew Tridgell
parent ab0755d0d8
commit 86a199c1bf
1 changed files with 7 additions and 0 deletions

View File

@ -622,6 +622,13 @@ void AP_ICEngine::set_starter(bool on)
#if AP_ICENGINE_TCA9554_STARTER_ENABLED #if AP_ICENGINE_TCA9554_STARTER_ENABLED
tca9554_starter.set_starter(on); tca9554_starter.set_starter(on);
#endif #endif
#if AP_RELAY_ENABLED
AP_Relay *relay = AP::relay();
if (relay != nullptr) {
relay->set(AP_Relay_Params::FUNCTION::ICE_STARTER, on);
}
#endif // AP_RELAY_ENABLED
} }