17.02.2015 Views

CCS C Compiler Manual PCB / PCM / PCH

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Built-in Functions<br />

Examples:<br />

Example Files:<br />

Also See:<br />

setup_cog(COG_ENABLED | COG_PWM | COG_FALLING_SOURCE_PWM3 |<br />

COG_RISING_SOURCE_PWM3, COG_NO_AUTO_SHUTDOWN,<br />

COG_PULSE_STEERING_A | COG_PULSE_STEERING_B);<br />

None<br />

set_cog_dead_band(), set_cog_phase(), set_cog_blanking(), cog_status(), cog_re<br />

setup_cwg( )<br />

Syntax:<br />

setup_cwg(mode,shutdown,dead_time_rising,dead_time_falling)<br />

mode- the setup of the CWG module. See the device's .h file for all option<br />

Some typical options include:<br />

<br />

<br />

<br />

<br />

CWG_ENABLED<br />

CWG_DISABLED<br />

CWG_OUTPUT_B<br />

CWG_OUTPUT_A<br />

Parameters:<br />

shutdown- the setup for the auto-shutdown feature of CWG module.<br />

See the device's .h file for all the options. Some typical options include:<br />

CWG_AUTO_RESTART<br />

CWG_SHUTDOWN_ON)COMP1<br />

CWG_SHUTDOWN_ON_FLT<br />

CWG_SHUTDOWN_ON_CLC2<br />

dead_time_rising- value specifying the dead time between A and B on th<br />

rising edge. (0-63)<br />

dead_time_rising- value specifying the dead time between A and B on th<br />

falling edge. (0-63)<br />

Returns:<br />

Function:<br />

Availability:<br />

Examples:<br />

undefined<br />

Sets up the CWG module, the auto-shutdown feature of module and the ri<br />

and falling dead times of the module.<br />

All devices with a CWG module.<br />

setup_cwg(CWG_ENABLED|CWG_OUTPUT_A|CWG_OUTPUT_B|<br />

CWG_INPUT_PWM1,CWG_SHUTDOWN_ON_FLT,60,30);<br />

287

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!