Closed kd0aij closed 7 years ago
@dogmaphobic Should bluetooth work on Android?
What device? The TBS Crossfire works. At least it was working the last time I used it.
I'm using bluetooth with PX4 stack, it works fine on ASUS zenpad 7 but it does not connect on Galaxy Note4, I get "service not available"
I need to know what "Bluetooth" device is plugged to the Pixhawk.
Mine shows up as HC-06 and the chip is labeled BC417
This? I need to get one to test. The only Bluetooth device I have is the Crossfire.
I found a datasheet for it. Did you have to set it up using the "AT" commands as described?
https://www.olimex.com/Products/Components/RF/BLUETOOTH-SERIAL-HC-06/resources/hc06.pdf
It's been 2.5 years since I got mine. Don't remember, but I probably did set the baud rate using an AT command first.
And that one looks almost identical to mine: http://smile.amazon.com/Kootek%C2%AE-Bluetooth-Serial-Module-Arduino/dp/B00DQ4A7O6?ie=UTF8&psc=1&redirect=true&ref_=oh_aui_search_detailpage
Got it in the mail today.
The good news, I can't get it to connect either. Meaning I could reproduce the issue and I can debug it. The bad news, I won't be able to do much for the next couple of weeks 8P
@dogmaphobic Do you think this is important enought to hold 3.0 release for?
Good question. Bluetooth was ever really tested using only the Crossfire. Today was the first time I connected something else. It took me an hour just to get the thing configured and paired with a Nexus 9. Bluetooth is inherently unreliable.
I don't think it's enough to hold 3.0 as I don't think that many people use it to begin with. Those who try, it will either work or not, which is quite standard with Bluetooth things, specially a $5 trinket from China.
@dogmaphobic update: can't connect via wifi using Moto G running Android 6.0, but Nexus 7 running Android 6.0.1 works fine
as of today, my Moto G won't connect via Bluetooth either. Any interest in why something that used to work is now broken? Or is BT deemed to be of no value for this application?
update: the free "BlueTerm" app connects to the BT dongle and displays data on both Nexus7 and MotoG
@dogmaphobic Did you ever get a bluetooth thingy? I don't have anyting to test with.
I have a similar problem with a HC06 bluetooth module on Android here (Beanstalk 6.0, Android 6.0.1 on Amazon Tate), see attached log file log.txt
I particularly wonder about the message "Using found rfcomm channel 0". When I use the HC06 under plain Linux, I have to bind to channel 1 to see the MAVLink data stream from the HC06.
Tower successfully connects to the drone on the same tablet, so I can definitely rule out any hardware or pairing issues. A cross test on my Sony Z3 (Android 6.0.1 again) reveals that the problem isn't specific to my tablet, either (same result, same log).
Same here i think! My galaxy tab s2 connects to bluetooth but noch data Coming! Tower works for me.
@dogmaphobic Would be nice to figure this one out for 3.1 release. Lots of request for it.
Working now.
same here, "failed to connect service". Looking forward for it
@GlidLov Are you using the latest version of QGC?
@DonLakeFlyer yes. Trying again today, uninstalling and reinstalling latest from google play
That looks like the same board I tested with. I'll try it again today.
I'm still not able to connect to BT via Android even with the new version. Just crashes the QGroundcontrol app on attempted connection to BT.
I also have the same problem as Patnetpatnet, QGC just crashes when I try to open a BT connection. I set up connections to both my HC-06 and to my TBS Crossfire, both with the same issue. Running on a brand new Acer Iconia, running Marshmallow 6.0. Both the HC-06 and xFire work fine with QGC on my Mac. Tried Blueterm on the HC-06 and it connects successfully.
@dogmaphobic Do you time to look at this?
Thanks for a quick response on re-opening the issue. Let me know if there is anything I can do to assist. Would it be worth me having a go at putting Qt on my Android device, compiling the source and seeing if I can feed back an error report?
I found the change that is causing the crash: #4349
It changed how the configuration is handled. The Bluetooth driver is now using a NULL pointer for its configuration and crashing. I need to understand what the change was for before I can find a fix.
I just compiled QGC in Qt and deployed to my tablet. I checked that the addition from #4565 was present before compiling, the following line was present in BluetoothLink.cc
, _config(qobject_cast<BluetoothConfiguration*>(config.data()))
Still crashing on opening the BT connection. Application output errors as follows
D QGroundControl: (null):0 ((null)): LinkManager mavlinkStatus:channel:flags 0xe12ec9d0 2 2
F libc : Fatal signal 11 (SIGSEGV), code 1, fault addr 0x18 in tid 30176 (QtThread)
"org.mavlink.qgroundcontrol" died.
Apologies if I'm doing something dumb here, I'm new to Qt! :)
I just compiled QGC in Qt and deployed to my tablet.
If you are building yourself, you can launch it through the debugger and see where it crashes.
@Siytek If you're new to Qt and you figured out how to get an android build to build and deploy then that's huge! That combination can be quite the pain. Anyway, if you could get the crash in the debugger and find the crash point that would be awesome.
Thanks @DonLakeFlyer, I'm quite well rehearsed with lower level stuff, I'm a hardware guy really (electronic engineer as a day job) but would like to improve my programming/embedded skills. There's some pretty good documentation so didn't have too much problem deploying to Android.
Sure, I was just in the process of reading up on the debugger but had to go out and do some socialising. I'll continue tomorrow and try find the point in which the crash occurs.
@DonLakeFlyer @dogmaphobic I've been scratching my head for a few hours now, when I deploy the debug build, it successfully runs on the target but debugging fails with the error
Debugging starts Failed to contact debugging port.Debugging has finished
Debugging works ok with the Qt example project, I can set breakpoints etc. Did I miss something?
Have you turned on developer mode on your device?
On Feb 19, 2017, at 8:54 AM, Simon notifications@github.com<mailto:notifications@github.com> wrote:
@DonLakeFlyerhttps://github.com/DonLakeFlyer @dogmaphobichttps://github.com/dogmaphobic I've been scratching my head for a few hours now, when I deploy the debug build, it successfully runs on the target but debugging fails with the error
Debugging starts Failed to contact debugging port.Debugging has finished
Debugging works ok with the Qt example project, I can set breakpoints etc. Did I miss something?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/mavlink/qgroundcontrol/issues/2910#issuecomment-280931666, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AFmsczcjC6bW0fhLY0qV109UzExnqGEiks5reHPZgaJpZM4Hk7Cs.
Yes USB debugging is active on my device, it works fine with one of the Qt sample applications. I am probably getting a bit off topic here with Qt related issues, ill head over to QGC in Google groups to start a new topic.
it works fine with one of the Qt sample applications
Yeah, sorry I missed that. Maybe Gus will have some ideas.
I can repro the crash, but I can't catch it in the debugger either.
Actually I can't repro the crash. Here's why:
Once I deleted QGC completely from the device and then really deployed a new version from QtCreator using master it all worked.
Also just discovered that daily builds are not getting pushed up correctly. They are a week old. So daily builds don't have the fix.
@DonLakeFlyer you are correct! Makes perfect sense, I deleted the original installation, debugging now working for me and BT didn't crash - I didn't assign an adapter nor try a connection but I now get the disconnect button available after pressing connect. Ill try it on the plane tomorrow.
Great. Let us know if everything is working for you now and we can close this one out.
Does the latest QGC in Google Play now have a BT Android fix? Or does one have to go this circuituitous route? Not clear. BT issues have been outstanding for a long long time btw. Thanks,
@dagar I just went to play store dev console and it says there is no APK in beta testing. Am I looking at the wrong place, or is something out of whack. Want to make sure Android beta is up to date with latest daily.
I just deployed a release build on my tab and I am pleased to report Bluetooth is now working as expected! At a glance, all instruments and information now seems to be displaying as expected in QGC. Thanks for resolving this issue, I'm excited to go try my tablet in the field now!
Thanks for testing folks.
FYI: Still trying to figure out Android daily builds from Google Play.
Did you manage to get daily builds sorted? @Patnetpatnet if you really want a copy with working Bluetooth and it's not going to be available on Google Play just yet, I can have a go at sending you a compiled version of the latest code.
The Android Google Play beta (daily build) isn't currently auto updating, but you can install it manually. https://s3-us-west-2.amazonaws.com/qgroundcontrol/builds/master/QGroundControl.apk
Thanks! Will test this weekend.
The version of Google play beta is 3.1.3, but the version posted here is 3.1.2-277.... Couldn't this be the reason why it is not updating ?
Did you manage to get daily builds sorted?
As far as I know google play still does not have the right daily build. @dagar ?
"service not available"