TEAM-ADA Archives

Team Ada: Ada Programming Language Advocacy

TEAM-ADA@LISTSERV.ACM.ORG

Options: Use Classic View

Use Monospaced Font
Show HTML Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Fortier Andres <[log in to unmask]>
Thu, 2 Mar 2000 00:26:36 -0300
text/plain (658 bytes) , text/html (4 kB)
HI,
   this is the code I wrote to hook to the keyboard interrupt with an entry call:

task X is
    Entry Foo;
    for Foo use at To_Address(16#9#);
end X;

task Body X is
begin
  loop
    Accept Foo do
       Put_Line("PPPPP");
       end Foo;
  end loop;
end X;

As the LRM said that we sholud provide the interrupt number, I put int. number 9.
(this number would work just fine if you use the setvect function in C)
Now the output I get is PPPPP
                        PPPPP
                        .
                        .
                        .
                        PPPPP
                        PPPPP
and so on.
What is wrong??
By the way, I'm using GW-GNAT 310.

Thanks in advance,
                  Chalito


ATOM RSS1 RSS2