Rpbasic-52 programming guide, Lineb – Remote Processing BASIC 52 User Manual
Page 74

RPBASIC-52 PROGRAMMING GUIDE
2-55
LINEB
(Function)
Syntax:
A = L I N E B (i/o bank,add ress)
Where: i/o bank = 0 to 7. Specific fun ctions are card de pendent. Re fer to your hardw are manu al.
address = device dependent. Usually it is 0 to 3.
Function:
Reads a byte from an I/O device.
Mode:
Comm and, Run
Use:
A = LINEB (3,0) Reads po rt A of 8255 at digita l port.
Cards:
All. i/o bank is unique to each card.
D E S C R IP T I ON
T h i s f u nc t io n is e q ui v al e nt t o I N P in o th e r B A S I C s. D a ta i s r e ad 8 b it s at a ti m e in c o nt r as t to o th e r L I N E
functions which return 1 bit at a time. The i/o bank selects a particular I/O device listed in yo ur hardware
manua l.
Use this command to read devices and obtain data not otherwise available using RPBASIC-52.
RELATED
L I N E , L I N E # ( f un c ti o n) , L I N E , L I N E #, L IN E B ( st a te m e n t) , C O N F I G L IN E
E R R O R
B A D A R G U M E N T i/o bank > 7
EXAMPLE
The follow ing exam ple reads all 8 lines a t port A on the dig ital I/O port.
100 A = LINEB (3,0)