TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: David Hare-Scott
from: Andrew MacIntyre
date: 1995-10-21 11:35:30
subject: Physical add. in Windows

On Oct 19 1995 (09:40), David Hare-Scott of 3:712/505 wrote:

DH> Here is one method from the MS KB article. >

DH> Method 1: Exported Selectors (Preferred)
DH> ----------------------------------------

DH> The Windows 3.0 and 3.1 Kernels export several selectors 
DH> that should
DH> be used by applications that require access to physical 
DH> memory located
DH> below the 1 megabyte (MB) boundary. The exported selectors 
DH> are:

DH>    __0000h, __0040h, __A000h, __B000h, __B800h, __C000h, 
DH> __D000h,
DH>    __E000h, and __F000h

DH> To use one of these selectors, place it onto a segment 
DH> register and
DH> access the memory or create a long pointer. Here are 
DH> examples using
DH> the Microsoft Macro Assembler (MASM) and Microsoft C:

DH>    In ASM:       externA  __0040h
DH>                  ...
DH>                  mov ax, __0040h
DH>                  mov es, ax


DH>    In C:         extern   WORD _0040h;
DH>                  LPSTR    lpBIOSDataArea;
DH>                  ...
DH>                  /* Note the & and single underscore */
DH>                  lpBIOSDataArea = (LPSTR)MAKELONG(0, 
DH> &_0040h);

DH> >
DH> My compiler knows nothing about the symbols __0040, _0040, 
DH> _0040h etc
DH> The second method is much longer and more complex.

You are including windows.h aren't you?

Regards, Andrew.

@EOT:

--- Msgedsq/2 3.05
* Origin: What a Coherent Point! Canberra, Oz (3:620/243.18)
SEEN-BY: 50/99 620/202 243 250 252 623/630 711/401 409 410 413 430 510 807
SEEN-BY: 711/808 809 932 934 712/515 713/888 714/906 800/1 7877/2809
@PATH: 620/243 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.