trishume / linux-track

Automatically exported from code.google.com/p/linux-track
MIT License
0 stars 0 forks source link

Mountain Lion #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.I installed Mountain Lion
2.WiiServer starts, but when I try to pair the WiiRemote, it won't work.
3.a If I keep the application active, the Bluetooth icon on the apple menu 
changes from active to paired, but the WiiServer keeps the orange "Connecting" 
string.
3.b If I change application, WiiServer crashes.

Is there anyone which has experienced the same problem?

Thanks,

linux-track is just great.

Original issue reported on code.google.com by antares...@gmail.com on 28 Jul 2012 at 8:41

GoogleCodeExporter commented 9 years ago
Hi,
so far, noone else chimed in with a Mountain Lion problem...

There is one thing you might try - close Wii Server, turn wiimote off and to be 
sure also deactivate bluetooth; now go to the known bluetooth devices and see, 
if the wiimote is listed - if it is, remove it...

When done, try to activate bluetooth, start wii server and try to pair the 
wiimote.

Let me know, if it helped; if not, I'll try to get ML too and see if I can 
reproduce the problem too - the only problem is, that our internet connection 
is not the fastest one (lousy wifi), so it might take me few days to get it...
Kind regards,

Michal

Original comment by f.jo...@email.cz on 29 Jul 2012 at 7:58

GoogleCodeExporter commented 9 years ago
Thank you, 
as you probably remember, I already mail you with another issue, you then gave 
me a custom library to be used inside the ltr_gui, meanwhile I changed Mac, 
still using that library successfully, but now, that I updated the OS the 
WiiServer doesn't work. May the ltr_gui lib affect in some ways the WiiServer 
app?

I tried to delete from the Apple Bluetooth Preferences the Nintendo WiiRemote. 
Then I started WiiServer, and try to pair them, but as long as I push the 
"Connect" button in WiiServer, the paired Nintendo WiiRemote shows up in the 
Apple BlueTooth preferences as Connected, but the WiiServer still shows the 
orange "Connecting" string. Sometimes then it crashes (i attach the crash 
report).

Original comment by antares...@gmail.com on 29 Jul 2012 at 8:34

Attachments:

GoogleCodeExporter commented 9 years ago
Thank you for the report - I just quickly glanced at it, but no tell tale signs 
there so far... I'll take a peek at in the evening, maybe I'll be able to see 
more...

I also tried to get the Mountain Lion, but my Mini is not compatible (I have 
2007 model, and they support 2009 up), so I'll not be able to directly 
reproduce the problem... Also it doesn't seem very probable I'll be able to get 
an upgrade anytime soon...

Anyway, I'll try to see if there were any changes in the bluetooth api and will 
work from there...
Kind regards,

Michal

Original comment by f.jo...@email.cz on 29 Jul 2012 at 9:20

GoogleCodeExporter commented 9 years ago
Update:
looking to the bluetooth docs and other sources, I see that there are some 
changes in the API...
Now I'm also trying to setup a development environment on the 10.7 - maybe the 
compiler will issue some warnings...

Also, the application creates a log - open the terminal and paste the following 
command in:

cp /tmp/linuxtrack*.log ~/Desktop

It will copy all the logs to your desktop - please zip them and attach them 
here...

And last, but not least - what exactly do you mean by "I change application" ?

Kind regards,

Michal

Original comment by f.jo...@email.cz on 29 Jul 2012 at 7:52

GoogleCodeExporter commented 9 years ago
With "I change application" I was meaning, if some other application involving 
bluetooth becomes active, the WiiServer crashes. 
The file I attach is a log of the application:
I opened the WiiServer, pushed on the WiiRemote the A B buttons (in order to 
start the pairing with the Mac), and pushed the "Connect", the Bluetooth Icon 
on the Apple Menu bar, changes to the grey B with the black line in the middle 
of the icon.
The WiiRemote keeps on flashing with the leds, meaning that it is still in the 
"pairing mode", while the WiiServer never leave the orange string 
"Connecting...".

Thanks for the support.

Original comment by antares...@gmail.com on 29 Jul 2012 at 8:52

Attachments:

GoogleCodeExporter commented 9 years ago
Hello,
here is an update...
The log shows signs of a race condition that I already saw before; the problem 
is, that I'm not completely sure what is the root cause.

