Brief description of class SlaveInterface.
More...
#include <armarx/control/ethercat/SlaveInterface.h>
Brief description of class SlaveInterface.
Detailed description of class SlaveInterface.
◆ SlaveInterface()
◆ ~SlaveInterface()
◆ doMappings()
| virtual void doMappings |
( |
| ) |
|
|
pure virtual |
This is called after EtherCAT Bus is PreOp Mode.
This is where the PDO Mapping can be configured for the slave.
◆ execute()
This method gets triggered by the Bus Controller, this function hast to be implemented cooperative.
The Bus controller will guarantee that the process data will be update before each call.
◆ finishPreparingForOp()
| virtual void finishPreparingForOp |
( |
| ) |
|
|
inlinevirtual |
This gets called after prepareForOp() was called.
This is useful if prepareForOp() executes a long running initialization and needs to be done before the slave goes into op
◆ finishPreparingForSafeOp()
| virtual void finishPreparingForSafeOp |
( |
| ) |
|
|
inlinevirtual |
◆ getErrorRegistersDevice()
◆ getSlaveIdentifier()
◆ getSlaveNumber()
| std::uint16_t getSlaveNumber |
( |
| ) |
const |
This returns the slave number of the slave on the bus +1 because slave 0 is the master.
- Returns
- index in ec_slave array
◆ handleErrors()
This tries to clear oder fix the errors or problems of the slave or just gives detailed information about the problem.
If hasError == false this function does nothing.
- Returns
- true if the function is trying to recover the slave or there is no error, false is send if this just reports the info
◆ hasError()
| virtual bool hasError |
( |
| ) |
|
|
pure virtual |
This function indicates if there is a error or Problem with this slave.
It should not
- Returns
- true if there is an error/problem with this slave otherwise false;
◆ hasPDOMapping()
| virtual bool hasPDOMapping |
( |
| ) |
const |
|
inlinevirtual |
◆ isEmergencyStopActive()
| virtual bool isEmergencyStopActive |
( |
| ) |
const |
|
inlinevirtual |
◆ prepareForOp()
| virtual void prepareForOp |
( |
| ) |
|
|
pure virtual |
This gets called between the SafeOp an the Op state of the bus at the initizialisation.
The slave can assume that the PDO is already mapped
◆ prepareForRun()
| virtual bool prepareForRun |
( |
| ) |
|
|
pure virtual |
This gets triggered by the bus controller before it will start the control loop.
If a slave needs more preparation than just getting in EtherCAT Op-Mode this should be done here. So slaves can assume that the EtherCAT state machine is in Op-Mode so PDO's are available. Attention!!! This needs to be implemented cooperative
- Returns
- true if the prepare is finished an don't needs to be called again
◆ prepareForSafeOp()
| virtual void prepareForSafeOp |
( |
| ) |
|
|
inlinevirtual |
◆ recoverFromEmergencyStop()
| virtual bool recoverFromEmergencyStop |
( |
| ) |
|
|
inlinevirtual |
◆ setErrorRegistersDevice()
◆ setInputPDO()
| virtual void setInputPDO |
( |
void * | ptr | ) |
|
|
pure virtual |
◆ setName()
| void setName |
( |
const std::string & | name | ) |
|
|
virtual |
◆ setOutputPDO()
| virtual void setOutputPDO |
( |
void * | ptr | ) |
|
|
pure virtual |
◆ setParentDeviceName()
| void setParentDeviceName |
( |
const std::string & | name | ) |
|
◆ shutdown()
| virtual bool shutdown |
( |
| ) |
|
|
pure virtual |
This gets triggered by the bus Controller before it will close the EtherCAT bus.
So if the device need to do something before to get in a safe state, this can be done here. Attention!!! This needs to be implemented cooperative
- Returns
- if slave is shut down
◆ errorRegistersDevice
◆ slaveIdentifier
The documentation for this class was generated from the following files: