Questions tagged [memory-layout]

For questions regarding the layout or mapping of memory in a retrocomputer.

Filter by
Sorted by
Tagged with
57
votes
3answers
14k views

Who set the 640K limit?

We all know that "640K should be enough for everyone". But who actually set this limit? The quote is often attributed to Bill Gates, but it doesn't seem like a decision for an Operating System vendor ...
49
votes
8answers
10k views

Why didn't the 8086 use linear addressing?

The 8086 used a segmented memory architecture where the linear address was computed from a 16-bit segment number and a 16-bit offset. This greatly complicated things from a programming perspective. ...
30
votes
1answer
3k views

Did DOS zero out the BSS area when it loaded a program?

As an example, say we have a DOS MZ EXE file that's around 20 KiB in size. The EXE header contains the value 0x1400 at offset 0x0A indicating that the program is requesting 5,120 paragraphs (or 80 KiB)...
27
votes
3answers
6k views

Why did Intel abandon unified CPU cache?

When Intel introduced the 80486 in 1989, they included their first on-chip cache, ostensibly to compete better with Motorola, who had been including on-chip caches for 5 years (MC68020, 1984). Unlike ...
27
votes
5answers
3k views

Why is the Amiga ROM at a high memory location, and RAM in low memory?

When a 68000 CPU powers up, it reads a few words at memory location zero to get the initial stack pointer and program counter. That suggests to me that a computer system designer would put the system ...
26
votes
2answers
3k views

How did an IBM 5150 with 16KB RAM work?

I keep reading that when it was first released, there was a variant of the IBM PC model 5150 that had only 16KB of RAM installed. From a hardware perspective, this would clearly work - the 5150 ...
21
votes
1answer
3k views

How is memory allocated in Super Mario World?

Super Mario World (SMW) is known to have several bugs relating to re-use of memory for multiple purposes. For example some memory items are used for more than one type of item, and the designers are ...
20
votes
2answers
2k views

How to check the C64 graphics mode used by Maniac Mansion

I have been investigating the MS-DOS port of the C64's Maniac Mansion game. The original MS-DOS port used the C64-specific character map to draw the various backgrounds in the game. I noticed that ...
18
votes
5answers
3k views

Was 1991's Hellcats the first instance of incremental screen updates?

In case you have never seen it, 1991's Hellcats was a seminal release on the Mac. It ran at full 8-bit color and could, on a newish machine, drive three 1024x768 screens at the same time. Nothing on ...
17
votes
7answers
8k views

Did any computer use a 7-bit byte?

In an answer to Why did IBM System 360 have byte addressable RAM I wrote regarding the choice of byte size: 7 bits would be a perfect match for ASCII, but engineers would instinctively recoil from ...
17
votes
4answers
3k views

Why did the TI-99/4 have two databuses?

Wikipedia says on Russian page: Однако к 16-разрядной шине были подключены только 256 байт статической памяти и системное ПЗУ. Остальная память (ОЗУ) и периферийные устройства были 8-разрядными и ...
15
votes
2answers
2k views

How does the Commodore 64 address more than 64 kilobytes of memory?

So, the Commodore 64 has two special registers in locations $00 and $01. By writing to these registers, you can somehow turn on and off the ROMs and other things. The thing that I am not understanding ...
15
votes
1answer
1k views

What are the “ports” used via IN/OUT, vs. the PEEK/POKE address space?

This is something of a followup to How much control of TRS-80 Model III disk drives was possible from its Cassette (ROM) BASIC? but on a more general topic: I know that PEEK and POKE enable direct ...
15
votes
2answers
959 views

What is this code on the zero page that was put there by the BASIC ROM?

