
Guangcheng Technology GC-2302 user manual
2. The following describes the situation when the GC-2302 module is used for pure
pulse output: The variable declaration area of the program is defined as follows:
Pwm_Duty1 at%Q0.0:int; (*Define the duty cycle of the first pulse output, unit %*)
Pwm_FQ1 at%Q2.0:dint; (*Define the frequency of the first pulse output, unit: Hz* )
Pwm_Duty2 at%Q6.0:int; (*Define the duty cycle of the second pulse output, unit %*)
Pwm_FQ2 at%Q8.0:dint; (*Define the frequency of the second pulse output, unit: Hz
*)
First call the motor pulse initialization function block in the program: the input pin
definition of the EXT_MOTOR_PWM_INIT function block:
EN_IN: Function block enable signal
NETNUMBER: Number of GC-2302 modules from PLC
MOTOR_CH: the pulse output number of the gc-2302, 1 or 2 MOTOR_MODE: 1
speed mode; 2 location mode; 3 Pulse output mode
The output pin definition of the function block:
EN_OUT: The value is 1 after successful initialization
ERROR: error value
Next, assign values for duty cycle and frequency,
E.g:
Pwm_Duty1:=30; (*Duty cycle is 30%*)
Pwm_FQ1:=30000; (* frequency is 30kHz*)
Pwm_Duty2:=50; (* Duty cycle is 50%*)
Pwm_FQ2:=50000; (*Frequency is 50kHz*)
B. GC2302 is used in connection with GCAN-IO-8000 controller:
1. Motor initialization: CANopen main index: 0x3000
CANopen sub-index: 0
Send frame data: PDO parameter + main index + sub index + device number (the
number of GC2302 modules) + channel number
(Corresponding to the channel number of GC2302, channel 1 or channel 2) + pulse
value (the number of pulses required for 1 revolution of the motor) For example:
Device number: 1, channel number: 1, pulse: 5000
send pdo: 0x601 23 00 30 00 01 01 88 13
Device number: 1, channel number: 2, pulse: 5000
send pdo: 0x601 23 00 30 00 01 02 88 13
Device number: 2, channel number: 1, pulse: 5000
send pdo: 0x601 23 00 30 00 02 01 88 13