int PIController::InitStage(const std::string& axisName, const std::string& stageType) { if (HasCST() && !stageType.empty()) { std::string stageType_local = stageType; if (onlyIDSTAGEvalid_) { if (strcmp(stageType.c_str(), "NOSTAGE") != 0) { stageType_local = "ID-STAGE"; } } if (!CST(axisName, stageType_local)) { return GetTranslatedError(); } } if (HasINI()) { if (!INI(axisName)) { return GetTranslatedError(); } } if (HasSVO()) { if (!SVO(axisName, TRUE)) { return GetTranslatedError(); } } return DEVICE_OK; }
int PIController::InitStage(const std::string& axisName, const std::string& stageType) { if (HasCST()) { std::string stageType_local = stageType; if (onlyIDSTAGEvalid_) { if (strcmp(stageType.c_str(), "NOSTAGE") != 0) { stageType_local = "ID-STAGE"; } } if (!CST(axisName, stageType_local)) return DEVICE_INVALID_PROPERTY_VALUE; } if (HasINI()) { if (!INI(axisName)) return DEVICE_ERR; } if (HasSVO()) { if (!SVO(axisName, TRUE)) return DEVICE_ERR; } return DEVICE_OK; }