|
|
DataMuseum.dkPresents historical artifacts from the history of: Rational R1000/400 |
This is an automatic "excavation" of a thematic subset of
See our Wiki for more about Rational R1000/400 Excavated with: AutoArchaeologist - Free & Open Source Software. |
top - metrics - download
Length: 5120 (0x1400)
Types: Ada Source
Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Com_Cl35_2, seg_051d49
└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
└─⟦5a81ac88f⟧ »Space Info Vol 1«
└─⟦this⟧
with Connexion_Serie;
with Driver_Serie;
package body Com_Cl35_2 is
package Gd renames General_Defs;
package Port_A is new Connexion_Serie (No_Port => General_Defs.Port_A);
Debut_Trame : constant Gd.Byte := 16#01#;
Fin_Trame_1 : constant Gd.Byte := 16#F1#;
Fin_Trame_2 : constant Gd.Byte := 16#F2#;
Taille_Max_Bstring : constant Natural := 250;
procedure Emission (B : General_Defs.Byte) is
begin
Port_A.Ecrire (B);
end Emission;
procedure Ecriture (Bs : General_Defs.Byte_String) is
begin
Emission (Debut_Trame);
for I in Bs'Range loop
Emission (Bs (I));
end loop;
Emission (Fin_Trame_1);
Emission (Fin_Trame_2);
end Ecriture;
function Lecture return General_Defs.Byte_String is
use Gd;
Bs : Gd.Byte_String (1 .. Taille_Max_Bstring);
F1, F2 : Gd.Byte;
I : Natural := Bs'First - 1;
begin
Driver_Serie.Interface_Serie.Validation_It
(Sorte => Driver_Serie.Interface_Serie.Pas_It);
if Port_A.Lire = Debut_Trame then
F1 := Port_A.Lire;
F2 := Port_A.Lire;
while (F1 /= Fin_Trame_1) and (F2 /= Fin_Trame_2) loop
I := I + 1;
if I > Taille_Max_Bstring then
raise Com_Cl35_Error;
end if;
Bs (I) := F1;
F1 := F2;
F2 := Port_A.Lire;
end loop;
else
raise Com_Cl35_Error;
end if;
Driver_Serie.Interface_Serie.Validation_It
(Sorte => Driver_Serie.Interface_Serie.R_Ab);
return Bs (Bs'First .. I);
end Lecture;
begin
Port_A.Configure (General_Defs.Bd9600, General_Defs.None, 8, 2);
end Com_Cl35_2;
nblk1=4
nid=2
hdr6=4
[0x00] rec0=25 rec1=00 rec2=01 rec3=004
[0x01] rec0=1a rec1=00 rec2=04 rec3=000
[0x02] rec0=01 rec1=00 rec2=02 rec3=000
[0x03] rec0=03 rec1=00 rec2=03 rec3=000
tail 0x2154b6a78879c58f6d142 0x42a00088462060003
Free Block Chain:
0x2: 0000 00 03 00 03 00 00 00 01 00 00 00 00 00 00 20 20 ┆ ┆
0x3: 0000 00 00 00 03 00 00 00 65 67 69 6e 05 00 34 20 20 ┆ egin 4 ┆