Page 1 of 2

android client app

Posted: Sun May 05, 2013 5:01 am
by atomicdog
What state is the android client app in?
I want to help out with it, so I'm wondering which parts work and which parts don't.

Re: android client app

Posted: Sun May 05, 2013 10:09 pm
by marcus
Hi atomicdog,

Glad to hear that you want to help out! Currently it's nothing more than a proof-of-concept. If you install the apk and plug the Crazyradio (using an adapter) you will get a UI with two virtual joysticks that can be used to control the Crazyflie (at a hardcoded address). It works for flying but that's all it does (and it's pretty hard). Here's a picture of the setup/app

What we would really like in the future is:
  • An API similar to the one we have in Python for the PC where you can easily connect and use log/param to log data and change parameters in the Crazyflie. This also takes care of downloading the log/param TOC and makes sure that we replies back when requesting information.
  • An API for communicating and setting up the Crazyradio similar to the one we have today
  • A bit more advanced client app where you can select what Crazyflie to connect to from a list and maybe see some feedback using logging.
The code is located here if you want to have a look.

/Marcus

Re: android client app

Posted: Wed May 08, 2013 6:53 pm
by falstaff
Hi,

One more thing to do: Set the Crazyflie to channel 107, since its fixed in the source of the android app right now.

Due to lack of alternatives I flew the first charge using my Android phone. I have to admin, its pertty hard to control the Crazyflie using this method, I think its especially due to lack of physical response (e.g. you don't "feel" how far you pushed the stick. On a real controller, you have a way better feeling for that). And when you see the reaction, its already too late to react... :-)

Maybe there is better solution how to steer the Crazyflie using a phone? Using Sensors?...

falstaff

Re: android client app

Posted: Wed May 08, 2013 7:22 pm
by foosel
falstaff wrote:One more thing to do: Set the Crazyflie to channel 107, since its fixed in the source of the android app right now.
Thank you! I was fooling around with the app the other day, it didn't work though (Crazyflie is set to channel 10), didn't find the time to investigate yet, you just saved my a bunch of time :) Just changed the source instead of the Crazyflie's setting, now it connects like charm... Now, flying with those on-screen joysticks on the other hand, that's indeed a whole different story :lol:

For anyone who wants to try this out as well but can or does not want to compile the client himself, I've uploaded my version of the compiled APK here, it's compiled against Android SDK 4.0 (API 14) and works fine on my Galaxy Nexus with 4.2.2.

Re: android client app

Posted: Wed May 08, 2013 7:35 pm
by atomicdog
falstaff wrote: Maybe there is better solution how to steer the Crazyflie using a phone? Using Sensors?...
That's what I'm thinking also. I want to try to use the accelerometer on the android for pitch and roll.

Re: android client app

Posted: Wed May 08, 2013 8:01 pm
by marcus
I agree it's pretty hard to control using the on-screen joysticks. If you do a test using the phone sensors I would really like to test it :D

Re: android client app

Posted: Thu May 09, 2013 8:57 am
by marcus
greggius did a test with the accelerometer (using the android phone to simulate a joystick to the PC) in this thread.
greggius wrote:Yep, sure did. Flight performance with accelerometers is pretty good; I find it just a little bit harder than using an xbox controller, although I probably just need more practice.
I also find that it’s easier to spin out of control; need to remember to keep my hand steady.
Seems like the sensors might work better than the joysticks.

/Marcus

Re: android client app

Posted: Fri May 10, 2013 9:29 pm
by SuperDave42
Might be able to get the 6Axis app on Android to map the PS3 controler analog sticks to the touch screen over BT and have the PS3 controller actually manipulate the Android CrazyFlie app. :shock:

Dave

Re: android client app

Posted: Wed May 15, 2013 8:38 am
by atomicdog
Here's the apk for my first quick & dirty attempt at controlling the roll and pitch using the accelerometer. So far, It's not really much easier for me. I think it's partly because I'm using a tablet and not a phone. So, I'm interested in how it feels to people with phones.

Re: android client app

Posted: Wed May 15, 2013 2:36 pm
by mjc506
Good work, feels much better for me :)