RLV12 V2.0 Firmware Description
Microcontroller
The core of the RLV12 emulator is based on a ATMega1284P microcontroller and it’s firmware. The microcontroller emulates the RLV12 functions and maps the units to either partitions or to disk images on a MBR formatted SD‑Card. The SD‑Card interface supports sizes up to 64Gbyte and disk images are standard disk images files that are stored on a FAT‑16 or FAT‑32 volume.
The firmware implements a command line interface to the user which allows to change various aspects of the emulator. The command line interface can be accessed via a serial interface and using a terminal emulation program and is set to 115'200baud, 8 bit data, no parity and one stop bit.
Startup
During startup the microcontroller initialises the emulation and checks for an SD‑Card inserted. If no SD‑Card is inserted it stops initialisation and presents a command line prompt.
In case a SD‑Card is inserted it will read the partitions. If it finds a FAT‑16 or FAT‑32 partition it will try to read an initial configuration file in the root directory and starts executing the commands in the configuration file. If there is no configuration file it will then look for any partition that has the exact size of a RL01 or RL02 volume and bind them to the individual units. If there are 4 or more partitions then the first 4 partitions will be assigned to the 4 units. Else it will assign only as many partitions to the units as there are valid partitions and the remaining units will be set offline.
During the initialisation it will show the progress and status and in case of problems display an error message.
Command Line Interface
The command line interface implements the following commands
- insert
- cd
- hello
- show
- dir
- type
- pwd
- fdisk
- attach
- detach
- help
- activate
- initialise
- logging
- number
- load
- readinit
- dump
- dmaaddress
- dmaread
- damwrite
- linked
- free
- dmatest
- bootrom
- mount
The command line interface allows editing the command line and has a one command history buffer.
insert
insert [cartridge
This command does nothing, it is just there to test the features of the table driven parser used by the user interface.
cd
cd
does a change directory. This will set the default director for other
file commands. This will act on the first FAT volume found on the SD-Card.
A no volume
message will be shown if there is no SD‑Card or if
no FAT volume was found on the SD‑Card.
hello
hallo
This command does nothing, it is just there to test the features of the table driven parser used by teh user interface
show
show
is used to show the status of various things
- logging
- units
- partitions
- version
- status
- bootrom
dir
dir
lists the current directory of the FAT volume
type
type
shows the content of the file on the FAT volume
pwd
pwd
prints the current working directory
fdisk
fdisk
shows the partitions on the SD‑Card
attach
attach
Attaches a file or partition to a unit
detach
detach
Detaches the file or partition from a unit
help
Shows the help screens
activate
Activates a previously inactive paritition. This command changes the partition type from FAT‑12 to Linux. This is useful as Windows or macOS cannot set the partition type to Linux when partitioning a SD‑Card.
initialise
Initialises a active partition, that is it writes a standard bad block information at the end of a RL01 or RL02 volume
logging
Manipulates the current logging or shows the current logging option
number
Translates a number into other base, ie. from octal, decimal, hex to octal, decimal and hex.
load
load [<address>|<filename>]
On startup the RLV12 emulator loads a default boot ROM into the local memory of the microcontroller. This boot ROM has a size of 256. words and is then visible from the PDP-11 at address 173000(8).
This image can also loaded to the normal PDP‑11 memory using the load command with an address. Using the load command with a filename will read the first 512. bytes from the file from the FAT volume and load this instead of the default boot ROM into the local memory of the microcontroller.
dump
dump -b
Dumps a block from a unit. It reads the block number of the partition or file attached to the unit starting with block number 0. It then displays the content as octal words and optionally decoded as ASCII or RADIX‑50.
dmaaddress
Sets the DMA address for later reads or writes
dmaread
Reads a word from the current DMA address
dmawrite
Writes a word to the current DMA address
linked
show a linked cluster on the mounted FAT volume
free
List the internal free dynamic memory
memtest
Tests the host memory
mount
Mounts a FAT volume on the SD‑Card
bootrom
With the bootrom
command you can
- enable the boot ROM
- write enable the boot ROM
- disable the boot ROM
- set the image for the boot ROM
- show the status of the boot ROM
By default the boot ROM is enabled, you can disable the boot ROM by using the
no bootrom
command. You reenable the boot ROM by using the bootrom
command.
With show bootrom
you can display the status of the boot ROM.
Per default the boot ROM is write enabled. This is usefull if you want to enter
a small programm via ODT. The write enable can be set with the bootrom rw
and
the bootrom ro
commands. With bootrom reset
you reload the original bootrom
and with bootrom load <file>
you can load a boot ROM file from the FAT volume.
Configuration File
During startup the emulator will try to read a file RLV12.INI
in the root
directory of the first FAT partition. Then it will read the file line by line
until it finds a line containing the keyword [RLV12]
. Once it has seen
this line every other line will be treated as a command line, however
only a subset of commands is allowed in the configuration file
- attach
- bootrom
- logging
- load
Parameters
Parameters of the command can take the following formats
Switches
Switches are a dash followed by a single character and optionally take another parameter, e.g.
dir -a
shows the current directory including the hidden files. This can be followed by an optional directory name.
Strings
Strings are just a list of characters except the blank. If you want to include blanks in your string you need to surround the string with single or double quoats.
Units
Units is the keyword for the disk drive followed by a single digit. The drive name
for RLV12 units is RL
.
Partitions
Partitions are identified by the keyword partition
immediately followed by a
single digit