begin
BitBtn1.Enabled := True;
BitBtn2.Enabled := False;
end;
end.
Ім'я данного файлу : Unit3.pas
Функціональне призначення : програмне забеспечення ПК, модуль головного вікна ВВК
Файл створений для дипломного проекта захисту кваліфікації фахівця
За фахом : Системне програмування;
Тема проекту : Віртуальний вимірювальний комплекс на базі учбового лабораторного стенду;
Керівник : М.В. Скородєлов, викладач кафедри ОТП;
Розробник : О.О. Ісмаілов, студент групи КІТ-23а;
Рік розробки : 2009.
unit Unit3;
interface
uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, Buttons;
type TForm3 = class(TForm)
BitBtn1: TBitBtn;
BitBtn2: TBitBtn;
BitBtn3: TBitBtn;
BitBtn4: TBitBtn;
Label1: TLabel;
procedure BitBtn1Click(Sender: TObject);
procedure BitBtn2Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
var Form3: TForm3;
implementation
uses Unit1, Unit2;
{$R *.dfm}
procedure TForm3.BitBtn1Click(Sender: TObject);
Form1.Visible := True;
procedure TForm3.BitBtn2Click(Sender: TObject);
Form2.Visible := true;
Ім'я данного файлу : main.asm
Функціональне призначення : програмне забеспечення ПК, модуль логічного аналізатора
#include <m8515def.inc>
.def tmp = r16
.def tmp1 = r17
.def RX_flag = r18
.def RX_Counter = r19
.def RX_Complete = r20
.def command = r21
.def tmp2 = r22
.def tmp3 = r23
.equ UC_REG = 0xC000
.equ RX_Buffer = 0x7C00
.macro USART_TRANSMITT_M
utm_l0:
wdr
sbis UCSRA, UDRE
rjmp utm_l0
out UDR, tmp
.endm
.macro WAIT_PUSK
mov tmp, command
andi tmp, 0b00010000
brne wp_l5
andi tmp, 0b00001110
lsr tmp
ldi tmp1, 1
wp_l0:
cpi tmp, 0
breq wp_l1
lsl tmp1
dec tmp
brne wp_l0
wp_l1:
andi tmp, 0b00000001
brne wp_l2
wp_l3:
in tmp2, PINB
and tmp2, tmp1
brne wp_l3
wp_l4:
breq wp_l4
rjmp wp_l5
wp_l2:
breq wp_l2
wp_l6:
brne wp_l6
wp_l5:
.macro ANALYZE_CLK_6
ac6_l0:
in tmp, PINB // 1 cycle
st Y+, tmp // 2 cycle
dec tmp3 // 1 cycle
brne ac6_l0 // 2 cycles or
// 1 cycle
ac6_l1:
brne ac6_l1 // 2 cycles
dec tmp3
.macro ANALYZE_CLK_8
ac8_l0:
nop // +2 cyle
nop
brne ac8_l0 // 2 cycles or
ac8_l1:
brne ac8_l1 // 2 cycles
.macro ANALYZE_CLK_16
ac16_l0:
ldi tmp1, 3 // +10 cyle
ac16_l2:
dec tmp1
brne ac16_l2
brne ac16_l0 // 2 cycles or
ac16_l1:
ac16_l3:
brne ac16_l3
brne ac16_l1 // 2 cycles
.macro ANALYZE_CLK_32
ac32_l0:
ldi tmp1, 8 // +26 cyle
ac32_l2:
brne ac32_l2
brne ac32_l0 // 2 cycles or
ac32_l1:
ac32_l3:
brne ac32_l3
brne ac32_l3 // 2 cycles
.macro ANALYZE_CLK_64
ac64_l0:
ldi tmp1, 19 // +58 cyle
ac64_l2:
brne ac64_l2
brne ac64_l0 // 2 cycles or
ac64_l1:
ac64_l3:
brne ac64_l3
brne ac64_l1 // 2 cycles
.macro ANALYZE_CLK_128
ac128_l0:
ldi tmp1, 40 // +122 cyle
ac128_l2:
brne ac128_l2
brne ac128_l0 // 2 cycles or
ac128_l1:
ac128_l3:
Страницы: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21