comp.lang.ada
 help / color / mirror / Atom feed
From: "Stephane Richard" <stephane.richard@verizon.net>
Subject: Re: Low Level Ada
Date: Thu, 20 Nov 2003 02:32:17 GMT
Date: 2003-11-20T02:32:17+00:00	[thread overview]
Message-ID: <RIVub.53110$bQ3.44966@nwrdny03.gnilink.net> (raw)
In-Reply-To: Y1Pub.185870$mZ5.1346044@attbi_s54

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1154 bytes --]

How about if I want to call an interrupt in Ada?

Say Interrupt 10h to set the video mode to 132x50 (mode 10Ah on a vesa/bde
standard video card) for example.


-- 
St�phane Richard
"Ada World" Webmaster
http://www.adaworld.com


<tmoran@acm.org> wrote in message news:Y1Pub.185870$mZ5.1346044@attbi_s54...
> > For instance, let's say I want to create an Array that would hold
characters
> > with the goal to send it to the video card directly (address $B800).
>    You can use an address clause to put an object (eg an array) anywhere
> and then just do normal assignment operations.  So if you declare
>   type Display_Strings is array(Integer range <>) of Char_Attribute_Pairs;
>   Screen : Display_Strings(1 .. 24*80);
>   for Screen'address use 16#B800#;
> you can
>   Screen(1) := ('a',Blinking);
> or
>   Screen(Start .. Start+Last-1) := Work_Buffer(1 .. Last);
> Note of course that if you are running on a Windows machine 16#B800# is
> a virtual memory address, not a hardware one.  In that case you would
need:
>   Video_Memory_Address: constant System.Address :=
Beg_Of_Windows(16#B800);
>   for Screen'address use Video_Memory_Address;





  reply	other threads:[~2003-11-20  2:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-11-19 13:43 Low Level Ada Stephane Richard
2003-11-19 18:40 ` Jeffrey Carter
2003-11-19 18:47 ` Jim Rogers
2003-11-19 18:56 ` tmoran
2003-11-20  2:32   ` Stephane Richard [this message]
2003-11-20  5:39     ` tmoran
     [not found]     ` <m2vfpfgsnt.fsf@jvdsys.demon.nl>
2003-11-20 12:20       ` Stephane Richard
2003-11-19 23:37 ` Freejack
2003-11-20 13:09 ` Marin David Condic
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox