flexemu - a FLEX emulator with X11/WIN32 interface

SYNOPSIS

On Linux/X11

flexemu [-i] [-h] [-f path] [-p path] [-c color] [-0 path] [-1 path] [-2 path] [-3 path] [-t] [-r <two_hex_digits>] [-s] [-v] [-u] [-j xFactor] [-k yFactor]

On WIN32

flexemu [-i] [-f path] [-p path] [-c color] [-0 path] [-1 path] [-2 path] [-3 path] [-u] [-j xFactor] [-k yFactor]

DESCRIPTION

flexemu emulates a MC6809 microprocessor system running FLEX Operating System. Additional hardware modules as for ex. two MC6821 parallel input/output ports, a floppy disk controller WD1793, a realtime clock MC146818 and a special video interface completely emulate the hardware of an Eurocom II/V7 computer. It was develloped by
ELTEC Elektronik and mainly distributed in Germany in the 80ies.

flexemu supports the following features:

OPTIONS

In general there are command line options and options editable by fsetup available. Commandline options can supersede fsetup-options.

Commandline options on Linux (X11) and WIN32

-f <hexfile>
Specifies the name of a program read during startup, usually a system monitor. Both intel Hex and Motorola S-record is supported. The default is neumon54.hex The file will be looked for in the working directory or in the directory specified as -p option or as Disk/Monitor directory. Flexemu can be used with other monitor programs as long as they support the special hardware needs of the Eurocom II/V7.
-c <color>
Specifies the foreground color. The default is green The background color is always black.
-i
Inverse video display (foreground and background colors exchanged)
-p <path>
Specifies a path in which diskimage files or nafs-directories will be looked for. Defaults:
WIN32: <INSTDIR>\data
X11: /usr/local/share/Flexemu
-0|1|2|3 <path>
Specifies a diskimage file or a directory path for drive 0, 1, 2 or 3. The default is system.dsk for drive 0. The file or directory will be looked for in the actual directory. If nothing is found the directory specified with the -poption or as Disk/Monitor directory will be looked for.
-j <xFactor>
Specifies a factor to multiply the width of the FLEX display. Default is 2. Valid values are 1 and 2.
-u
Enables the support of undocumented MC6809 Instructions. See Chapter Undocumented MC6809 Instructions for details.
-k <yFactor>
Specifies a factor to multiply the height of the FLEX display. Default is 2. Valid values are 1, 2 and 3.

Commandline options only on Linux (X11):

-h
Print a short syntax description.
-v
only print version number
-t
Terminal only mode. All input/output will be done on the terminal from which flexemu is started. All Escape-Sequences of this terminal can be accessed. Montior program neumnt54.hex is needed for this
-r <two_hex_digits>
Define a reset key for terminal mode specified as two hex digits. The default is 1E , means Ctrl-^

Only if X11 present:

-s
run X11 synchronized

Options editable with fsetup

On both X11 and WIN32 there is a program fsetup available to edit options

Name Description Default
Screen geometry Pixelsize used for the video display 1024x512
Display Inverse Display video normal or inverse off
Color Specifies the foreground color green
X11 only:HTML browser Executable used as HTML browser netscape
Disk/Monitor directory A Directory Path containing
FLEX disks and monitor program
WIN32: <INSTDIR>\data
X11: /usr/local/share/Flexemu
Monitor program A Filename or Directory Path for the monitor program neumon54.hex
Disk for drive 0 A Filename or Directory Path for FLEX disk 0 system.dsk
Disk for drive 1 A Filename or Directory Path for FLEX disk 1 no default
Disk for drive 2 A Filename or Directory Path for FLEX disk 2 no default
Disk for drive 3 A Filename or Directory Path for FLEX disk 3 no default

Breakpoint support

With the menu Processor->Breakpoints up to two breakpoints can be set. They have to be input as a one to four digit hexadecimal address. Execution automatically stops when the PC contains one of the breakpoint addresses.

CPU Instruction Logging

With the menu Processor->Logging the logging of each executed CPU instruction can be enabled. The Instruction Logging Dialog contains the following entry fields. Addresses have to be input as a one to four digit hexadecimal address:

Fieldname Defaultvalue Description
Min Address 0000 Only log instructions on an address higher or equal to this address
Max Address FFFF Only log instructions on an address lower or equal to this address
Start Address <not set> Start Instruction logging when the value of the PC is equal to the Start Address
Stop Address <not set> Stop Instruction logging when the value of the PC is equal to the Stop Address
Filename <not set> Filename to be used for the instruction logging. Independant of the Start and Stop Address this file remains open as long as Flexemu keeps running until another Filename is set. An empty filename finishes Instruction logging.

CPU Frequency control

With the toggle menu item Processor->Frequency 1.3396 MHz the CPU frequency can be switched between the maximum possible frequency (depending on the available host CPU performance) and the original CPU frequency which exactly is 1.3396 MHz. With the command emu freq other frequencies can be specified. See FLEX Utilities for details.

Undocumented MC6809 Instructions

The support of undocumented MC6809 instructions can be controled either with the command line option -u or with the menu point Processor->Undocumented Instructions. To be able do distinguish them from the supported instructions the disassembler displays their mnemonics in lower case. Undocumented MC6809 instructions are not available with Fastflex. The following undocumented instructions are supported:

Mnemonic Opcode Mode Description
neg 01 Direct Same as Op 00 (NEG)
negcom 02 Direct If cc.c = 0 then NEG else COM
lsr 05 Direct Same as Op 04 (LSR)
dec 0B Direct Same as Op 0A (DEC)
reset 3E Inherent Same as CPU Reset
nega 41 Inherent Same Op 40 (NEGA)
coma 42 Inherent Same Op 43 (COMA)
lsra 45 Inherent Same Op 44 (LSRA)
deca 4B Inherent Same Op 4A (DECA)
clra 4E Inherent Same Op 4F (CLRA)
negb 51 Inherent Same Op 50 (NEGB)
comb 52 Inherent Same Op 53 (COMB)
lsrb 55 Inherent Same Op 54 (LSRB)
decb 5B Inherent Same Op 5A (DECB)
clrb 5E Inherent Same Op 5F (CLRB)
neg 61 Indexed Same Op 60 (NEG)
com 62 Indexed Same Op 63 (COM)
lsr 65 Indexed Same Op 64 (LSR)
dec 6B Indexed Same Op 6A (DEC)
neg 71 Extended Same Op 70 (NEG)
com 72 Extended Same Op 73 (COM)
lsr 75 Extended Same Op 74 (LSR)
dec 7B Extended Same Op 7A (DEC)
EXG 1E Implied In extension to the normal exchange of Byte and Word registers also exchange of mixed Byte/Word registers is supported. If the target is a Word the upper Byte is filled with $FF. If the target is a Byte only the lower Byte of the source register is moved.

Also supports "invalid" register codes. If the source is such an invalid register $FF or $FFFF is moved to the target register

TFR 1F Implied In extension to the normal transfer of Byte and Word registers also transfer of mixed Byte/Word registers is supported. If the target is a Word the upper Byte is filled with $FF. If the target is a Byte only the lower Byte of the source register is moved.

Also supports "invalid" register codes. If the source is such an invalid register $FF or $FFFF is moved to the target register

SEE ALSO

RELATED URLS

BUGS

If a drive can not be logged in no error message will be displayed. If a directory will be logged in as a drive and it has too much files or its filesize all together is too large no error message will be displayed and as much files as possible will be managed. emu commands (See FLEX Utilities for details) only have poor error messages.