Bluetooth Questions

Investigation into how Linux on the PS3 might lead to homebrew development.

Moderators: cheriff, emoon

Post Reply
knicknak
Posts: 4
Joined: Sun Sep 06, 2009 10:08 pm

Bluetooth Questions

Post by knicknak »

When you shut off a PS3 in GameOS mode, pressing the PS button on a remote or a controller will wake up the machine. Is it possible to do this when the machine is shut off in OtherOS mode - i.e. can a process be listening for these events when the machine is in Standby on OtherOS mode?

Could the Linux Bluetooth HIDP daemon (HIDD) be modified to turn off an active device if the device has not been used in some time period. I.e. could a timer be implemented where after say 10 mins of no activity from a controller that was active, turn off the device?

Could HIDD be modified to light the correct LED on the sixaxis controller(s) to indicate which joystick the device is enumerated as?
jimparis
Posts: 1145
Joined: Fri Jun 10, 2005 4:21 am
Location: Boston

Re: Bluetooth Questions

Post by jimparis »

knicknak wrote:When you shut off a PS3 in GameOS mode, pressing the PS button on a remote or a controller will wake up the machine. Is it possible to do this when the machine is shut off in OtherOS mode - i.e. can a process be listening for these events when the machine is in Standby on OtherOS mode?
As far as I know, nobody has figured out how to do this. Since the BT module seems to sit on USB, one possibility would be to physically sniff traffic between the PS3 and the BT module and see if there's some magic incantation it's doing to put the BT module into that wake-up mode.
Could the Linux Bluetooth HIDP daemon (HIDD) be modified to turn off an active device if the device has not been used in some time period. I.e. could a timer be implemented where after say 10 mins of no activity from a controller that was active, turn off the device?
If I remember right, closing the connection from the host side will cause the sixaxis to turn off. I don't know if the Bluez daemons can do that easily, but it should work.
Could HIDD be modified to light the correct LED on the sixaxis controller(s) to indicate which joystick the device is enumerated as?
You'd have to modify HIDD, yeah, but it's possible. My "sixaxis server" code does this (without HIDD). http://ps3.jim.sh/sixaxis/bt/
ouasse
Posts: 80
Joined: Mon Jul 30, 2007 5:58 am
Location: Paris, France

Post by ouasse »

the PS3 wireless joystick driver Sashz uses in pdaXrom-ng is derived from Jim's code, and implements a Linux Joystick device in /dev/js[0-]. There should be a way to modify it to turn the controller off after a certain period of inactivity.

It sets up the LEDs correctly and does not need the bluez driver to work (even though the bluetooth interface needs to be configured using hciconfig first).

http://mail.pdaxrom.org/downloads/PS3/b ... .1.tar.bz2
knicknak
Posts: 4
Joined: Sun Sep 06, 2009 10:08 pm

Post by knicknak »

Thanks for the excellent info.

A tangent: Regarding pdaXrom-ng's implementation, when you boot linux, why does pdaXrom-ng leave the controller on? There isn't a way to handoff the controller to the flavor of linux that you boot is there? If you boot GameOS from pdaXrom-ng it turns off the controller (so that you can re-initialize with the GameOS I'm guessing).

PdaXrom-ng seems to work for the controllers, but not the ps3 remote - is adding support for the ps3 remote a difficult proposition? i.e. are there any gotchas because of the way the remote works compared to the controllers?
ouasse
Posts: 80
Joined: Mon Jul 30, 2007 5:58 am
Location: Paris, France

Post by ouasse »

knicknak wrote:when you boot linux, why does pdaXrom-ng leave the controller on? There isn't a way to handoff the controller to the flavor of linux that you boot is there?
I think you are talking about the pdaXrom-ng - based bootloader. pdaXrom-ng also is a full distribution to be used for liveCD's or bootable USB sticks.

The bootloader just does not shutdown the sixaxis daemon before booting the chosen Linux kernel. This is the only reason the controller is still on after kernel boot, and indeed messes up with joystick drivers on the distributions, whatever the driver is based on HIDD or sashz's sixaxisd.
knicknak wrote:PdaXrom-ng seems to work for the controllers, but not the ps3 remote - is adding support for the ps3 remote a difficult proposition? i.e. are there any gotchas because of the way the remote works compared to the controllers?
I think it does not handle the remote because nobody added remote support. Feel free to have a look at the code, and add the necessary ;)
Post Reply