Moving anafi through pcmd

What is the proper way to use PCMD with anafi drone? Can you give us an example that show how to use pcmd to move the drone in the forward direction only. I tried the function of olympe that involve start_piloting, stop_piloting, piloting_pcmd.

However, it seems that the motion of the drone is not as expected. For example when we send a signal to move only forward the drone drift to the right and it takes time to respond to the command. But, when we use high value the drone only move forward and there’s no drift to the right or left. Why this is happening?

In our setting we set the maximum tilt of the drone to be only 1 degree. This is because we need to achieve very accurate motion. Thank you for your help

I am using it in here (check move function); basically I am moving the anafi with a joystick controller.

Check the moving range ([-100:100]) and the piloting_time (from 0.0 onwards). Basically, as I get the controller values between [-1:1], this value is multiplied times 100 to get the strength of the movement. The piloting_time param is tweaked depending on how precise I want the movement to be (the lesser, the more precise a movement will be).