(question copied from SO (from the days before RC.SE existed): http://stackoverflow.com/q/31877835/477476) Zero-page memory maps of the PET that I've found claim that the zero page address range$00C2....
14
votes
2answers
3k views

How was a line of Commodore 64 BASIC code stored in its memory?

I am reading up on old C64 stuff and I am using the Vice emulator to play with it. Currently I am studying about how the C64 stored BASIC programs in RAM. This is quite clear (it starts on address $...
14
votes
1answer
751 views

How did the Sideways address space work?

I was researching the BBC Micro when I found the Sideways address space: a 16KiB memory space allowing access to up to 16 16KiB external blocks of ROM (or RAM). But 16 blocks of 16KiB is 256KiB, ...
14
votes
1answer
1k views

What manages Upper Memory Blocks (UMBs) in MS-DOS?

I had always assumed that EMM386.EXE was responsible for managing the Upper Memory Blocks - UMBs - the memory space between 640KiB and 1MiB in real mode x86. For example, on MS-DOS 6.22, help emm386....
14
votes
1answer
795 views

What did POKE 842,13 on Atari do? (Jamming the Return key)

In quite a few programs on Atari, I found the self-programming trick: 10 GRAPHICS 0 : REM clear the screen, enter standard text mode 20 POSITION 2,4 : REM place cursor 4 lines from ...
13
votes
5answers
3k views

Mapping more than 64kb of address space

I'm planning out a 6502 homebrew build but seem to be stuck in the issue of buying parts. My plan is to extend the addressing capabilities of the 6502 by giving myself 64kb of RAM, and another 64kb of ...
13
votes
1answer
3k views

What is this unused memory range in the Game Boy's memory map?

Here is a basic memory map of the Game Boy's 16bit address bus: 0000-3FFF 16KB ROM Bank 00 (in cartridge, fixed at bank 00) 4000-7FFF 16KB ROM Bank 01..NN (in cartridge, switchable bank number) 8000-...
12
votes
2answers
687 views

Why did Amstrad choose such bank combinations for its all-RAM mode in +2A and +3 Spectrum computers?

The +2A and the +3 versions of the ZX Spectrum, made by Amstrad, had a new banking mode, called "special". This banking mode is entered by setting bit 0 of port 1FFD. When active, two bits from this ...
11
votes
3answers
1k views

How can I access/use memory outside of the standard 1 MB address range of MS-DOS?

How do you access more memory (above the 1MB) in DOS if the 640KB of conventional memory are not enough? I have read a lot about this, but I couldn't figure out how to do this in actual code. Is ...
11
votes
1answer
757 views

Why did the Amstrad CPC use a nonlinear screen memory layout?

The screen memory layout on the Commodore 64 in bitmap mode was nonlinear - which incurred a penalty in development time, code size and speed for games using it - because when designing the VIC-II, ...
11
votes
1answer
1k views

Why are some soft switches on the Apple II only triggered with a write?

The Apple II uses memory mapped I/O and soft switches to do many things. One thing has confused me though: why are some soft switches only activated when written to? For example, 80COLON ($C00D) and ...
10
votes
3answers
4k views

Disable memory refresh on Z80

Is there a software method of disabling memory refresh on the Z80? Or would it be acceptable to create a hardware method of disabling the address bus during the refresh cycle? If I switch off the ...
10
votes
3answers
2k views

Why are the PPU registers on the NES mirrored?

The NES Picture Processing Unit has eight memory-mapped registers to the CPU in registers $2000 to $2007. The are incompletely decoded, so they are mirrored every 8 bytes from register $2008 to $...
10
votes
2answers
1k views

Is all 100% of a 64k Apple II memory usable?

Are there any areas of the 64k RAM which are permanently unusable by anything, whether by the built-in monitor ROM or user programs? Looking at $C000-C0FF, this is the "softswitch" area, and as far ...
10
votes
2answers
664 views

Behaviour of $D000-$D3FF section on the C64 during bankswitching

My question is about bankswitching behaviour on the Commodore 64. I'm writing a C64 game for a 16kb cartridge with EXROM and GAME pulled low, so the available bankswitching modes are (according to ...
10
votes
2answers
516 views

Why is the Interrupt Enable Hardware Register in the HRAM area on the Gameboy?

It's something I've always been wondering: Almost all of the hardware registers on the Gameboy are placed between $ff00 and $ff7f (with plenty of gaps and empty space), the HRAM is located between $...
10
votes
1answer
861 views

Amiga 500+ rev8A, 1 MB chip RAM and 0.5 MB slow RAM

I have an 500+ rev8A, I added the missing 0.5 MB RAM and the U32 to the motherboard. I also have 512 KB in the trapdoor. This results in 1.5 MB chip RAM; but I want to have 1 MB chip RAM and 0.5 MB ...
9
votes
5answers
2k views

C64 cartridge emulation with ATmega

As a personal project I had the idea to create a custom cartridge for my Commodore 64 and use an ATmega 1284p microcontroller to emulate eproms and/or custom chips. Basically my idea is similar to ...
9
votes
1answer
685 views

Commodore Plus/4 60671 bytes free - how?

It is widely known that, while the Commodore 64 did indeed provide 64K of RAM for machine code programs, only 38K was usable from BASIC; this was because bank switching was needed to get at the rest, ...
9
votes
2answers
1k views

Unused RAM Chips on x86 machines

On classic x86 machines the upper 384 KB of system memory contains video RAM and BIOS ROM Besides other things. Those areas overlay over conventional RAM, so that you can't use all upper memory, but ...
9
votes
2answers
246 views

Paradigm for (repeated) use of PDP-10 indirect bit

Answers to question PDP-10 effective address calculation explain how PDP-10 effective address calculation works, including potentially infinite indirections. However the answers don't address how this ...
8
votes
3answers
1k views

Why VGA framebuffer was limited to 64kB window?

VGA framebuffer was fixed to 64kB at A0000h. Right after that there’s MDA/CGA framebuffer at B0000h. I am not sure, but I recall VGA did have to support CGA and its framebuffer, but was there any ...
7
votes
5answers
582 views

Could the Intel 8086 CPU have many segments in memory of the same type?

The Intel 8086 CPU could address up to 1 MB of memory using segmentation, and this CPU have 4 segment registers, which are CS and SS and DS and ES. Each segment in memory can have a maximum size of ...
7
votes
1answer
1k views

How does Notepad store text files in memory?

Before I knew about line endings, I used to open small executables in Notepad and ruin them completely. However, some more complex executables (e.g. Paint Shop) were too big for Notepad, and I was ...
6
votes
1answer
489 views

Can the Nintendo 64 run code directly from ROM?

I've read that the usual way to execute code on the N64 is to use DMA to copy it from ROM into RAM, and then run from RAM. However, it seems that the contents of the ROM are directly visible to the ...
6
votes
1answer
141 views

Details of ZS Scorpion port 0x1ffd

There's this page about the ZS Scorpion, and I'm reading about the way bankswitching works. Port 0x7ffd is the same as on western ZX Spectrums, but to double the amount of RAM to 256k and also the ...
5
votes
9answers
607 views

Were there any games/software that used memory beyond what was advertised available to BASIC on the machine?

Were there any games/software that used memory beyond what was advertised as available to BASIC on the machine ? On home / personal computers any time up to 1984 . Without needing to plug in any ...
5
votes
3answers
491 views

How does the PMD 85 display colour or greyscales?

I stumbled across this computer in an article on hackaday, Home computers behind the Iron Curtain and since it has this bizarre resolution, I looked closer into it. Some claims from Wikipedia: ...
5
votes
2answers
2k views

How did the BBC sideways ROM software for the AMX mouse process the user port input data to determine x and y movement?

This mouse plugged into the user port on the underside of the BBC micro models. The mouse came with software in the form of a sideways ROM which provided APIs, CLI commands for own programs as well as ...
5
votes
3answers
648 views

How to use HGR2 (or HGR) on an Apple II

I am a big fan of the TV show lost, and I was trying to make the Dharma Initiative logo. But at certain point I couldn't add new lines of code and the final part of the logo was cut off. I tried to ...
5
votes
1answer
853 views

How does JSR actually work on the 65c816 CPU for the SNES (Super Nintendo)?

Take the following machine code for the 65c816 for the SNES (Super Nintendo): 00000000 ea ea 78 18 fb c2 18 a2 ff 1f 9a 20 fa 80 e2 20 |..x........ ... | 00000010 a9 80 8d 00 21 a9 e0 8d 22 21 ...
5
votes
2answers
586 views

What is the reason of the particular range of the last 4K block of memory selection in Apple II

Following my previous question on Identifying the functionality of the memory select in Apple II and now that I know that the memory select device is simply an interconnection block. Searching for ...
5
votes
1answer
427 views

Bank switching and memory perspectives (C64)

I've been reading up on bank switching on Wiki and in particular here which contains the below nice image and have a few questions: Am I right in thinking that LOAD loads into RAM (dark grey in the ...
5
votes
1answer
156 views

How did games written for tape-based BBC micro, get officially and unofficially ported to disk, bearing in mind extra workspace needed by DFS ROM?

If I recall, PAGE = &E00 for a BBC Model B system with cassette tape based storage. On installation of Acorn DFS ROM (with 8271 Floppy disc controller), the ROM allocated more memory, increasing ...
4
votes
7answers
476 views

Static memory partitioning

Does anyone know of any operating system that used static memory partitioning: contiguous physical memory allocation with one process per partition, one partition per process, partitions generated at ...
4
votes
2answers
480 views

How can I malloc() a block that's guaranteed to lie within a single DMA segment in Turbo C 2.01?

I'm following root42's videos about DOS programming using Turbo C 2.01. I've written my own Soundblaster 1.xx driver following the Creative Labs documentation, and I'm confused about memory allocation....
4
votes
2answers
726 views

Transforming a memory dump into something loadable

As a follow-up to this question, I now have: A memory dump of the unpacked application The start address of the application I can verify that the dump is correct by starting a new instance of Vice, ...