onilink25 / android-bluez-ime

Automatically exported from code.google.com/p/android-bluez-ime
0 stars 0 forks source link

Support the Wii-mote #7

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
If possible, the Wii-mote should be supported as well.

Original issue reported on code.google.com by kenneth@hexad.dk on 30 Jan 2011 at 9:37

GoogleCodeExporter commented 8 years ago
Works fine for me exept one big bug. When you try to change mapping for Left 
thumbstick left (nunchuck) it automatically changes the mapping for Button A 
(remote) thus making either button or thumbstick unusable. I dont think this 
even requires a wiimote to test, so should not probably be a problem to fix :)

P.S. Both buttons do actually work, they only map as one.

Original comment by Hc.Hot.C...@gmail.com on 13 Jun 2011 at 8:45

GoogleCodeExporter commented 8 years ago
Looking at the source. They definately have the same id.
svn/trunk/BluezIME/src/com/hexad/bluezime/WiimoteReader.java

Line 67 "KeyEvent.KEYCODE_A, //Byte 1, bit 3"
and 
Line 121 along with line 147 "KeyEvent.KEYCODE_A, //Classic, Left stick left"

Original comment by Hc.Hot.C...@gmail.com on 13 Jun 2011 at 8:54

GoogleCodeExporter commented 8 years ago
Oops, there are too many keys :)

Attached is a debug version which has the left-thumbstick-left reassigned to Q.

I will put it on Market shortly.

Original comment by kenneth@hexad.dk on 13 Jun 2011 at 7:12

Attachments:

GoogleCodeExporter commented 8 years ago
Issue 46 has been merged into this issue.

Original comment by kenneth@hexad.dk on 14 Jun 2011 at 7:51

GoogleCodeExporter commented 8 years ago
Issue 47 has been merged into this issue.

Original comment by kenneth@hexad.dk on 14 Jun 2011 at 9:23

GoogleCodeExporter commented 8 years ago
I have put up the updated version in downloads:
http://code.google.com/p/android-bluez-ime/downloads/list

If you have trouble using Wiimote, please use the debug version attached to 
this issue.

The version on market no longer has Wiimote support because the users give the 
app poor ratings if Wiimote does not work due to their firmware.

Original comment by kenneth@hexad.dk on 15 Jun 2011 at 4:25

GoogleCodeExporter commented 8 years ago
Forgot to check back here. You mind explaining how to go about getting that 
logcat for you? Also, no Motion Plus accessory. Just a stock Classics 
controller in an original Wiimote.

Original comment by ChicoK...@gmail.com on 15 Jun 2011 at 7:17

GoogleCodeExporter commented 8 years ago
If you have the Android SDK, the easiest way is this:
https://sites.google.com/site/androidhowto/how-to-1/save-logcat-to-a-text-file

If you do not have the SDK installed, there is a free app called alogcat that 
will do it on the phone/tablet:
https://market.android.com/details?id=org.jtb.alogcat 

Original comment by kenneth@hexad.dk on 15 Jun 2011 at 7:22

GoogleCodeExporter commented 8 years ago
i have a SGS and i'm sending my logcat.txt good luck with that

Original comment by aNDRoiD....@gmail.com on 20 Jun 2011 at 12:43

GoogleCodeExporter commented 8 years ago
Thanks for that comprehensive log file.

I have deleted it because it contains a list of all files on your SD card, 
which I assume you want to keep private.

The log reveals that you get the same message as the others: "L2CAP not yet 
supported".
It also reveals that you have a BluetoothHIDService running, which I assume 
means that you are running Honeycomb?

The interesting thing about this is that HID is a layer on top of L2CAP, 
meaning that you cannot have HID without L2CAP. This means that L2CAP *is* 
supported by the kernel, but not exposed to the regular socket function calls. 
(Wiimotes use a non-standard HID-like communication method, so they won't work 
with regular HID support).

