本文整理汇总了C++中AP_InertialSensor::init方法的典型用法代码示例。如果您正苦于以下问题:C++ AP_InertialSensor::init方法的具体用法?C++ AP_InertialSensor::init怎么用?C++ AP_InertialSensor::init使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类AP_InertialSensor
的用法示例。
在下文中一共展示了AP_InertialSensor::init方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: setup
void SchedTest::setup(void)
{
// we
ins.init(AP_InertialSensor::COLD_START,
AP_InertialSensor::RATE_50HZ);
// initialise the scheduler
scheduler.init(&scheduler_tasks[0], ARRAY_SIZE(scheduler_tasks));
}
示例2: setup
void setup(void)
{
serial_manager.init();
ins.init(100);
baro.init();
ahrs.init();
gps.init(NULL, serial_manager);
}
示例3: setup
void setup(void)
{
ins.init(100);
ahrs.init();
serial_manager.init();
if( compass.init() ) {
hal.console->printf("Enabling compass\n");
ahrs.set_compass(&compass);
} else {
hal.console->printf("No compass detected\n");
}
gps.init(NULL, serial_manager);
}
示例4: setup
void setup(void)
{
hal.console->println("AP_InertialSensor startup...");
#if CONFIG_HAL_BOARD == HAL_BOARD_APM2 || CONFIG_HAL_BOARD == HAL_BOARD_MEGA2560
// we need to stop the barometer from holding the SPI bus
hal.gpio->pinMode(40, HAL_GPIO_OUTPUT);
hal.gpio->write(40, 1);
#endif
ins.init(AP_InertialSensor::COLD_START,
AP_InertialSensor::RATE_100HZ);
// display initial values
display_offsets_and_scaling();
hal.console->println("Complete. Reading:");
}
示例5: setup
void setup(void)
{
// setup any board specific drivers
BoardConfig.init();
hal.console->printf("AP_InertialSensor startup...\n");
ins.init(100);
// display initial values
display_offsets_and_scaling();
// display number of detected accels/gyros
hal.console->printf("\n");
hal.console->printf("Number of detected accels : %u\n", ins.get_accel_count());
hal.console->printf("Number of detected gyros : %u\n\n", ins.get_gyro_count());
hal.console->printf("Complete. Reading:\n");
}
示例6: setup
void setup(void)
{
#ifdef APM2_HARDWARE
// we need to stop the barometer from holding the SPI bus
hal.gpio->pinMode(40, HAL_HAL_GPIO_OUTPUT);
hal.gpio->write(40, HIGH);
#endif
ins.init(AP_InertialSensor::RATE_100HZ);
ahrs.init();
serial_manager.init();
if( compass.init() ) {
hal.console->printf("Enabling compass\n");
ahrs.set_compass(&compass);
} else {
hal.console->printf("No compass detected\n");
}
gps.init(NULL, serial_manager);
}