20: P
ULSE
I
NSTRUCTIONS
« FC4A M
ICRO
S
MART
U
SER
’
S
M
ANUAL
»
20-7
PWM1 (Pulse Width Modulation 1)
PWM2 (Pulse Width Modulation 2)
Note:
The PWM1 and PWM2 instructions can be used only once in a user program. When PWM1 or PWM2 is not used,
unused output Q0 or Q1 can be used for another pulse instruction or ordinar y output.
Applicable CPU Modules
Valid Operands
Source operand S1 (control register) uses 8 data registers starting with the operand designated as S1. Data registers D0
through D1292 and D2000 through D7992 can be designated as S1. For details, see below.
Destination operand D1 (status relay) uses 3 internal relays starting with the operand designated as D1. Internal relays M0
through M1270 can be designated as D1. The least significant digit of the internal relay number designated as D1 must be
0. Special internal relays cannot be designated as D1. For details, see page 6-2.
Source Operand S1 (Control Register)
Store appropriate values to data registers starting with the operand designated by S1 before executing the PWM instruction
as required, and make sure that the values are within the valid range. Operands S1+5 through S1+7 are for read only.
FC4A-C10R2/C
FC4A-C16R2/C
FC4A-C24R2/C
FC4A-D20K3/S3
FC4A-D20RK1/RS1 & FC4A-D40K3/S3
—
—
—
X
X
Operand
Function
I
Q
M
R
T
C
D
Constant
Repeat
S1 (Source 1)
Control register
—
—
—
—
—
—
X
—
—
D1 (Destination 1)
Status relay
—
—
X
—
—
—
—
—
—
Operand
Function
Description
R/W
S1+0
Output pulse frequency
0: 6.81 Hz
1: 27.26 Hz
2: 217.86 Hz
R/W
S1+1
Pulse width ratio
1 to 100
(1% to 100% of the period determined by output pulse frequency S1+0)
R/W
S1+2
Pulse counting
0: Disable pulse counting
1: Enable pulse counting (PWM1 only)
R/W
S1+3
Preset value (high word)
1 to 100,000,000 (05F5 E100h) (PWM1 only)
R/W
S1+4
Preset value (low word)
S1+5
Current value (high word)
1 to 100,000,000 (05F5 E100h) (PWM1 only)
R
S1+6
Current value (low word)
S1+7
Error status
0 to 5
R
When input is on, the PWM1 instruction generates a pulse output. The output
pulse frequency is selected from 6.81, 27.26, or 217.86 Hz, and the output
pulse width ratio is determined by source operand S1.
PWM1 sends out output pulses from output Q0.
PWM1 can be programmed to generate a predetermined number of output
pulses. When pulse counting is disabled, PWM1 generates output pulses while
the star t input for the PWM1 instruction remains on.
PWM
1
S1
*****
D1
*****
When input is on, the PWM2 instruction generates a pulse output. The output
pulse frequency is selected from 6.81, 27.26, or 217.86 Hz, and the output
pulse width ratio is determined by source operand S1.
PWM2 sends out output pulses from output Q1.
PWM2 generates output pulses while the star t input for the PWM2 instruction
remains on. PWM2 cannot be programmed to generate a predetermined number
of output pulses.
PWM
2
S1
*****
D1
*****
Summary of Contents for FC4A-C10R2
Page 1: ...FC4A SERIES Micro Programmable Logic Controller User s Manual FC9Y B812 ...
Page 6: ...PREFACE 4 FC4A MICROSMART USER S MANUAL ...
Page 94: ...2 MODULE SPECIFICATIONS 2 74 FC4A MICROSMART USER S MANUAL ...
Page 184: ...6 ALLOCATION NUMBERS 6 20 FC4A MICROSMART USER S MANUAL ...
Page 218: ...8 ADVANCED INSTRUCTIONS 8 8 FC4A MICROSMART USER S MANUAL ...
Page 240: ...11 BINARY ARITHMETIC INSTRUCTIONS 11 8 FC4A MICROSMART USER S MANUAL ...
Page 244: ...12 BOOLEAN COMPUTATION INSTRUCTIONS 12 4 FC4A MICROSMART USER S MANUAL ...
Page 252: ...13 SHIFT ROTATE INSTRUCTIONS 13 8 FC4A MICROSMART USER S MANUAL ...
Page 274: ...15 WEEK PROGRAMMER INSTRUCTIONS 15 8 FC4A MICROSMART USER S MANUAL ...
Page 378: ...22 DUAL TEACHING TIMER INSTRUCTIONS 22 4 FC4A MICROSMART USER S MANUAL ...
Page 386: ...23 INTELLIGENT MODULE ACCESS INSTRUCTIONS 23 8 FC4A MICROSMART USER S MANUAL ...
Page 408: ...24 ANALOG I O CONTROL 24 22 FC4A MICROSMART USER S MANUAL ...
Page 426: ...26 COMPUTER LINK COMMUNICATION 26 6 FC4A MICROSMART USER S MANUAL ...