Wrong Height using flowdeck

Firmware/software/electronics/mechanics
Max_Kemmeren
Member
Posts: 40
Joined: Wed Jan 20, 2021 4:03 pm

Re: Wrong Height using flowdeck

Post by Max_Kemmeren »

Dear Tobias,

Hereby the data from the ranger log class.

Within the figure you can see two flights again (top row and bottom row), with the following plots: estimation of ceiling height from ground, the ceiling distance estimation from drone to ceiling and the ranger measurements (zrange and up).

Once again you can see the difference between two flight performed using the same drone, same code and same environment. With the drone being switched on and off between flights. Starting from a new battery in flight one and reusing it in flight 2.

What was observed from the flight:

Flight one the drone climbed to the first 0.4 m height and then 20 cm away from ceiling and afterwards 10.
Flight two, drone did not climb to 0.4 as the flight altitude was observed to be lower but the zranger says it reached 0.4. afterwards it climbs to what it thinks should be 0.2 away from ceiling but then the up ranger measures something different and the drone climbs slowely.

It can be said that the zranger is wrong, because the actual height of the table I am flying under is around 70 cm and the zranger in flight 2 measures its flying at 80 cm.

Hope this is clear.
Attachments
Screenshot from 2021-08-20 10-32-03.png
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Wrong Height using flowdeck

Post by tobias »

Tricky problem this... If the zranger was the problem it feels like I should pretty easily be able to reproduce it here but I can't. There must be something more to it.

If you manually move it after the power cycle do you also get wrong measurements or is a flight needed.

I guess you don't have another flow deck to test with to rule out any HW problems with the one you have?

Another thing to try, does unplugging and plugging the same battery help?
Max_Kemmeren
Member
Posts: 40
Joined: Wed Jan 20, 2021 4:03 pm

Re: Wrong Height using flowdeck

Post by Max_Kemmeren »

Dear tobias,

I found the problem. It seems to be something to do with the charge left in the crazyflie after turning it off without unplugging the battery.

By replugging the battery between flights the problem is one. Moreover when touching the connection pins to the multiranger, with either my fingers or by using pair of metal tweezers the charge will also dissapear and the problem will also be gone.

I dont know is this is an actual hardware problem or more a design problem. I will go to university this Wednesday and will try another flowdeck to see if its this specific flowdeck or maybe combination of the long pins, battery flowdeck and multiranger together.

Thanks for the help, will post an update after wednesday.

Greetings
Max
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Wrong Height using flowdeck

Post by tobias »

Great that we are closing in on the problem. Also it is a surprising one. From my knowledge the sensor is reset during startup so something like this shouldn't happen... Keep us posted.
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Wrong Height using flowdeck

Post by tobias »

If you have time I'm curios if you get the same result if you use the cfclient flight control -> take-off functionality. For me the height is very consistent, measuring ~53cm to the center of the crazyflie. I'm flying with the Flow v2 and Multiranger.
Max_Kemmeren
Member
Posts: 40
Joined: Wed Jan 20, 2021 4:03 pm

Re: Wrong Height using flowdeck

Post by Max_Kemmeren »

I will test it.

I tested another flowdeck v2 and had similar problem. I did not even fly that time. So what I did was just take the drone and look at logging in cfclient. Just switching it on and off showed a different heigth. Again when touching the pins or unplugging the battery when having the drone turned off solved the problem( as left charge is dissapated).

I will see if the Take-off function has similar problem.
Max_Kemmeren
Member
Posts: 40
Joined: Wed Jan 20, 2021 4:03 pm

Re: Wrong Height using flowdeck

Post by Max_Kemmeren »

The Take-off button in the client does nothing, so I do not know what is wrong.
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Wrong Height using flowdeck

Post by tobias »

The mystery grows... Did you try with and without the Multiranger deck? If you get the same result on two Flow decks and I don't then I'm thinking there is something else triggering the issue. What FW are you running etc? You probably need to update the cfclient and cf-lib.
Max_Kemmeren
Member
Posts: 40
Joined: Wed Jan 20, 2021 4:03 pm

Re: Wrong Height using flowdeck

Post by Max_Kemmeren »

I updated both cflib and the cfclient but still the take-off button does not function. When I run the latest firmware on the cf the problem still exists.

I tested it with multiranger attached and problem happens and disappears if you touch the metal pins to discharge.

I tested it witouth the multiranger and problem seems less to non existent.

So I dont know what is happening, but for now will leave it as it is as I can use the trick to work around this bug.
tobias
Bitcraze
Posts: 2339
Joined: Mon Jan 28, 2013 7:17 pm
Location: Sweden

Re: Wrong Height using flowdeck

Post by tobias »

To summarize all the findings:
  • It is related to the Multiranger deck but effects the zranger sensor
  • A small discharge as touching the pins fixes the issue or unplugging/plugging the battery.
My next guess is that it has to do with supply from the CF2.1, possibly something is off with it. If you have another one to try with that would be a next thing to try. Or measure the voltages VCOM and VCC.
Post Reply