Merge pull request #94 from shadowguy/master

Added I/O flush before first query (Micronix MMC-x00)
(cherry picked from commit beba85f7b2)
This commit is contained in:
Kevin Peterson
2018-06-06 14:27:44 -05:00
committed by kpetersn
parent 1cb778ae55
commit 7c287138ff
+3
View File
@@ -136,6 +136,9 @@ MMC200Axis::MMC200Axis(MMC200Controller *pC, int axisNo)
// controller axes are numbered from 1
axisIndex_ = axisNo + 1;
// Flush I/O in case there is lingering garbage
pC_->writeReadController();
// Read the version string to determine controller model (200/100)
sprintf(pC_->outString_, "%dVER?", axisIndex_);
status = pC_->writeReadController();