00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051 #include "youbot/YouBotJointParameter.hpp"
00052 namespace youbot {
00053
00054 YouBotApiJointParameter::YouBotApiJointParameter() {
00055
00056
00057 }
00058
00059 YouBotApiJointParameter::~YouBotApiJointParameter() {
00060
00061
00062 }
00063
00064 YouBotJointParameter::YouBotJointParameter() {
00065
00066
00067 }
00068
00069 YouBotJointParameter::~YouBotJointParameter() {
00070
00071
00072 }
00073
00074 JointName::JointName() {
00075
00076 this->name = "JointName";
00077 this->parameterType = API_PARAMETER;
00078
00079 }
00080
00081 JointName::~JointName() {
00082
00083
00084 }
00085
00086 void JointName::getParameter(std::string& parameter) const {
00087
00088 parameter = this->value;
00089
00090 }
00091
00092 void JointName::setParameter(const std::string parameter) {
00093
00094 this->value = parameter;
00095
00096 }
00097
00098 void JointName::toString(std::string& value) {
00099
00100 std::stringstream ss;
00101 ss << this->name << ": " << this->value;
00102 value = ss.str();
00103
00104 }
00105
00106 InitializeJoint::InitializeJoint() {
00107
00108 this->name = "InitializeJoint";
00109 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00110
00111 }
00112
00113 InitializeJoint::~InitializeJoint() {
00114
00115
00116 }
00117
00118 void InitializeJoint::getParameter(bool& parameter) const {
00119
00120 parameter = this->value;
00121
00122 }
00123
00124 void InitializeJoint::setParameter(const bool parameter) {
00125
00126 this->value = parameter;
00127
00128 }
00129
00130 void InitializeJoint::toString(std::string& value) {
00131
00132 std::stringstream ss;
00133 ss << this->name << ": " << this->value;
00134 value = ss.str();
00135
00136 }
00137
00138 void InitializeJoint::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00139
00140 message.stctOutput.commandNumber = msgType;
00141 message.stctOutput.moduleAddress = DRIVE;
00142 message.stctOutput.typeNumber = 15;
00143 message.stctOutput.value = (int)this->value;
00144
00145 }
00146
00147 void InitializeJoint::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00148
00149 this->value = message.stctInput.value;
00150
00151 }
00152
00153 CalibrateJoint::CalibrateJoint() {
00154
00155 this->name = "CalibrateJoint";
00156 this->parameterType = API_PARAMETER;
00157
00158 }
00159
00160 CalibrateJoint::~CalibrateJoint() {
00161
00162
00163 }
00164
00165 void CalibrateJoint::getParameter(bool& doCalibration, CalibrationDirection& calibrationDirection, quantity<si::current>& maxCurrent) const {
00166
00167 doCalibration = this->doCalibration;
00168 calibrationDirection = this->calibrationDirection;
00169 maxCurrent = this->maxCurrent;
00170
00171 }
00172
00173 void CalibrateJoint::setParameter(const bool doCalibration, CalibrationDirection calibrationDirection, const quantity<si::current>& maxCurrent) {
00174
00175 this->doCalibration = doCalibration;
00176 this->calibrationDirection = calibrationDirection;
00177 this->maxCurrent = maxCurrent;
00178
00179 }
00180
00181 void CalibrateJoint::toString(std::string& value) {
00182
00183 std::stringstream ss;
00184 ss << this->name << ": " << "doCalibration " <<this->doCalibration << " calibrationDirection "<< this->calibrationDirection << " maxCurrent " << this->maxCurrent;
00185 value = ss.str();
00186
00187 }
00188
00189 FirmwareVersion::FirmwareVersion() {
00190
00191 this->name = "FirmwareVersion";
00192 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00193
00194 }
00195
00196 FirmwareVersion::~FirmwareVersion() {
00197
00198
00199 }
00200
00201 void FirmwareVersion::getParameter(int& controllerType, std::string& firmwareVersion) const {
00202
00203 controllerType = this->controllerType;
00204 firmwareVersion = this->firmwareVersion;
00205
00206 }
00207
00208 void FirmwareVersion::setParameter(const int controllerType, const std::string firmwareVersion) {
00209
00210 this->controllerType = controllerType;
00211 this->firmwareVersion = firmwareVersion;
00212
00213 }
00214
00215 void FirmwareVersion::toString(std::string& value) {
00216
00217 std::stringstream ss;
00218 ss << this->name << ": Controller: " << this->controllerType << " Version: " << this->firmwareVersion;
00219 value = ss.str();
00220
00221 }
00222
00223 void FirmwareVersion::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00224
00225 message.stctOutput.commandNumber = FIRMWARE_VERSION;
00226 message.stctOutput.moduleAddress = DRIVE;
00227 message.stctOutput.typeNumber = 0;
00228 message.stctOutput.value = 0;
00229
00230 }
00231
00232 void FirmwareVersion::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00233
00234
00235 }
00236
00237 GearRatio::GearRatio() {
00238
00239 this->name = "GearRatio";
00240 this->parameterType = API_PARAMETER;
00241
00242 }
00243
00244 GearRatio::~GearRatio() {
00245
00246
00247 }
00248
00249 void GearRatio::getParameter(double& parameter) const {
00250
00251 parameter = this->value;
00252
00253 }
00254
00255 void GearRatio::setParameter(const double parameter) {
00256
00257 if (parameter == 0) {
00258 throw std::out_of_range("A Gear Ratio of 0 is not allowed");
00259 }
00260 this->value = parameter;
00261
00262 }
00263
00264 void GearRatio::toString(std::string& value) {
00265
00266 std::stringstream ss;
00267 ss << this->name << ": " << this->value;
00268 value = ss.str();
00269
00270 }
00271
00272 EncoderTicksPerRound::EncoderTicksPerRound() {
00273
00274 this->name = "EncoderTicksPerRound";
00275 this->parameterType = API_PARAMETER;
00276
00277 }
00278
00279 EncoderTicksPerRound::~EncoderTicksPerRound() {
00280
00281
00282 }
00283
00284 void EncoderTicksPerRound::getParameter(unsigned int& parameter) const {
00285
00286 parameter = this->value;
00287
00288 }
00289
00290 void EncoderTicksPerRound::setParameter(const unsigned int parameter) {
00291
00292 if (parameter == 0) {
00293 throw std::out_of_range("Zero Encoder Ticks per Round are not allowed");
00294 }
00295 this->value = parameter;
00296
00297 }
00298
00299 void EncoderTicksPerRound::toString(std::string& value) {
00300
00301 std::stringstream ss;
00302 ss << this->name << ": " << this->value;
00303 value = ss.str();
00304
00305 }
00306
00307 InverseMovementDirection::InverseMovementDirection() {
00308
00309 this->name = "InverseMovementDirection";
00310 this->parameterType = API_PARAMETER;
00311
00312 }
00313
00314 InverseMovementDirection::~InverseMovementDirection() {
00315
00316
00317 }
00318
00319 void InverseMovementDirection::getParameter(bool& parameter) const {
00320
00321 parameter = this->value;
00322
00323 }
00324
00325 void InverseMovementDirection::setParameter(const bool parameter) {
00326
00327 this->value = parameter;
00328
00329 }
00330
00331 void InverseMovementDirection::toString(std::string& value) {
00332
00333 std::stringstream ss;
00334 ss << this->name << ": " << this->value;
00335 value = ss.str();
00336
00337 }
00338
00339 JointLimits::JointLimits() {
00340
00341 this->name = "JointLimits";
00342 this->parameterType = API_PARAMETER;
00343 this->lowerLimit = 0;
00344 this->upperLimit = 0;
00345 this->areLimitsActive = true;
00346
00347 }
00348
00349 JointLimits::~JointLimits() {
00350
00351
00352 }
00353
00354 void JointLimits::getParameter(int& lowerLimit, int& upperLimit, bool& areLimitsActive) const {
00355
00356 lowerLimit = this->lowerLimit;
00357 upperLimit = this->upperLimit;
00358 areLimitsActive = this->areLimitsActive;
00359
00360 }
00361
00362 void JointLimits::setParameter(const int lowerLimit, const int upperLimit, const bool activateLimits) {
00363
00364 if (lowerLimit > upperLimit) {
00365 throw std::out_of_range("The lower joint limit it not allowed to be bigger than the upper limit");
00366 }
00367 this->lowerLimit = lowerLimit;
00368 this->upperLimit = upperLimit;
00369 this->areLimitsActive = activateLimits;
00370
00371 }
00372
00373 void JointLimits::toString(std::string& value) {
00374
00375 std::stringstream ss;
00376 ss << this->name << ": lower Limit: " << this->lowerLimit << " upper Limit: " << this->upperLimit;
00377 value = ss.str();
00378
00379 }
00380
00381 JointLimitsRadian::JointLimitsRadian() {
00382
00383 this->name = "JointLimitsRadian";
00384 this->parameterType = API_PARAMETER;
00385 this->lowerLimit = 0;
00386 this->upperLimit = 0;
00387 this->areLimitsActive = true;
00388
00389 }
00390
00391 JointLimitsRadian::~JointLimitsRadian() {
00392
00393
00394 }
00395
00396 void JointLimitsRadian::getParameter(quantity<plane_angle>& lowerLimit, quantity<plane_angle>& upperLimit, bool& areLimitsActive) const {
00397
00398 lowerLimit = this->lowerLimit;
00399 upperLimit = this->upperLimit;
00400 areLimitsActive = this->areLimitsActive;
00401
00402 }
00403
00404 void JointLimitsRadian::setParameter(const quantity<plane_angle>& lowerLimit, const quantity<plane_angle>& upperLimit, const bool activateLimits) {
00405
00406 if (lowerLimit > upperLimit) {
00407 throw std::out_of_range("The lower joint limit it not allowed to be bigger than the upper limit");
00408 }
00409 this->lowerLimit = lowerLimit;
00410 this->upperLimit = upperLimit;
00411 this->areLimitsActive = activateLimits;
00412
00413 }
00414
00415 void JointLimitsRadian::toString(std::string& value) {
00416
00417 std::stringstream ss;
00418 ss << this->name << ": lower Limit: " << this->lowerLimit << " upper Limit: " << this->upperLimit;
00419 value = ss.str();
00420
00421 }
00422
00423 TorqueConstant::TorqueConstant() {
00424
00425 this->name = "TorqueConstant";
00426 this->parameterType = API_PARAMETER;
00427
00428 }
00429
00430 TorqueConstant::~TorqueConstant() {
00431
00432
00433 }
00434
00435 void TorqueConstant::getParameter(double& parameter) const {
00436
00437 parameter = this->value;
00438
00439 }
00440
00441 void TorqueConstant::setParameter(const double parameter) {
00442
00443 if (parameter == 0 || parameter < 0) {
00444 throw std::out_of_range("It is not allowed to set a zero or negative torque constant");
00445 }
00446 this->value = parameter;
00447
00448 }
00449
00450 void TorqueConstant::toString(std::string& value) {
00451
00452 std::stringstream ss;
00453 ss << this->name << ": " << this->value;
00454 value = ss.str();
00455
00456 }
00457
00458 MaximumPositioningVelocity::MaximumPositioningVelocity() {
00459
00460 this->name = "MaximumPositioningVelocity";
00461 this->lowerLimit = INT_MIN * radian_per_second;
00462 this->upperLimit = INT_MAX * radian_per_second;
00463 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00464
00465 }
00466
00467 MaximumPositioningVelocity::~MaximumPositioningVelocity() {
00468
00469
00470 }
00471
00472 void MaximumPositioningVelocity::getParameter(quantity<angular_velocity>& parameter) const {
00473
00474 parameter = this->value;
00475
00476 }
00477
00478 void MaximumPositioningVelocity::setParameter(const quantity<angular_velocity>& parameter) {
00479
00480 if (this->lowerLimit > parameter) {
00481 throw std::out_of_range("The parameter exceeds the lower limit");
00482 }
00483 if (this->upperLimit < parameter) {
00484 throw std::out_of_range("The parameter exceeds the upper limit");
00485 }
00486
00487 this->value = parameter;
00488
00489 }
00490
00491 void MaximumPositioningVelocity::toString(std::string& value) {
00492
00493 std::stringstream ss;
00494 ss << this->name << ": " << this->value;
00495 value = ss.str();
00496
00497 }
00498
00499 void MaximumPositioningVelocity::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00500
00501
00502 message.stctOutput.commandNumber = msgType;
00503 message.stctOutput.moduleAddress = DRIVE;
00504 message.stctOutput.typeNumber = 4;
00505 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
00506
00507
00508 }
00509
00510 void MaximumPositioningVelocity::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00511
00512 double motorRPM = (int32)message.stctInput.value;
00513 this->value = ((motorRPM / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second;
00514
00515 }
00516
00517 MotorAcceleration::MotorAcceleration() {
00518
00519 this->name = "MotorAcceleration";
00520 this->lowerLimit = INT_MIN * radian_per_second/second;
00521 this->upperLimit = INT_MAX * radian_per_second/second;
00522 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00523
00524 }
00525
00526 MotorAcceleration::~MotorAcceleration() {
00527
00528
00529 }
00530
00531 void MotorAcceleration::getParameter(quantity<angular_acceleration>& parameter) const {
00532
00533 parameter = this->value;
00534
00535 }
00536
00537 void MotorAcceleration::setParameter(const quantity<angular_acceleration>& parameter) {
00538
00539 if (this->lowerLimit > parameter) {
00540 throw std::out_of_range("The parameter exceeds the lower limit");
00541 }
00542 if (this->upperLimit < parameter) {
00543 throw std::out_of_range("The parameter exceeds the upper limit");
00544 }
00545
00546 this->value = parameter;
00547
00548 }
00549
00550 void MotorAcceleration::toString(std::string& value) {
00551
00552 std::stringstream ss;
00553 ss << this->name << ": " << this->value;
00554 value = ss.str();
00555
00556 }
00557
00558 void MotorAcceleration::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00559
00560
00561 message.stctOutput.commandNumber = msgType;
00562 message.stctOutput.moduleAddress = DRIVE;
00563 message.stctOutput.typeNumber = 11;
00564 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
00565
00566
00567 }
00568
00569 void MotorAcceleration::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00570
00571 double motorRPMperSec = (int32)message.stctInput.value;
00572 this->value = ((motorRPMperSec / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second/second;
00573
00574 }
00575
00576 RampGeneratorSpeedAndPositionControl::RampGeneratorSpeedAndPositionControl() {
00577
00578 this->name = "RampGeneratorSpeedAndPositionControl";
00579 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00580
00581 }
00582
00583 RampGeneratorSpeedAndPositionControl::~RampGeneratorSpeedAndPositionControl() {
00584
00585
00586 }
00587
00588 void RampGeneratorSpeedAndPositionControl::getParameter(bool& parameter) const {
00589
00590 parameter = this->value;
00591
00592 }
00593
00594 void RampGeneratorSpeedAndPositionControl::setParameter(const bool parameter) {
00595
00596 this->value = parameter;
00597
00598 }
00599
00600 void RampGeneratorSpeedAndPositionControl::toString(std::string& value) {
00601
00602 std::stringstream ss;
00603 ss << this->name << ": " << this->value;
00604 value = ss.str();
00605
00606 }
00607
00608 void RampGeneratorSpeedAndPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00609
00610
00611 message.stctOutput.commandNumber = msgType;
00612 message.stctOutput.moduleAddress = DRIVE;
00613 message.stctOutput.typeNumber = 146;
00614 message.stctOutput.value = value;
00615
00616
00617 }
00618
00619 void RampGeneratorSpeedAndPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00620
00621 this->value = message.stctInput.value;
00622
00623 }
00624
00625 PositionControlSwitchingThreshold::PositionControlSwitchingThreshold() {
00626
00627 this->name = "PositionControlSwitchingThreshold";
00628 this->lowerLimit = INT_MIN * radian_per_second;
00629 this->upperLimit = INT_MAX * radian_per_second;
00630 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00631
00632 }
00633
00634 PositionControlSwitchingThreshold::~PositionControlSwitchingThreshold() {
00635
00636
00637 }
00638
00639 void PositionControlSwitchingThreshold::getParameter(quantity<angular_velocity>& parameter) const {
00640
00641 parameter = this->value;
00642
00643 }
00644
00645 void PositionControlSwitchingThreshold::setParameter(const quantity<angular_velocity>& parameter) {
00646
00647 if (this->lowerLimit > parameter) {
00648 throw std::out_of_range("The parameter exceeds the lower limit");
00649 }
00650 if (this->upperLimit < parameter) {
00651 throw std::out_of_range("The parameter exceeds the upper limit");
00652 }
00653
00654 this->value = parameter;
00655
00656 }
00657
00658 void PositionControlSwitchingThreshold::toString(std::string& value) {
00659
00660 std::stringstream ss;
00661 ss << this->name << ": " << this->value;
00662 value = ss.str();
00663
00664 }
00665
00666 void PositionControlSwitchingThreshold::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00667
00668
00669 message.stctOutput.commandNumber = msgType;
00670 message.stctOutput.moduleAddress = DRIVE;
00671 message.stctOutput.typeNumber = 12;
00672 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
00673
00674
00675 }
00676
00677 void PositionControlSwitchingThreshold::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00678
00679 double motorRPM = (int32)message.stctInput.value;
00680 this->value = ((motorRPM / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second;
00681
00682 }
00683
00684 SpeedControlSwitchingThreshold::SpeedControlSwitchingThreshold() {
00685
00686 this->name = "SpeedControlSwitchingThreshold";
00687 this->lowerLimit = INT_MIN * radian_per_second;
00688 this->upperLimit = INT_MAX * radian_per_second;
00689 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00690
00691 }
00692
00693 SpeedControlSwitchingThreshold::~SpeedControlSwitchingThreshold() {
00694
00695
00696 }
00697
00698 void SpeedControlSwitchingThreshold::getParameter(quantity<angular_velocity>& parameter) const {
00699
00700 parameter = this->value;
00701
00702 }
00703
00704 void SpeedControlSwitchingThreshold::setParameter(const quantity<angular_velocity>& parameter) {
00705
00706 if (this->lowerLimit > parameter) {
00707 throw std::out_of_range("The parameter exceeds the lower limit");
00708 }
00709 if (this->upperLimit < parameter) {
00710 throw std::out_of_range("The parameter exceeds the upper limit");
00711 }
00712
00713 this->value = parameter;
00714
00715 }
00716
00717 void SpeedControlSwitchingThreshold::toString(std::string& value) {
00718
00719 std::stringstream ss;
00720 ss << this->name << ": " << this->value;
00721 value = ss.str();
00722
00723 }
00724
00725 void SpeedControlSwitchingThreshold::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00726
00727
00728 message.stctOutput.commandNumber = msgType;
00729 message.stctOutput.moduleAddress = DRIVE;
00730 message.stctOutput.typeNumber = 8;
00731 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
00732
00733
00734 }
00735
00736 void SpeedControlSwitchingThreshold::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00737
00738 double motorRPM = (int32)message.stctInput.value;
00739 this->value = ((motorRPM / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second;
00740
00741 }
00742
00743 VelocityThresholdForHallFX::VelocityThresholdForHallFX() {
00744
00745 this->name = "VelocityThresholdForHallFX";
00746 this->lowerLimit = INT_MIN * radian_per_second;
00747 this->upperLimit = INT_MAX * radian_per_second;
00748 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00749
00750 }
00751
00752 VelocityThresholdForHallFX::~VelocityThresholdForHallFX() {
00753
00754
00755 }
00756
00757 void VelocityThresholdForHallFX::getParameter(quantity<angular_velocity>& parameter) const {
00758
00759 parameter = this->value;
00760
00761 }
00762
00763 void VelocityThresholdForHallFX::setParameter(const quantity<angular_velocity>& parameter) {
00764
00765 if (this->lowerLimit > parameter) {
00766 throw std::out_of_range("The parameter exceeds the lower limit");
00767 }
00768 if (this->upperLimit < parameter) {
00769 throw std::out_of_range("The parameter exceeds the upper limit");
00770 }
00771
00772 this->value = parameter;
00773
00774 }
00775
00776 void VelocityThresholdForHallFX::toString(std::string& value) {
00777
00778 std::stringstream ss;
00779 ss << this->name << ": " << this->value;
00780 value = ss.str();
00781
00782 }
00783
00784 void VelocityThresholdForHallFX::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00785
00786
00787 message.stctOutput.commandNumber = msgType;
00788 message.stctOutput.moduleAddress = DRIVE;
00789 message.stctOutput.typeNumber = 14;
00790 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
00791
00792
00793 }
00794
00795 void VelocityThresholdForHallFX::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00796
00797 double motorRPM = (int32)message.stctInput.value;
00798 this->value = ((motorRPM / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second;
00799
00800 }
00801
00802 PParameterFirstParametersPositionControl::PParameterFirstParametersPositionControl() {
00803
00804 this->name = "PParameterFirstParametersPositionControl";
00805 this->lowerLimit = 0;
00806 this->upperLimit = INT_MAX;
00807 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00808
00809 }
00810
00811 PParameterFirstParametersPositionControl::~PParameterFirstParametersPositionControl() {
00812
00813
00814 }
00815
00816 void PParameterFirstParametersPositionControl::getParameter(int& parameter) const {
00817
00818 parameter = this->value;
00819
00820 }
00821
00822 void PParameterFirstParametersPositionControl::setParameter(const int parameter) {
00823
00824 if (this->lowerLimit > parameter) {
00825 throw std::out_of_range("The parameter exceeds the lower limit");
00826 }
00827 if (this->upperLimit < parameter) {
00828 throw std::out_of_range("The parameter exceeds the upper limit");
00829 }
00830
00831 this->value = parameter;
00832
00833 }
00834
00835 void PParameterFirstParametersPositionControl::toString(std::string& value) {
00836
00837 std::stringstream ss;
00838 ss << this->name << ": " << this->value;
00839 value = ss.str();
00840
00841 }
00842
00843 void PParameterFirstParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00844
00845
00846 message.stctOutput.commandNumber = msgType;
00847 message.stctOutput.moduleAddress = DRIVE;
00848 message.stctOutput.typeNumber = 130;
00849 message.stctOutput.value = value;
00850
00851
00852 }
00853
00854 void PParameterFirstParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00855
00856 this->value = (int32)message.stctInput.value;
00857
00858 }
00859
00860 IParameterFirstParametersPositionControl::IParameterFirstParametersPositionControl() {
00861
00862 this->name = "IParameterFirstParametersPositionControl";
00863 this->lowerLimit = INT_MIN;
00864 this->upperLimit = INT_MAX;
00865 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00866
00867 }
00868
00869 IParameterFirstParametersPositionControl::~IParameterFirstParametersPositionControl() {
00870
00871
00872 }
00873
00874 void IParameterFirstParametersPositionControl::getParameter(int& parameter) const {
00875
00876 parameter = this->value;
00877
00878 }
00879
00880 void IParameterFirstParametersPositionControl::setParameter(const int parameter) {
00881
00882 if (this->lowerLimit > parameter) {
00883 throw std::out_of_range("The parameter exceeds the lower limit");
00884 }
00885 if (this->upperLimit < parameter) {
00886 throw std::out_of_range("The parameter exceeds the upper limit");
00887 }
00888
00889 this->value = parameter;
00890
00891 }
00892
00893 void IParameterFirstParametersPositionControl::toString(std::string& value) {
00894
00895 std::stringstream ss;
00896 ss << this->name << ": " << this->value;
00897 value = ss.str();
00898
00899 }
00900
00901 void IParameterFirstParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00902
00903
00904 message.stctOutput.commandNumber = msgType;
00905 message.stctOutput.moduleAddress = DRIVE;
00906 message.stctOutput.typeNumber = 131;
00907 message.stctOutput.value = value;
00908
00909
00910 }
00911
00912 void IParameterFirstParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00913
00914 this->value = (int32)message.stctInput.value;
00915
00916 }
00917
00918 DParameterFirstParametersPositionControl::DParameterFirstParametersPositionControl() {
00919
00920 this->name = "DParameterFirstParametersPositionControl";
00921 this->lowerLimit = INT_MIN;
00922 this->upperLimit = INT_MAX;
00923 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00924
00925 }
00926
00927 DParameterFirstParametersPositionControl::~DParameterFirstParametersPositionControl() {
00928
00929
00930 }
00931
00932 void DParameterFirstParametersPositionControl::getParameter(int& parameter) const {
00933
00934 parameter = this->value;
00935
00936 }
00937
00938 void DParameterFirstParametersPositionControl::setParameter(const int parameter) {
00939
00940 if (this->lowerLimit > parameter) {
00941 throw std::out_of_range("The parameter exceeds the lower limit");
00942 }
00943 if (this->upperLimit < parameter) {
00944 throw std::out_of_range("The parameter exceeds the upper limit");
00945 }
00946
00947 this->value = parameter;
00948
00949 }
00950
00951 void DParameterFirstParametersPositionControl::toString(std::string& value) {
00952
00953 std::stringstream ss;
00954 ss << this->name << ": " << this->value;
00955 value = ss.str();
00956
00957 }
00958
00959 void DParameterFirstParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
00960
00961
00962 message.stctOutput.commandNumber = msgType;
00963 message.stctOutput.moduleAddress = DRIVE;
00964 message.stctOutput.typeNumber = 132;
00965 message.stctOutput.value = value;
00966
00967
00968 }
00969
00970 void DParameterFirstParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
00971
00972 this->value = (int32)message.stctInput.value;
00973
00974 }
00975
00976 IClippingParameterFirstParametersPositionControl::IClippingParameterFirstParametersPositionControl() {
00977
00978 this->name = "IClippingParameterFirstParametersPositionControl";
00979 this->lowerLimit = INT_MIN;
00980 this->upperLimit = INT_MAX;
00981 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
00982
00983 }
00984
00985 IClippingParameterFirstParametersPositionControl::~IClippingParameterFirstParametersPositionControl() {
00986
00987
00988 }
00989
00990 void IClippingParameterFirstParametersPositionControl::getParameter(int& parameter) const {
00991
00992 parameter = this->value;
00993
00994 }
00995
00996 void IClippingParameterFirstParametersPositionControl::setParameter(const int parameter) {
00997
00998 if (this->lowerLimit > parameter) {
00999 throw std::out_of_range("The parameter exceeds the lower limit");
01000 }
01001 if (this->upperLimit < parameter) {
01002 throw std::out_of_range("The parameter exceeds the upper limit");
01003 }
01004
01005 this->value = parameter;
01006
01007 }
01008
01009 void IClippingParameterFirstParametersPositionControl::toString(std::string& value) {
01010
01011 std::stringstream ss;
01012 ss << this->name << ": " << this->value;
01013 value = ss.str();
01014
01015 }
01016
01017 void IClippingParameterFirstParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01018
01019
01020 message.stctOutput.commandNumber = msgType;
01021 message.stctOutput.moduleAddress = DRIVE;
01022 message.stctOutput.typeNumber = 135;
01023 message.stctOutput.value = value;
01024
01025
01026 }
01027
01028 void IClippingParameterFirstParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01029
01030 this->value = (int32)message.stctInput.value;
01031
01032 }
01033
01034 PParameterFirstParametersSpeedControl::PParameterFirstParametersSpeedControl() {
01035
01036 this->name = "PParameterFirstParametersSpeedControl";
01037 this->lowerLimit = INT_MIN;
01038 this->upperLimit = INT_MAX;
01039 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01040
01041 }
01042
01043 PParameterFirstParametersSpeedControl::~PParameterFirstParametersSpeedControl() {
01044
01045
01046 }
01047
01048 void PParameterFirstParametersSpeedControl::getParameter(int& parameter) const {
01049
01050 parameter = this->value;
01051
01052 }
01053
01054 void PParameterFirstParametersSpeedControl::setParameter(const int parameter) {
01055
01056 if (this->lowerLimit > parameter) {
01057 throw std::out_of_range("The parameter exceeds the lower limit");
01058 }
01059 if (this->upperLimit < parameter) {
01060 throw std::out_of_range("The parameter exceeds the upper limit");
01061 }
01062
01063 this->value = parameter;
01064
01065 }
01066
01067 void PParameterFirstParametersSpeedControl::toString(std::string& value) {
01068
01069 std::stringstream ss;
01070 ss << this->name << ": " << this->value;
01071 value = ss.str();
01072
01073 }
01074
01075 void PParameterFirstParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01076
01077
01078 message.stctOutput.commandNumber = msgType;
01079 message.stctOutput.moduleAddress = DRIVE;
01080 message.stctOutput.typeNumber = 140;
01081 message.stctOutput.value = value;
01082
01083
01084 }
01085
01086 void PParameterFirstParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01087
01088 this->value = (int32)message.stctInput.value;
01089
01090 }
01091
01092 IParameterFirstParametersSpeedControl::IParameterFirstParametersSpeedControl() {
01093
01094 this->name = "IParameterFirstParametersSpeedControl";
01095 this->lowerLimit = INT_MIN;
01096 this->upperLimit = INT_MAX;
01097 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01098
01099 }
01100
01101 IParameterFirstParametersSpeedControl::~IParameterFirstParametersSpeedControl() {
01102
01103
01104 }
01105
01106 void IParameterFirstParametersSpeedControl::getParameter(int& parameter) const {
01107
01108 parameter = this->value;
01109
01110 }
01111
01112 void IParameterFirstParametersSpeedControl::setParameter(const int parameter) {
01113
01114 if (this->lowerLimit > parameter) {
01115 throw std::out_of_range("The parameter exceeds the lower limit");
01116 }
01117 if (this->upperLimit < parameter) {
01118 throw std::out_of_range("The parameter exceeds the upper limit");
01119 }
01120
01121 this->value = parameter;
01122
01123 }
01124
01125 void IParameterFirstParametersSpeedControl::toString(std::string& value) {
01126
01127 std::stringstream ss;
01128 ss << this->name << ": " << this->value;
01129 value = ss.str();
01130
01131 }
01132
01133 void IParameterFirstParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01134
01135
01136 message.stctOutput.commandNumber = msgType;
01137 message.stctOutput.moduleAddress = DRIVE;
01138 message.stctOutput.typeNumber = 141;
01139 message.stctOutput.value = value;
01140
01141
01142 }
01143
01144 void IParameterFirstParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01145
01146 this->value = (int32)message.stctInput.value;
01147
01148 }
01149
01150 DParameterFirstParametersSpeedControl::DParameterFirstParametersSpeedControl() {
01151
01152 this->name = "DParameterFirstParametersSpeedControl";
01153 this->lowerLimit = INT_MIN;
01154 this->upperLimit = INT_MAX;
01155 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01156
01157 }
01158
01159 DParameterFirstParametersSpeedControl::~DParameterFirstParametersSpeedControl() {
01160
01161
01162 }
01163
01164 void DParameterFirstParametersSpeedControl::getParameter(int& parameter) const {
01165
01166 parameter = this->value;
01167
01168 }
01169
01170 void DParameterFirstParametersSpeedControl::setParameter(const int parameter) {
01171
01172 if (this->lowerLimit > parameter) {
01173 throw std::out_of_range("The parameter exceeds the lower limit");
01174 }
01175 if (this->upperLimit < parameter) {
01176 throw std::out_of_range("The parameter exceeds the upper limit");
01177 }
01178
01179 this->value = parameter;
01180
01181 }
01182
01183 void DParameterFirstParametersSpeedControl::toString(std::string& value) {
01184
01185 std::stringstream ss;
01186 ss << this->name << ": " << this->value;
01187 value = ss.str();
01188
01189 }
01190
01191 void DParameterFirstParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01192
01193
01194 message.stctOutput.commandNumber = msgType;
01195 message.stctOutput.moduleAddress = DRIVE;
01196 message.stctOutput.typeNumber = 142;
01197 message.stctOutput.value = value;
01198
01199
01200 }
01201
01202 void DParameterFirstParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01203
01204 this->value = (int32)message.stctInput.value;
01205
01206 }
01207
01208 IClippingParameterFirstParametersSpeedControl::IClippingParameterFirstParametersSpeedControl() {
01209
01210 this->name = "IClippingParameterFirstParametersSpeedControl";
01211 this->lowerLimit = INT_MIN;
01212 this->upperLimit = INT_MAX;
01213 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01214
01215 }
01216
01217 IClippingParameterFirstParametersSpeedControl::~IClippingParameterFirstParametersSpeedControl() {
01218
01219
01220 }
01221
01222 void IClippingParameterFirstParametersSpeedControl::getParameter(int& parameter) const {
01223
01224 parameter = this->value;
01225
01226 }
01227
01228 void IClippingParameterFirstParametersSpeedControl::setParameter(const int parameter) {
01229
01230 if (this->lowerLimit > parameter) {
01231 throw std::out_of_range("The parameter exceeds the lower limit");
01232 }
01233 if (this->upperLimit < parameter) {
01234 throw std::out_of_range("The parameter exceeds the upper limit");
01235 }
01236
01237 this->value = parameter;
01238
01239 }
01240
01241 void IClippingParameterFirstParametersSpeedControl::toString(std::string& value) {
01242
01243 std::stringstream ss;
01244 ss << this->name << ": " << this->value;
01245 value = ss.str();
01246
01247 }
01248
01249 void IClippingParameterFirstParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01250
01251
01252 message.stctOutput.commandNumber = msgType;
01253 message.stctOutput.moduleAddress = DRIVE;
01254 message.stctOutput.typeNumber = 143;
01255 message.stctOutput.value = value;
01256
01257
01258 }
01259
01260 void IClippingParameterFirstParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01261
01262 this->value = (int32)message.stctInput.value;
01263
01264 }
01265
01266 PParameterSecondParametersPositionControl::PParameterSecondParametersPositionControl() {
01267
01268 this->name = "PParameterSecondParametersPositionControl";
01269 this->lowerLimit = INT_MIN;
01270 this->upperLimit = INT_MAX;
01271 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01272
01273 }
01274
01275 PParameterSecondParametersPositionControl::~PParameterSecondParametersPositionControl() {
01276
01277
01278 }
01279
01280 void PParameterSecondParametersPositionControl::getParameter(int& parameter) const {
01281
01282 parameter = this->value;
01283
01284 }
01285
01286 void PParameterSecondParametersPositionControl::setParameter(const int parameter) {
01287
01288 if (this->lowerLimit > parameter) {
01289 throw std::out_of_range("The parameter exceeds the lower limit");
01290 }
01291 if (this->upperLimit < parameter) {
01292 throw std::out_of_range("The parameter exceeds the upper limit");
01293 }
01294
01295 this->value = parameter;
01296
01297 }
01298
01299 void PParameterSecondParametersPositionControl::toString(std::string& value) {
01300
01301 std::stringstream ss;
01302 ss << this->name << ": " << this->value;
01303 value = ss.str();
01304
01305 }
01306
01307 void PParameterSecondParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01308
01309
01310 message.stctOutput.commandNumber = msgType;
01311 message.stctOutput.moduleAddress = DRIVE;
01312 message.stctOutput.typeNumber = 230;
01313 message.stctOutput.value = value;
01314
01315
01316 }
01317
01318 void PParameterSecondParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01319
01320 this->value = (int32)message.stctInput.value;
01321
01322 }
01323
01324 IParameterSecondParametersPositionControl::IParameterSecondParametersPositionControl() {
01325
01326 this->name = "IParameterSecondParametersPositionControl";
01327 this->lowerLimit = INT_MIN;
01328 this->upperLimit = INT_MAX;
01329 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01330
01331 }
01332
01333 IParameterSecondParametersPositionControl::~IParameterSecondParametersPositionControl() {
01334
01335
01336 }
01337
01338 void IParameterSecondParametersPositionControl::getParameter(int& parameter) const {
01339
01340 parameter = this->value;
01341
01342 }
01343
01344 void IParameterSecondParametersPositionControl::setParameter(const int parameter) {
01345
01346 if (this->lowerLimit > parameter) {
01347 throw std::out_of_range("The parameter exceeds the lower limit");
01348 }
01349 if (this->upperLimit < parameter) {
01350 throw std::out_of_range("The parameter exceeds the upper limit");
01351 }
01352
01353 this->value = parameter;
01354
01355 }
01356
01357 void IParameterSecondParametersPositionControl::toString(std::string& value) {
01358
01359 std::stringstream ss;
01360 ss << this->name << ": " << this->value;
01361 value = ss.str();
01362
01363 }
01364
01365 void IParameterSecondParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01366
01367
01368 message.stctOutput.commandNumber = msgType;
01369 message.stctOutput.moduleAddress = DRIVE;
01370 message.stctOutput.typeNumber = 231;
01371 message.stctOutput.value = value;
01372
01373
01374 }
01375
01376 void IParameterSecondParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01377
01378 this->value = (int32)message.stctInput.value;
01379
01380 }
01381
01382 DParameterSecondParametersPositionControl::DParameterSecondParametersPositionControl() {
01383
01384 this->name = "DParameterSecondParametersPositionControl";
01385 this->lowerLimit = INT_MIN;
01386 this->upperLimit = INT_MAX;
01387 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01388
01389 }
01390
01391 DParameterSecondParametersPositionControl::~DParameterSecondParametersPositionControl() {
01392
01393
01394 }
01395
01396 void DParameterSecondParametersPositionControl::getParameter(int& parameter) const {
01397
01398 parameter = this->value;
01399
01400 }
01401
01402 void DParameterSecondParametersPositionControl::setParameter(const int parameter) {
01403
01404 if (this->lowerLimit > parameter) {
01405 throw std::out_of_range("The parameter exceeds the lower limit");
01406 }
01407 if (this->upperLimit < parameter) {
01408 throw std::out_of_range("The parameter exceeds the upper limit");
01409 }
01410
01411 this->value = parameter;
01412
01413 }
01414
01415 void DParameterSecondParametersPositionControl::toString(std::string& value) {
01416
01417 std::stringstream ss;
01418 ss << this->name << ": " << this->value;
01419 value = ss.str();
01420
01421 }
01422
01423 void DParameterSecondParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01424
01425
01426 message.stctOutput.commandNumber = msgType;
01427 message.stctOutput.moduleAddress = DRIVE;
01428 message.stctOutput.typeNumber = 232;
01429 message.stctOutput.value = value;
01430
01431
01432 }
01433
01434 void DParameterSecondParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01435
01436 this->value = (int32)message.stctInput.value;
01437
01438 }
01439
01440 IClippingParameterSecondParametersPositionControl::IClippingParameterSecondParametersPositionControl() {
01441
01442 this->name = "IClippingParameterSecondParametersPositionControl";
01443 this->lowerLimit = INT_MIN;
01444 this->upperLimit = INT_MAX;
01445 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01446
01447 }
01448
01449 IClippingParameterSecondParametersPositionControl::~IClippingParameterSecondParametersPositionControl() {
01450
01451
01452 }
01453
01454 void IClippingParameterSecondParametersPositionControl::getParameter(int& parameter) const {
01455
01456 parameter = this->value;
01457
01458 }
01459
01460 void IClippingParameterSecondParametersPositionControl::setParameter(const int parameter) {
01461
01462 if (this->lowerLimit > parameter) {
01463 throw std::out_of_range("The parameter exceeds the lower limit");
01464 }
01465 if (this->upperLimit < parameter) {
01466 throw std::out_of_range("The parameter exceeds the upper limit");
01467 }
01468
01469 this->value = parameter;
01470
01471 }
01472
01473 void IClippingParameterSecondParametersPositionControl::toString(std::string& value) {
01474
01475 std::stringstream ss;
01476 ss << this->name << ": " << this->value;
01477 value = ss.str();
01478
01479 }
01480
01481 void IClippingParameterSecondParametersPositionControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01482
01483
01484 message.stctOutput.commandNumber = msgType;
01485 message.stctOutput.moduleAddress = DRIVE;
01486 message.stctOutput.typeNumber = 233;
01487 message.stctOutput.value = value;
01488
01489
01490 }
01491
01492 void IClippingParameterSecondParametersPositionControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01493
01494 this->value = (int32)message.stctInput.value;
01495
01496 }
01497
01498 PParameterSecondParametersSpeedControl::PParameterSecondParametersSpeedControl() {
01499
01500 this->name = "PParameterSecondParametersSpeedControl";
01501 this->lowerLimit = INT_MIN;
01502 this->upperLimit = INT_MAX;
01503 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01504
01505 }
01506
01507 PParameterSecondParametersSpeedControl::~PParameterSecondParametersSpeedControl() {
01508
01509
01510 }
01511
01512 void PParameterSecondParametersSpeedControl::getParameter(int& parameter) const {
01513
01514 parameter = this->value;
01515
01516 }
01517
01518 void PParameterSecondParametersSpeedControl::setParameter(const int parameter) {
01519
01520 if (this->lowerLimit > parameter) {
01521 throw std::out_of_range("The parameter exceeds the lower limit");
01522 }
01523 if (this->upperLimit < parameter) {
01524 throw std::out_of_range("The parameter exceeds the upper limit");
01525 }
01526
01527 this->value = parameter;
01528
01529 }
01530
01531 void PParameterSecondParametersSpeedControl::toString(std::string& value) {
01532
01533 std::stringstream ss;
01534 ss << this->name << ": " << this->value;
01535 value = ss.str();
01536
01537 }
01538
01539 void PParameterSecondParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01540
01541
01542 message.stctOutput.commandNumber = msgType;
01543 message.stctOutput.moduleAddress = DRIVE;
01544 message.stctOutput.typeNumber = 234;
01545 message.stctOutput.value = value;
01546
01547
01548 }
01549
01550 void PParameterSecondParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01551
01552 this->value = (int32)message.stctInput.value;
01553
01554 }
01555
01556 IParameterSecondParametersSpeedControl::IParameterSecondParametersSpeedControl() {
01557
01558 this->name = "IParameterSecondParametersSpeedControl";
01559 this->lowerLimit = INT_MIN;
01560 this->upperLimit = INT_MAX;
01561 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01562
01563 }
01564
01565 IParameterSecondParametersSpeedControl::~IParameterSecondParametersSpeedControl() {
01566
01567
01568 }
01569
01570 void IParameterSecondParametersSpeedControl::getParameter(int& parameter) const {
01571
01572 parameter = this->value;
01573
01574 }
01575
01576 void IParameterSecondParametersSpeedControl::setParameter(const int parameter) {
01577
01578 if (this->lowerLimit > parameter) {
01579 throw std::out_of_range("The parameter exceeds the lower limit");
01580 }
01581 if (this->upperLimit < parameter) {
01582 throw std::out_of_range("The parameter exceeds the upper limit");
01583 }
01584
01585 this->value = parameter;
01586
01587 }
01588
01589 void IParameterSecondParametersSpeedControl::toString(std::string& value) {
01590
01591 std::stringstream ss;
01592 ss << this->name << ": " << this->value;
01593 value = ss.str();
01594
01595 }
01596
01597 void IParameterSecondParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01598
01599
01600 message.stctOutput.commandNumber = msgType;
01601 message.stctOutput.moduleAddress = DRIVE;
01602 message.stctOutput.typeNumber = 235;
01603 message.stctOutput.value = value;
01604
01605
01606 }
01607
01608 void IParameterSecondParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01609
01610 this->value = (int32)message.stctInput.value;
01611
01612 }
01613
01614 DParameterSecondParametersSpeedControl::DParameterSecondParametersSpeedControl() {
01615
01616 this->name = "DParameterSecondParametersSpeedControl";
01617 this->lowerLimit = INT_MIN;
01618 this->upperLimit = INT_MAX;
01619 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01620
01621 }
01622
01623 DParameterSecondParametersSpeedControl::~DParameterSecondParametersSpeedControl() {
01624
01625
01626 }
01627
01628 void DParameterSecondParametersSpeedControl::getParameter(int& parameter) const {
01629
01630 parameter = this->value;
01631
01632 }
01633
01634 void DParameterSecondParametersSpeedControl::setParameter(const int parameter) {
01635
01636 if (this->lowerLimit > parameter) {
01637 throw std::out_of_range("The parameter exceeds the lower limit");
01638 }
01639 if (this->upperLimit < parameter) {
01640 throw std::out_of_range("The parameter exceeds the upper limit");
01641 }
01642
01643 this->value = parameter;
01644
01645 }
01646
01647 void DParameterSecondParametersSpeedControl::toString(std::string& value) {
01648
01649 std::stringstream ss;
01650 ss << this->name << ": " << this->value;
01651 value = ss.str();
01652
01653 }
01654
01655 void DParameterSecondParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01656
01657
01658 message.stctOutput.commandNumber = msgType;
01659 message.stctOutput.moduleAddress = DRIVE;
01660 message.stctOutput.typeNumber = 236;
01661 message.stctOutput.value = value;
01662
01663
01664 }
01665
01666 void DParameterSecondParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01667
01668 this->value = (int32)message.stctInput.value;
01669
01670 }
01671
01672 IClippingParameterSecondParametersSpeedControl::IClippingParameterSecondParametersSpeedControl() {
01673
01674 this->name = "IClippingParameterSecondParametersSpeedControl";
01675 this->lowerLimit = INT_MIN;
01676 this->upperLimit = INT_MAX;
01677 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01678
01679 }
01680
01681 IClippingParameterSecondParametersSpeedControl::~IClippingParameterSecondParametersSpeedControl() {
01682
01683
01684 }
01685
01686 void IClippingParameterSecondParametersSpeedControl::getParameter(int& parameter) const {
01687
01688 parameter = this->value;
01689
01690 }
01691
01692 void IClippingParameterSecondParametersSpeedControl::setParameter(const int parameter) {
01693
01694 if (this->lowerLimit > parameter) {
01695 throw std::out_of_range("The parameter exceeds the lower limit");
01696 }
01697 if (this->upperLimit < parameter) {
01698 throw std::out_of_range("The parameter exceeds the upper limit");
01699 }
01700
01701 this->value = parameter;
01702
01703 }
01704
01705 void IClippingParameterSecondParametersSpeedControl::toString(std::string& value) {
01706
01707 std::stringstream ss;
01708 ss << this->name << ": " << this->value;
01709 value = ss.str();
01710
01711 }
01712
01713 void IClippingParameterSecondParametersSpeedControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01714
01715
01716 message.stctOutput.commandNumber = msgType;
01717 message.stctOutput.moduleAddress = DRIVE;
01718 message.stctOutput.typeNumber = 237;
01719 message.stctOutput.value = value;
01720
01721
01722 }
01723
01724 void IClippingParameterSecondParametersSpeedControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01725
01726 this->value = (int32)message.stctInput.value;
01727
01728 }
01729
01730 PParameterCurrentControl::PParameterCurrentControl() {
01731
01732 this->name = "PParameterCurrentControl";
01733 this->lowerLimit = INT_MIN;
01734 this->upperLimit = INT_MAX;
01735 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01736
01737 }
01738
01739 PParameterCurrentControl::~PParameterCurrentControl() {
01740
01741
01742 }
01743
01744 void PParameterCurrentControl::getParameter(int& parameter) const {
01745
01746 parameter = this->value;
01747
01748 }
01749
01750 void PParameterCurrentControl::setParameter(const int parameter) {
01751
01752 if (this->lowerLimit > parameter) {
01753 throw std::out_of_range("The parameter exceeds the lower limit");
01754 }
01755 if (this->upperLimit < parameter) {
01756 throw std::out_of_range("The parameter exceeds the upper limit");
01757 }
01758
01759 this->value = parameter;
01760
01761 }
01762
01763 void PParameterCurrentControl::toString(std::string& value) {
01764
01765 std::stringstream ss;
01766 ss << this->name << ": " << this->value;
01767 value = ss.str();
01768
01769 }
01770
01771 void PParameterCurrentControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01772
01773
01774 message.stctOutput.commandNumber = msgType;
01775 message.stctOutput.moduleAddress = DRIVE;
01776 message.stctOutput.typeNumber = 172;
01777 message.stctOutput.value = value;
01778
01779
01780 }
01781
01782 void PParameterCurrentControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01783
01784 this->value = (int32)message.stctInput.value;
01785
01786 }
01787
01788 IParameterCurrentControl::IParameterCurrentControl() {
01789
01790 this->name = "IParameterCurrentControl";
01791 this->lowerLimit = INT_MIN;
01792 this->upperLimit = INT_MAX;
01793 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01794
01795 }
01796
01797 IParameterCurrentControl::~IParameterCurrentControl() {
01798
01799
01800 }
01801
01802 void IParameterCurrentControl::getParameter(int& parameter) const {
01803
01804 parameter = this->value;
01805
01806 }
01807
01808 void IParameterCurrentControl::setParameter(const int parameter) {
01809
01810 if (this->lowerLimit > parameter) {
01811 throw std::out_of_range("The parameter exceeds the lower limit");
01812 }
01813 if (this->upperLimit < parameter) {
01814 throw std::out_of_range("The parameter exceeds the upper limit");
01815 }
01816
01817 this->value = parameter;
01818
01819 }
01820
01821 void IParameterCurrentControl::toString(std::string& value) {
01822
01823 std::stringstream ss;
01824 ss << this->name << ": " << this->value;
01825 value = ss.str();
01826
01827 }
01828
01829 void IParameterCurrentControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01830
01831
01832 message.stctOutput.commandNumber = msgType;
01833 message.stctOutput.moduleAddress = DRIVE;
01834 message.stctOutput.typeNumber = 173;
01835 message.stctOutput.value = value;
01836
01837
01838 }
01839
01840 void IParameterCurrentControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01841
01842 this->value = (int32)message.stctInput.value;
01843
01844 }
01845
01846 DParameterCurrentControl::DParameterCurrentControl() {
01847
01848 this->name = "DParameterCurrentControl";
01849 this->lowerLimit = INT_MIN;
01850 this->upperLimit = INT_MAX;
01851 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01852
01853 }
01854
01855 DParameterCurrentControl::~DParameterCurrentControl() {
01856
01857
01858 }
01859
01860 void DParameterCurrentControl::getParameter(int& parameter) const {
01861
01862 parameter = this->value;
01863
01864 }
01865
01866 void DParameterCurrentControl::setParameter(const int parameter) {
01867
01868 if (this->lowerLimit > parameter) {
01869 throw std::out_of_range("The parameter exceeds the lower limit");
01870 }
01871 if (this->upperLimit < parameter) {
01872 throw std::out_of_range("The parameter exceeds the upper limit");
01873 }
01874
01875 this->value = parameter;
01876
01877 }
01878
01879 void DParameterCurrentControl::toString(std::string& value) {
01880
01881 std::stringstream ss;
01882 ss << this->name << ": " << this->value;
01883 value = ss.str();
01884
01885 }
01886
01887 void DParameterCurrentControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01888
01889
01890 message.stctOutput.commandNumber = msgType;
01891 message.stctOutput.moduleAddress = DRIVE;
01892 message.stctOutput.typeNumber = 174;
01893 message.stctOutput.value = value;
01894
01895
01896 }
01897
01898 void DParameterCurrentControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01899
01900 this->value = (int32)message.stctInput.value;
01901
01902 }
01903
01904 IClippingParameterCurrentControl::IClippingParameterCurrentControl() {
01905
01906 this->name = "IClippingParameterCurrentControl";
01907 this->lowerLimit = INT_MIN;
01908 this->upperLimit = INT_MAX;
01909 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01910
01911 }
01912
01913 IClippingParameterCurrentControl::~IClippingParameterCurrentControl() {
01914
01915
01916 }
01917
01918 void IClippingParameterCurrentControl::getParameter(int& parameter) const {
01919
01920 parameter = this->value;
01921
01922 }
01923
01924 void IClippingParameterCurrentControl::setParameter(const int parameter) {
01925
01926 if (this->lowerLimit > parameter) {
01927 throw std::out_of_range("The parameter exceeds the lower limit");
01928 }
01929 if (this->upperLimit < parameter) {
01930 throw std::out_of_range("The parameter exceeds the upper limit");
01931 }
01932
01933 this->value = parameter;
01934
01935 }
01936
01937 void IClippingParameterCurrentControl::toString(std::string& value) {
01938
01939 std::stringstream ss;
01940 ss << this->name << ": " << this->value;
01941 value = ss.str();
01942
01943 }
01944
01945 void IClippingParameterCurrentControl::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
01946
01947
01948 message.stctOutput.commandNumber = msgType;
01949 message.stctOutput.moduleAddress = DRIVE;
01950 message.stctOutput.typeNumber = 175;
01951 message.stctOutput.value = value;
01952
01953
01954 }
01955
01956 void IClippingParameterCurrentControl::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
01957
01958 this->value = (int32)message.stctInput.value;
01959
01960 }
01961
01962 MaximumVelocityToSetPosition::MaximumVelocityToSetPosition() {
01963
01964 this->name = "MaximumVelocityToSetPosition";
01965 this->lowerLimit = INT_MIN * radian_per_second;
01966 this->upperLimit = INT_MAX * radian_per_second;
01967 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
01968
01969 }
01970
01971 MaximumVelocityToSetPosition::~MaximumVelocityToSetPosition() {
01972
01973
01974 }
01975
01976 void MaximumVelocityToSetPosition::getParameter(quantity<angular_velocity>& parameter) const {
01977
01978 parameter = this->value;
01979
01980 }
01981
01982 void MaximumVelocityToSetPosition::setParameter(const quantity<angular_velocity>& parameter) {
01983
01984 if (this->lowerLimit > parameter) {
01985 throw std::out_of_range("The parameter exceeds the lower limit");
01986 }
01987 if (this->upperLimit < parameter) {
01988 throw std::out_of_range("The parameter exceeds the upper limit");
01989 }
01990
01991 this->value = parameter;
01992
01993 }
01994
01995 void MaximumVelocityToSetPosition::toString(std::string& value) {
01996
01997 std::stringstream ss;
01998 ss << this->name << ": " << this->value;
01999 value = ss.str();
02000
02001 }
02002
02003 void MaximumVelocityToSetPosition::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
02004
02005
02006 message.stctOutput.commandNumber = msgType;
02007 message.stctOutput.moduleAddress = DRIVE;
02008 message.stctOutput.typeNumber = 7;
02009 message.stctOutput.value = (int32) round((value.value() / (storage.gearRatio * 2.0 * M_PI)) * 60.0);
02010
02011
02012 }
02013
02014 void MaximumVelocityToSetPosition::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
02015
02016 double motorRPM = (int32)message.stctInput.value;
02017 this->value = ((motorRPM / 60.0) * storage.gearRatio * 2.0 * M_PI) * radian_per_second;
02018
02019 }
02020
02021 PositionTargetReachedDistance::PositionTargetReachedDistance() {
02022
02023 this->name = "PositionTargetReachedDistance";
02024 this->lowerLimit = INT_MIN;
02025 this->upperLimit = INT_MAX;
02026 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
02027
02028 }
02029
02030 PositionTargetReachedDistance::~PositionTargetReachedDistance() {
02031
02032
02033 }
02034
02035 void PositionTargetReachedDistance::getParameter(int& parameter) const {
02036
02037 parameter = this->value;
02038
02039 }
02040
02041 void PositionTargetReachedDistance::setParameter(const int parameter) {
02042
02043 if (this->lowerLimit > parameter) {
02044 throw std::out_of_range("The parameter exceeds the lower limit");
02045 }
02046 if (this->upperLimit < parameter) {
02047 throw std::out_of_range("The parameter exceeds the upper limit");
02048 }
02049
02050 this->value = parameter;
02051
02052 }
02053
02054 void PositionTargetReachedDistance::toString(std::string& value) {
02055
02056 std::stringstream ss;
02057 ss << this->name << ": " << this->value;
02058 value = ss.str();
02059
02060 }
02061
02062 void PositionTargetReachedDistance::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
02063
02064
02065 message.stctOutput.commandNumber = msgType;
02066 message.stctOutput.moduleAddress = DRIVE;
02067 message.stctOutput.typeNumber = 10;
02068 message.stctOutput.value = value;
02069
02070
02071 }
02072
02073 void PositionTargetReachedDistance::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
02074
02075 this->value = (int32)message.stctInput.value;
02076
02077 }
02078
02079 ClearI2tExceededFlag::ClearI2tExceededFlag() {
02080
02081 this->name = "ClearI2tExceededFlag";
02082 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
02083 this->value = true;
02084
02085 }
02086
02087 ClearI2tExceededFlag::~ClearI2tExceededFlag() {
02088
02089
02090 }
02091
02092 void ClearI2tExceededFlag::getParameter() const {
02093
02094
02095 }
02096
02097 void ClearI2tExceededFlag::setParameter() {
02098
02099
02100 }
02101
02102 void ClearI2tExceededFlag::toString(std::string& value) {
02103
02104 std::stringstream ss;
02105 ss << this->name << ": " << this->value;
02106 value = ss.str();
02107
02108 }
02109
02110 void ClearI2tExceededFlag::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
02111
02112 message.stctOutput.commandNumber = msgType;
02113 message.stctOutput.moduleAddress = DRIVE;
02114 message.stctOutput.typeNumber = 29;
02115 message.stctOutput.value = value;
02116
02117 }
02118
02119 void ClearI2tExceededFlag::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
02120
02121 if (message.stctOutput.commandNumber == message.stctInput.commandNumber && message.stctInput.status == NO_ERROR) {
02122 this->value = message.stctInput.value;
02123 }
02124
02125 }
02126
02127 ClearMotorControllerTimeoutFlag::ClearMotorControllerTimeoutFlag() {
02128
02129 this->name = "ClearMotorControllerTimeoutFlag";
02130 this->parameterType = MOTOR_CONTOLLER_PARAMETER;
02131 this->value = true;
02132
02133 }
02134
02135 ClearMotorControllerTimeoutFlag::~ClearMotorControllerTimeoutFlag() {
02136
02137
02138 }
02139
02140 bool ClearMotorControllerTimeoutFlag::getParameter() const {
02141
02142 return this->value;
02143
02144 }
02145
02146 void ClearMotorControllerTimeoutFlag::setParameter() {
02147
02148
02149 }
02150
02151 void ClearMotorControllerTimeoutFlag::toString(std::string& value) {
02152
02153 std::stringstream ss;
02154 ss << this->name << ": " << this->value;
02155 value = ss.str();
02156
02157 }
02158
02159 void ClearMotorControllerTimeoutFlag::getYouBotMailboxMsg(YouBotSlaveMailboxMsg& message, TMCLCommandNumber msgType, const YouBotJointStorage& storage) const {
02160
02161 message.stctOutput.commandNumber = msgType;
02162 message.stctOutput.moduleAddress = DRIVE;
02163 message.stctOutput.typeNumber = 158;
02164 message.stctOutput.value = value;
02165
02166 }
02167
02168 void ClearMotorControllerTimeoutFlag::setYouBotMailboxMsg(const YouBotSlaveMailboxMsg& message, const YouBotJointStorage& storage) {
02169
02170 if (message.stctOutput.commandNumber == message.stctInput.commandNumber && message.stctInput.status == NO_ERROR) {
02171 this->value = message.stctInput.value;
02172 }
02173
02174 }
02175
02176 PParameterTrajectoryControl::PParameterTrajectoryControl() {
02177
02178 this->name = "PParameterTrajectoryControl";
02179 this->lowerLimit = 0;
02180 this->upperLimit = INT_MAX;
02181 this->parameterType = API_PARAMETER;
02182
02183 }
02184
02185 PParameterTrajectoryControl::~PParameterTrajectoryControl() {
02186
02187
02188 }
02189
02190 void PParameterTrajectoryControl::getParameter(double& parameter) const {
02191
02192 parameter = this->value;
02193
02194 }
02195
02196 void PParameterTrajectoryControl::setParameter(const double parameter) {
02197
02198 if (this->lowerLimit > parameter) {
02199 throw std::out_of_range("The parameter exceeds the lower limit");
02200 }
02201 if (this->upperLimit < parameter) {
02202 throw std::out_of_range("The parameter exceeds the upper limit");
02203 }
02204
02205 this->value = parameter;
02206
02207 }
02208
02209 void PParameterTrajectoryControl::toString(std::string& value) {
02210
02211 std::stringstream ss;
02212 ss << this->name << ": " << this->value;
02213 value = ss.str();
02214
02215 }
02216
02217 IParameterTrajectoryControl::IParameterTrajectoryControl() {
02218
02219 this->name = "IParameterTrajectoryControl";
02220 this->lowerLimit = INT_MIN;
02221 this->upperLimit = INT_MAX;
02222 this->parameterType = API_PARAMETER;
02223
02224 }
02225
02226 IParameterTrajectoryControl::~IParameterTrajectoryControl() {
02227
02228
02229 }
02230
02231 void IParameterTrajectoryControl::getParameter(double& parameter) const {
02232
02233 parameter = this->value;
02234
02235 }
02236
02237 void IParameterTrajectoryControl::setParameter(const double parameter) {
02238
02239 if (this->lowerLimit > parameter) {
02240 throw std::out_of_range("The parameter exceeds the lower limit");
02241 }
02242 if (this->upperLimit < parameter) {
02243 throw std::out_of_range("The parameter exceeds the upper limit");
02244 }
02245
02246 this->value = parameter;
02247
02248 }
02249
02250 void IParameterTrajectoryControl::toString(std::string& value) {
02251
02252 std::stringstream ss;
02253 ss << this->name << ": " << this->value;
02254 value = ss.str();
02255
02256 }
02257
02258 DParameterTrajectoryControl::DParameterTrajectoryControl() {
02259
02260 this->name = "DParameterTrajectoryControl";
02261 this->lowerLimit = INT_MIN;
02262 this->upperLimit = INT_MAX;
02263 this->parameterType = API_PARAMETER;
02264
02265 }
02266
02267 DParameterTrajectoryControl::~DParameterTrajectoryControl() {
02268
02269
02270 }
02271
02272 void DParameterTrajectoryControl::getParameter(double& parameter) const {
02273
02274 parameter = this->value;
02275
02276 }
02277
02278 void DParameterTrajectoryControl::setParameter(const double parameter) {
02279
02280 if (this->lowerLimit > parameter) {
02281 throw std::out_of_range("The parameter exceeds the lower limit");
02282 }
02283 if (this->upperLimit < parameter) {
02284 throw std::out_of_range("The parameter exceeds the upper limit");
02285 }
02286
02287 this->value = parameter;
02288
02289 }
02290
02291 void DParameterTrajectoryControl::toString(std::string& value) {
02292
02293 std::stringstream ss;
02294 ss << this->name << ": " << this->value;
02295 value = ss.str();
02296
02297 }
02298
02299 IClippingParameterTrajectoryControl::IClippingParameterTrajectoryControl() {
02300
02301 this->name = "IClippingParameterTrajectoryControl";
02302 this->lowerLimit = INT_MIN;
02303 this->upperLimit = INT_MAX;
02304 this->parameterType = API_PARAMETER;
02305
02306 }
02307
02308 IClippingParameterTrajectoryControl::~IClippingParameterTrajectoryControl() {
02309
02310
02311 }
02312
02313 void IClippingParameterTrajectoryControl::getParameter(double& parameter) const {
02314
02315 parameter = this->value;
02316
02317 }
02318
02319 void IClippingParameterTrajectoryControl::setParameter(const double parameter) {
02320
02321 if (this->lowerLimit > parameter) {
02322 throw std::out_of_range("The parameter exceeds the lower limit");
02323 }
02324 if (this->upperLimit < parameter) {
02325 throw std::out_of_range("The parameter exceeds the upper limit");
02326 }
02327
02328 this->value = parameter;
02329
02330 }
02331
02332 void IClippingParameterTrajectoryControl::toString(std::string& value) {
02333
02334 std::stringstream ss;
02335 ss << this->name << ": " << this->value;
02336 value = ss.str();
02337
02338 }
02339
02340
02341 }