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

Add access to attitude rates #740

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions dronekit/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,13 @@ class Attitude(object):
:param roll: Roll in radians
"""

def __init__(self, pitch, yaw, roll):
def __init__(self, pitch, yaw, roll,pitchspeed,yawspeed,rollspeed):
self.pitch = pitch
self.yaw = yaw
self.roll = roll
self.pitchspeed = pitchspeed
self.yawspeed = yawspeed
self.rollspeed = rollspeed

def __str__(self):
fmt = '{}:pitch={pitch},yaw={yaw},roll={roll}'
Expand Down Expand Up @@ -1712,7 +1715,7 @@ def attitude(self):
"""
Current vehicle attitude - pitch, yaw, roll (:py:class:`Attitude`).
"""
return Attitude(self._pitch, self._yaw, self._roll)
return Attitude(self._pitch, self._yaw, self._roll,self._pitchspeed,self._yawspeed,self._rollspeed)

@property
def gps_0(self):
Expand Down