close

Вход

Забыли?

вход по аккаунту

?

Отчет(10)

код для вставкиСкачать
 ???? ??????: ???????? ????????? ??????, ?????????? ? ???? ???????? ??????????? ? ?????????? IDE. ????????? IDE
IDE - Integrated Drive Electronics (?????????? ?? ?????????? ????????????)
ATA - AT Attachment 1986 -1990?. C??????? ???????? ?3?10
PATA - Parallel ATA
IDE ???????????? ??? ??????????? ?? ????? 2 ??????, ?? ?????? ????? ? ????? 2, ?.?. ???? 2 ?? 2 . ??????????? ?????? ??????????? ?? ????? ?????, ? ?????????? ??????????? ????????????.
????????? ?????????? (CHS). ????? ????????? ????????? ?????????? ?? 137 ?? (65536(?????????)?16(???????)?255(????????)?512)=137 ??
???????? ????????? ?????????? ?????? (LBA). ????? ????? - 28-?????? ?????. ? ???????? D/H ?????? ??? L ?????????? ??? ?????????.
?????????? ????????? ??????? ?????? TLL:
U???"1" � 2,4 ?, U???"0" � 0,5?
U??"1" � 2,0 ?, U??"0" � 0,8?
???????:
40 ????????? - SFF 8057
4 ???????? - min+12B
2,3 ???????? - +5?
??? Ultra DMA - 80-?????????? ??????
??? ?????????????? ????????? - ???????????? 50-?????????? ?????? SFF8212
???????? ???????? ???? ?????? ??????? ????????? ??????????, ????????? ???????? ???? (BSY-??? ? ???????? ?????????). ???? ??? ?????????? ??????????????, ?? ? ????? ??????????. ????????? ????? ??????????? ?????????? ?????????? ??????????.
?????????? ???????????? ??????????, ???? ?????????? ? ??????? D/H ????, ? ???????? ???? ??? DEV ? ?? ????????? ?? ?????????? ??????????. ???? DEV=0, ?? ??? ??????? ??????????, ???? DEV=1, ?? ??? ???????.
???? ?????? ???????? ??? ?????????????? ??????? ????????? ??????????? ??????????. DRDY=1 - ??????? ??????????.
???? ??????? ????????? ????????? ?????? ? ???? ????????? ?????????.
???? ?????????? ??? ??????????? ??????? ? ??????? ??????
?????????? ????????????? ??? BSY=1 ? ????????? ? ?????????? ???????.
????????? ??? ????? ????????? ??????? ????????, ????????????? ??????????.
????? U???. , ??/? ??? ?????????? PIO mode
0
3
4 3.3
16.6 ATA
ATA-2
FAST ATA-2 Single word DMA mode
0
1
2 2.08
8.33 ATA
ATA
ATA Multi word mode
0
1
2 4.16
16.66 ATA-2
ATA-2
FAST AT-A2 Ultra DMA mode
0
1
2
3
4
5 16.6
100 ATA/ATAPI-4
ATA/ATAPI-6 ????????? ?????? ?????????? ? ?????? ?????? ??????? ???????? ?????
program write_sector;
uses dos;
type address_packet=record packet_size:byte; reserved0:byte; blocks_to_transfer:byte; reserved1:byte; host_buffer:pointer; lba_address:array[0..7] of byte; end;
var
addr:address_packet; buffer:array[0..511] of byte; to_write:string; i:word; disk_number:byte; r:registers; begin
disk_number:=1; writeln('Enter string to write:'); readln(to_write); for i:=1 to length(to_write) do buffer[i-1]:=ord(to_write[i]); addr.packet_size:=sizeof(addr); addr.blocks_to_transfer:=1; addr.host_buffer:=@buffer; for i:=0 to 7 do addr.lba_address[i]:=0; r.ah:=$43; r.dl:=$80+disk_number; r.ds:=seg(addr); r.si:=ofs(addr); intr($13,r); if r.ah <> $00 then
begin writeln('Error: ',r.ah); exit; end;
end.
????????? ?????? ??????????
program read_sector;
uses dos;
type address_packet=record packet_size:byte; reserved0:byte; blocks_to_transfer:byte; reserved1:byte; host_buffer:pointer; lba_address:array[0..7] of byte; { ????? LBA }
end;
var
addr:address_packet; buffer:array[0..511] of byte; i,j:word; cur_byte,disk_number:byte; r:registers; begin
disk_number:=1; addr.packet_size:=sizeof(addr); addr.blocks_to_transfer:=1; addr.host_buffer:=@buffer; for i:=0 to 7 do addr.lba_address[i]:=0; r.ah:=$42; r.dl:=$80+disk_number; r.ds:=seg(addr); r.si:=ofs(addr); intr($13,r); if r.ah <> $00 then begin writeln('Error: ',r.ah); exit; end;
for i:=0 to 15 do begin
write(i*16,': '); for j:=0 to 15 do begin
cur_byte:=buffer[i*16+j]; if cur_byte < 32 then write('_') else write(chr(cur_byte)); end;
writeln; end;
end.
????????? ????????? ?????????? ??????????
program disk_information;
uses dos;
type disk_info=record size:word; information_flags:word; num_of_cyl:longint; num_of_heads:longint; num_of_sec_pt:longint; num_of_sec:array[0..7] of byte; bytes_in_sec:word; dpte_addr:pointer; dpi:word; dpi_len:byte; reserved0:byte; reserved1:word; bus_type:array[0..3] of char; interface_type:array[0..7] of char; interface_path:array[0..7] of byte; device_path:array[0..15] of byte; reserved3:byte; dpi_csum:byte; end;
var
info:disk_info; r:registers; disk_number:byte; begin
disk_number:=0; info.size:=sizeof(info); r.ah:=$48; r.dl:=$80+disk_number; r.ds:=seg(info); r.si:=ofs(info); intr($13,r); if r.ah <> $00 then begin writeln('Error: ',r.ah); exit; end;
writeln('Cyls: ',info.num_of_cyl); writeln('Heads: ',info.num_of_heads); writeln('Sectors per track: ',info.num_of_sec_pt);
writeln('Bytes in sector: ',info.bytes_in_sec); writeln('Host bus type: ',info.bus_type); writeln('Interface type: ',info.interface_type); end.
Документ
Категория
Без категории
Просмотров
7
Размер файла
19 Кб
Теги
отчет
1/--страниц
Пожаловаться на содержимое документа