Changeset 337:a276a58aaa6e
- Timestamp:
- 11/15/12 16:51:42 (12 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- src/mlx
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/fs.py
r334 r337 248 248 - xpdrC: a boolean indicating whether the transponder is in C mode, or 249 249 None, if the state cannot be read properly 250 251 FIXME: needed when taxiing only: 252 - payload weight 253 254 FIXME: needed rarely: 255 - latitude, longitude 256 - transporter 257 - visibility 250 - apMaster: a boolean indicating whether the autopilot is switched on, or 251 None, if the state cannot be read properly 252 - apHeadingHold: a boolean indicating whether the autopilot's heading hold 253 mode is switched on, or None, if the state cannot be read properly 254 - apHeading: the autopilot heading value in degrees (float), 255 or None, if the state cannot be read properly 256 - apAltitudeHold: a boolean indicating whether the autopilot's altitude hold 257 mode is switched on, or None, if the state cannot be read properly 258 - apAltitude: the autopilot altitude value in feet (float), 259 or None, if the state cannot be read properly 258 260 """ 261 -
src/mlx/fsuipc.py
r334 r337 1189 1189 ("visibility", 0x0e8a, "H"), 1190 1190 ("cog", 0x2ef8, "f"), 1191 ("xpdrC", 0x7b91, "b")] 1191 ("xpdrC", 0x7b91, "b"), 1192 ("apMaster", 0x07bc, "d"), 1193 ("apHeadingHold", 0x07c8, "d"), 1194 ("apHeading", 0x07cc, "H"), 1195 ("apAltitudeHold", 0x07d0, "d"), 1196 ("apAltitude", 0x07d4, "u")] 1192 1197 1193 1198 specialModels = [] … … 1387 1392 1388 1393 state.xpdrC = data[self._monidx_xpdrC]==0 1394 1395 state.apMaster = data[self._monidx_apMaster]!=0 1396 state.apHeadingHold = data[self._monidx_apHeadingHold]!=0 1397 state.apHeading = data[self._monidx_apHeading] * 360.0 / 65536.0 1398 state.apAltitudeHold = data[self._monidx_apAltitudeHold]!=0 1399 state.apAltitude = data[self._monidx_apAltitude] / \ 1400 const.FEETTOMETRES / 65536.0 1389 1401 1390 1402 return state -
src/mlx/gui/monitor.py
r334 r337 37 37 padding_left = 16, padding_right = 16) 38 38 39 table = gtk.Table(rows = 7, columns = 1 2)39 table = gtk.Table(rows = 7, columns = 14) 40 40 table.set_homogeneous(False) 41 41 table.set_row_spacings(4) … … 190 190 self._xpdrC = gtk.Label("XPDR CHARLIE") 191 191 table.attach(self._xpdrC, 10, 12, 6, 7) 192 193 self._apMaster = gtk.Label("AP MASTER") 194 table.attach(self._apMaster, 0, 1, 7, 8) 195 196 self._apHeadingHold = gtk.Label("AP HDG HOLD") 197 table.attach(self._apHeadingHold, 1, 2, 7, 8) 198 199 (label, self._apHeading) = self._createLabeledEntry("AP HDG:", 5) 200 table.attach(label, 2, 3, 7, 8) 201 table.attach(self._apHeading, 3, 4, 7, 8) 202 203 self._apAltitudeHold = gtk.Label("AP ALT HOLD") 204 table.attach(self._apAltitudeHold, 5, 6, 7, 8) 205 206 (label, self._apAltitude) = self._createLabeledEntry("AP ALT:", 10) 207 table.attach(label, 6, 7, 7, 8) 208 table.attach(self._apAltitude, 7, 8, 7, 8) 192 209 193 210 alignment.add(table) … … 266 283 self._position.set_text("-") 267 284 self._xpdrC.set_sensitive(False) 285 self._apMaster.set_sensitive(False) 286 self._apHeadingHold.set_sensitive(False) 287 self._apHeading.set_text("-") 288 self._apAltitudeHold.set_sensitive(False) 289 self._apAltitude.set_text("-") 268 290 else: 269 291 self._timestamp.set_text(time.strftime("%H:%M:%S", … … 346 368 self._xpdrC.set_sensitive(aircraftState.xpdrC) 347 369 370 self._apMaster.set_sensitive(aircraftState.apMaster) 371 self._apHeadingHold.set_sensitive(aircraftState.apHeadingHold) 372 self._apHeading.set_text("%03.0f" % (aircraftState.apHeading,)) 373 self._apAltitudeHold.set_sensitive(aircraftState.apAltitudeHold) 374 self._apAltitude.set_text("%5.0f" % (aircraftState.apAltitude,)) 375 348 376 #------------------------------------------------------------------------------
Note:
See TracChangeset
for help on using the changeset viewer.