国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > Delphi > 正文

變速齒輪Delphi實現(xiàn)

2019-11-18 18:02:59
字體:
來源:轉載
供稿:網(wǎng)友
{D7+Win98,不能用于2000}
unit MainUnit;

interface

uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;

type
TForm1 = class(TForm)
Button1: TButton;
Button2: TButton;
Button3: TButton;
PRocedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;

var
Form1: TForm1;

implementation

{$R *.dfm}
procedure speed(count:Word);stdcall;
const
ExceptionUsed=$03;
var
IDT:array [0..5]of byte;
lpOldGate:dword;
begin
asm
sidt IDT
mov ebx,dword ptr [IDT+2]
add ebx,8*ExceptionUsed
cli
mov dx,word ptr [ebx+6]
shl edx,16d
mov dx,word ptr [ebx]
mov [lpOldGate],edx
mov eax,offset @@Ring0Code
mov word ptr [ebx],ax
shr eax,16d
mov word ptr [ebx+6],ax
int ExceptionUsed
mov ebx,dword ptr[IDT+2]
add ebx,8*ExceptionUsed
mov edx,[lpOldGate]
mov word ptr [ebx],dx
shr edx,16d
mov word ptr [ebx+6],dx
jmp @@exit


@@Ring0Code:
mov al,$34
out $43,al
mov ax,Count
out $40,al
mov al,ah
out $40,al
iretd
@@exit:
end;

end;

procedure TForm1.Button1Click(Sender: TObject);
begin
speed($6000);//慢
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
Speed($1044);
end;

procedure TForm1.Button3Click(Sender: TObject);
begin
speed($500);
end;

end.


上一篇:SQL在Delphi數(shù)據(jù)庫程序設計應用淺談

下一篇:Delphi控件制作技巧[二]

發(fā)表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發(fā)表
學習交流
熱門圖片

新聞熱點

疑難解答

圖片精選

網(wǎng)友關注

主站蜘蛛池模板: 康马县| 正安县| 隆子县| 乌拉特后旗| 称多县| 通辽市| 贵州省| 永吉县| 子洲县| 建水县| 乌拉特中旗| 临城县| 鸡东县| 孝昌县| 崇信县| 会理县| 兴义市| 长子县| 静宁县| 黄浦区| 扶风县| 九江县| 英超| 永城市| 怀安县| 常山县| 商洛市| 闸北区| 和林格尔县| 惠水县| 黔南| 张家港市| 香格里拉县| 九台市| 江西省| 蕲春县| 鄂伦春自治旗| 平远县| 卢湾区| 虞城县| 虞城县|