Controlling the Motor

Nov 9, 2010 at 11:26 PM

Hi,

I try to rotate my motor for a certain number of degrees (e.g. 360 for one whole rotation).

But this does not work as expected. Sometimes it rotates only a quarter and sometimes it rotates two or more whole rotations.

The code I'm using for my test is as follows - what am I doing wrong?

 

this._nxt.SetOutputState
        (
        MotorPort.PortA,
        100,
        MotorModes.On,
        MotorRegulationMode.Idle,
        0,
        MotorRunState.Running,
        360
        );

 

Thanks for your help, Regards

Michael

Coordinator
Nov 10, 2010 at 1:08 PM

Hi Michael,

I'm afraid it might be a bug in the library, there remained some in the motor control logic. As the "Current project status" section says on the Home page the motor control is not fully tested. However you have the full source code...

I'm sorry for the inconvenience and thanks for understanding.

György Balássy