On the other hand I got an idea and I'm working on it now - in a nutshell, 
instead of searching for the wiimote myself (and possibly racing with the 
system), I leave the work to system and then just query found devices...
I hope to have something for you to test in a matter of day or two (will try, 
but can't promise that).
Kind regards,

Michal 

Original comment by f.jo...@email.cz on 30 Jul 2012 at 9:39

GoogleCodeExporter commented 9 years ago
Thank you. By looking at the WiiRemote and Mac outputs (bluetooth icon on the 
mac, flashing leds on the WiiRemote), I also think there is a kind of race 
between the OS and the WiiServer, I don't remember if this happened in Lion 
too, but now the OS recognize the Bluetooth device as "Joystick". I attach the 
properties of the Nintendo WiiRemote, as seen on the Bluetooth Preferences 
Panel of the MacOS ML (sorry for the italian).
By the way:
Nome = Name
Tipo = Type
Indirizzo = Address
Nome Mostrato = Displayed Name
Servizi = Services
Abbinato = Paired
Configurato = Configured
Preferito = Starred
Connesso = Connected
Classe disp. princ. = Princ. device class
Classe disp. sec. = Secondary device class
Classe serv. disp = no idea
ID prodotto = ID product

Thanks

Giovanni

Original comment by antares...@gmail.com on 31 Jul 2012 at 7:42

Attachments:

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hello Giovanni,
I don't mind italian at all (had two year long course in the highschool, but 
forgot almost everyting since then ;) )...

The wiimote being recognized as joystick is ok - this is the same on Lion. What 
bothers me, is for example this: if I remove the device from known devices and 
pair the wiimote again, as long as I don't disconnect it using the power button 
on the wiimote, I'm able to connect it back by just pressing 1+2 (at least the 
BT icon shows connection). But I have a feeling that there is still something 
wrong, because at that point I can open baseband connection just fine, while I 
can't open L2CAP channel (and bluetooth explorer shows the two L2CAP channels 
in red)...

When I disconnect it by pressing the power button on the wiimote, it won't 
connect anymore, unless I do the pairing again (now speaking strictly about 
system itself, no Wii Server involved).

Today I'll try to dig a bit deeper to see if I can find something - it might be 
caused by the fact, that it is recognized as HID device, but it is not quite 
HID compliant... Maybe if I could persuade it do leave the HID driver to let 
go...
Or there might be something wrong with the pairing not being finished properly 
- hopefully this evening I'll know more...

Kind regards,

Michal

Original comment by f.jo...@email.cz on 31 Jul 2012 at 4:00

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
here is the result of my experiments...
It should be fully compatible with the linuxtrack version you already have - 
just use this Wii server instead of the old one...
Please let me know if it works for you (if it does not, please attach the log 
files and/or crashlog).
Thank you for your help,

Michal

Original comment by f.jo...@email.cz on 1 Aug 2012 at 8:25

Attachments:

GoogleCodeExporter commented 9 years ago
Hi Michal,
I tried the WiiServer, but unfortunately it does not work: I attach the log. 
The app does not crash, but when I try to pair the WiiMote to the WiiServer, 
and then push connect, the bluetooth icon goes to the "paired" mode (gray bold 
icon, with an horizontal line), but few seconds later, it returns to the 
standard active icon (black bluetooth B).
The WiiServer does not change (never) to the Connected Green Light.
Thanks

Giovanni

P.S. I use the last official release of x-plane, but I saw that in the next 
version (10.10) there will be some differences in the mouse behavior in the 3D 
cockpit view, hope this will not be a proble for the plugin :)

Original comment by antares...@gmail.com on 1 Aug 2012 at 8:38

Attachments:

GoogleCodeExporter commented 9 years ago
Sometimes when I leave the Apple BlueTooth Assistant open it ask me for a code 
to be written on the Wii (like it was a Smartphone). But never connects. It 
seems that the OS is blocking the wii server to provide a service for the 
WiiMote. If I can help you with other tests please contact me!

Original comment by antares...@gmail.com on 1 Aug 2012 at 8:56

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
thank you for the prompt response (although I expected different result ;) )...

I don't know if you have an developer account at apple, so I'm attaching a 
bluetooth packet logger for Mountain Lion... It should record the communication 
and give me a clue on what is going on in there...

Its usage is pretty straight forward - just start the logger, it will ask you 
to get admin rights to access the hardware. If the logging window doesn't pop 
up, just select File-New...
Now start the Wii server and try the pairing - you should see packets popping 
up in the logging window.

When done, save the packet log and send it to me please...
Thank you,

Michal

PS. We'll see - if the behavior changes, then I'll correct it...

Original comment by f.jo...@email.cz on 1 Aug 2012 at 9:04

Attachments:

