The 2nd to the 9th pin on the 25pin LPT port has 5v between each one and one of the ground pins : 16-25 if I turn them on. But how can I activate it in Pascal?
In C I can use: outportb(PORT,val); Is there a similar function in Pascal?
: The 2nd to the 9th pin on the 25pin LPT port has 5v between each one and one of the ground pins : 16-25 if I turn them on. But how can I activate it in Pascal? : : In C I can use: outportb(PORT,val); Is there a similar function in Pascal? :
: : The 2nd to the 9th pin on the 25pin LPT port has 5v between each one and one of the ground pins : 16-25 if I turn them on. But how can I activate it in Pascal? : : : : In C I can use: outportb(PORT,val); Is there a similar function in Pascal? : : : : Try : : port[0x378]:=$01; : : \|/// @) : ASHLEY4.
*********************** ///Pascal 1.Mem[seg:off]:=$10; //put data 1 byte to address[seg:off] 2.v1:=MemW[seg:off]; //put data 2 bytes from address[seg:off] to v1 3.v1:=MemL[seg:off]; //put data 4 bytes from address[seg:off] to v1 4.port[No.]:=$10 //put data 1 byte to port number... 5.portw[No.]:=$1234 //put data 2 bytes to port number... ///Delphi sample procedure setdsp(mode : word); assembler; asm mov ax, mode int 10h end;
I've got it working, but forgot to ask how to input data. The lpt port also has pins for paper feed and error... if i want do send data to the computer with them. Do i have to ground them, or put logic 1 (3.5volts) on them? Don't want to blow my motherboard!!!
: ///Delphi sample : procedure setdsp(mode : word); assembler; : asm : mov ax, mode : int 10h : end; : : Ruangroj : :this will crach the computer under w95 w98 and maybe not work under NT this for setting screen mode like setdsp($13); is mode 320x200x256 colours and its for real mode not protected mode or kind of .
you have to be carefuly on sample you send because this one may cause several problems on someone computer.
: I've got it working, but forgot to ask how to input data. The lpt port also has pins for paper feed and error... if i want do send data to the computer with them. Do i have to ground them, or put logic 1 (3.5volts) on them? Don't want to blow my motherboard!!! :
Reasonable concern... Buy extra LPT port or better USB>LPT convertor.
Comments
:
: In C I can use: outportb(PORT,val); Is there a similar function in Pascal?
:
Try
port[0x378]:=$01;
\|///
@)
ASHLEY4.
: :
: : In C I can use: outportb(PORT,val); Is there a similar function in Pascal?
: :
:
: Try
:
: port[0x378]:=$01;
:
: \|///
@)
: ASHLEY4.
***********************
///Pascal
1.Mem[seg:off]:=$10; //put data 1 byte to address[seg:off]
2.v1:=MemW[seg:off]; //put data 2 bytes from address[seg:off] to v1
3.v1:=MemL[seg:off]; //put data 4 bytes from address[seg:off] to v1
4.port[No.]:=$10 //put data 1 byte to port number...
5.portw[No.]:=$1234 //put data 2 bytes to port number...
///Delphi sample
procedure setdsp(mode : word); assembler;
asm
mov ax, mode
int 10h
end;
Ruangroj
: procedure setdsp(mode : word); assembler;
: asm
: mov ax, mode
: int 10h
: end;
:
: Ruangroj
:
:this will crach the computer under w95 w98 and maybe not work under NT
this for setting screen mode like
setdsp($13); is mode 320x200x256 colours and its for real mode not protected mode or kind of .
you have to be carefuly on sample you send because this one may
cause several problems on someone computer.
Just Dont try it.
:
:
:
:
:
:
Reasonable concern... Buy extra LPT port or
better USB>LPT convertor.
Iby