11.07.2015 Views

PICBASIC PLUS LITE Manual - Profe Saul

PICBASIC PLUS LITE Manual - Profe Saul

PICBASIC PLUS LITE Manual - Profe Saul

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>PICBASIC</strong> <strong>PLUS</strong> Compiler5.43. OUTPUTSyntax :Overview :Operators :OUTPUT Port . PinMakes the specified Pin an output.Port.Pin must be a Port.Pin constant declaration.Example : OUTPUT PortA.0 ‘ Make bit-0 of PortA an outputNotes :An Alternative method for making a particular pin an output is by directlymodifying the TRIS: -TRISB.0 = 0‘ Set PORTB, bit-0 to an outputThe above method is quicker, and produces less code than the OUT-PUT command.All of the pins on a port may be set to output by setting the wholeTRIS register at once: -TRISB = %00000000‘ Set all of PORTB to outputsIn the above examples, setting a TRIS bit to 0 makes the pin an output,and conversely, setting the bit to 1 makes the pin an input.85Copyright Crownhill 2001

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

Saved successfully!

Ooh no, something went wrong!