MPI 04.00 Reference >> mpiMotor
mpiMotorConfigSet
Declaration
long mpiMotorConfigSet(MPIMotor motor, MPIMotorConfig *config);
Required Header: stdmpi.h
Change History: Modified in 04.00.
Description
mpiMotorConfigSet sets a Motor's (motor) configuration using data from the structure pointed to by config.
motor | A handle to an Motor object. |
---|---|
*config | A pointer to the MPIMotorConfig structure. |
Return Values |
---|
MPIMessageOK |
MPIMotorMessageDEMAND_MODE_NOT_SET |
MPIMotorMessageDEMAND_MODE_UNSUPPORTED |
Sample Code
MPIMotorConfig motorConfig; mpiMotorConfigGet(motor, &motorConfig); motorConfig.type = MPIMotorTypeSERVO; mpiMotorConfigSet(motor, &motorConfig);