Setpoint explanation

Firmware/software/electronics/mechanics
Post Reply
dspatel89
Beginner
Posts: 4
Joined: Wed Mar 02, 2016 6:19 am

Setpoint explanation

Post by dspatel89 »

Hi,

I am confused about how the setpoint actually works. What I am looking for is to send the crazyflie from current position to the new position being inputed by the user. I wish to know does the crazyflie have the capability to appropriately make the necessary roll pitch and yaw calculations to move to a new setpoint. I am looking to develop an outdoor setpoint functionality using GPS lat and long . Any help and guidance would be much appreciated.

Thanks
PierreD
Beginner
Posts: 15
Joined: Fri Jul 01, 2016 8:44 am

Re: Setpoint explanation

Post by PierreD »

Basically, the setpoint contains (roll, pitch, yaw, thrust). (Take a look here)
Roll and pitch are in degrees, yaw is in degree per second and finally thrust is a value between 0 and 65535.

There are two different methods for autonomous flight :
- the older one uses a kinect or a webcam. In this methods, it's the client which calculates the setpoints to send in order to move from point A to point B. (doc here and here)
- the new one uses the Loco Positioning System. AFAIK, the setpoints are calculated inboard to avoid the latency of using an external client. So maybe you should take a look at the way LPS works.

Moreover, someone on the forum developed a GPS deck, but I don't know if he used it to control the crazyflie or just to see it position.
dspatel89
Beginner
Posts: 4
Joined: Wed Mar 02, 2016 6:19 am

Re: Setpoint explanation

Post by dspatel89 »

Thank You for your reply. One of the important thing that I need to know is about the calculations of roll pitch yaw required that will take the crazyflie from its current position X to desired position Y. Does the current firmware have the capability to do this calculation. I currently have the GPS integrated with crazyflie and it gives the lat long and MSLh values. To make things simple I am looking to implement the outdoor localization in an area of 100 sq.m so that I can ignore the curvature of the earth and consider the surface as a flat plane. So what I need now is to determine the RPY values that will help me to move the crazyflie from its current lat and long(position) to the desired lat long.

Thanks
Dhaval
PierreD
Beginner
Posts: 15
Joined: Fri Jul 01, 2016 8:44 am

Re: Setpoint explanation

Post by PierreD »

Take a look at the code used on the kinect project. In control folder you'll find kctrl.py.
It's this file who send the setpoints according to the actual position of the crazyflie and the desired position. It uses several PIDs in order to control each value (yaw pitch roll thrust).
Post Reply