Page
User manual
On this page you will find useful information on how to use Xcpc.
Command-line options
Usage: xcpc [toolkit-options] [xcpc-options] [files...]
Help options:
--help display this help and exit
--version display the version and exit
Emulation options:
--company={value} Isp, Triumph, Saisho, Solavox, Awa, Schneider, Orion, Amstrad
--machine={value} cpc464, cpc664, cpc6128
--monitor={value} color, green, gray, ctm640, ctm644, gt64, gt65, cm14, mm12
--refresh={value} 50Hz, 60Hz
--keyboard={value} english, french, german, spanish, danish
--memory={value} 64kb, 128kb, 192kb, 256kb, 320kb, 384kb, 448kb, 512kb
--renderer={value} default, ximage, opengl
--sysrom={filename} 32Kb system rom
--rom000={filename} 16Kb expansion rom #00
--rom001={filename} 16Kb expansion rom #01
--rom002={filename} 16Kb expansion rom #02
--rom003={filename} 16Kb expansion rom #03
--rom004={filename} 16Kb expansion rom #04
--rom005={filename} 16Kb expansion rom #05
--rom006={filename} 16Kb expansion rom #06
--rom007={filename} 16Kb expansion rom #07
--rom008={filename} 16Kb expansion rom #08
--rom009={filename} 16Kb expansion rom #09
--rom010={filename} 16Kb expansion rom #10
--rom011={filename} 16Kb expansion rom #11
--rom012={filename} 16Kb expansion rom #12
--rom013={filename} 16Kb expansion rom #13
--rom014={filename} 16Kb expansion rom #14
--rom015={filename} 16Kb expansion rom #15
--drive0={filename} drive0 disk image
--drive1={filename} drive1 disk image
--snapshot={filename} initial snapshot
Misc. options:
--speedup={factor} speeds up emulation by an integer factor
--xshm use the XShm extension
--no-xshm don't use the XShm extension
--crt-emulation simulate crt monitor
--no-crt-emulation don't simulate crt monitor
Debug options:
--quiet set the loglevel to quiet mode
--trace set the loglevel to trace mode
--debug set the loglevel to debug mode
Environment variables
Loglevel
The default loglevel is overridden with the --quiet, --trace, --debug options.
You can also set the default loglevel with the XCPC_LOGLEVEL variable:
export XCPC_LOGLEVEL={xcpc-loglevel}
The available loglevel values are:
0 = quiet
1 = error
2 = alert
3 = print
4 = trace
5 = debug
Runtime
When Xcpc is run in portable mode or installed in a location other than that configured during compilation, you must tell the emulator where to find some resources such as the logo and the original ROMs (firmware and base).
You can set some environment variables to fix some paths:
XCPC_BINDIR: optional, not currently usedXCPC_LIBDIR: optional, not currently usedXCPC_DATDIR: optional, not currently usedXCPC_DOCDIR: optional, not currently usedXCPC_RESDIR: mandatory, specifies the path where to find the emulator logoXCPC_ROMDIR: mandatory, specifies the path where to find the firmware and basic romsXCPC_DSKDIR: optional, not currently usedXCPC_SNADIR: optional, not currently used
export XCPC_DATDIR="{path-to-dat-directory}"
export XCPC_ROMDIR="{path-to-rom-directory}"
Joysticks
You can select the joysticks if not correctly handled by default.
XCPC_JOYSTICK0: the path to the joystick0 device (defaults to/dev/input/js0on Linux)XCPC_JOYSTICK1: the path to the joystick1 device (defaults to/dev/input/js1on Linux)
Example:
export XCPC_JOYSTICK0="{path-to-joystick0}"
export XCPC_JOYSTICK1="{path-to-joystick1}"
Audio
You can adjust audio parameters if they are not good by default.
XCPC_AUDIO_CHANNELS: the channel count,1for mono,2for stereo,4for surround 4.0XCPC_AUDIO_SAMPLERATE: the sample rate, for example11025,22050,44100,48000XCPC_AUDIO_PERIODSIZEINMILLISECONDS: the audio period size in milliseconds
Example for low-end hardware:
export XCPC_AUDIO_CHANNELS="1"
export XCPC_AUDIO_SAMPLERATE="11025"
Example for high-end hardware:
export XCPC_AUDIO_CHANNELS="2"
export XCPC_AUDIO_SAMPLERATE="48000"
Hotkeys
Some Hotkeys/shortcuts are available:
F1for help.F2for loading snapshots.F3for saving snapshots.F5for resetting the emulator.F6for inserting disk into drive A.F7for removing disk from drive A.F8for inserting disk into drive B.F9for removing disk from drive B.
Keyboard
The left control keys (Left Control, Left Alt, …) are sent to the emulated machine, so if you want to send some keycodes (e.g. when you are using an AZERTY keyboard), you must use the right control keys of your keyboard (Right Control, Right Shift, AltGr, …).
If you don’t have a joystick or if joystick support is not available at compilation time, a joystick emulator is provided:
HomeorEndfor toggling the joystick emulation.Cursor Upfor moving the joystick up.Cursor Downfor moving the joystick down.Cursor Leftfor moving the joystick left.Cursor Rightfor moving the joystick right.Left Controlfor Fire 1.Left Altfor Fire 2.
Joystick
Joystick support is available under Linux:
- Up to two physical joysticks can be used.
- Joysticks must be plugged before launching Xcpc.
- Joysticks are tied by default to
/dev/input/js0and/dev/input/js1. - You can set the
XCPC_JOYSTICK0environment variable to specify the first joystick device. - You can set the
XCPC_JOYSTICK1environment variable to specify the second joystick device.
Drag’n drop
Xcpc supports drag’n drop, so you can use your file manager to load snapshots and/or disk images.
The supported extensions are:
.snafor loading snapshots.dskfor loading raw disk images.dsk.gzfor loading compressed disk images with the zlib algorithm (requires zlib)..dsk.bz2for loading compressed disk images with the bz2 algorithm (requires libbz2)..zipfor loading disk images packed in a zip archive (requires libzip).
Note: A zip archive is opened read-only and the alphabetically-first .dsk member is loaded automatically; writes back to the archive are not supported (extract the disk first if you need to save changes).