[SOLVED]CF2 Launched into wall as soon as cfclient connected

Post here to get support
Post Reply
lxrocks
Member
Posts: 31
Joined: Sat Feb 15, 2014 1:24 am

[SOLVED]CF2 Launched into wall as soon as cfclient connected

Post by lxrocks »

I finally got my hands on a PS Dual Shock 3, connected it to my mac, started cfclient and connected to the Radio and CF2 just launched into the wall like a missile - missed my face by inches :)

So what did I do wrong here?

Is it likely the controller is faulty , I don't have PS so how do I test it?
chad
Expert
Posts: 555
Joined: Sun Sep 28, 2014 12:54 am
Location: New York, USA
Contact:

Re: CF2 Launched into wall as soon as cfclient connected.

Post by chad »

I've noticed with both the CF1 and CF2 on my Mac that sometimes when I plug in my PS3 controller, the inputs have some insane values (like thrust @ 72%). Once I hit the PS button, they typically reset to default (0) values. Take a look at the "Flight Control" tab in the client, just below the artificial horizon in the "Target" column. If these fields show crazy values when you're not touching the controller, try to hit the PS button prior to connecting to the Crazyflie. If hitting the PS button doesn't correct them, disconnect and reconnect the PS controller either via the USB cable if wired or from the Bluetooth menu if wireless.

It's good to be in the habit of checking the "Target" values (input values) before you hit the Connect button. If pitch, roll, and yaw fluctuate, it's not an issue but make sure thrust is at 0 before connecting. Another thing I sometimes do (especially if I'm running the headless client on my Mac) is turn on the Crazyflie, then after the self-test, flip it upside down just prior to connecting (starting up cfheadless). If it stays still, I flip it back over and commence flying. I only do this if I'm running the headless client on my Mac though. :o
Crazyflier - my CF journal...
4x Crazyflie Nano (1.0) 10-DOF + NeoPixel Ring mod.
3x Crazyflie 2.0 + Qi Charger and LED Decks.
Raspberry Pi Ground Control.
Mac OS X Dev Environment.
Walkera Devo7e, ESky ET6I, PS3 and iOS Controllers.
mlundh
Beginner
Posts: 18
Joined: Fri Nov 28, 2014 5:31 pm

Re: CF2 Launched into wall as soon as cfclient connected.

Post by mlundh »

I noticed the same problem, and i actually created an issue about it on the CF firmware github repo. I think that the firmware should do some sanity checks before allowing the motors to start. In the mean time, the check that chad mentioned is the only way to be sure.
lxrocks
Member
Posts: 31
Joined: Sat Feb 15, 2014 1:24 am

Re: CF2 Launched into wall as soon as cfclient connected.

Post by lxrocks »

Thanks for the advice Chad.

After replacing a broken motor, I started it up again making sure i had a firm grip on the CF2. Thrust was 0.0% so there were no problems. A lesson learnt for me. I don't have much experience with game equipment so have a bit of learning curve. My goal was to play with the code and see what i can get it to do, however I realise I actually have a lot to learn about flying before I can get into the code

:)
Post Reply