-
Notifications
You must be signed in to change notification settings - Fork 392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RPM Motor Mapping #196
Comments
Hi @zcase the mapping between the gym-pybullet-drones/gym_pybullet_drones/envs/BaseAviary.py Lines 700 to 707 in 235c896
You are correct the different standards are use by different autopilots, e.g. in gym-pybullet-drones/gym_pybullet_drones/envs/BetaAviary.py Lines 258 to 262 in 235c896
|
@JacopoPan This is great thank you. Do you by chance have any links to the documents that discuss what you did for the Crazyflie drone and the beta flight stuff? |
The Python binding for the Crazyflie firmware are discussed in this technical report https://arxiv.org/pdf/2308.16743.pdf |
@JacopoPan The links you provided have been helpful, but I think I may be confusing myself and am looking for a little guidance. Based off of what you said, the action space is: action = [prop0_link_action, prop1_link_action, prop2_link_action, prop3_link_action] To make sure I'm on the right page here is what I have found regarding the crazyflie motors (left) and the mapping of the action space to it (on the right) source (https://www.bitcraze.io/documentation/system/platform/cf2-components/) For Betaflight motors, I found the following: source (https://betaflight.com/docs/wiki/configurator/motors-tab) source (https://www.bitcraze.io/documentation/tutorials/getting-started-with-crazyflie-2-x/) Crazyflie: (URDF, Motors, Action Mapping QUESTION 1 Crazyflie + Betaflight: (BM = Betaflight Motor) (CM = Crazyflie motor) The following image is the shows the Betaflight motor layout with its actions in the YELLOW As while in Red 1-4 are the Crazyflie motors and A0-A3 are the Crazyflie actions on their own (without Betaflight) I would have assumed you might only swap the actions for motors 1 and 2. QUESTION 2 Ardupilot has this motor mapping source (https://ardupilot.org/copter/docs/connect-escs-and-motors.html) QUESTION 3 I really appreciate your help with this. It is probably something really silly that I'm missing. I just can't see it for some reason. |
Hi @zcase I think there are at least 2 misunderstandings here
|
Ok that helps a bit with the URDF stuff but not sure I see the relation to the motor mapping and the actions. You mentioned:
Is this just for the Crazyflie base training? Crazyflie: (URDF, Motors, Action Mapping) Based on your latest response, I have updated the Racer Mapping here: Racer/Betaflight: (URDF, Motors, Action Mapping) Racer/Betaflight Ordered to match +- CrazyFlie Ordering above: (Starting at bottom right and going counterclockwise But for the racer urdf and action mapping, why isn't the action mapping just:
Instead we get:
Is this because like you mentioned:
And if we want the action space to represent the RPMs we need convert it to the global ENU space or to the body? |
@JacopoPan I am looking into using the RL training that uses the RPM setting. I was curious how the motors map to that of the RPM output? Does index 0 of the output array correspond to that of the prop0 in the URDF file?
Also I have seen things out there showing different configurations for motor layouts like found here:
https://ardupilot.org/copter/docs/connect-escs-and-motors.html
How does this relate to what you have or is it like a stated above that index 0 = prop0, index 1 = prop1, ..., index N =propN?
Thank you!
The text was updated successfully, but these errors were encountered: