PINMAP | ||
Bit/Byte | CCS PICC Specific code | Pinmap useage |
Byte | OUTPUT_B(0x77); | blat = (0x77); |
bpin = (0x77); | ||
variable = INPUT_B(); | variable = bpin; | |
variable = blat; | ||
bdir = 0x00; | ||
bdir = 0xff; | ||
Bit | OUTPUT_HIGH(PIN_B3); | b3pin = 1; |
b3lat = 1; | ||
OUTPUT_LOW(PIN_B3); | b3pin = 0; | |
b3lat = 0; | ||
OUTPUT_BIT(PIN_B3,variable); | b3pin = variable; | |
b3lat = variable; | ||
OUTPUT_TOGGLE(PIN_B3); | b3pin ^= 0x08; | |
b3lat ^= 0x08; | ||
OUTPUT_DRIVE(PIN_B3); | b3dir = 0; | |
OUTPUT_FLOAT(PIN_B3); | b3dir = 1; | |
For PICs without separate latch registers, __pin and __lat will operate on the same register during writes. |
Any questions or comments?
This page last updated on
September 04, 2011