Page 1 of 2

MK1 can't connect to android app

Posted: Sun Feb 14, 2016 2:37 am
by murph1379
I have an MK1, with the 2.8.7 firmware. The Racecapture 1.4.2 program for windows can connect and configure it via USB without a problem. I have the android app version 4.4 installed on a samsung galaxy 7" tablet running Android 4.4.2.

Regardless of how many times I click on the screen, I can't get the RaceCapture icon & bluetooth configuration thing to show up at all, so I can't connect the app to the RaceCapture Pro.

I read in another post that clearing the data from the app would help. I tried that, and unfortunately that didn't fix it. :( Tried restarting the tablet and the device several times, and unfortunately I don't have another tablet to try. SoloStorm can see and connect to the RCP without an issue, so I know Bluetooth is paired ok.

Any ideas on how to fix this?

thanks!

Posted: Sun Feb 14, 2016 8:55 pm
by toga94m
I went off and did something else for 10-20 minutes and eventually my 2.8.7 MK1 connected to the app over bluetooth. Hoping the next release gets it back to where it used to connect quickly. On the bright side, when it's running and then gets disconnected (powercycling MK1) the reconnect is quick and painless - it just picks up streaming data like nothing happened.

Posted: Mon Feb 15, 2016 12:31 am
by murph1379
RaceCapture actually crashes on my tablet after 10 minutes or so of trying to connect. :(

Posted: Sun Feb 21, 2016 8:42 pm
by brentp
Hi - let's figure this out more.

Are you running the 1.3.7 app or did you sign up for the 1.4.3 beta ?

What tablet make / model are you using?

Do you see this problem on another android device, just as a comparison?

Posted: Wed Feb 24, 2016 12:54 pm
by murph1379
brentp wrote:Hi - let's figure this out more.

Are you running the 1.3.7 app or did you sign up for the 1.4.3 beta ?

What tablet make / model are you using?

Do you see this problem on another android device, just as a comparison?
The Racecapture app is version 1.3.13, according to Android.

It's a Samsung Galaxy Tab 3 7", 2013 model running Android 4.4.2.

I don't own another Android device, so I haven't been able to test that.

Posted: Wed Feb 24, 2016 3:30 pm
by stieg
Hey @Toga94m
I went off and did something else for 10-20 minutes and eventually my 2.8.7 MK1 connected to the app over bluetooth. Hoping the next release gets it back to where it used to connect quickly.
Yeah... that is no good. I assume you are running the 1.4.2 beta app? Will you confirm?

Posted: Mon Feb 29, 2016 1:53 am
by toga94m
sorry,been on a different planet for the past week. Tonight my app says 1.4.3 (beta program) but I haven't confirmed it does the same thing regarding connect time/delay. I should have time to do testing again this week.

Posted: Mon Feb 29, 2016 10:25 pm
by stieg
Cool. Let us know when you can.

Posted: Thu Mar 03, 2016 1:40 am
by toga94m
Okay, so today (after rebooting the tablet) it hooked up pretty quickly. Android tablet running 1.4.3 beta app, RCP MK1 running 2.8.7 .......... shut it all down, turn MK1 back on (powered via USB from AC adapter) and relaunch app - no top-line indication that it's trying to find a BT connection. Dongle keeps blinking hopefully. Gave up after a few minutes. Close app, turn off bluetooth, try to turn it back on, ahh, won't turn on. Flaky BT stack on this tablet. Restart tablet. Turn on bluetooth, then launch app. 16 seconds after launch, the main screen is up and it's looking for a connection.. one pass through. Then no more attempts on the top status line. And from looking at the app log, it didn't iterate through all 3 bluetooth devices (specifically missing the RaceCapturePro device, which was in the enumerated list of detected ports).

Anything else I should try?

Code: Select all

[Kivy        ] v1.9.0
[Logger      ] Record log in /data/data/com.autosportlabs.racecapture/files/.kivy/logs/kivy_16-03-02_4.txt
[Python      ] v2.7.2 (default, Feb  6 2016, 17:42:32) 
[GCC 4.8]
[Factory     ] 173 symbols loaded
stderr: /data/data/com.autosportlabs.racecapture/files/lib/python2.7/site-packages/kivy/core/image/img_pygame.py:13: RuntimeWarning: import cdrom: No module named cdrom
stderr: (ImportError: No module named cdrom)
[Image       ] Providers: img_tex, img_dds, img_gif, img_pygame (img_pil, img_ffpyplayer ignored)
[Window      ] Provider: pygame
&#91;GL          &#93; OpenGL version <OpenGL ES 2.0 build 1.9@2564405>
&#91;GL          &#93; OpenGL vendor <Imagination Technologies>
&#91;GL          &#93; OpenGL renderer <PowerVR SGX 544MP>
&#91;GL          &#93; OpenGL parsed version&#58; 2, 0
&#91;GL          &#93; Texture max size <4096>
&#91;GL          &#93; Texture max units <8>
&#91;Support     &#93; Android install hooks
&#91;Window      &#93; virtual keyboard not allowed, single mode, not docked
&#91;Text        &#93; Provider&#58; pygame
&#91;Clipboard   &#93; Provider&#58; android
Call to deprecated function __call__ in /home/brent/git-projects/RaceCapture_App/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/site-packages/kivy/utils.py line 251.Called from /home/brent/git-projects/RaceCapture_App/.buildozer/android/app/autosportlabs/widgets/filebrowser/__init__.py line 81 by <module>&#40;&#41;.
Call to deprecated function __call__ in /home/brent/git-projects/RaceCapture_App/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/site-packages/kivy/utils.py line 251.Called from /home/brent/git-projects/RaceCapture_App/.buildozer/android/app/autosportlabs/racecapture/settings/systemsettings.py line 21 by get_default_data_dir&#40;&#41;.
Call to deprecated function __call__ in /home/brent/git-projects/RaceCapture_App/.buildozer/android/platform/python-for-android/build/python-install/lib/python2.7/site-packages/kivy/utils.py line 251.Called from /home/brent/git-projects/RaceCapture_App/.buildozer/android/app/autosportlabs/racecapture/settings/systemsettings.py line 30 by get_default_user_files_dir&#40;&#41;.
&#91;UserPrefs   &#93; Data Dir is&#58; /storage/emulated/0/Android/data/com.autosportlabs.racecapture/files
&#91;AppConfig   &#93; using user storage directory&#58; /sdcard/racecapture
&#91;GL          &#93; NPOT texture support is available
&#91;OSC         &#93; using <thread> for socket
&#91;Base        &#93; Start application main loop
&#91;Android     &#93; found 17 joystick
&#91;Android     &#93; create joystick <0>
&#91;Android     &#93; discard joystick <0> cause no button
&#91;Android     &#93; create joystick <1>
&#91;Android     &#93; create joystick <2>
&#91;Android     &#93; create joystick <3>
&#91;Android     &#93; create joystick <4>
&#91;Android     &#93; create joystick <5>
&#91;Android     &#93; create joystick <6>
&#91;Android     &#93; create joystick <7>
&#91;Android     &#93; create joystick <8>
&#91;Android     &#93; create joystick <9>
&#91;Android     &#93; create joystick <10>
&#91;Android     &#93; create joystick <11>
&#91;Android     &#93; create joystick <12>
&#91;Android     &#93; create joystick <13>
&#91;Android     &#93; create joystick <14>
&#91;Android     &#93; create joystick <15>
&#91;Android     &#93; create joystick <16>
&#91;RCPAPI      &#93; msg_rx_worker starting
&#91;RCPAPI      &#93; cmd_sequence_worker starting
&#91;RCPAPI      &#93; auto_detect_worker starting
&#91;RCPAPI      &#93; Starting auto-detect
&#91;AndroidComms&#93; detected ports&#58; MCM,BECAUSERACECAR,RaceCapturePro
&#91;RCPAPI      &#93; Searching for device on all ports
&#91;RCPAPI      &#93; Trying MCM
&#91;AndroidComms&#93; Opening connection MCM
&#91;AndroidComms&#93; after open
&#91;RCPAPI      &#93; attempting to recover connection
&#91;RCPAPI      &#93; Giving up on MCM
&#91;AndroidComms&#93; close
&#91;RCPAPI      &#93; Trying BECAUSERACECAR
&#91;AndroidComms&#93; Opening connection BECAUSERACECAR
&#91;AndroidComms&#93; after open
&#91;RaceCaptureApp&#93; Current Tracks Loaded
And then, after uploading this app log, it connected on the first pass thru the 3 BT devices. Strange. At least I've got 8+ weeks till RaceCar Season starts.

Posted: Thu Mar 03, 2016 3:27 pm
by stieg
Looking at your logfile I see the unit listed:
[AndroidComms] detected ports: MCM,BECAUSERACECAR,RaceCapturePro
But it would appear that the app just doesn't get to it. What is "BECAUSERACECAR" on your tablet? From what I can see it got stuck on this device. Anyway it seems like this is probably related to this issue: https://github.com/autosportlabs/RaceCa ... issues/888. We will have to see what we can do to make it faster.

Thanks for the info Tom. Nothing more for you to do now. Subscribe to that ticket so you are notified when it is fixed. We may send a beta your way to see if the patch we make solves the issues (tablets can be finicky devices you know). Cheers.

Posted: Thu Mar 03, 2016 6:01 pm
by toga94m
stieg wrote:Looking at your logfile I see the unit listed:
[AndroidComms] detected ports: MCM,BECAUSERACECAR,RaceCapturePro
But it would appear that the app just doesn't get to it. What is "BECAUSERACECAR" on your tablet? From what I can see it got stuck on this device.
MCM is a bluetooth receiver/amplifier that drives two in-ceiling speakers in the kitchen
BecauseRacecar is my Win8 laptop, which was on but not trying to connect. I used bluetooth 5 minutes later to send the Android app logfile over to the laptop.

In prior app logfiles, the app iterated across all three devices multiple times before finally connecting. This test, it just stopped and gave up. Seems hit-or-miss now.

I bought a Black Friday Kindle in November, to replace this aging Asus tablet. What's the status of the beta app on the Kindle/Amazon store?

Posted: Fri Mar 04, 2016 3:36 pm
by stieg
In prior app logfiles, the app iterated across all three devices multiple times before finally connecting. This test, it just stopped and gave up. Seems hit-or-miss now.
We hear ya. We had to make some changes to the app to support some new functionality coming in the 2.9.0 firmware so that is probably what caused it (but am not 100% sure).
I bought a Black Friday Kindle in November, to replace this aging Asus tablet. What's the status of the beta app on the Kindle/Amazon store?
I assume you mean a Fire tablet? As to the status of the beta app on the kindle store... I have no idea. Brent would know that better than me.

Posted: Fri Mar 04, 2016 3:54 pm
by brentp
Hi -

A couple of things that will improve the MK1 and MK2 experience.

What we'll have is the first connection attempt it will scan all devices and settle on the first RaceCapture/Pro it can find.

Next attempt it will attempt to connect to the last known device. Failing that, it will fall back to scanning all devices.

This is all to support the ability to change the RCP Bluetooth Name (coming in 2.9.0)

The kindle app store can only handle one app version - it doesn't have the ability of a separate beta track.

So, what we can do is wait for the production release; push the beta to amazon app store early; or manually supply APKs that can be loaded manually.

Posted: Fri Mar 04, 2016 5:41 pm
by toga94m
stieg wrote:
In prior app logfiles, the app iterated across all three devices multiple times before finally connecting. This test, it just stopped and gave up. Seems hit-or-miss now.
We hear ya. We had to make some changes to the app to support some new functionality coming in the 2.9.0 firmware so that is probably what caused it (but am not 100% sure).
I totally get the need to rename the RCP hardware... it'd suck to have a bunch of cars in grid, all talking to each other's tablets instead of their own. But - instead of repeatedly scanning all paired devices, could you do something like : when the app first starts after an upgrade, present a list of paired BT devices, and let the human poke a checkbox on the one they want to use? Rather than iterating and shouting "HELLO" at my kitchen speakers, and my laptop, and whatever else?

Does the app know to throw away messages that don't start with the VER response, until the incoming buffer is empty, or does it just parse the first line it sees? I'm guessing that my MK1 streaming output is burying the tablet with data, when all it asked for was a response to "getVer".

Should the app be launched and scanning before powering on the RCP hardware, so its query is first in line when the hardware wakes up?

Posted: Fri Mar 04, 2016 5:57 pm
by toga94m
Also looking to find out what drives the MK1 bluetooth LED. I see it's wired to U2 (the BT chip) directly, but can't find a part number for U2 so I can look up a datasheet. I didn't notice anything in source related to the LED, so maybe it independently shows if it thinks it's paired and communicating? Or is its state of on/off/blink controlled by MK1 thru AT commands?