RL78/G1G Sensorless Speed control of 120-degree conducting controlled permanent magnetic synchronous motor (Implementation)
R01AN3582EJ0100 Rev.1.00
Page 40 of 46
Jan 13, 2017
Table 3-30
List of Macro definitions “mtr_spm_less_120.h” [3/4]
File name
Macro name
Definition value
Remarks
mtr_spm_less
_120.h
MTR_VP_ON_U_PWM
21
Conduction pattern
MTR_VP_ON_W_PWM
22
MTR_WP_ON_U_PWM
23
MTR_WP_ON_V_PWM
24
MTR_OFFSET_CALC_TIME
CP_OFFSET_CALC_TIME
Time to calculate voltage offset [ms]
MTR_BOOT_REF_V
CP_BOOT_REF_V
Voltage reference at draw-in [V]
MTR_V_UP_PERIOD
CP_V_UP_TIME
Time to increase voltage step at draw-in [ms]
MTR_V_UP_STEP
(int16) MTR_BOOT_REF_V
/ MTR_V_UP_PERIOD
Increase step of voltage at draw-in
MTR_V_CONST_TIME
CP_V_CONST_TIME
Period of constant voltage at draw-in [ms]
MTR_CW
0
Rotation direction
MTR_CCW
1
MTR_FLG_CLR
0
Constant for flag management
MTR_FLG_SET
1
MTR_MODE_INACTIVE
0x00
Inactive mode
MTR_MODE_ACTIVE
0x01
Active mode
MTR_MODE_ERROR
0x02
Error mode
MTR_SIZE_STATE
3
State size
MTR_EVENT_INACTIVE
0x00
Inactive event
MTR_EVENT_ACTIVE
0x01
Active event
MTR_EVENT_ERROR
0x02
Error event
MTR_EVENT_RESET
0x03
Reset event
MTR_SIZE_EVENT
4
Event size
MTR_MODE_INIT
0x00
Initialize mode
MTR_MODE_BOOT
0x01
Boot mode
MTR_MODE_DRIVE
0x02
Drive mode
MTR_MODE_ANALYSIS
0x03
Analysis mode
MTR_MODE_TUNE
0x04
Tune mode
MTR_SENSOR_LESS
0x01
Sensorless
MTR_SENSOR_HALL
0x02
Hall sensor
MTR_SENSOR_ENCD
0x04
Encoder
MTR_SENSOR_RESO
0x08
Resolver
MTR_METHOD_FOC
0x00
Fields oriented control
MTR_METHOD_180
0x01
180 degree control
MTR_METHOD_WIDE
0x02
Wide angle electricity control
MTR_METHOD_120
0x03
120 degree control
MTR_CONTROL_CURRENT
0x01
Current control
MTR_CONTROL_SPEED
0x02
Speed control
MTR_CONTROL_POSITION
0x04
Position control
MTR_CONTROL_TORQUE
0x08
Torque control
MTR_CONTROL_VOLTAGE
0x10
Voltage control