TIP: Click on subject to list as thread! ANSI
echo: cis.tandy.coco
to: DENNIS SKALA 73177,2365 (X)
from: Kevin Darling (UG Pres) 76703,4227
date: 1990-07-14 16:54:20
subject: #5162-#Memory Size Testing

#: 5201 S10/Tandy CoCo
    14-Jul-90  16:54:20
Sb: #5162-#Memory Size Testing
Fm: Kevin Darling (UG Pres) 76703,4227
To: DENNIS SKALA 73177,2365 (X)

Dennis -

F$GBlkMp returns the info you need; including the block size, which is needed
if your driver were to work on other OS9 systems.

However, the buffer size required is a lot to ask from system space... and you
said that this was for the coco3 only, so:

Look in the direct page variables, and you can determine where and how big the
block map is.

 $0040-41 D.BlkMap - points to start of block map
 $0042-43 [noname] - points to end of block map + 1

128,256, and 512K coco's will have those set to $0200 and $0240... that is, $40
blocks of RAM. The trick is, the smaller memory machines will have "NotRAM"
($80) bytes set in some of the blockmap. By subtracting out the number of
notram blocks, you can figure up total memory size. The 1024K machines will
have a blockmap size of $80 ($0200-0280).

So: total blocks = [$0042] - [$0040] - (number of blocks in map set to $80).
    total RAM    = total blocks * 8K

Refs: NotRAM defined in os9defs. D.BlkMap on page 2-1-3 my book. Blockmap
example on page 2-1-5 my book. [noname] not defined anywhere .

There are 2 Replies.

SOURCE: compuserve via textfiles.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™.