sub_fpwm_set

Top  Previous  Next
Got to SUB-20 page

Synopsis

int sub_fpwm_set( sub_handle hndl, int pwm_n, double duty )

 

Configure specific fast PWM output.

Parameters

pwm_n - number of FPWM output to configure. Can be 0,1,2

duty - desired duty cycle % in range 0..100. Can be not integer.

Return value

On success function returns 0. Otherwise error code.

Example

sub_fpwm_set( hndl, 0, 20 );

sub_fpwm_set( hndl, 1, 30.5 );

sub_fpwm_set( hndl, 2, 12.25 );

See also

sub_fpwm_config

Error Codes