PS2 Programming

I want to use 1 motor and control its speed precisely on ps2 remote analog. i am using arduino mega 2560. please guide me. and super herculas motor driver. i have used the follwoing condition but it is not giving me precise control.

if(Psx.Right_x == 132 && Psx.Right_y == 0)

First you need a PS2 library, there are 3 in this section.

Gamepads and Joysticks

I myself use the PS2X library.

After you get the library and get it working, you then need a motor driver. Those should be fairly simple to find on ebay or some other online store. Search Arduino motor driver or Arduino motor shield.