I did a little digging, and I think I found the source code for 
BluetoothHIDService:
http://gitorious.org/pandroid/frameworks-base/commit/2bf61eb6a21c1d28206667e5636
4e0c573b3298e/diffs

Now, the really interesting next step is to determine if the same code can be 
compiled and supplied by an app. And then to see if this can be done on a 
2.2/2.3 kernel.

Stay tuned .... :)

Original comment by kenneth@hexad.dk on 20 Jun 2011 at 7:10

GoogleCodeExporter commented 8 years ago
It looks like I have the same issue, but here is one of the errors anyway:

E/BLZ20_WRAPPER( 3965): ##### ERROR : blz20_wrp_connect: protocol BTPROTO_L2CAP 
not yet supported#####

In the app I get:
"Error: Unknown error:0"

If I try to connect to the wiimote using the built-in bluetooth manager I get 
this:
"Sorry, but hid device is not supported on this phone"

I am using the Epic 4g with the EF02 Gingerbread leak, so it may not mean much. 
With Froyo I had similar issues with the wiimote.

Original comment by tbo...@gmail.com on 22 Jun 2011 at 6:15

GoogleCodeExporter commented 8 years ago
I have Samsung Galaxy Ace - and also have BTPROTO_L2CAP not yet supported 
message. However I try launch one bluetooth test - and they tell me "L2CAP 
work" - maybe they use alternative L2CAP init code ? If You interest - I attach 
this test and one decompiled source.

Original comment by exception.cpp@gmail.com on 23 Jun 2011 at 3:34

Attachments:

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Forgot version - I have android 2.3.3, core 2.6.35.7-perf-CL185571
In description says "L2CAP is supported"
Also I have android SDK and root on my phone - if need I can send any 
addinional information (logs/tests/etc).

Original comment by exception.cpp@gmail.com on 23 Jun 2011 at 3:40

GoogleCodeExporter commented 8 years ago
Sorry for flood - but maybe possible install additional driver or use "Kernel 
Update Utility Tool" or something else to my rooted phone - to fix issues with 
L2CAP ?

Original comment by exception.cpp@gmail.com on 23 Jun 2011 at 3:45

GoogleCodeExporter commented 8 years ago
Thanks for the test code. It seems to use the reflection method (same as I 
use), but the test checks if you can create an incoming socket, not an outbound 
one. Furthermore, it does not actually connect, it just calls the setup and 
teardown, so I think it is safe to say that it reports the wrong results.

The only "Kernel Update Utility Tool" I can find is this:
http://www.xda-developers.com/android/flash-kernels-easily-with-kernel-update-ut
ility-tool/
Which seems to be a simple way of installing a custom kernel.

Original comment by kenneth@hexad.dk on 23 Jun 2011 at 7:43

GoogleCodeExporter commented 8 years ago
Thanks for your hard work. I also get error 0 on my galaxy s2 when trying the 
wiimote. any ideas?

Original comment by marc.knu...@gmail.com on 28 Jun 2011 at 9:47

GoogleCodeExporter commented 8 years ago
Issue 50 has been merged into this issue.

Original comment by kenneth@hexad.dk on 29 Jun 2011 at 6:43

GoogleCodeExporter commented 8 years ago
I have sprint HTC Evo 4G with kernel 2.6.32.17 and verizon samsung galaxy with 
kernel 2.6.32.9 and wiimote isn't working with it. it shows error 0 on the 
screen and logcat shows ####ERROR : wrp_wsock_create: out of wsock blocks####
let mek now if anyone needs more details or have any suggestions to get this 
fix. I am willing to spare couple of days on this.

Original comment by prashant...@gmail.com on 30 Jun 2011 at 7:28

GoogleCodeExporter commented 8 years ago
Earlier I tried using wiiuse library through JNI which worked fine on Motorola 
Droid device but does not work on Samsung Galaxy and HTC EVO devices I have 
with me.
the error in this case was hci_get_route(NULL) fails to get the device id. I 
really want to see this working on HTC and samsung devices.