GoogleCodeExporter commented 9 years ago
Hi Michal, I do have the developer account, but in the new Mac i didn't install 
XCode... By the way the Bluetooth logger returns this result (hope you could 
read them). I upload the WiiServer log too.
The sequence of action was:
1. start the logger
2. start wiiserver
3. push connect button.
4. push the pairing mode in the WiiRemote.
5. wait.
...
6. I clicked two times on the bluetooth menu on the apple menu (i tell you this 
since I saw that in the logger some instructions were logged during my call to 
the menu.
7. WiiServer

sent the logs... :)

Original comment by antares...@gmail.com on 1 Aug 2012 at 9:21

Attachments:

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
looking at the log, it is obvious, that the Control channel doesn't get open at 
all (I use synchronous call, so it should return as soon as the channel is 
opened).

Looking at the comm dump, it is obvious, that something opens both those 
channels and after a minute or so it closes them down... I suspect the HID 
driver is playing with it for some reason...

I'll try one more thing now - there is a function, that should hint the system 
to leave the device be...
If that doesn't help, I'll have to dive into the HID stuff to see if I can make 
him to let go...
Kind regards,

Michal

Original comment by f.jo...@email.cz on 1 Aug 2012 at 9:46

Attachments:

GoogleCodeExporter commented 9 years ago
By having a quick look around the web I found 
http://www.iospirit.com/blog/article/169/Mountain-Lion-Bluetooth-Blues/

By the way, with this last version when i try to pair the WiiServer with the 
WiiMote, it asks me for a pin.
Maybe the answer is leave everything without password! :)

Original comment by antares...@gmail.com on 1 Aug 2012 at 10:05

Attachments:

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
I'm heading to bed (not much sleep these days is taking its toll ;) )...
Just a few random thoughts...

 - When pairing the wiimote, do you press 1+2 buttons, or the red sync under battery cover?
  The thing is, that the red button pairing is somewhat different...

 - It is strange, that the system picks up the wiimote - if 1+2 is pressed, it just puts the device to the discoverable state, but wiimote itself is not advertising its presence as far as I know...

 - When the BT icon changes to connected, try pressing the power button on a wiimote for a few seconds; the BT icon should change back to idle; now press 1+2 - does it changes to connected too? If not, try starting the wii server and try the connection then...

 - You might also try to open the bluetooth prefs and try removing the wiimote from there... Then try again the Wii server...

Good night,

Michal

Original comment by f.jo...@email.cz on 1 Aug 2012 at 10:13

GoogleCodeExporter commented 9 years ago
I always use the 1+2 buttons, since it is way faster, tomorrow I will try what 
you said. But every time you sent me an application I remove fom the known 
devices the nintendo controller.

Goodnight

Original comment by antares...@gmail.com on 1 Aug 2012 at 10:19

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
I looked at the blog post and on a first glance it doesn't seem very good...

On the other hand, still there are few things that we could try out...
I'd try to go the HID way as it seems that the HID driver is taking over - 
either just to tell him to let go, or go entirely through HID (change the 
communication layer).

The question now is - would you be interested in carying out some more tests? 
It would help me a lot... On the other hand, I can fully understand if you 
decide to botch the mountain lion for now and go back to lion, so you can fly 
as usual. The decision is yours and don't feel pressed as you helped me a lot 
already...

Let me know what do you think,

Michal

Original comment by f.jo...@email.cz on 2 Aug 2012 at 6:17

GoogleCodeExporter commented 9 years ago
Dear Michal,
I will not downgrade to lion, that's for sure. I will help you, but this 
saturday I will go in holiday, and I won't take the laptop with me! Anyway 
write me all you want to test, when I came back from work in the nezt days, I 
will do my homeworks!!!

I will also try to see if somebody finds a workaround for this "mountain lion 
/bluetooth issue"!

Original comment by antares...@gmail.com on 2 Aug 2012 at 6:33

GoogleCodeExporter commented 9 years ago
I was googling around and found this 
http://stream.weiv.co/mountain-lion-bluetooth-woes-and-its-fix
Although is not a fix, maybe can be part of the solution.

Original comment by antares...@gmail.com on 2 Aug 2012 at 7:04

GoogleCodeExporter commented 9 years ago
Thank you for the link, I'll check that, although I don't think it is where 
we're stuck right now - from the log it seems that the process freezes in the 
function opening the channel...

And thank you for the commitment - it is a huge help for me...
Enjoy the holidays and hopefully when you come back you'll have the wiimote 
working.
Kind regards,

Michal

Original comment by f.jo...@email.cz on 2 Aug 2012 at 7:28

GoogleCodeExporter commented 9 years ago
Maybe the last post was a bit misleading! I will help you until saturday, then, 
if I leave my Laptop at home, it will be a problem, but maybe we can get to a 
stable version in the next days! :) Let me know!

