NinjaFlight
|
Go to the source code of this file.
Data Structures | |
struct | failsafe |
Macros | |
#define | FAILSAFE_POWER_ON_DELAY_US (1000 * 1000 * 5) |
#define | MILLIS_PER_TENTH_SECOND 100 |
#define | MILLIS_PER_SECOND 1000 |
#define | PERIOD_OF_1_SECONDS 1 * MILLIS_PER_SECOND |
#define | PERIOD_OF_3_SECONDS 3 * MILLIS_PER_SECOND |
#define | PERIOD_OF_30_SECONDS 30 * MILLIS_PER_SECOND |
#define | PERIOD_RXDATA_FAILURE 200 |
#define | PERIOD_RXDATA_RECOVERY 200 |
Enumerations | |
enum | failsafePhase_e { FAILSAFE_IDLE = 0, FAILSAFE_RX_LOSS_DETECTED, FAILSAFE_LANDING, FAILSAFE_LANDED, FAILSAFE_RX_LOSS_MONITORING, FAILSAFE_RX_LOSS_RECOVERED } |
enum | failsafeRxLinkState_e { FAILSAFE_RXLINK_DOWN = 0, FAILSAFE_RXLINK_UP } |
Functions | |
void | failsafe_init (struct failsafe *self, struct ninja *ninja, const struct config *config) |
void | failsafe_start_monitoring (struct failsafe *self) |
void | failsafe_update (struct failsafe *self) |
void | failsafe_reset (struct failsafe *self) |
failsafePhase_e | failsafe_get_state (struct failsafe *self) |
bool | failsafe_is_monitoring (struct failsafe *self) |
bool | failsafe_is_active (struct failsafe *self) |
bool | failsafe_is_receiving_rx (struct failsafe *self) |
void | failsafe_on_rx_suspend (struct failsafe *self, uint32_t suspendPeriod) |
void | failsafe_on_rx_resume (struct failsafe *self) |
void | failsafe_on_valid_data_received (struct failsafe *self) |
void | failsafe_on_valid_data_failed (struct failsafe *self) |
#define FAILSAFE_POWER_ON_DELAY_US (1000 * 1000 * 5) |
#define MILLIS_PER_SECOND 1000 |
#define MILLIS_PER_TENTH_SECOND 100 |
#define PERIOD_OF_1_SECONDS 1 * MILLIS_PER_SECOND |
#define PERIOD_OF_30_SECONDS 30 * MILLIS_PER_SECOND |
#define PERIOD_OF_3_SECONDS 3 * MILLIS_PER_SECOND |
#define PERIOD_RXDATA_FAILURE 200 |
#define PERIOD_RXDATA_RECOVERY 200 |
enum failsafePhase_e |
failsafePhase_e failsafe_get_state | ( | struct failsafe * | self | ) |
bool failsafe_is_active | ( | struct failsafe * | self | ) |
bool failsafe_is_monitoring | ( | struct failsafe * | self | ) |
bool failsafe_is_receiving_rx | ( | struct failsafe * | self | ) |
void failsafe_on_rx_resume | ( | struct failsafe * | self | ) |
void failsafe_on_rx_suspend | ( | struct failsafe * | self, |
uint32_t | suspendPeriod | ||
) |
void failsafe_on_valid_data_failed | ( | struct failsafe * | self | ) |
void failsafe_on_valid_data_received | ( | struct failsafe * | self | ) |
void failsafe_reset | ( | struct failsafe * | self | ) |
void failsafe_start_monitoring | ( | struct failsafe * | self | ) |
void failsafe_update | ( | struct failsafe * | self | ) |