AP_Motors: fix example sketch

Also minor formatting fix
Thanks to OXINARF for spotting this
This commit is contained in:
Randy Mackay 2016-12-15 10:35:58 +09:00
parent ffa6d1a5b9
commit 037e411e35
1 changed files with 2 additions and 3 deletions

View File

@ -59,8 +59,7 @@ void setup()
// motor initialisation
motors.set_update_rate(490);
motors.set_frame_class_and_type(AP_Motors::MOTOR_FRAME_QUAD, AP_Motors::MOTOR_FRAME_TYPE_X);
motors.Init();
motors.init(AP_Motors::MOTOR_FRAME_QUAD, AP_Motors::MOTOR_FRAME_TYPE_X);
#if HELI_TEST == 0
motors.set_throttle_range(1000,2000);
motors.set_throttle_avg_max(0.5f);
@ -69,7 +68,7 @@ void setup()
motors.output_min();
// setup radio
rc3.set_radio_min(1000);
rc3.set_radio_min(1000);
rc3.set_radio_max(2000);
// set rc channel ranges