17.02.2015 Views

CCS C Compiler Manual PCB / PCM / PCH

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

output_x( )<br />

Syntax:<br />

Parameters:<br />

Returns:<br />

Function:<br />

Availability:<br />

Requires:<br />

Examples:<br />

Example Files:<br />

Also See:<br />

output_a (value)<br />

output_b (value)<br />

output_c (value)<br />

output_d (value)<br />

output_e (value)<br />

output_f (value)<br />

output_g (value)<br />

output_h (value)<br />

output_j (value)<br />

output_k (value)<br />

value is a 8 bit int<br />

undefined<br />

Output an entire byte to a port. The direction register is changed in accordance<br />

with the last specified #USE *_IO directive.<br />

All devices, however not all devices have all ports (A-E)<br />

Nothing<br />

OUTPUT_B(0xf0);<br />

ex_patg.c<br />

input(), output_low(), output_high(), output_float(), output_bit(), #USE<br />

FIXED_IO, #USE FAST_IO, #USE STANDARD_IO, General Purpose I/O<br />

output_bit( )<br />

Syntax:<br />

Parameters:<br />

output_bit (pin, value)<br />

Pins are defined in the devices .h file. The actual number is a bit address. For<br />

example, port a (byte 5 ) bit 3 would have a value of 5*8+3 or 43 . This is<br />

defined as follows: #define PIN_A3 43 . The PIN could also be a variable.<br />

The variable must have a value equal to one of the constants (like PIN_A1) to<br />

work properly. The tristate register is updated unless the FAST_IO mode is<br />

set on port A. Note that doing I/O with a variable instead of a constant will<br />

226

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

Saved successfully!

Ooh no, something went wrong!