Original comment by prashant...@gmail.com on 30 Jun 2011 at 7:33

GoogleCodeExporter commented 8 years ago
any more news on the wiimote compatibility?

Original comment by marc.knu...@gmail.com on 3 Jul 2011 at 7:04

GoogleCodeExporter commented 8 years ago
I have samsung Galaxy S (Vibrant) With 2.3.4 and I am able to find wiimote, but 
no emulation after that. 

Original comment by pablit...@gmail.com on 4 Jul 2011 at 2:47

GoogleCodeExporter commented 8 years ago
I have samsung Galaxy S (Vibrant) With 2.3.4 and I am able to find wiimote, but 
no emulation after that. 

Original comment by pablit...@gmail.com on 4 Jul 2011 at 2:47

GoogleCodeExporter commented 8 years ago
@prashant...: The "out of wsock blocks" happens because there is a leak in 
Android when creating sockets, so after trying too much, it will run out of 
sockets, you need to reboot and then you will get another error message.

@marc.knu...: No progress yet, I will not be able to look at this for another 
2-3 weeks.

Original comment by kenneth@hexad.dk on 4 Jul 2011 at 7:07

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I have a samsung infuse 4g that wont work with this app. It is able to detect 
the remote. I get the same error 0 as everyone else. I see some amazimg 
possobilities with this app though. Maybe way down the road developing an app 
that tramsformes the wii remote into a universal remote by utilizing LIRC code 
loaded from the phone.

Original comment by brennanh...@gmail.com on 17 Jul 2011 at 9:19

Attachments:

GoogleCodeExporter commented 8 years ago
Issue 57 has been merged into this issue.

Original comment by kenneth@hexad.dk on 26 Jul 2011 at 8:30

GoogleCodeExporter commented 8 years ago
I have realized that I will not have the time to look into this any further for 
the foreseeable future. Given that no-one else has managed to get this working, 
I assume that it is indeed impossible, and has given up my plans to look at 
this in more detail. If I change my mind, I will write here. If someone has 
some new information regarding L2CAP support for Sense/Galaxy, please let me 
know.

Original comment by kenneth@hexad.dk on 10 Aug 2011 at 9:31

GoogleCodeExporter commented 8 years ago
Not sure if this has been asked but are there any reported issues with this 
program working with the Tmobile g2x from LG? thanks in advance. Really looking 
for a controller program that would allow me to play my emulators

Original comment by qui...@gmail.com on 12 Aug 2011 at 11:31

GoogleCodeExporter commented 8 years ago
I have the T-Moblile Galaxy S and my wiimote won't connect.  It says Error: 
Unknown error: 0.  I just got froyo on my phone last night, but I don't know if 
that makes a difference.

Original comment by m.mackl...@gmail.com on 20 Aug 2011 at 2:03

GoogleCodeExporter commented 8 years ago
I own a Vibrant too (T-mobile's Galaxy S) and unfortunately (it seems to be the 
case that)  Samsung and HTC products have inapropriate bluetooth stack which 
pretty much leads no HID device to be able to work (either through Bluez IME or 
any other wiimote app). The problem appears to be insolvable and the people 
with the aforementioned are just in bad lack. You can still install custom 
firmwares (either CM7, or MiUI) to make wiimote work, but that will probably 
put you out of warranty and you'd lose the TV-out functionality...sadly.

Original comment by Stevethe...@gmail.com on 21 Aug 2011 at 8:05

GoogleCodeExporter commented 8 years ago
Great Apps, works like a charm on Andoid-x86/Acer Aspire with the Wiimote. 
Would love to know if Bluez IME can work with Amarino 
apps:www.amarino-toolkit.net
That would be great.
Thanks for the good work.

Original comment by bocar2...@gmail.com on 25 Aug 2011 at 2:14

GoogleCodeExporter commented 8 years ago
Hi,

I own an xperia arc phone (gingerbread) and I've recently bought a zeemote 
stick.

