DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦496a42327⟧ Ada Source

    Length: 5120 (0x1400)
    Types: Ada Source
    Notes: 03_class, FILE, R1k_Segment, e3_tag, package body Test_Desa, seg_02100e

Derivation

└─⟦8527c1e9b⟧ Bits:30000544 8mm tape, Rational 1000, Arrival backup of disks in PAM's R1000
    └─ ⟦5a81ac88f⟧ »Space Info Vol 1« 
        └─⟦this⟧ 

E3 Source Code



with Text_Io;
with Z80_Defs;
with Desassembleur;
with Octet;

package body Test_Desa is

    -- VARIABLES ----------------------------------------------------------

    Fin : Boolean := False;


    -- PROCEDURES ---------------------------------------------------------


    function Lire_Clavier return Octet.T_Octet is
        Resultat : Octet.T_Octet := 0;
        Chaine_Lue : String (1 .. 2);

    begin

        Text_Io.Put (">");  
        Text_Io.Get (Chaine_Lue);
        case Chaine_Lue (1) is
            when '0' .. '9' =>
                Resultat := Character'Pos (Chaine_Lue (1)) -
                               Character'Pos ('0');
            when 'a' .. 'f' =>
                Resultat := Character'Pos (Chaine_Lue (1)) -
                               Character'Pos ('a') + 10;
            when 'A' .. 'F' =>
                Resultat := Character'Pos (Chaine_Lue (1)) -
                               Character'Pos ('A') + 10;
            when others =>
                Fin := True;
        end case;
        Resultat := Resultat * 16;

        case Chaine_Lue (2) is
            when '0' .. '9' =>
                Resultat := Resultat + Character'Pos (Chaine_Lue (2)) -
                               Character'Pos ('0');
            when 'a' .. 'f' =>
                Resultat := Resultat + Character'Pos (Chaine_Lue (2)) -
                               Character'Pos ('a') + 10;
            when 'A' .. 'F' =>
                Resultat := Resultat + Character'Pos (Chaine_Lue (2)) -
                               Character'Pos ('A') + 10;
            when others =>
                Fin := True;
        end case;

        Text_Io.Put ("valeur lue en decimal : ");
        Text_Io.Put_Line (Integer'Image (Resultat));
        return Resultat;

    end Lire_Clavier;


    ------------------------------------------------

    procedure Afficher_Instruction (Instruc : Desassembleur.Instruction) is
    begin  
        Text_Io.Put_Line ("");
        Text_Io.Put (Desassembleur.Mnemonic'Image (Instruc.Mnemo));
        Text_Io.Put ("   ");
        Text_Io.Put (Z80_Defs.Operande'Image (Instruc.Op_Gauche));
        Text_Io.Put (" , ");
        Text_Io.Put (Z80_Defs.Operande'Image (Instruc.Op_Droit));
        --  Text_Io.Put (Integer'Image (Instruc.Donnee));
        Text_Io.Put (Z80_Defs.Mot'Image (Instruc.Donnee));
        Text_Io.Put ("     taille:");
        Text_Io.Put (Integer'Image (Instruc.Taille));
        Text_Io.Put_Line ("");
    end Afficher_Instruction;

    --------------------------------------------

    procedure Je_Teste_Le_Desa is
        Val_Lue : Octet.T_Octet := 0;
    begin
        while (not Fin) loop
            if (Desassembleur.Traiter_Code (Lire_Clavier)) then

                Afficher_Instruction (Desassembleur.Instruction_Trouvee);
            end if;

        end loop;

    end Je_Teste_Le_Desa;



end Test_Desa;

E3 Meta Data

    nblk1=4
    nid=0
    hdr6=8
        [0x00] rec0=22 rec1=00 rec2=01 rec3=070
        [0x01] rec0=1d rec1=00 rec2=03 rec3=07e
        [0x02] rec0=1f rec1=00 rec2=02 rec3=000
        [0x03] rec0=02 rec1=00 rec2=04 rec3=000
    tail 0x2151c8612838d4cb34f5f 0x42a00088462060003