Ignore:
Timestamp:
11/17/12 13:08:43 (12 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

#142: added the reading and logging of the elevator trim

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/gui/monitor.py

    r337 r340  
    188188        table.attach(self._position, 7, 10, 6, 7)
    189189
    190         self._xpdrC = gtk.Label("XPDR CHARLIE")
    191         table.attach(self._xpdrC, 10, 12, 6, 7)
     190        (label, self._elevatorTrim) = self._createLabeledEntry("Trim:", 5)
     191        table.attach(label, 10, 11, 6, 7)
     192        table.attach(self._elevatorTrim, 11, 12, 6, 7)
    192193
    193194        self._apMaster = gtk.Label("AP MASTER")
     
    207208        table.attach(label, 6, 7, 7, 8)
    208209        table.attach(self._apAltitude, 7, 8, 7, 8)
     210
     211        self._xpdrC = gtk.Label("XPDR CHARLIE")
     212        table.attach(self._xpdrC, 10, 12, 7, 8)
    209213
    210214        alignment.add(table)
     
    282286            self._windDirection.set_text("-")
    283287            self._position.set_text("-")
    284             self._xpdrC.set_sensitive(False)
     288            self._elevatorTrim.set_text("-")
    285289            self._apMaster.set_sensitive(False)
    286290            self._apHeadingHold.set_sensitive(False)
     
    288292            self._apAltitudeHold.set_sensitive(False)
    289293            self._apAltitude.set_text("-")
     294            self._xpdrC.set_sensitive(False)
    290295        else:
    291296            self._timestamp.set_text(time.strftime("%H:%M:%S",
     
    366371            self._position.set_text(util.getCoordinateString((aircraftState.latitude,
    367372                                                              aircraftState.longitude)))
    368             self._xpdrC.set_sensitive(aircraftState.xpdrC)
    369 
     373            self._elevatorTrim.set_text("%.2f" % (aircraftState.elevatorTrim,))
    370374            self._apMaster.set_sensitive(aircraftState.apMaster)
    371375            self._apHeadingHold.set_sensitive(aircraftState.apHeadingHold)
     
    374378            self._apAltitude.set_text("%5.0f" % (aircraftState.apAltitude,))
    375379
     380            self._xpdrC.set_sensitive(aircraftState.xpdrC)
     381
    376382#------------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.