I've connected the zeemote using the bluetooth menu, but then it's not 
accessible in apps. So I've been looking for a software solution and I found 
bluez IME...

But it can't install on my phone : the "install" button on the android market 
is greyed out and I can't do anything.

Is it because the xperia arc (x12) is not supported by your software ? If so 
can you add support ?

Thanks

Original comment by Brup...@gmail.com on 28 Aug 2011 at 5:31

GoogleCodeExporter commented 8 years ago
@bocar2: Bluez IME sends keypresses, so if Amarino can listen for soft-keyboard 
keypresses or listen for Android service messages, it should work. Please 
create a new issue if you want to discuss that so this can be kept as a Wiimote 
specific issue.

Original comment by kenneth@hexad.dk on 30 Aug 2011 at 3:02

GoogleCodeExporter commented 8 years ago
Issue 75 has been merged into this issue.

Original comment by kenneth@hexad.dk on 5 Sep 2011 at 7:02

GoogleCodeExporter commented 8 years ago
I'm with phili, I think the classic wii controller would make a lot of sense. I 
tried to set up the annalog stick to better control my characters on the n64oid 
but it wont accept the input method. Regardless I think its a killer app.

Original comment by dyrst...@gmail.com on 27 Sep 2011 at 12:56

GoogleCodeExporter commented 8 years ago
So how do I fix the 'unknown error 0' problem? Got a samsung gio gt-s5660, 
android 2.2.1, borrowed wii remote. I don't entirely know what I'm doing (or 
doing wrong). I've had a read through the comments and can't make much sense 
from it.

Original comment by patrolma...@gmail.com on 13 Oct 2011 at 6:32

GoogleCodeExporter commented 8 years ago
@Bruphie:
I have checked every availability box in Market.
You can download the apk and install it manually:
https://code.google.com/p/android-bluez-ime/downloads/list

@dyrstadj:
Classic Controller is fixed in 1.10. n64oid has been updated and now supports 
analog stick from within n64oid (but actually calling BluezIME behind the 
scenes).

@patrolmaverick
The only known workaround is to root the phone and install a custom ROM, such 
as CM7:
http://www.cyanogenmod.com/

If you mean "fix it" as in "code something", you need to somehow update the 
Bluetooth kernel module to support L2CAP. The code for this is in the Android 
repositories, but the kernel has been compiled without it.

Original comment by kenneth@hexad.dk on 13 Oct 2011 at 7:45

GoogleCodeExporter commented 8 years ago
i have a problem, it keeps saying error connection refused when i attempt to 
use bluez ime as the input Nonstop. it works Under Android keyboard... tho when 
i play games the analog is under sensitive. i cant for the life of me change 
input to bluez ime in the settings just error spam

Original comment by Imapsyco...@yahoo.com on 13 Oct 2011 at 9:06

GoogleCodeExporter commented 8 years ago
Are you saying that Wiimote works on your phone, but not when using BluezIME ?
What phone/ROM are you using? And what is "Android keyboard", do you have a 
link?

Original comment by kenneth@hexad.dk on 16 Oct 2011 at 2:16

GoogleCodeExporter commented 8 years ago
Issue 104 has been merged into this issue.

Original comment by kenneth@hexad.dk on 24 Oct 2011 at 8:05

GoogleCodeExporter commented 8 years ago
I'm using a AT&T Captivate with the custom Serendipity VII 2.3 rom and I too 
get the unknown error 0 message... CM7 ran like crap on this phone (on mine, 
anyway) and I was really looking forward to getting this working. Sad days.

Original comment by tam.ashd...@gmail.com on 27 Oct 2011 at 9:35

GoogleCodeExporter commented 8 years ago
@tam:
You need to get in touch with the Kernel ROM developers and ask them to build 
the kernel with L2CAP support.

Original comment by kenneth@hexad.dk on 28 Oct 2011 at 9:04

