Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

C Compiler Reference Manual

#USE FIXED_IO
Syntax:

#use fixed_io (port_outputs=pin, pin?)

Elements:

port is A-G, pin is one of the pin constants defined in the


devices .h file.

Purpose:

This directive affects how the compiler will generate code for
input and output instructions that follow. This directive takes
effect until another #use xxx_IO directive is encountered.
The fixed method of doing I/O will cause the compiler to
generate code to make an I/O pin either input or output every
time it is used. The pins are programmed according to the
information in this directive (not the operations actually
performed). This saves a byte of RAM used in standard I/O.

Examples:

#use fixed_io(a_outputs=PIN_A2, PIN_A3)

Example Files:

None

Also See:

#use fast_io, #use standard_io

#USE I2C
Syntax:

#use i2c (options)

Elements:

Options are separated by commas and may be:


MASTER
Set the master mode
SLAVE
Set the slave mode
SCL=pin
Specifies the SCL pin (pin is a bit
address)
SDA=pin
Specifies the SDA pin
ADDRESS=nn
Specifies the slave mode address
FAST
Use the fast I2C specification
SLOW
Use the slow I2C specification
RESTART_WDT
Restart the WDT while waiting in
I2C_READ

66

You might also like