Subversion Repositories svnkaklik

Compare Revisions

Regard whitespace Rev 5 → Rev 6

/programy/delphi/mlzic/Blikac.~pas
0,0 → 1,44
unit Blikac;
 
interface
 
uses PortInc,Windows, Messages, SysUtils, Classes,
Graphics, Controls, Forms, Dialogs, ExtCtrls, StdCtrls;
 
type
TForm1 = class(TForm)
ScrollBar1: TScrollBar; Edit1: TEdit;
Timer1: TTimer;
procedure ScrollBar1Change(Sender: TObject);
procedure FormCreate(Sender: TObject);
procedure Timer1Timer(Sender: TObject);
end;
 
var
Form1: TForm1;
 
implementation
{$R *.DFM}
var Vystup: Integer;
 
procedure TForm1.ScrollBar1Change(Sender: TObject);
begin
Edit1.Text := floattostr(Scrollbar1.Position)+ ' ms';
Timer1.Interval := Scrollbar1.Position
end;
 
procedure TForm1.FormCreate(Sender: TObject);
begin
OpenCom (Pchar('COM2:9600,N,8,1'));
Timer1.Enabled := true;
Vystup := 0;
end;
 
procedure TForm1.Timer1Timer(Sender: TObject);
begin
Vystup := (Vystup + 1) AND 1;
DTR (Vystup);
RTS (Vystup);
end;
 
end.