Main Site Documentation

MotorControllerL298 motor number labels


#1

I just found out that my MotorControllerL298 has the motor numbering wrong. When I try to start motor1 with the following code, nothing happens unless I connect the motor to the terminals labeled M2- and M2+.


        void button_ButtonPressed(Button sender, Button.ButtonState state)
        {
            if (!button.IsLedOn)
            {
                motorControllerL298.MoveMotorRamp(MotorControllerL298.Motor.Motor1, 100, 5000);
                button.TurnLEDOn();
            }
            else
            {
                motorControllerL298.MoveMotorRamp(MotorControllerL298.Motor.Motor1, 0, 5000);
                button.TurnLEDOff();
            }
        }


#2

The enum was swapped. Will fix asap.