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.

Availability:<br />

Requires:<br />

Examples:<br />

Example Files:<br />

Also See:<br />

All devices<br />

Constants are defined in the devices .h file.<br />

setup_counters (RTCC_INTERNAL, WDT_2304MS);<br />

None<br />

setup wdt(), setup_timer 0(), see header file for device selected<br />

setup_cog( )<br />

Syntax:<br />

setup_cog(mode, [shutdown]);<br />

setup_cog(mode, [shutdown], [sterring]);<br />

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

Some typical options include:<br />

<br />

<br />

<br />

<br />

COG_ENABLED<br />

COG_DISABLED<br />

COG_CLOCK_HFINTOSC<br />

COG_CLOCK_FOSC<br />

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

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

Parameters:<br />

<br />

<br />

<br />

COG_AUTO_RESTART<br />

COG_SHUTDOWN_ON_C1OUT<br />

COG_SHUTDOWN_ON_C2OUT<br />

steering- optional parameter for steering the PWM signal to COG output pins and<br />

the COG pins static level. Used when COG is set for steered PWM or synchronou<br />

PWM modes. Not available on all devices, see the device's .h file if available and<br />

Some typical options include:<br />

COG_PULSE_STEERING_A<br />

COG_PULSE_STEERING_B<br />

COG_PULSE_STEERING_C<br />

COG_PULSE_STEERING_D<br />

Returns:<br />

Function:<br />

Availability:<br />

undefined<br />

Sets up the Complementary Output Generator (COG) module, the auto-shutdown<br />

the module and if available steers the signal to the different output pins.<br />

All devices with a COG module.<br />

286

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

Saved successfully!

Ooh no, something went wrong!