| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent e510f51 commit 206a350
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -176,6 +176,10 @@ def groundspeed(self): | |||
| 176 | 176 | def airspeed(self): | |
| 177 | 177 | return self.__module.airspeed | |
| 178 | 178 | ||
| 179 | + @property | ||
| 180 | + def mount_status(self): | ||
| 181 | + return [ self.__module.mount_pitch, self.__module.mount_yaw, self.__module.mount_roll ] | ||
| 182 | + | ||
| 179 | 183 | @property | |
| 180 | 184 | def channel_override(self): | |
| 181 | 185 | overrides = self.__rc.override | |
@@ -319,6 +323,10 @@ def __init__(self, mpstate): | |||
| 319 | 323 | self.yawspeed = None | |
| 320 | 324 | self.rollspeed = None | |
| 321 | 325 | ||
| 326 | + self.mount_pitch = None | ||
| 327 | + self.mount_yaw = None | ||
| 328 | + self.mount_roll = None | ||
| 329 | + | ||
| 322 | 330 | self.rc_readback = {} | |
| 323 | 331 | ||
| 324 | 332 | self.last_waypoint = 0 | |
@@ -398,6 +406,12 @@ def set(chnum, v): | |||
| 398 | 406 | set(6, m.chan6_raw) | |
| 399 | 407 | set(7, m.chan7_raw) | |
| 400 | 408 | set(8, m.chan8_raw) | |
| 409 | + elif typ == "MOUNT_STATUS": | ||
| 410 | + self.mount_pitch = m.pointing_a / 100 | ||
| 411 | + self.mount_roll = m.pointing_b / 100 | ||
| 412 | + self.mount_yaw = m.pointing_c / 100 | ||
| 413 | + self.__on_change('mount') | ||
| 414 | + | ||
| 401 | 415 | ||
| 402 | 416 | if (self.vehicle is not None) and hasattr(self.vehicle, 'mavrx_callback'): | |
| 403 | 417 | self.vehicle.mavrx_callback(m) | |
| Back | FazBrowse Home | New Git URL |
0 commit comments