void stabilizerInit(void) { if(isInit) return; sensorsInit(); stateEstimatorInit(); stateControllerInit(); powerDistributionInit(); #if defined(SITAW_ENABLED) sitAwInit(); #endif xTaskCreate(stabilizerTask, STABILIZER_TASK_NAME, STABILIZER_TASK_STACKSIZE, NULL, STABILIZER_TASK_PRI, NULL); isInit = true; }
void stabilizerInit(void) { if(isInit) return; motorsInit(motorMapBrushed); imu6Init(); sensfusion6Init(); controllerInit(); #if defined(SITAW_ENABLED) sitAwInit(); #endif rollRateDesired = 0; pitchRateDesired = 0; yawRateDesired = 0; xTaskCreate(stabilizerTask, (const signed char * const)STABILIZER_TASK_NAME, STABILIZER_TASK_STACKSIZE, NULL, STABILIZER_TASK_PRI, NULL); isInit = true; }