Giovanni

Original comment by antares...@gmail.com on 2 Aug 2012 at 4:32

GoogleCodeExporter commented 9 years ago
Thank you for the clarification Giovanni...
Here is an update according to the post 21 - lets see if it makes a difference.
In the meantime I'm going to take a peek at the HID stuff.
Kind regards,

Michal

Original comment by f.jo...@email.cz on 2 Aug 2012 at 7:54

Attachments:

GoogleCodeExporter commented 9 years ago
It actually crash on start. I attach the log (i tried to disconnect the USB 
devices too, but no improvements).

Process:         WiiServer [38742]
Path:            /Users/USER/*/WiiServer.app/Contents/MacOS/WiiServer
Identifier:      linuxtrack.WiiServer
Version:         1.0
Code Type:       X86-64 (Native)
Parent Process:  launchd [730]
User ID:         503

Date/Time:       2012-08-02 22:02:25.480 +0200
OS Version:      Mac OS X 10.8 (12A269)
Report Version:  10

Interval Since Last Report:          235837 sec
Crashes Since Last Report:           10
Per-App Crashes Since Last Report:   1
Anonymous UUID:                      B19847F2-C224-417B-9BA2-B340746A005F

Crashed Thread:  0

Exception Type:  EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000002, 0x0000000000000000

Application Specific Information:
dyld: launch, loading dependent libraries

Dyld Error Message:
  Library not loaded: /Users/*/libltr.0.dylib
  Referenced from: /Users/USER/*/WiiServer.app/Contents/MacOS/WiiServer
  Reason: image not found

Binary Images:
       0x1074a1000 -        0x1074a5fff +linuxtrack.WiiServer (1.0) <4AA5948D-1EF1-3B71-8AA9-12C9E4A1CF72> /Users/USER/*/WiiServer.app/Contents/MacOS/WiiServer
       0x1074b2000 -        0x1074b2fff +GlimsLoaderMinimal.dylib (1) <951A7DBD-1ACB-0D85-E99B-871D1708BBF5> /Library/Frameworks/GlimsAdditions.framework/Library/GlimsLoaderMinimal.dylib
    0x7fff670a1000 -     0x7fff670d593f  dyld (210.2.3) <A40597AA-5529-3337-8C09-D8A014EB1578> /usr/lib/dyld
    0x7fff8177e000 -     0x7fff8177efff  com.apple.Cocoa (6.7 - 19) <1F77945C-F37A-3171-B22E-F7AB0FCBB4D4> /System/Library/Frameworks/Cocoa.framework/Versions/A/Cocoa
    0x7fff836fc000 -     0x7fff837caff7  com.apple.Bluetooth (4.0.9 - 4.0.9f8) <E74E0A5F-CAF9-39D8-8A95-61B74E87C995> /System/Library/Frameworks/IOBluetooth.framework/Versions/A/IOBluetooth
    0x7fff85c16000 -     0x7fff85e34fff  com.apple.CoreData (106 - 407.5) <45EF39FE-7FD6-366E-BB5C-3E86E0B7DA3C> /System/Library/Frameworks/CoreData.framework/Versions/A/CoreData
    0x7fff88fcf000 -     0x7fff8932bff7  com.apple.Foundation (6.8 - 945) <0C972F73-0C07-3384-98F2-B176E0289494> /System/Library/Frameworks/Foundation.framework/Versions/C/Foundation
    0x7fff898c9000 -     0x7fff8a4f3fff  com.apple.AppKit (6.8 - 1187) <C9309F5C-9441-3E5B-A120-B03FEDDA63F9> /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit

