juancarlostinoco / ardupilot-mega

Automatically exported from code.google.com/p/ardupilot-mega
0 stars 0 forks source link

Arducopter not compile: g.rc_9, g.rc_10, g.rc_11 does not exist. #705

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Get git revision 3b6b95c32c7c
2. Compile arducopter for APM 2
3.

What is the expected output? What do you see instead?
In function 'void init_rc_out()':
error: 'class Parameters' has no member named 'rc_9'

What version of the product are you using? On what operating system?
git revision 3b6b95c32c7c

Please provide any additional information below.

Original issue reported on code.google.com by denis.artru on 5 Aug 2012 at 8:44

GoogleCodeExporter commented 8 years ago
--- a/ArduCopter/radio.pde
+++ b/ArduCopter/radio.pde
@@ -68,9 +68,11 @@ static void init_rc_out()
        APM_RC.enable_out(CH_9);
        APM_RC.enable_out(CH_10);
        APM_RC.enable_out(CH_11);
-       APM_RC.OutputCh(CH_9,   g.rc_9.radio_trim);
-       APM_RC.OutputCh(CH_10,  g.rc_10.radio_trim);
-       APM_RC.OutputCh(CH_11,  g.rc_11.radio_trim);
+#if MOUNT == ENABLED
+       APM_RC.OutputCh(CH_9,   g.rc_camera_yaw.radio_trim);
+       APM_RC.OutputCh(CH_10,  g.rc_camera_roll.radio_trim);
+       APM_RC.OutputCh(CH_11,  g.rc_camera_pitch.radio_trim);
+#endif
 #endif
        #if INSTANT_PWM == 1
        motors.set_update_rate(AP_MOTORS_SPEED_INSTANT_PWM);

Original comment by denis.artru on 5 Aug 2012 at 9:45