Reply To: Motor Control not behaving

HomeForumsMonoBrick EV3 FirmwareMotor Control not behavingReply To: Motor Control not behaving

Author Image
Rich Champeaux

So I used Resharper to decompile MonoBrickFirmware.dll and I’ve figured out why MotorSync.On(speed, turnRatio) never returns. It’s calling the On(speed, turnRatio, degrees, brake, waitForCompletion) overload and is passing “true” for waitForCompletion. Therefore it will never return.

public void On(sbyte speed, short turnRatio)
this.On(speed, turnRatio, 0U, false, true);

public void On(sbyte speed, short turnRatio, uint degrees, bool brake, bool waitForCompletion = true)
this.StepSync(speed, turnRatio, degrees, brake, waitForCompletion);
if (!waitForCompletion)

So, I can just use the 5 parameter overload instead of the two parameter one.

Posted in

Make a donation