Set PWM #0

\i I P long::freq word::duty_cycle

Parameter Type Range Description
freq¹ long 1 ... 1000000 frequency in Hertz
duty_cycle word 1 ... 9999 duty cycle in units of 0.01%

Configures the PWM 0 (on relay output 0) with the specified parameters.

Note

Response: [ACK]

Example

\iIP\0\L500\D8000

After sending this command, the PWM 0 on relay output 0 is running with 500 Hertz and a duty cycle of 80%. The resulting signal will have a rising edge every 2ms (1/500Hz = 0.002s) and stay high for 1.6ms (80% of 2ms).

See also:

Set PWM #1
Pulse Width Modulation (PWM) Related Commands