From pc send data to PS3

Technical discussion on the newly released and hard to find PS3.

Moderators: cheriff, emoon

Post Reply
huanmengQQ
Posts: 7
Joined: Sun Aug 30, 2009 6:01 pm

From pc send data to PS3

Post by huanmengQQ »

Hello everyone!

Now I just want to send data from the PC to control the PS3.So I send the sixaxis's data just as
the report descriptor's format.But it doesn't work.

The code is:

Code: Select all

unsigned char report_1[50]={
                  0xA1,0x01,0x00,0x80,0x00,0x00,0x00,0x80,0x80,0x80,
                  0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,
                  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
                  0x03,0x05,0x16,0xFF,0xCD,0x00,0x00,0x33,0x7F,0x77,
                  0x01,0x80,0x02,0x07,0x02,0x14,0x01,0x96,0x01,0xE8};
unsigned char report_2[50]={
                  0xA1,0x01,0x00,0x00,0x00,0x00,0x00,0x80,0x80,0x80,
                  0x80,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
                  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
                  0x03,0x05,0x16,0x00,0x00,0x00,0x00,0x33,0x02,0x77,
                  0x01,0x9E,0x02,0x08,0x01,0xF2,0x01,0x93,0x00,0x02};
unsigned char report_3[50]={
                  0xA1,0x01,0x00,0x20,0x00,0x00,0x00,0x80,0x80,0x80,
                  0x80,0x00,0x00,0x00,0x00,0x00,0x7f,0x00,0x00,0x00,
                  0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
                  0x03,0x05,0x16,0x00,0x00,0x00,0x00,0x33,0x02,0x77,
                  0x01,0x9E,0x02,0x08,0x01,0xF2,0x01,0x93,0x00,0x02};
		
unsigned char feature_1[]= {
		  0x43,0x02,0x01, 0x03, 0x00, 0x05, 0x0c, 0x01, 0x02, 0x18,
		  0x18, 0x18, 0x18, 0x09, 0x0a, 0x10, 0x11, 0x12,
		  0x13, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x02,
		  0x02, 0x02, 0x02, 0x00, 0x00, 0x00, 0x04, 0x04,
		  0x04, 0x04, 0x00, 0x00, 0x02, 0x01, 0x02, 0x00,
		  0x64, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00
	};
unsigned char feature_ef[]= {
		  0x53,0xef,0xef, 0x04, 0x00, 0x05, 0x03, 0x01, 0xa0, 0x00,
		  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		  0x02, 0x74, 0x02, 0x71, 0x00, 0x00, 0x00, 0x00,
		  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
		  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04
	};

                send ( sctl, feature_1,50,MSG_DONTWAIT );
                usleep(1000000);
                send ( sctl, feature_ef,50,MSG_DONTWAIT );
                usleep(send ( 1000000);
                send ( sint, report_1,50,MSG_NOSIGNAL );
                usleep(100000);
                send ( sint, report_2,50,MSG_NOSIGNAL );
                usleep(100000);
                send ( sint, report_3,50,MSG_NOSIGNAL );
                usleep(100000);
                send ( sint, report_2,50,MSG_NOSIGNAL );
                usleep(100000);              
Thanks for any help!
Everyone is NO.1
huanmengQQ
Posts: 7
Joined: Sun Aug 30, 2009 6:01 pm

Post by huanmengQQ »

Anyone can help me?

May be I didn't express myself exactly.
I want to use the PC to control the PS3,so I change the class of the bluetooth adaptor to 0x000508 which is the class of sixaxis.And then I use the code download from the http://anselm.hoffmeister.be/computer/h ... ex.html.en which run on the PC.Finally use the PS3 to find and connect to the bluetooth adaptor.It works well,the mouse and the keyboard can control the PS3 smoothly.

But when I change the sdprecord to sixaxis's and send the data to the PS3 ,it doesn't work. How should I do?

I also read the article http://forums.ps2dev.org/viewtopic.php? ... f41cea49d1.
But I don't receive the 0xf4 feature report.Shuld I send the get_report to get the 0xf4 feature?Or the report is sent when PS3 is connected?
Everyone is NO.1
jimparis
Posts: 1145
Joined: Fri Jun 10, 2005 4:21 am
Location: Boston

Post by jimparis »

You already posted this in the other thread, no need to double-post it. I will answer there.
Post Reply