The oLPT Object uses one I/O Group and two I/O Lines to send data to a printer.
When the oLPT Object's Value property is assigned, the assigned value is sent out the I/O Lines specified by the IOGroup and a data strobe is generated on the I/O Line specified by the IOLineS property.
The IOLineB property specifies which I/O line to read the printer's busy line.
The DIO property is an instance of the oDIO8F object which is created when the oLPT object is. The oLPT object configures the oDIO8F object in such a way that it will provide the proper I/O control of the printer. Changing attributes of the oDIO8F may change the way the printer behaves to something different than the way described in this document. (see oDIO8F object for more detail on how the oDIO8F Object sends data to the printer)
Attributes of the printer's operation can be adjusted by directly manipulating the oDIO8F object, but note that doing so may change the way the printer behaves to something different than the way described in this document.
Address
Returns a pointer to the address of the oCounter Object instance.
'This program sends the line
' "Hello world."
'to a printer.
Dim Lpt1 As New oLPT
Sub Main()
Lpt1.IOGroup = 3
Lpt1.IOLineS = 11
Lpt1.IOLineB = 8
Lpt1.Operate = cvTrue
Do
If Lpt1.IOLineB.IsHigh Then
Lpt1.VString = "Hello world."
Lpt1.Value = 13
Delay = 100
End If
Loop
End Sub
// This program sends the line
// "Hello world."
// to a printer.
oLPT Lpt1 = New oLPT;
Void Main(Void){
Lpt1.IOGroup = 3;
Lpt1.IOLineS = 11;
Lpt1.IOLineB = 8;
Lpt1.Operate = cvTrue;
Do{
If (Lpt1.IOLineB.IsHigh){
Lpt1.VString = "Hello world.";
Lpt1.Value = 13;
Delay = 100;
}
} While (1);
}
Basic Syntax
'This program sends the line
' "Hello world."
'to a printer.
Dim Lpt1 As New oLPT(3,11,8,cvOn)
Do
If Lpt1.IOLineB.IsHigh Then
Lpt1.VString = "Hello world."
Lpt1.Value = 13
Delay = 100
End If
Loop