66 this->
name =
"ActualMotorVoltage";
78 parameter = this->value;
85 ss << this->
name <<
": " << this->value.value();
104 this->value = temp/100.0 * volt;
111 this->
name =
"ErrorAndStatus";
123 parameter = this->value;
124 this->parseYouBotErrorFlags();
130 std::stringstream ss;
131 ss << this->
name <<
": " << this->value;
158 std::string errorMessage;
163 LOG(
warning) << errorMessage <<
"over current";
168 LOG(
warning) << errorMessage <<
"under voltage";
173 LOG(
warning) << errorMessage <<
"over voltage";
178 LOG(
warning) << errorMessage <<
"over temperature";
183 LOG(
info) << errorMessage <<
"is halted";
188 LOG(
warning) << errorMessage <<
"hall sensor problem";
198 LOG(
info) << errorMessage <<
"velocity mode active";
203 LOG(
info) << errorMessage <<
"position mode active";
208 LOG(
info) << errorMessage <<
"torque mode active";
213 LOG(
info) << errorMessage <<
"position reached";
218 LOG(
info) << errorMessage <<
"is initialized";
228 LOG(
warning) << errorMessage <<
"I2t exceeded";
237 this->
name =
"PositionError";
249 parameter = this->value;
255 std::stringstream ss;
256 ss << this->
name <<
": " << this->value.value();
279 this->
name =
"PositionErrorSum";
291 parameter = this->value;
297 std::stringstream ss;
298 ss << this->
name <<
": " << this->value.value();
323 this->
name =
"VelocityError";
335 parameter = this->value;
341 std::stringstream ss;
342 ss << this->
name <<
": " << this->value.value();
361 this->value = ((temp / 60.0) * storage.
gearRatio * 2.0 * M_PI) * radian_per_second;
367 this->
name =
"VelocityErrorSum";
379 parameter = this->value;
385 std::stringstream ss;
386 ss << this->
name <<
": " << this->value.value();
405 this->value = ((temp / 60.0) * storage.
gearRatio * 2.0 * M_PI) * radian_per_second;
412 this->
name =
"CurrentError";
424 parameter = this->value;
430 std::stringstream ss;
431 ss << this->
name <<
": " << this->value.value();
450 this->value = temp /1000.0 * ampere;
457 this->
name =
"CurrentErrorSum";
469 parameter = this->value;
475 std::stringstream ss;
476 ss << this->
name <<
": " << this->value.value();
495 this->value = temp /1000.0 * ampere;
502 this->
name =
"RampGeneratorSpeed";
514 parameter = this->value;
520 std::stringstream ss;
521 ss << this->
name <<
": " << this->value.value();
540 this->value = ((temp / 60.0) * storage.
gearRatio * 2.0 * M_PI) * radian_per_second;
546 this->
name =
"I2tSum";
547 this->lowerLimit = 0;
548 this->upperLimit = INT_MAX;
560 parameter = this->value;
566 if (this->lowerLimit > parameter) {
567 throw std::out_of_range(
"The parameter exceeds the lower limit");
569 if (this->upperLimit < parameter) {
570 throw std::out_of_range(
"The parameter exceeds the upper limit");
572 this->value = parameter;
578 std::stringstream ss;
579 ss << this->
name <<
": " << this->value;
603 this->
name =
"ActualMotorDriverTemperature";
615 parameter = this->value;
621 std::stringstream ss;
622 ss << this->
name <<
": " << this->value.value();
640 double materialConstant = 3434;
642 double nominator = materialConstant * 298.16;
643 double denominator = materialConstant + (log(R_NTC/10.0) * 298.16);
644 this->value = ((nominator/denominator) - 273.16) * celsius::degree;
651 this->
name =
"ActualModuleSupplyCurrent";
663 parameter = this->value;
669 std::stringstream ss;
670 ss << this->
name <<
": " << this->value.value();
void getParameter(quantity< electric_potential > ¶meter) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void toString(std::string &value)
YouBotJointParameterReadOnly()
void toString(std::string &value)
void toString(std::string &value)
ActualModuleSupplyCurrent()
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
virtual ~ErrorAndStatus()
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
virtual ~ActualModuleSupplyCurrent()
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
void setParameter(const unsigned int parameter)
void toString(std::string &value)
void getParameter(unsigned int ¶meter) const
mailboxInputBuffer stctInput
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
void toString(std::string &value)
void toString(std::string &value)
virtual ~YouBotJointParameterReadOnly()
void toString(std::string &value)
mailboxOutputBuffer stctOutput
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
virtual ~PositionErrorSum()
void getParameter(quantity< si::angular_velocity > ¶meter) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
virtual ~ActualMotorDriverTemperature()
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
EtherCAT mailbox message of the youBot slaves.
void toString(std::string &value)
void getParameter(quantity< si::current > ¶meter) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getParameter(quantity< si::current > ¶meter) const
void toString(std::string &value)
ActualMotorDriverTemperature()
virtual ~VelocityErrorSum()
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
ParameterType parameterType
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
unsigned int encoderTicksPerRound
virtual ~ActualMotorVoltage()
void getParameter(quantity< si::angular_velocity > ¶meter) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
void getParameter(quantity< plane_angle > ¶meter) const
void getParameter(quantity< plane_angle > ¶meter) const
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void toString(std::string &value)
void getYouBotMailboxMsg(YouBotSlaveMailboxMsg &message, TMCLCommandNumber msgType, const YouBotJointStorage &storage) const
void getParameter(quantity< si::current > ¶meter) const
virtual ~CurrentErrorSum()
void parseYouBotErrorFlags() const
void toString(std::string &value)
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)
Stores YouBotJoint informations which are needed in the driver.
void getParameter(unsigned int ¶meter) const
virtual ~RampGeneratorSpeed()
void getParameter(quantity< celsius::temperature > ¶meter) const
void toString(std::string &value)
void getParameter(quantity< si::angular_velocity > ¶meter) const
void setYouBotMailboxMsg(const YouBotSlaveMailboxMsg &message, const YouBotJointStorage &storage)