|
Re: easyc demo code not working
Hopefully you've run through some of the tutorials in EasyC to become familiar with some of the library calls. I believe the Cam demo you are talking about is designed to drive the robot towards the light, which means it isn't set up to control the servos. Take a close look at the code. You can modify it to position the servos instead of the wheels. Just send the desired signal to the pwm out that the servo is attached to.
servoPosition = 127 - error/2;
Something like that.
|