GoogleCodeExporter commented 8 years ago
Issue 109 has been merged into this issue.

Original comment by kenneth@hexad.dk on 30 Oct 2011 at 8:57

GoogleCodeExporter commented 8 years ago
@kenneth@hexad.dk:
I've got a kernel with a build-in L2CAP support on my Galaxy (evidenced by the 
fact that I can now pair my sixaxis with it) but I still *can't* get wiimote 
working (again -error 0-). Lack of L2CAP is NOT the reason why bluezime/Wiimote 
can't work with our phones, there's sth else (out there) preventing it/us as 
well. 

If we're able -somehow- to get that bug, we may *finally* have our Galaxy 
phones supporting the Wiimote. Now where can it be? ....

Original comment by Stefanos...@gmail.com on 14 Nov 2011 at 9:00

GoogleCodeExporter commented 8 years ago
@Stefanos:

Pairing is not the same as having L2CAP. The pairing happens elsewhere, the 
communication/connection is what requires L2CAP.

Does logcat still say "L2CAP not supported" ?

Original comment by kenneth@hexad.dk on 14 Nov 2011 at 10:09

GoogleCodeExporter commented 8 years ago
@Kenneth: I m pretty sure L2CAP is enabled as it says so on my kernels specs. 
Also I currently game on my big TV by using my sixaxis and Galaxy S so it 
definately didn't "just pair". 

Either the guys of the SixAxis app found a work-around or my kernel is indeed 
L2CAP enabled (which I believe is the most probable of the two given that only 
now I was able to -finally- use my sixaxis with my phone)....

Either way considering that the "sixaxis guys" did it (make it work with SGS) I 
believe "we" can do so as well (with the wiimote).

Original comment by Stefanos...@gmail.com on 14 Nov 2011 at 9:05

GoogleCodeExporter commented 8 years ago
Issue 119 has been merged into this issue.

Original comment by kenneth@hexad.dk on 19 Nov 2011 at 9:25

GoogleCodeExporter commented 8 years ago
The sixaxis app requires a rooted phone, it is possible that they inject a 
kernel module that gives L2CAP support.

I am not saying that your ROM does not have L2CAP, I am just saying that if 
logcat says "L2CAP not supported" then your kernel does not support L2CAP. It 
is very cool if the Sixaxis guys have made a way to enable L2CAP, but I doubt 
they are willing to share it with an OpenSource project for free.

If logcat has a different error message than "L2CAP not supported", I am 
willing to look at a log and see if there is something BluezIME can do 
differently so it may work on your phone. If it says "L2CAP not supported" I 
belive the problem is still that the ROM does not support L2CAP.

Original comment by kenneth@hexad.dk on 19 Nov 2011 at 9:43

GoogleCodeExporter commented 8 years ago
Guys, man up a touch and stop giving Kenneth grief (and aggressive challenges).
I had same problem with my HTC Desire S, so I moaned to HTC who simply said 
they only support bluetooth connectivity to speakers and such like, and do not 
plan to facilitate connecting to other partys hardware (ie Nintendo Wiimotes).
I ran the phone stock for a while, then last week decided it meant enough to me 
to be able to connect to a decent controller, so I got s-off and rooted through 
revolutionary.io, then using 'Rom Manager' from the market replaced my phones 
rom with Cyanogen mod 7.summat. (full instructions on how to root from stock 
are on the cyanogen mod website - thanks guys!).
This rom does have full l2cap support. Now I can connect to the wiimote classic 
controller.
The bottom line is, how much do you want to connect to the wiimote? are you 
prepared to root for it? (this does invalidate your phone warranty by the way).
If the answer is no, grow a pair and stop taking it out on Kenneth and face up 
to your own decision.
I'd also quickly like to say thanks to Kenneth for an amazing app, which he has 
provided for free using his own time, and who is incredibly helpful and 
facilitating.
Thanks again Kenneth!

Original comment by janeand...@live.co.uk on 20 Nov 2011 at 11:41