HIGH and LOW in BASIC

Questions about the BASICtools and MakeItC
Post Reply
YahooArchive
Posts: 1463
Joined: Fri Oct 19, 2012 5:11 am

HIGH and LOW in BASIC

Post by YahooArchive » Fri Jan 25, 2013 3:52 pm

These 2 keywords were originally added for compatibility with PBASIC.

From Parallax PBASIC help file:

The HIGH command sets the specified pin to 1 (a +5 volt level) and then sets its
mode to output.

As it turns out the ARMbasic compiler was not doing this, but just setting the
pin high, and not altering the pin direction control.

The ARMbasic compiler has been updated to do this (version 7.43f)

There were some instances of HIGH/LOW used in the BASIClibs, these have been
changed to use OUT.

IN,OUT are the fastest way to change a pin state.

As HIGH,LOW, and IO change the pin direction as well as the state, they are
slower.



Post Reply