Issues recognizing the PS2 Controller

G’day,

I’ve been building the Lynxmotion A-Pod over the last few days. I’m up to the point where I’m hooking up the PS2 controller using this tutorial (I’ve got the BotBoarduino):

lynxmotion.com/images/html/build99f.htm
and
lynxmotion.com/images/html/build185.htm
Originally I had issues running the arduino code compiling because of lack of the PS2X library, I looked around and found this library and installed:

github.com/madsci1016/Arduino-PS2X

The code then successfully compiled and uploaded. I can confirm that the code itself is running. I modified several sections of PS2_Controller.cpp to see if the code could recognize the PS2 controller. All tests came back negative.

I then tried the library’s example code (making sure that the pins were modified to suit the board). I kept getting this output:

[code]No controller found, check wiring, see readme.txt to enable debug. visit www.billporter.info for troubleshooting tips

Unknown Controller type found[/code]

Whilst the receiver is powered it has one red light which is on solidly, and another which blinks. Then when I power on the PS2 controller the flashing light becomes solid (showing that it is successfully connected?).

I’ve also double checked the wiring several times. It’s correct.

Is there anything I’m missing? Are there any suggestions on what to try now?

Thanks,

John

I also just put the library into debug mode, here was the output:

OUT:IN Configure

1:FF 43:41 0:5A 1:FF 0:FF

OUT:IN Configure

1:FF 44:F1 0:FF 1:FF 3:F9 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FF 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:FF 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FD 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FF 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:F9 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FF 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FF 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:FF 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FD 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FD 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:FF 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:41 0:FF 1:FF 3:F9 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:F1 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN

1:FF 42:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0
0:0 0:0

OUT:IN Configure

1:FF 43:F9 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FF 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:C1 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:41 0:FA 1:FF 0:FF

OUT:IN Configure

1:FF 44:FF 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FF 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:FF 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FD 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FF 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:FF 0:FF 1:FF 0:FF

OUT:IN Configure

1:FF 44:FF 0:FF 1:FF 3:41 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FD 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN Configure

1:FF 43:41 0:FA 1:FF 0:FF

OUT:IN Configure

1:FF 44:FF 0:FF 1:FF 3:FF 0:FF 0:FF 0:FF 0:FF

OUT:IN Configure

1:FF 43:FD 0:FF 0:FF 5A:FF 5A:FF 5A:FF 5A:FF 5A:FF

OUT:IN

1:FF 42:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:FF 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0 0:0
0:0 0:0

Controller mode not matched or no controller found

Expected 0x41, 0x73 or 0x79, but got FF

No controller found, check wiring, see readme.txt to enable debug. visit www.billporte
r.info for troubleshooting tips

Unknown Controller type found

Bill Porters code works great, but I found at times it had some issues with the Lynxmotion controllers, so I forked my own copy of his library as did Lynxmotion. When Lynxmotion came out with Rev C? of the controller there was an issue with timings and the like, which I made some miner changes for. I believe that Lynxmotion has picked these changes up.

You can get to their fork up at: github.com/Lynxmotion/Arduino-PS2X

If that does not work, you might compare it to my fork: github.com/KurtE/Arduino-PS2X

Thanks Kurt,

Yes, the Lynxmotion version has the new changes. It is now identical to your version – I just did a detailed comparison --, except yours has also support for SAM3X8E.

@boar401s2, If you haven’t already done this, you also have to remove the JA, JB, and JC jumpers from the board. They’re identified by number 5 in this manual:

1 Like

Thanks for all the help! I tried both the lynxmotion and Kurt’s forks - and neither of them worked. I replaced the PS2X library folder under ~/My Documents/Arduino/libraries with the PS2X_lib from both of the forks. I then tried the example code with each, making sure the pins were correct:

  error = ps2x.config_gamepad(9,7,8,6, true, true);   //setup pins and settings:  GamePad(clock, command, attention, data, Pressures?, Rumble?) check for error 

I also removed JA, JB, and JC, whilst leaving JPU in place. I kept getting this output:

No controller found, check wiring, see readme.txt to enable debug. visit www.billporter.info for troubleshooting tips

Unknown Controller type

To confirm, I do have a rev. c controller.

Any thoughts?

All the standard ones…

Picture of wiring would help. This helps to verify that the right wires are going to the right pins. Also that you are passing +5v to the board and not VS. Are the leds on the receiver on? One steady one blinking? Does it pair with remote. When this happens usually both leds go solid on.

There are several threads up on the forums that talk about debugging PS2s.

Good Luck

Everything A-OK as far as blinking, etc on the BotBoarduino.

I just plugged into my Arduino Mega, and ran the example code. It worked fine. I’m going to retry on the BotBoarduino.

The situation is this. The BotBoarduino has some kind of problem. I’ve tried the controller successfully with other Arduino boards with no problems.
However, when I wire the reciever into the BotBoarduino, there’s problems. I’ve tried both wiring it into the the servo headers (as the guides suggests)
and wiring it into the shield sockets. Below are two pictures of the original (as the manual asks for) wiring:

Try switching the cable with the purple, blue and yellow wires on the level shifter (purple connects to ATT).

Thanks, I tried something, I can’t remember exactly what it was, but something like that. It works now. Thanks for all your help!