Trouble with PS2 wireless controler

I have a bot board and a ps2 controler cable. Iam having trouble getting the wireless to work. The controler is a Game Stop 2.4GHZ brand made by Mad Cats. I have the green wire hooked up to 7.2VDC. Iam using basic stamp 2.5 code. When I run a debug window, it comes up and the controler links up to the base. But the debug window does not change when I press any buttons. Like its reading it but its not. If any you has any ideas to get it to work I would be thankful.

Which processor are you using? Is it a plain jane BS2, or something faster? Can you post the code you are using? The Bot Board has a special port for the Playstation controller that has an inverter on the data line. Are you using it? Can you post an image of the board showing the jumpers installed? Or a list of installed jumpers… Thanks

I’m having the same problem with my code. Although I am using the BS2 OEM version so I don’t have to have a carrier board, I am using a external circuit to invert the signal and handle pull-ups. I am using the Lynxmotion cable to connect a MadCatz 440 Series 2.4 GHz wireless controller to the BS, which then ends it serially to a OOPic-R. I have it do this because the OOPic-R can’t poll the PlayStation controller fast enough by itself. Anyhow, the circuit I have works with the MadCatz 400 Series wired controller fine. I have the green wire of the adapter connected to 7.2v unregulated. You would think that since the 400 series and 440 series are so close that they would use the same chipset and, thus, work the same, they don’t appear to do so. I can get the “Link” light to come on but the Basic stamp doesn’t read the controller and it appears as though it isn’t plugged in. I’ve connecting the controller every which way I can think of but it still doesn’t seem to work. I think there might be some additional timing requirements for wireless feature. What am I don’t wrong?

Thanks in Advance, botguy

Code debugs raw data:

’ {$STAMP BS2}
’ {$PBASIC 2.5}
’ ----- I/O Definitions ]-------------------------------------------------

PsxDat PIN 4 ’ PSX joystick interface
PsxCmd PIN 5
PsxAtt PIN 6
PsxClk PIN 7

’ ----- Constants ]-------------------------------------------------------

Inverted CON 1 ’ inverted clock signal
Direct CON 0 ’ no inverter in clock line
ClockMode CON Direct

’ ----- Variables ]-------------------------------------------------------

idx VAR Nib ’ loop counter
psxOut VAR Byte ’ byte to controller
psxIn VAR Byte ’ byte from controller

’ joystick packet

psxID VAR Byte ’ controller ID
psxThumbL VAR Byte ’ left thumb buttons
psxThumbR VAR Byte ’ right thumb buttons
psxStatus VAR Byte ’ status ($5A)
psxJoyRX VAR Byte ’ r joystick - X axis
psxJoyRY VAR Byte ’ r joystick - Y axis
psxJoyLX VAR Byte ’ l joystick - X axis
psxJoyLY VAR Byte ’ l joystick - Y axis

Main:
HIGH PsxAtt ’ deselect PSX controller
OUTPUT PsxCmd
PsxClk = ~ClockMode ’ release clock
OUTPUT PsxClk ’ make clock an output

DO
GOSUB Get_PSX_Packet ’ type and packet
DEBUG CLS
DEBUG IHEX2 psxId, " (", IHEX2 psxStatus, “)”,
CLREOL, CR, CR,
BIN8 psxThumbL, " ", BIN8 psxThumbR, " "

    DEBUG DEC3 psxJoyLX, " ", DEC3 psxJoyLY, " ",
          DEC3 psxJoyRX, " ", DEC3 psxJoyRY

PAUSE 100

LOOP

END

’ ----- Subroutines ]-----------------------------------------------------

’ This routine manually creates the clock signal,
’ so it can be used with a direct (via 220 ohm resistor)
’ connection to the clock input

’ Execution time on BS2 is ~145 ms.

Get_PSX_Packet:
LOW PsxAtt ’ select controller
psxOut = $01 : GOSUB PSX_TxRx ’ send “start”
psxOut = $42 : GOSUB PSX_TxRx ’ send “get data”
psxId = psxIn ’ save controller type
psxOut = $00 : GOSUB PSX_TxRx
psxStatus = psxIn ’ should be $5A (“ready”)
GOSUB PSX_TxRx : psxThumbL = psxIn ’ get PSX data
GOSUB PSX_TxRx : psxThumbR = psxIn
GOSUB PSX_TxRx : psxJoyRX = psxIn
GOSUB PSX_TxRx : psxJoyRY = psxIn
GOSUB PSX_TxRx : psxJoyLX = psxIn
GOSUB PSX_TxRx : psxJoyLY = psxIn
HIGH PsxAtt ’ deselect controller
RETURN

PSX_TxRx:
FOR idx = 0 TO 7
PsxCmd = psxOut.LOWBIT(idx) ’ setup command bit
PsxClk = ClockMode ’ clock the bit
psxIn.LOWBIT(idx) = PsxDat ’ get data bit
PsxClk = ~ClockMode ’ release clock
NEXT
RETURN

I have tried both of the ideas and nothing changed. The plane jane basic stamp 2 still will not connect to the wireless controler. I have double cheched I have 7.2vdc in the green wire. The controler is pluged in to the PS2 port on the bot board. And here is the code Iam useing. Thanks for the help and does any one have any more ideas?

Thanks Kendall

'{$STAMP BS2}
’ {$PBASIC 2.5

 clk         CON   7

att CON 6
dat CON 4
cmd CON 5

'****************************************************************************************
’ Variables:

index VAR Byte
char VAR Byte

'****************************************************************************************

main:

LOW att ’ select the PSX controller

SHIFTOUT cmd,clk, LSBFIRST,$01,$42] ’ send “get ready” and “send data”
SHIFTIN dat, clk, 3, [char] ’ read then discard this byte, it

SHIFTIN dat, clk, 3, [char] ’ 1st “digital” byte - left switches
DEBUG BIN char, " " ’ debug window binary format

SHIFTIN dat, clk, 3, [char] ’ 2nd “digital” byte - right switches
DEBUG BIN char, " " ’ debug window binary format

SHIFTIN dat, clk, 3, [char] ’ right joystick left / right
DEBUG DEC char, " " ’ debug window decimal format

SHIFTIN dat, clk, 3, [char] ’ right joystick up / down
DEBUG DEC char, " " ’ debug window decimal format

SHIFTIN dat, clk, 3, [char] ’ left joystick left / right
DEBUG DEC char, " " ’ debug window decimal format

SHIFTIN dat, clk, 3, [char] ’ left joystick up / down
DEBUG DEC char, CR ’ debug window dec format and return

HIGH att

GOTO main