|
@@ -47,38 +47,31 @@ var
|
|
portw : tportw;
|
|
portw : tportw;
|
|
portl : tportl;
|
|
portl : tportl;
|
|
|
|
|
|
-function inportb(port : word) : byte;[internproc:fpc_in_x86_inportb];
|
|
|
|
-function inportw(port : word) : word;[internproc:fpc_in_x86_inportw];
|
|
|
|
-//function inportl(port : word) : longint;[internproc:fpc_in_x86_inportl];
|
|
|
|
-procedure outportb(port : word;data : byte);[internproc:fpc_in_x86_outportb];
|
|
|
|
-procedure outportw(port : word;data : word);[internproc:fpc_in_x86_outportw];
|
|
|
|
-//procedure outportl(port : word;data : longint);[internproc:fpc_in_x86_outportl];
|
|
|
|
-
|
|
|
|
implementation
|
|
implementation
|
|
|
|
|
|
{ to give easy port access like tp with port[] }
|
|
{ to give easy port access like tp with port[] }
|
|
|
|
|
|
procedure tport.writeport(p : word;data : byte);inline;
|
|
procedure tport.writeport(p : word;data : byte);inline;
|
|
begin
|
|
begin
|
|
- outportb(p,data);
|
|
|
|
|
|
+ fpc_x86_outportb(p,data);
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
function tport.readport(p : word) : byte;inline;
|
|
function tport.readport(p : word) : byte;inline;
|
|
begin
|
|
begin
|
|
- readport:=inportb(p);
|
|
|
|
|
|
+ readport:=fpc_x86_inportb(p);
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
procedure tportw.writeport(p : word;data : word);inline;
|
|
procedure tportw.writeport(p : word;data : word);inline;
|
|
begin
|
|
begin
|
|
- outportw(p,data);
|
|
|
|
|
|
+ fpc_x86_outportw(p,data);
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
function tportw.readport(p : word) : word;inline;
|
|
function tportw.readport(p : word) : word;inline;
|
|
begin
|
|
begin
|
|
- readport:=inportw(p);
|
|
|
|
|
|
+ readport:=fpc_x86_inportw(p);
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|