Config — dosbox.conf in Depth
Outcome: you can find the configuration file, read its sections, change a setting, and — the part most guides skip — prove the change took effect.
The file is created at first launch:
~/.dosbox/dosbox-0.74-3.conf on Linux.
It is plain text, organised in sections
in square brackets. The ones that matter
first:
[dosbox]— the machine itself:machine=svga_s3(the emulated graphics card),memsize=16(megabytes of memory),captures(where screenshots and recordings land).[cpu]—core=autoandcycles=auto: how fast the emulated processor runs (chapter 11).[mixer],[sblaster],[gus],[speaker]— the sound hardware (chapter 10).[dos]—ems=true,xms=true,umb=true: the memory services old programs ask for, all visible in chapter 4'sMEMoutput.[render]— how the emulated screen is drawn on yours:aspect,scaler.[autoexec]— commands run at startup, line by line. This section is treated as its own topic in chapter 8.
You can also hand DOSBox a config of
your choosing with -conf file, which
is what the lab did — and the experiment
(transcript t06) is the template for
proving any setting. The lab copied the
default file, changed two values —
memsize=16 -> memsize=32
cycles=auto -> cycles=12000
— appended its commands to [autoexec],
and started DOSBox with that file and
no -c flags at all. Three proofs
came back as files. A marker line the
autoexec section wrote (CONFRAN.TXT)
proved the file was even read — worth
doing explicitly, because a missing
config file is not an error: DOSBox
silently runs on defaults (t07), so
"nothing complained" proves nothing.
MEM then reported 31,552 Kb of
free extended memory against 15,168 Kb
in the 16 MB run: the doubled memsize,
visible from inside the guest. And the
Z: drive tool CONFIG read the running
machine's settings back:
Z:\>config -get "cpu cycles"
12000
Z:\>config -get "dosbox memsize"
32
CONFIG is the config file's other
face: CONFIG -GET "section name" reads
a value from the running emulator,
CONFIG -SET changes one for the
session, and CONFIG -WRITECONF writes
the current settings out to a file. Use
it whenever you change something and
want the machine itself, not your
editor, to confirm the change arrived.
One discipline the lab followed and recommends: one change, one proof. Two values changed in t06 only because each carried its own independent check — a memory number and a CONFIG readout cannot be confused with each other. Change three things and check none, and the first odd behaviour you meet has three suspects.