Rabbit Semiconductor 101-0505 Datasheet


Add to my manuals
108 Pages

advertisement

Rabbit Semiconductor 101-0505 Datasheet | Manualzz

D.2 Digital I/O (OP68xx.LIB) int digIn(int channel);

Reads the state of an input channel.

A runtime error will occur if

brdInit

was not executed before executing

digIn

, or when

channel

is out of range.

PARAMETER channel

is the input channel number (0–12), where IN00–IN12 are the normal user digital inputs.

RETURN VALUE

The state of the input (0 or 1).

SEE ALSO brdInit, digOut, ledOut

void digOut(int channel, int value);

Sets the state of a digital output (

OUT00–OUT10)

.

Remember to call the

brdInit

function before executing this function.

A runtime error will occur if

brdInit

was not executed before executing

digOut

, or when

channel

or

value

is out of range.

NOTE: The LEDs and digital outputs OUT00–OUT06 are driven by the same driver chip. Do not use both

ledOut

and

digOut

to control the same LED or digital output in a given application.

PARAMETERS channel

is the output channel number (0–10).

value

is the output value (0 or 1).

SEE ALSO brdInit, digIn, ledOut

User’s Manual 71

advertisement

Was this manual useful for you? Yes No
Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Related manuals

advertisement

Table of contents