SD cards and hard disks¶
Media > SD Card holds the card of a machine with an SD card slot. Media > Drives holds the hard disks of a machine with an IDE interface. Either can be an image file or a folder on your computer. The divMMC’s cards are described in divMMC.
SD card¶
The two ZX Evolution machines, the ZX Spectrum Next and the ZXM-Phoenix have an SD card slot. The Pentagons and the Scorpions have one if a Z-Controller is fitted. The Next starts from a card with System/Next on it, and its menu also has System/Next Card… (see The SD card). Media > SD Card shows the card in the slot, or (no card), and has:
Open Image… - insert a card from an image file.
Open Folder… - use a folder on your computer as the card. See A folder as a disk.
Eject - take the card out.
Refresh - a folder card only: files added, changed or deleted in the folder reach the machine while it runs. See Refresh.
Write Protect - the card’s lock switch: the machine cannot write to the card. On a folder card it makes that one folder read only.
What the machine writes to a card image goes into the image file at once. To start with a
card, use --sdcard <file or folder> on the command line.
Z-Controller¶
The Z-Controller is a ZX-BUS card by Alexey Zhabin (KOE) with an SD card slot on ports
#57 and #77. Xpeccy+ emulates its SD part, as the card’s own logic has it. You can fit
it to the Pentagon, the Pentagon 1024 SL and both Scorpions: on the Machine page of
Options, set the SD card row to Z-Controller. Apply then powers the machine
off and on, as if the card were fitted with the power off. Its card is the one in
Media > SD Card, its light is the SD light in the status bar, and the setting belongs
to the machine. A Pentagon takes a divMMC or a Z-Controller, not both.
The ProfROM of the Scorpion, from version 4.xx.38 on (the Turbo+ comes with 4.44), finds the card at power-on and reads it in its navigator: a FAT32 card, or a folder. FATALL by savelij copies files between the card and TR-DOS disks on any of these machines, from FAT16 or FAT32.
The ZXM-Phoenix has the same two ports in a chip on its own board, so its SD card row comes set to Z-Controller, and Fatall is the first item of its start menu.
Hard disks¶
A machine with an IDE interface (see Which machine has what) has
two places for a drive, Master and Slave. Connect them first: on the Machine page
of Options, click the
gear in the Hard disk row and set Master
(and Slave, if you want two) to HDD (ATA).
Media > Drives then has a submenu for each connected device, named Master: or Slave: followed by the name of the image in it:
Open Image… - open a hard disk image:
.hdi, or a plain image of the disk with any other extension.Open Folder… - use a folder on your computer as the disk. See A folder as a disk.
Eject - take the image out.
Refresh - a folder disk only, as on an SD card: see Refresh.
Properties… - opens the window Hard Disk: Master (or Slave), which shows the image, its cylinders, heads and sectors (C / H / S), its Capacity, and the LBA box. LBA lets the system address the disk by sector number. Clear it for an old system that only knows cylinders, heads and sectors.
What the machine writes to a hard disk image goes into the file at once. The images stay mounted when you switch machines, and are opened again at the next start.
A folder as a disk¶
Open Folder… in Media > SD Card, in a divMMC’s card menus and in Media > Drives lets the machine use a folder on your computer as if it were a FAT32 card or disk. You do not need to make an image: copy programs into the folder and open it. You pick the folder in a window named Folder to use as the card or Folder to use as the disk. A folder as a disk, in Under the Hood, explains how the disk is made and written back.
The folder is read when you open it, and again at Machine > Reset > Hard Reset and when you switch machines. Apply in Options does not read it again, except for a hard disk’s folder if the machine had no interface for it until then. To bring in files added, changed or deleted since then without a reset, use Refresh (see Refresh).
The disk is made big enough for the folder, from 512 MB up to 32 GB. If the folder takes writes, the disk also gets as much free room as its files take, plus 256 MB. A larger folder is not opened, and the message folder too big for a disk says so.
These are left out: files of 4 GB and over, folders more than 16 levels deep, entries past 65536 in one folder, and anything past 200000 entries in all. If something was left out, the message folder: not all of it fits says so.
A link to a folder (a junction on Windows) is followed once. A link that leads back into the folder, or to a place already shown, is left out. A Windows shortcut (
.lnk) is a file like any other. Files your system hides are left out.A folder is not a whole disk: attributes, dates other than the last write and sectors outside files last only until the folder is read again (see What a folder cannot do). For full compatibility, use an image.
On a hard disk, a folder that holds NedoOS with its
ZXLDRfile in the top level can boot NedoOS.
Writing to a folder¶
A folder takes what the machine writes. If the machine saves a program there, or changes or deletes a file, the files in the folder itself change. The folder is updated about half a second after the machine stops writing. If the machine saves a file with no date, the file gets the time it was written on your computer.
The first time the machine writes to a folder, the machine stops, and the Writing to a folder window asks:
Allow writing - the folder takes this write and every one after it.
Read-only - the folder stays as it is. What the machine wrote stays in memory, and the machine sees it, until the folder is read again. Folders opened after that are read only.
It asks only once: your answer becomes the Folders setting. Both settings are in the Folder as a disk group on the Emulation page of Options:
Folders - R/W, read/write (the default), or R/O, read-only. The machine cannot write to a folder opened read-only: esxDOS reports
I/O ERROR, and a hard disk reports an error. R/O takes effect at Apply: a folder in use stops changing, and what the machine writes to it from then on stays in memory, as with the Read-only answer above. R/W takes effect when the folder is next read: at a Hard Reset or a change of machine.Deleted files - Move to trash (the default) puts a file the machine deletes into your system’s trash. Delete permanently removes it. If the trash does not take a file, the file stays in the folder.
Write Protect in a card’s menu makes that one folder read only, whatever Folders says.
What the machine wrote is never lost on the way. If something cannot be carried over - a file another program has open, a name your system refuses - a message says so once and names the files. If a file’s content could not be put in its place, it is kept in the folder’s top level with (recovered) in its name. If you change a file on your computer while the machine has the folder, your change is kept: the machine’s version is saved beside it as name (2), and if the machine deletes the file, it stays where it is.
Keep a copy of anything you cannot afford to lose. If the machine formats the card or disk, or deletes most of the folder at once, your files are not touched. From then on the folder is left alone, what the machine writes stays in memory, and a message says so.
Refresh¶
Refresh in a folder card’s or folder disk’s menu brings in what you changed in the folder since it was read: new files and folders, changed files, deleted ones. The machine keeps running and needs no remount, unlike a real card put back. What the machine wrote there goes to the folder first. The message refreshed: 2 new, 1 gone, 0 changed says what changed.
The machine sees the change the next time it reads the folder: esxDOS at its next listing, the NextZXOS Browser when it shows the folder again (leave it and come back). Files that stayed keep their place on the disk, so a file the machine has open, a disk image it has mounted and the folder it is in read on as before.
Refresh is refused, with a message, if not all that the machine wrote has reached the
folder, if the folder is no longer written to, or if the changes do not fit on the disk.
In that case, Eject and Open Folder… read the folder anew. An image file has no
Refresh. A changed ZXLDR boots only after a Hard Reset.
Two hotkeys work on SD cards from the keyboard. They have no key until you give them one. SD Card: Refresh refreshes every folder card the machine uses. SD Card: Eject takes out the machine’s card: on the ZX Evolution and the Next, the card in the slot (on the Next, its own card goes back in); on the other machines, the card in the divMMC’s first filled slot.