Skip to content
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

Different formula for computing RPM #25

Closed
mfarrelm opened this issue Feb 28, 2021 · 1 comment
Closed

Different formula for computing RPM #25

mfarrelm opened this issue Feb 28, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@mfarrelm
Copy link

Hi, Jacopo
Is the matrix A below is used to compute RPM given the torque and force? If it is, why for the calculation of torque x and y, it is divided by 2 not square root of 2. As I know for the X drone model, you divide the total RPM by square root of two

if self.DYNAMICS_ATTR:
if self.DRONE_MODEL == DroneModel.CF2X:
self.A = np.array([ [1, 1, 1, 1], [.5, .5, -.5, -.5], [-.5, .5, .5, -.5], [-1, 1, -1, 1] ])
elif self.DRONE_MODEL in [DroneModel.CF2P, DroneModel.HB]:
self.A = np.array([ [1, 1, 1, 1], [0, 1, 0, -1], [-1, 0, 1, 0], [-1, 1, -1, 1] ])

@JacopoPan JacopoPan added the bug Something isn't working label Feb 28, 2021
@JacopoPan
Copy link
Member

Hi @mfarrelm, thanks for pointing this out, fix'd! DynAviary—the one class using RPMs computed from self.A—is a bit of a orphaned implementation at this time: if you develop any controller on top of it, please let me know, I'd be happy to include it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants