Connecting Playstation 2 controller to arduino
Connecting Playstation 2 controller to arduino
I`m planning to connect a Playstation2 controller to my control system.
I have searched and not found a code, and how to wire the controller to the arduino.
I would like to have a analog output for each joystick (4 in total, 2 for each joystick)
and digital (on/off) for the rest of the buttons on the controller.
Have anyone code and wiring for this, or a tip for where I can find it?
Thanks in advance
I have searched and not found a code, and how to wire the controller to the arduino.
I would like to have a analog output for each joystick (4 in total, 2 for each joystick)
and digital (on/off) for the rest of the buttons on the controller.
Have anyone code and wiring for this, or a tip for where I can find it?
Thanks in advance
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: Connecting Playstation 2 controller to arduino
Hey Kjetil,Kjetil wrote:I`m planning to connect a Playstation2 controller to my control system.
I have searched and not found a code, and how to wire the controller to the arduino.
I would like to have a analog output for each joystick (4 in total, 2 for each joystick)
and digital (on/off) for the rest of the buttons on the controller.
Have anyone code and wiring for this, or a tip for where I can find it?
Thanks in advance
Have a look at the link below. I have been able to build exactly what you are describing, and I have posted the code in the link below.
viewtopic.php?f=15&t=831
Hope this helps!
Ryan
"KR2_Diving"
Re: Connecting Playstation 2 controller to arduino
Thanks for the information.
I have connected the controller but getting an error that the controller is not connected. Do I need to add any resistors between any of the wires?
I have connected the controller but getting an error that the controller is not connected. Do I need to add any resistors between any of the wires?
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: Connecting Playstation 2 controller to arduino
Sometimes yes. On my controller, I needed to connect a 10K resistor between the brown wire and the 3.3V connection...Kjetil wrote:Do I need to add any resistors between any of the wires?
There are more details and an FAQ section on this site:
http://www.billporter.info/2010/06/05/p ... rary-v1-0/
This is also where I got all my code.
Happy to help!
Ryan
"KR2_Diving"
Re: Connecting Playstation 2 controller to arduino
Thanks again, everything is working fine. Just need to adjust the code.
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: Connecting Playstation 2 controller to arduino
Great to hear!
Keep us posted!
Ryan
"KR2_Diving"
Keep us posted!
Ryan
"KR2_Diving"
Re: Connecting Playstation 2 controller to arduino
Hello
Can someone help me. I have a not original ps2 controller that I wanna use to control my rov.
But after opening the connector. I found out that I dont have a 3,3v-5v wire/pin.
I thought that maybe the controller uses the 7v that controls your dualshock.
Put when I connect a battery to it the led turns on but the motors start spinning to.
Does someone has some experience with that kind of controller?
Can someone help me. I have a not original ps2 controller that I wanna use to control my rov.
But after opening the connector. I found out that I dont have a 3,3v-5v wire/pin.
I thought that maybe the controller uses the 7v that controls your dualshock.
Put when I connect a battery to it the led turns on but the motors start spinning to.
Does someone has some experience with that kind of controller?
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: Connecting Playstation 2 controller to arduino
Hmmm... i am no expert, but I would have thought that was one part of the controller that you could not do without!
How many wires are there in the cable?
Have a look at this site, check out the comments on the bottom of the page. There is a lot of troubleshooting included in the comments...
This page also included a very scientific analysis of the controller. It may provide some clues or other things for you to look into.
Hope this assists.
Let me know what you have for wires inside the cable. (Number of and color of.)
How many wires are there in the cable?
Have a look at this site, check out the comments on the bottom of the page. There is a lot of troubleshooting included in the comments...
This page also included a very scientific analysis of the controller. It may provide some clues or other things for you to look into.
Hope this assists.
Let me know what you have for wires inside the cable. (Number of and color of.)
Re: Connecting Playstation 2 controller to arduino
Thx for the reply
I know these sites but nothing about no 3,3v wire.
I´ve try to upload a pic but I get an error message.
The colors are totaly in different order. I´ll try to explain.
Pin1 / pin2 / pin3 / pin4 / pin5 / pin6 / pin7 / pin8 / pin9
Brown / Blue / Yellow / Orange / no pin / Black / Red / no pin / Green
I know these sites but nothing about no 3,3v wire.
I´ve try to upload a pic but I get an error message.
The colors are totaly in different order. I´ll try to explain.
Pin1 / pin2 / pin3 / pin4 / pin5 / pin6 / pin7 / pin8 / pin9
Brown / Blue / Yellow / Orange / no pin / Black / Red / no pin / Green
- KR2_Diving
- Posts: 391
- Joined: Aug 30th, 2012, 11:43 am
- Location: Currently: NW Suburbs of Chicago. Originally: NE Wisconsin
Re: Connecting Playstation 2 controller to arduino
This is just a thought, but perhaps the 3.3v is generated inside the controller, from the 5v supply?
It may be worth opening the controller up to see what is inside...
It may be worth opening the controller up to see what is inside...