Difference between revisions of "EtherCAT:EC SLAVE SET STATE"
m (Miborich moved page Axystems:EtherCAT:EC SLAVE SET STATE to EtherCAT:EC SLAVE SET STATE: Global renaming of Axystems: namespace into (Main):) |
m (Text replace - "Axystems:" to "") |
||
Line 1: | Line 1: | ||
− | {{ | + | {{Template:EtherCAT-Function |
|DESCRIPTION= | |DESCRIPTION= |
Revision as of 09:15, 22 May 2014
This function set the slave's operational state. Please use EC_SLAVE_NMT_STATESET to attempt setting of a drive's opmode in an informative manner.
Input
Axis' address (example: Ax.dAdd), new state as long where:
EC_STATE_INIT - 0x01
EC_STATE_PREOP - 0x02
EC_STATE_SAFEOP - 0x04
EC_STATE_OP - 0x08
Output
None
Return Value
0 if successful, -1 otherwise
Declaration
public function EC_SLAVE_SET_STATE(byval addr as long, byval stat as long) as long
Examples
retVal = EC_SLAVE_SET_STATE(slave_addr[i], EC_STATE_SAFEOP )