Changeset 8820 for trunk/MagicSoft/Cosy/devdrv
- Timestamp:
- 01/19/08 12:55:11 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Cosy/devdrv/shaftencoder.cc
r8811 r8820 15 15 16 16 ShaftEncoder::ShaftEncoder(const BYTE_t nodeid, const char *name, MLog &out) 17 : NodeDrv(nodeid, name, out), fPos(0), fVel(0), fAcc(0),18 f Turn(0), fDirection(kUndefined), fHysteresisPos(0), fHysteresisNeg(0),19 f Label(NULL), fUpdPos(0), fPosHasChanged(false), fDirHasChanged(false),20 f Report(NULL),21 /*fTwin(0), fIsUpdated(kFALSE),*/22 17 : NodeDrv(nodeid, name, out), 18 fPos(0), fVel(0), fAcc(0), fTurn(0), fTicks(0), 19 fDirection(kUndefined), fHysteresisPos(0), fHysteresisNeg(0), 20 fLabel(NULL), fUpdPos(0), 21 fPosHasChanged(false), fDirHasChanged(false), 22 fReport(NULL), fMotor(0), fOffset(0), fDirChangedPos(0) 23 23 { 24 24 } … … 186 186 } 187 187 188 char text[21] ;188 char text[21]=""; 189 189 if (pos!=fUpdPos && fLabel) 190 190 { … … 314 314 } 315 315 316 if (multipos>GetPos()) fDirection = kForward; 317 else if (multipos<GetPos()) fDirection = kBackward; 318 else fDirection = kUndefined; 316 if (multipos>GetPos()) 317 fDirection = kForward; 318 else 319 if (multipos<GetPos()) 320 fDirection = kBackward; 321 else 322 fDirection = kUndefined; 319 323 320 324
Note:
See TracChangeset
for help on using the changeset viewer.