![]() |
peripherals
1.4.2
RoadNarrows Robotics Hardware Peripherals Package
|
Public Member Functions | |
| int | open (const std::string &devName, int baudRate) |
| Function opens serial communication with motor controller device. More... | |
| int | close () |
| Function closes serial communication with motor controller device. More... | |
| int | sendCommand (int fd, byte_t *buf, int nBytes, int timeout) |
| int | recvResponse (int fd, byte_t *buf, int timeout) |
Public Member Functions inherited from rnr::Mot | |
| Mot (float maxSpeed, float minSpeed, float speedStepSize, float maxBrake, float minBrake, float brakeStepSize) | |
| virtual bool | motIDIsValid (int motID)=0 |
| Function sends commands to the motor controller and receives responses from the motor controller. More... | |
| virtual int | setSpeed (int motID, float speed, units_t units=units_norm)=0 |
| Description. More... | |
| virtual int | setSpeed (VecSpeedTupples vecSpeedTupple, units_t units=units_norm)=0 |
| Function updates the speed of all motors simultaneously but individually. More... | |
| virtual int | stop (int motID)=0 |
| Function stops motor specified. More... | |
| virtual int | eStop ()=0 |
| Function simultaneously halts motor rotation for all motors by setting speeds to zero. More... | |
| virtual int | eStopRelease ()=0 |
| Function releases emergency stop condition and allows normal ops. More... | |
| virtual int | getCurrentLimits ()=0 |
| Function determines if a motor controller can monitor current. More... | |
| virtual int | setCurrentLimits (int motID, int current, units_t units=units_amp)=0 |
| Function sets minimum and maximum limits for current. More... | |
| virtual int | getCurrent (int motID, units_t units=units_amp)=0 |
| Function retrieves value for current load on a single motor. More... | |
| virtual int | getVoltageLimits ()=0 |
| Function retrieves value for current load on a single motor. More... | |
| virtual int | setVoltageLimits (int lowVoltage, int overVoltage)=0 |
| Function sets the minimum and maximum limits for applied voltage for all motors. More... | |
| virtual int | getVoltage ()=0 |
| Function retrieves value for voltage applied to a single motor. More... | |
| virtual int | setSpeedProfile (int motID, int accel, int decel=-1)=0 |
| Function retrieves value for voltage applied to a single motor. More... | |
Protected Attributes | |
| int | m_fd |
| int | m_ntimeout |
| int | m_nbaudRate |
Protected Attributes inherited from rnr::Mot | |
| float | m_fMaxSpeed |
| Function sets the acce1 leration rate for motors. More... | |
| float | m_fMinSpeed |
| float | m_fSpeedStepSize |
| float | m_fMaxBrake |
| float | m_fMinBrake |
| float | m_fBrakeStepSize |
Additional Inherited Members | |
Public Types inherited from rnr::Mot | |
| typedef std::vector< IDFloatTupple > | VecSpeedTupples |
| typedef std::vector< IDIntTupple > | VecSpeedRawTupples |
| typedef std::vector< int > | VecMotID |
Definition at line 63 of file MotRoboteq.h.
|
virtual |
Function closes serial communication with motor controller device.
Uses SerDevClose to close serial connection. Returns: 0 on success, -1 on fail.
Implements rnr::Mot.
|
virtual |
Function opens serial communication with motor controller device.
Uses SerDevOpen to open serial connection with device (devName) Returns: File descriptor >=0 on success, -1 on fail.
Implements rnr::Mot.