Main Site Documentation

Two motorController L298 at a time?


hy i wanted to use two motorController L298 to control 4 Motors ( each motorController controls 2 motors). But if i use

do i use the MotorControllerL298 from the motorControllerL298_1 ??
because i have two motorControllerL298 (motorControllerL298_1 &motorControllerL298_2) and just one MotorController. (MotorControllerL298)

here is the Code i want to use (to fly a Quadocopter)(for example I use here a Joystick to control it):


int speed2Y = (((Convert.ToInt32(joystick2.GetPosition().Y.ToString())) + 1) / 2);
                motorControllerL298_1.MoveMotor(MotorControllerL298.Motor.Motor1, speed2Y);
                motorControllerL298_1.MoveMotor(MotorControllerL298.Motor.Motor2, speed2Y);
                motorControllerL298_2.MoveMotor(MotorControllerL298.Motor.Motor1, speed2Y);
                motorControllerL298_2.MoveMotor(MotorControllerL298.Motor.Motor2, speed2Y);

are all MotorControllerL298 the same or do they inherit it from motorControllerL298_1 or _2??

thank you for your HELP
cacciu :slight_smile:



Welcome to the community.

Your post is a bit confusing. Do you have 2 physical motor controllers as found here: ?


Sorry I did not see this sooner, however, the MotorControllerL298 is a class declaration, and you will call that to resolve any static members such as direction, etc. The motorControllerL298_1 and motorControllerL298_2 are the object declarations and you would call upon the one in which you want to control at the given time.