flexutil - Miscellaneous FLEX utilities


SYNOPSIS

Utilities within flexemu:

emu
mount
umount
sync
exit
timeset
time
rtc
cls
tounix
fmsstat
ofiles

Utilities on Linux and Windows:

fromflex
toflex

Utilities on Linux:

rcvflex

DESCRIPTION

emu

emu is a command to directly communicate with the emulator from within the FLEX command shell. There are different operations concerning the cpu, the floppy controller or the graphical user interface (gui).
emu <irq | firq | nmi>
send a corresponding interrupt signal to the cpu. before invoking this command, there should already be set an interrupt vector before!
emu mount <path> <drive_nr>
mounts a disk image (DSK- or FLX-Format) or a virtual disk (directory disk). <path> as a floppy with drive number <drive_nr>. <drive_nr> can be one of 0 - 3.
emu info [<drive_nr>]
prints some information on drive with number <drive_nr> or, if no <drive_nr> is specified on all drives. <drive_nr> can be 0 - 3.
emu sync [<drive_nr>]
Synchronizes the contents of a native file system drive with number <drive_nr> or, if no <drive_nr> is specified on all drives. <drive_nr> can be 0 - 3. The execution is aborted and an error message is printed if any file is currently opened on the specified drive. Drives mounted with a disk image are silently ignored.
emu umount <drive_nr>
unmounts a previously mounted disk image or a virtual disk (directory disk). <drive_nr> can be 0 - 3. The execution is aborted and an error message is printed if any file is currently opened on the specified drive.
emu format <disk_name> <track_count> <sector_count>
formats a disk with name <disk_name>, a <track_count> and <sector_count>. The disk format is estimated by the file extension of <disk_name>. Supported file extensions are *.dsk and *.wta for DSK-Format, and *.flx for FLX-Format. If <disk_name> has no file extension a directory disk will be formatted. The newly formatted disk will not be mounted automatically!
emu terminal | graphic
At the time only available on Linux (sorry). If started flexemu in full graphics mode (without option -t ) this command can be used to switch between performing I/O on the graphic display or on the terminal. A hardware reset or nmi always switches back to graphic mode. This command is configurable for each Monitor file if it supports a SERPAR flag. The configuration is done in the file flexemu.conf. By default it is preconfigured for neumon54.hex. It supports a parallel I/O on pia1 (MC6821) which will be used in the graphic mode, and a serial I/O on acia1 (MC6850) wich will be used in the terminal mode. for neumon54.hex the modes can be switched 'by hand' by changing the contents of address 0xEF86 (SERPAR):

SERPARmode
== 0parallel I/O (graphic mode)
!= 0seriell I/O (terminal mode)

After a reset or nmi SERPAR will be initialized by the contents of address 0xf07c (INITSP).

emu freq [<target_frequency>]
Prints the actual frequency on which the virtual CPU is running. An optionally given target_frequency gives a target frequency.
emu cycles
Prints the actual number of processor cycles executed.
emu exit
immediately exits the emulator. A warning message is printed if any file is currently opened for WRITE or UPDATE. In this case it has to be confirmed to really exit the emulator, because files could get corrupted.
mount <path> <drive_nr>
Shortcut to emu mount command.
umount <drive_nr>
Shortcut to emu umount command.
sync [<drive_nr>]
Shortcut to emu sync command.
exit
Shortcut to emu exit command.
timeset
a menu driven command to set the time, date or alarm time of the real time clock MC146818. If setting the alarm time a interrupt vector for firq should already be installed! Setting the date only updates the date in the real time clock but not the date used by FLEX.
time
Prints the actual date and time of the real time clock MC146818.
rtc on | off | alarm
Initializes or removes a continuous display of the actual time on the down left corner of the graphic display. The periodic interrupt of the rtc MC146818 will be used for this. The optional parameter specifies the action: on initializes the display to update every second. alarm initializes the display to update if alarm time reached. off removes the clock display.
cls
Clears the graphics display.
fmsstat
File Management System (FMS) status. Print a list of currently opened files.
ofiles <count> [<file_spec> <mode> [<file_spec> <mode> ...]] <command>
The ofiles utility can open one or multiple files with a file access mode followed by executing a command. This way a command can be tested executing in the context of opened files.

<count> is the number of files to be opened. <count> can be 0 up to 12.

<file_spec> specifies the file to be opened.

<mode> specifies one of the following file access modes:

modedescription
+ROpen for read, the file has to exist.
+WOpen for write, the file must not exist.
+UOpen for update, the file has to exist. According to the FLEX documentation only supported for random files.

If <file_spec> has no drive specified the working drive is used, if no file extension is specified TXT is used. <command> can be any standard utility command located in the utility command space (UCS) to be executed. See FLEX Memory Map for details. After processing <command> all files are closed. <command> only is processed if all <file_specs> have successfully been opened.

tounix <disk_image_name>
This utility is useful on a real FLEX system. It transmits the whole contents of a FLEX disk in drive 1 over the serial line. tounix is available as source file so it can be adapted to any special needs. The counterpart on Linux is rcvflex.
fromflex
convert FLEX ASCII format to UNIX/MS-DOS ASCII format. The conversion will be done from stdin to stdout.
toflex
convert a UNIX/MS-DOS ASCII format to FLEX ASCII format. The conversion will be done from stdin to stdout.
rcvflex [-h | <serial_device>]
At the time only available on Linux (sorry). This utility transmits a FLEX disk from a real FLEX system to a Linux box. The counterpart on the FLEX system is the command tounix.cmd. The default for <serial_device> is /dev/cua2.

SEE ALSO

Documents on the behalf of the FLEX User Group

Related Links