RX72M Group
Single-Chip Motor Control via EtherCAT Communications
R01AN5434EJ0110 Rev.1.10
Page 30 of 85
Aug.31.2020
5.4 R_MTR_ExecEvent
This function issues indicators of events with regard to the state of system operation of the motor control
program.
Format
void R_MTR_ExecEvent (uint8_t u1_event, uint8_t u1_id)
Parameters
u1_event
Event Name
Value
Trigger Source
MTR_EVENT_INACTIVE
0x00
This indicator corresponds to torque through the motor
being turned on.
MTR_EVENT_ACTIVE
0x01
This indicator corresponds to torque through the motor
being turned off.
MTR_EVENT_ERROR
0x02
This indicator corresponds to the system detecting an
error.
MTR_EVENT_RESET
0x03
This indicator corresponds to the operation being
initialized or recovery from an error.
u1_id
Specifies the ID of the motor to be controlled.
MTR_ID_A /* Motor A*/
Return Values
None
Properties
The prototypes are declared in r_mtr_driver_acces.h.
Description
This function indicates changes to the state of system operation by issuing an event indicator as an
argument.
Example
/* Execution ACTIVE event */
R_MTR_ExecEvent(MTR_EVENT_ACTIVE, MTR_ID_A);