Model: MacBookPro9,2, BootROM MBP91.00D3.B06, 2 processors, Intel Core i5, 2.5 
GHz, 16 GB, SMC 2.2f38
Graphics: Intel HD Graphics 4000, Intel HD Graphics 4000, Built-In, 512 MB
Memory Module: BANK 0/DIMM0, 8 GB, DDR3, 1600 MHz, 0x857F, 
0x483634314755363747313630304700000000
Memory Module: BANK 1/DIMM0, 8 GB, DDR3, 1600 MHz, 0x857F, 
0x483634314755363747313630304700000000
AirPort: spairport_wireless_card_type_airport_extreme (0x14E4, 0xF5), Broadcom 
BCM43xx 1.0 (5.106.98.81.20)
Bluetooth: Version 4.0.9f8 10405, 2 service, 18 devices, 1 incoming serial ports
Network Service: Wi-Fi, AirPort, en1
Serial ATA Device: TOSHIBA MK5065GSXF, 500,11 GB
Serial ATA Device: MATSHITADVD-R   UJ-8A8
USB Device: hub_device, 0x8087  (Intel Corporation), 0x0024, 0x1d100000 / 2
USB Device: USB 2.0 Hub, 0x1a40  (TERMINUS TECHNOLOGY INC.), 0x0101, 0x1d110000 
/ 8
USB Device: CH FIGHTERSTICK USB, 0x068e, 0x00f3, 0x1d112000 / 11
USB Device: CH PRO THROTTLE USB, 0x068e, 0x00f1, 0x1d113000 / 10
USB Device: CH PRO PEDALS USB, 0x068e, 0x00f2, 0x1d114000 / 9
USB Device: hub_device, 0x0424  (SMSC), 0x2513, 0x1d180000 / 3
USB Device: Apple Internal Keyboard / Trackpad, apple_vendor_id, 0x0253, 
0x1d183000 / 6
USB Device: BRCM20702 Hub, 0x0a5c  (Broadcom Corp.), 0x4500, 0x1d181000 / 5
USB Device: Bluetooth USB Host Controller, apple_vendor_id, 0x821d, 0x1d181300 
/ 7
USB Device: IR Receiver, apple_vendor_id, 0x8242, 0x1d182000 / 4
USB Device: hub_device, 0x8087  (Intel Corporation), 0x0024, 0x1a100000 / 2
USB Device: FaceTime HD Camera (Built-in), apple_vendor_id, 0x8509, 0x1a110000 
/ 3

Original comment by antares...@gmail.com on 2 Aug 2012 at 8:04

GoogleCodeExporter commented 9 years ago
Error in the build script - wrong library path...
Here is the corrected version...

Original comment by f.jo...@email.cz on 2 Aug 2012 at 8:33

Attachments:

GoogleCodeExporter commented 9 years ago
Works perfectly, both the WiiServer + ltr_gui + X-PLANE!  Great Job!

Original comment by antares...@gmail.com on 2 Aug 2012 at 8:39

GoogleCodeExporter commented 9 years ago
Thank you for the great news and for your help Giovanni!
If I may ask you one more thing - I'll go once more through the code to see if 
I didn't introduced any stupid mistakes and when I'm done (probably during 
tomorrow), I'd ask you for one more test (hopefully a final one;) )...
Thank you,

Michal

PS. Actually you solved the problem by pointing me at the blog post - their 
solution works...

Original comment by f.jo...@email.cz on 2 Aug 2012 at 8:48

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
could you test this last version and let me know if it works for you?
Thank you,

Michal

PS. I took the librerty to introduce you to our hall of fame, as you really 
helped me a great deal (including providing me with a solution on a golden 
plate ;) )

Original comment by f.jo...@email.cz on 2 Aug 2012 at 10:50

Attachments:

GoogleCodeExporter commented 9 years ago
Sure I will, but i will do that tomorrow :) just shut down my computer

Thanks for everything!

Inviato da iPhone

Il giorno 03/ago/2012, alle ore 00:50, "linux-track@googlecode.com"
<linux-track@googlecode.com> ha scritto:

Original comment by antares...@gmail.com on 2 Aug 2012 at 10:52

GoogleCodeExporter commented 9 years ago
Hi Michal,
thank you for the Hall of Fame! But really I did nothing special, you solved 
the problem brilliantly!!
Here I attach the log of a simple comunication between the WiiServer and the 
WiiRemote.
1. I start the WiiServer.
2. Connect button
3. on the remote push the A+B buttons.
4. pairs, asking me for a password that i ignore
5. connected.
6. i push the disconnect button on the WiiServer.

Original comment by antares...@gmail.com on 3 Aug 2012 at 4:31

Attachments:

GoogleCodeExporter commented 9 years ago
Hello Giovanni,
I'm just giving you credit, where credit is due - without refering me to that 
blogpost I wouldn't have come up with the solution so you really deserve it...

Do I understand it correctly, that it is working?
Thank you for your help,

Michal

Original comment by f.jo...@email.cz on 3 Aug 2012 at 8:07

GoogleCodeExporter commented 9 years ago
Works perfectly, i'm using it right now!

Original comment by antares...@gmail.com on 3 Aug 2012 at 8:12

GoogleCodeExporter commented 9 years ago
Thank you very much for the great news!
And thank you for your help...
Enjoy your holidays,

Michal

PS. I'm going to close this ticket; in case of further problems, please reopen 
it... 

Original comment by f.jo...@email.cz on 3 Aug 2012 at 8:42