Thank you so much everyone for all your support! Using the code that you guys suggested the servos now communicate with the sensor and it all works beautifully.....except for one small thing.

For some reason the servo's movement is now really jittery, especially when working at higher speeds. I don't know if its an issue with the code (somewhere in the loop prompt), or if its the batteries which cannot provide enough amperage for the servos under heavy loads (the battery pack is 4 AS's).

If anyone has an idea why this might bee, some suggestions to resolve the problem would be highly appreciated.

or if its the batteries which cannot provide enough amperage for the servos under heavy loads (the battery pack is 4 AS's).

Ooh, ooh, I know. It isn't the software.

Oddly enough it could well be the software :~ If the timing loop that is setting the time between the PWM is too long the servos stop trying to seek, they go into no resistance mode. If the servos are under a small load that causes them to move off the desired point slightly when this happens then they will indeed jitter or oscillate about the desired point.

But then a really big battery might fix it too XD

Cheers Pete.

EmbeddedAT .. From Concept to Prototype to ProductionElectronics and firmware design and project mentoringI do answer personal requests for help when accompanied with a PayPal receipt

Could any one suggest an alternative capable of providing the charge necessary?

I'd suggest that you think about where the servo you are using was intended to be used. Most likely, the place you got it from also sells RC cars, trucks, boats, airplanes, and helicopters. You'll notice that none of them use 4AA batteries. They use big, rechargeable batteries.

Why? Because servos need a lot of current, and 4AA batteries just can't provide the needed current. Look at the batteries available from the same vendor you got your servo from, and pick one of them. Matched to your servo's voltage and current requirements, of course.