Make your own free website on Tripod.com
Usage of program Drive image & ZX file transfer

Purpose is making copy of media (drive, disk) in form of image file, and reverse operation - copiing from image to media. Such image files are useful as backups, as images suitable for diverse emulators. Program works with hard drive category of medias - there belong: IDE hard disks, PEN drives, diverse FLASH storage cards as Compact Flash - they attach usually via some USB card reader to PC.dr105.png
Refresh button is for forcing detection of all drives again - in case you connected/disconnected something. Not likely will be needed - autodetection will care about it.  Under it you may set offset from start of disks and count of sectors if want to read/write only segment of drive.
Selection of drive is by simple click on it's line in list window left. Then program attempts to detect used filesystem on that media - 'DOS mbr' means usually that it is hard disk in PC - so better don't write to it! PLUSIDEDOS  is used by Spectrum +3e and some other clones. 'Charea DoS' is mine system, with 36 areas by begin letter A-Z, 0-9.
Because it is not possible to detect correct CHS parameters via USB reader, there is possibility to enter them manually. Program usually offers usable values for Compact Flash cards. With click on 'Size CHS' user may change detected drive's size, by need. That size remains until next drive selection. 'LBA' is required only for disk Init, see below.
  With click on 'Open image file' you may select image file instead drive. You may then perform even conversion RAW-HDF or HDF-RAW. Just click after selecting image file on 'Read from drive', and program will convert. Program gets CHS parameters from hdf files, but for RAW it is not possible (except when Charea DoS FS is on, see below - Guess geo.) , so enter them manually by need  - in case of (older) image files for usage with CHS ROMs.
Program will ask for extra confirmation in case of attempting write to drive over 2 GB - to prevent accidental write to PC hard disks, what will result in destroying partition records and datas on them.
Limitations: works only in Windows XP and newer versions.
Must have admin rights to read/write on drives.
Speed: it should work pretty fast with USB 2.0 card readers. Speed depends much from used media. Newer CF cards can read over 2 MB/sec. Write is usually slower 2-3 times than read. New PEN drives are  even faster - read over 5MB/sec.

ZX file transfer:

Before clicking on 'File transfer' button be sure that Image format is correct set. Program usually automatically sets it, but sometimes user will need to manually set it. For 8-bit simple IF drives or images must set HDF 256.

ZX > PC:
User may extract ZX files from drives or image files (raw or hdf format). After selecting drive from list or file with 'Open image file' click on 'File transfer' - it is designed for Charea DoS system, used by hard disk and CF ROMs (zxcflba.rom, zx8bide.rom & zxide.rom) on this site. If you get mess instead lists probably CHS is incorrect. For LBA it is 'standard' 32 Sector/track and 8 Heads. Clicking on 'Guess geo.' may detect and set correct drive geometry.
drchabr.png
At left
select Charea, then clicking on files in middle box selects them for transfer - they appear in right box. With 'Save sel.' it will be transferred to PC.
Resulting file may be TAP file , Z80 snapshot.  If length ( last column at Cat: )  is 49152 it will be Z80. It is possible to save ZX files directly, without header - just check 'Save bin.', and all will be saved so, with extensions bin. You may select max 32 files at once. However, it is not wise to select lot of files for TAP at once - because all will go in single TAP file. Best way is as it is shown on pic. above - first select BASIC loader and then CODE (after it). Most of programs is recorded so.
'Erase sel.' is for erasing ZX files. It works little unusual - may erasing only last file in charea. But you may select again multiple files, just select them in order from last to up - may select from different chareas at once.
With click on 'Chareas' program will set segment for just currently selected charea - to make easy save/write of individual chareas of drives.

