Changeset 634:b695e9445e24 for src/mlx
- Timestamp:
- 05/10/15 06:44:20 (10 years ago)
- Branch:
- default
- Phase:
- public
- Location:
- src/mlx
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mlx/acft.py
r631 r634 374 374 if newStage==const.STAGE_LANDING: 375 375 self._logQNH(aircraftState) 376 elif newStage==const.STAGE_GOAROUND: 377 from logger import Logger 378 self._flight.handleFault("goaround", 379 aircraftState.timestamp, 380 "Go-around detected, please, explain!", 381 Logger.NO_SCORE) 376 382 elif newStage==const.STAGE_TAXIAFTERLAND: 377 383 flight = self._flight -
src/mlx/logger.py
r604 r634 186 186 NO_GO_SCORE = 10000 187 187 188 NO_SCORE = 9999 189 188 190 def __init__(self, output): 189 191 """Construct the logger.""" … … 271 273 fault = self._faults[faultID] if faultID in self._faults else None 272 274 275 text = "%s (NO GO)" % (what) if score==Logger.NO_GO_SCORE \ 276 else "%s" % (what,) if score==Logger.NO_SCORE \ 277 else "%s (%.1f)" % (what, score) 278 279 if score==Logger.NO_SCORE: 280 score = 0 281 273 282 if fault is not None and score<=fault.score: 274 283 return fault.getLatestEntry().id if updatePrevious else -1 275 276 text = "%s (NO GO)" % (what) if score==Logger.NO_GO_SCORE \277 else "%s (%.1f)" % (what, score)278 284 279 285 if updatePrevious and fault is not None:
Note:
See TracChangeset
for help on using the changeset viewer.