motor_to_channel_map arrays FLIGHT CONTROLLER problem

Hi, i'm a newbie.

I have the cheerson cx-20 open source.

I have a problem with one of my motor. The motor and the esc are ok. The problem is the port of the fc connected with the motor (i've tried to disconnect it and reconnect in another port and it works).

I've read in this forum that someone worked around this issue modifying some value of the motor_to_channel_map.

I installed github, cloned the arducopter apm 3.2.1 and searched for this string. I found it in the AP_Motors_Class.h and changed like this:

// offsets for motors in motor_out, _motor_filtered and _motor_to_channel_map arrays

#define AP_MOTORS_MOT_1 0

#define AP_MOTORS_MOT_2 4

#define AP_MOTORS_MOT_3 2

#define AP_MOTORS_MOT_4 3

#define AP_MOTORS_MOT_5 1

#define AP_MOTORS_MOT_6 5

#define AP_MOTORS_MOT_7 6

#define AP_MOTORS_MOT_8 7 

I'd like to use the port number 5 of the fc instead the number 2 that is damaged.

Do you think is CORRECT???

If yes, after those modification how can i compile it to install on my drone???

thanks to everyone!!!

Stefano

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Activity