ntnu-arl / ORACLE

(Visually-attentive) Uncertainty-aware navigation method using deep neural networks
BSD 3-Clause "New" or "Revised" License
66 stars 5 forks source link

Real World Velocity controller problem #7

Closed guglielmo610 closed 1 month ago

guglielmo610 commented 2 months ago

Hello, I would like to ask how did you use as a command to the velocity controller of the ardupilot? Because the cmd_vel_publisher is giving 6 elements: 3 linear velocities and 3 angles (roll, pitch and yaw). But the problem is that the linear velocities are given in body_frame while the angles are absolute and so given in global frame. If I choose the body frame for the velocity setup then the drone will continue to turn because the angle is in global frame... Furthermore, if I modify the code to get just the relative angle in body frame, is it correct to command an angle as an angular velocity? Will I obtain the same response that I get in the gazebo simulator? I also tried to use both the position and velocity setup together in order to command the angles as the drone orientation in quaternions but the result is not optimal. What do you suggest? Thanks

HuanNguyenARL commented 2 months ago

Hi @guglielmo610, we use this lmf_controller node to convert from [v_x, v_y, v_z, steering angle] command from ORACLE to [v_x, v_y, v_z, angular rate]-mavros command . In this repo lmf_ws you can file all the launch files and config files (Ardupilot, mavros, controller, ...) to run ORACLR on the real robot.