Changeset 343:d13af9285d29
- Timestamp:
- 12/02/12 08:11:28 (12 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/pyuipc_sim.py
r336 r343 321 321 self.apAltitudeHold = False 322 322 self.apAltitude = 7000 323 324 self.elevatorTrim = 0.0 323 325 324 326 def read(self, offset, type): … … 517 519 elif offset==0x2200: # Engine #3 N1 518 520 return self.n1[self.ENGINE_3] 521 elif offset==0x2ea0: # Elevator trim 522 return self.elevatorTrim * math.pi / 180.0 519 523 elif offset==0x2ef8: # Centre of Gravity 520 524 return self.cog … … 765 769 elif offset==0x2200: # Engine #3 N1 766 770 self.n1[self.ENGINE_3] = value 771 elif offset==0x2ea0: # Elevator trim 772 self.elevatorTrim = value * 180.0 / math.pi 767 773 elif offset==0x2ef8: # Centre of Gravity 768 774 self.cog = value … … 1440 1446 CLI.altitude2pyuipc) 1441 1447 1448 self._valueHandlers["trim"] = ([(0x2ea0, "f")], 1449 lambda value: value * 180.0 / math.pi, 1450 lambda word: 1451 float(word) * math.pi / 180.0) 1452 1442 1453 def default(self, line): 1443 1454 """Handle unhandle commands."""
Note:
See TracChangeset
for help on using the changeset viewer.