PC > ZX:
Click on 'PC > Cha.' button, and may select multiple files with Win. fileselector:
chabr2
Supported filetypes are: SCR - ZX screen, exactly 6912 bytes long. SNA - old snapshot files.  Z80 snapshot - V 1.45, V 2.01 & V 3.0 , only for 48K, for now. Plus TAP files and BINary files - bin ones will be copied directly as CODE files, with start address 25000, max len. 48KB. Transfer mode depends on file extension. Because authors of software, and especially 'authors' of TAP files had pretty limited naming imagination, and to prevent to see too often message like: chabr3 I implemented some autonaming system. In case of duplicate name in TAP file, prog. will rename it to re.xxx.PCfilename . 're' may be changed in editbox 'Rename:'. xxx is auto-counter in range 1 to 255. If begin character is illegal (not A-z, 0-9) it will be changed to 9. Codes above 127 and below 32 in filenames will be changed to '?'- to make edit easier.
After getting such renamed files it is good to correct BASIC loader, and save datas with some meaningful names: Corrections will be needed for commands like: LOAD "" - it is not allowed by disk systems, so enter in brackets filename. Mine ROM also not accepts LOAD "pic" SCREEN$ - change it to LOAD "pic" CODE [16384] . Luckily, ZX filesystem is case sensitive, so you may play with RePTON, rEpToN etc... .
In some cases transferred snapshot will not work - it is because of limited hardware. Stack may be overloaded. In such case help is to make another snapshot file on PC (looking for another on WEB). Rule is: make snapshot when game is paused.  In case of 'Name already exists' by snapshots just simple rename PC file...
Some TAP files have headerless (and nameless) parts - such blocks will be transferred to files with names: hl.1.PCfilename, hl.2.PCfilename etc. Of course, here is also possible to change prefix 'hl' to different - editbox 'H'less:'. User must find way how to make later load of those files normally - some machine code knowledge is necessary.
For experts: If I reg points to ROM, it must be #39 for IM 2 mode, because ROM is full with code.



Image creation:
In main window, at top right is button 'Create img' . It will create empty image file in format according to settings in box 'Image format', with geometry by settings in box 'CHS setting'.
Recomended is usage of HDF format - it holds all necessary parameters. For 8-bit simple IF  HDF 256 format is required.


Initialization of disk or image file:

drinit.png
Before usage, disk (media) must be initialized, what means creating of filesystem. It is something like partitioning on PC.
 Select drive or Open image file. Set geometry by need (it can't be autodetected in some cases). For zxcflba.rom (CF interface) click button 'LBA' - it will set correct parameters for init (32 sec/tr & 8 heads). Check is Image format correct (for 8-bit simple IF it must be HDF 256). Then click on '
Init' at top right.
Program divides space by criteria how much begin letter is common. So, much more space for S than for Q.
In listbox is begin letter, then total capacity of it's charea and number of CAT slots - so much files can be stored there. By clicking on charea in listbox it's parameters will appear in setboxes right. There may adjust size and slot count. Lower will see total size of all chareas. Most important is to watch 'Free:' indicator. If it go in negative, you must decrease size of some charea(s). Otherwise last charea(s) will be outside of disks capacity.
Small setbox 'Data at:' is for setting start cylinder of first charea. It is standardly 1, but in some cases may be bigger, up to 9. Can't be 0 (at start is Master CAT). After writing in value click on  'Data at:' to enter it. And may need to decrease some sizes after...
Old filesystem has some limitations: max size of charea is 32MB by CF and 16-bit IF, and 16MB by 8-bit simple IF.
Count of CAT slots is limited to 4064/2032. Still, there is lot of space: in 16MB can fit over 330 snapshot. Max size of drive/media what can be fully used is about 1.1 GB.
New filesystem with big sectors has max charea sizes of 64MB for all types of interfaces. Check 'Big Sectors' for such ROMs before init. It has sense only for larger drives/medias - over 500MB. Fillable media size is then 2.2 GB (4.4 GB for 8-bit IF).

With click on button with long text, and confirmation disk/image will be initalized and ready for usage. You may imediately check it by entering 'File transfer' .


Download


    July, Okt. 2006  P. Putnik