diff --git a/ReadMe.txt b/ReadMe.txt index 6309bf9e..a8b2bed7 100644 --- a/ReadMe.txt +++ b/ReadMe.txt @@ -191,6 +191,20 @@ the drive containing the CP/M 3 image and use the CPMLDR command to load CP/M. It will ask you for the disk unit number containing the CP/M 3 system files which are on the disk image you created. +ZPM3 +---- + +Like CP/M 3, ZPM3 exists in an experimental state and is started +just like CP/M 3 above. Just use the zpm_hd.img file to create +your CF or SD Card. There is an issue with the ZPMLDR app used +to start ZPM. Instead, just use CPMLDR which works exactly the +same way. + +Note that ZPM3 seems to be completely constrainted to use drive +A: as the boot drive. So, the RomWBW adaptation of ZPM3 will +"swap" the initial drive A: (typically RAM drive) with the +ZPM3 boot drive at startup. + ROM Customization ----------------- diff --git a/Source/CPM3/@banks.txt b/Source/CPM3/@banks.txt deleted file mode 100644 index 7fb0d406..00000000 --- a/Source/CPM3/@banks.txt +++ /dev/null @@ -1,28 +0,0 @@ -COMMON 8F ?? -CPMSYS 8E 00 -HBIOS 8D ?? -TPA 8C 01 -BUFS 8B 02 - -8D:7000 -> 8E:0300 - - -00 -> 8E -01 -> 8C -02 -> 8B -03 -> 8A -... - -if bnk = 0, then hbbnk = 8EH (BID_USR) -else hbbnk = 8DH (BID_BIOS) - bnk - - or a - jr z,bank0 - neg ; 2 -> -2 - add 8DH ; 8D - 2 = 8B - jp HBX_SETBNK -bank0: - ld a,(8EH) - jp HBX_SETBNK - ret - diff --git a/Source/CPM3/Build.cmd b/Source/CPM3/Build.cmd index efacbb00..5008a0ca 100644 --- a/Source/CPM3/Build.cmd +++ b/Source/CPM3/Build.cmd @@ -24,7 +24,7 @@ rem pause rem Resident CPM3 echo. echo. -echo *** Resident BIOS *** +echo *** Resident CPM3 BIOS *** echo. copy optres.lib options.lib copy genres.dat gencpm.dat @@ -43,7 +43,7 @@ rem pause rem Banked CPM3 echo. echo. -echo *** Banked BIOS *** +echo *** Banked CPM3 BIOS *** echo. copy optbnk.lib options.lib copy genbnk.dat gencpm.dat @@ -59,6 +59,25 @@ zx GENCPM -AUTO -DISPLAY copy cpm3.sys cpm3bnk.sys rem pause +rem Banked ZPM3 +echo. +echo. +echo *** Banked ZPM3 BIOS *** +echo. +copy optzpm.lib options.lib +copy genbnk.dat gencpm.dat +zx RMAC -BIOSKRNL +zx RMAC -SCB +zx Z80ASM -BOOT/MF +zx Z80ASM -CHARIO/MF +zx Z80ASM -MOVE/MF +zx Z80ASM -DRVTBL/MF +zx Z80ASM -DISKIO/MF +zx LINK -ZPMBIOS3[B]=BIOSKRNL,SCB,BOOT,CHARIO,MOVE,DRVTBL,DISKIO +rem zx GENCPM -AUTO -DISPLAY +rem copy cpm3.sys zpm3.sys +rem pause + rem *** Resident *** rem copy cpm3res.sys cpm3.sys rem copy genres.dat getcpm.dat diff --git a/Source/CPM3/Clean.cmd b/Source/CPM3/Clean.cmd index 34c3444b..02fa2692 100644 --- a/Source/CPM3/Clean.cmd +++ b/Source/CPM3/Clean.cmd @@ -3,7 +3,7 @@ setlocal if exist bios3.spr del bios3.spr if exist bnkbios3.spr del bnkbios3.spr -if exist swpbios3.spr del swpbios3.spr +if exist zpmbios3.spr del zpmbios3.spr if exist *.rel del *.rel if exist cpmldr.com del cpmldr.com if exist *.err del *.err diff --git a/Source/CPM3/boot.z80 b/Source/CPM3/boot.z80 index 0d9031ed..d0b5cb0f 100644 --- a/Source/CPM3/boot.z80 +++ b/Source/CPM3/boot.z80 @@ -38,7 +38,7 @@ tpa$bank equ 0 if banked ; Clone page zero from bank 0 to additional banks - ld b,2 ; last bank + ld b,3 ; last bank ld c,0 ; src bank init$2: push bc ; save bank id's @@ -250,7 +250,7 @@ stpsiz equ $ - stpimg ?ldccp: - if drvswap + if zpm ; Swap A: and system drive (make A: the system drive) ld bc,(@dtbl) ; get drive A DPH @@ -614,6 +614,27 @@ bin2bcd1: pop bc ret + if zpm + +signon$msg db 13,10,'ZPM3' + if banked + db ' [BANKED]' + endif + db ' on HBIOS v' + biosver + db 13,10,13,10,0 + +ccp$msg db 13,10,'BIOS Err on ' +ccp$msg$drv db '?' + db ': No ZCCP.COM file',0 + + +ccp$fcb db 0,'ZCCP ','COM',0,0,0,0 + ds 16 +fcb$nr db 0,0,0 + + else + signon$msg db 13,10,'CP/M v3.0' if banked db ' [BANKED]' @@ -631,6 +652,8 @@ ccp$fcb db 0,'CCP ','COM',0,0,0,0 ds 16 fcb$nr db 0,0,0 + endif + @bootdu db 0 hdspv db 2 ; slices per volume for hard disks (must be >= 1) diff --git a/Source/CPM3/genbnk.dat b/Source/CPM3/genbnk.dat index b3ca77b2..4a542bd3 100644 --- a/Source/CPM3/genbnk.dat +++ b/Source/CPM3/genbnk.dat @@ -8,7 +8,7 @@ MEMTOP = FD BNKSWT = Y COMBAS = 80 LERROR = Y -NUMSEGS = 02 +NUMSEGS = 03 MEMSEG00 = 01,43,00 MEMSEG01 = 0E,72,02 MEMSEG02 = 01,7F,03 diff --git a/Source/CPM3/optbnk.lib b/Source/CPM3/optbnk.lib index 7cfeb133..93dbb3c3 100644 --- a/Source/CPM3/optbnk.lib +++ b/Source/CPM3/optbnk.lib @@ -5,4 +5,4 @@ false equ not true banked equ true -drvswap equ false +zpm equ false diff --git a/Source/CPM3/optres.lib b/Source/CPM3/optres.lib index cbfd10c7..1c08bd24 100644 --- a/Source/CPM3/optres.lib +++ b/Source/CPM3/optres.lib @@ -5,4 +5,4 @@ false equ not true banked equ false -drvswap equ false +zpm equ false diff --git a/Source/CPM3/optswp.lib b/Source/CPM3/optzpm.lib similarity index 83% rename from Source/CPM3/optswp.lib rename to Source/CPM3/optzpm.lib index 52448081..eba22e9b 100644 --- a/Source/CPM3/optswp.lib +++ b/Source/CPM3/optzpm.lib @@ -6,4 +6,4 @@ false equ not true banked equ true -drvswap equ true +zpm equ true diff --git a/Source/Images/hd_cpm3/s0/u0/GENCPM.COM b/Source/Images/hd_cpm3/s0/u0/GENCPM.COM new file mode 100644 index 00000000..d9d67499 Binary files /dev/null and b/Source/Images/hd_cpm3/s0/u0/GENCPM.COM differ diff --git a/Source/Images/hd_cpm3/s0/u0/WBW.TXT b/Source/Images/hd_cpm3/s0/u0/ROMWBW.TXT similarity index 69% rename from Source/Images/hd_cpm3/s0/u0/WBW.TXT rename to Source/Images/hd_cpm3/s0/u0/ROMWBW.TXT index 9bdf3827..8e3f0534 100644 --- a/Source/Images/hd_cpm3/s0/u0/WBW.TXT +++ b/Source/Images/hd_cpm3/s0/u0/ROMWBW.TXT @@ -1,3 +1,10 @@ +This is a generic CP/M 3 adaptation for RomWBW. + +To start CP/M 3, first boot into CP/M 2.2 or ZSystem. Then +switch to the drive that contains the CP/M 3 hard disk image +and run CPMLDR. You will be prompted for the disk unit +of the CP/M 3 image. + With the following exceptions, the files in this directory came from the CP/M 3 binary distribution on "The Unofficial CP/M Web site" at http://www.cpm.z80.de/binary.html. diff --git a/Source/Images/hd_zpm3/s0/u0/ROMWBW.TXT b/Source/Images/hd_zpm3/s0/u0/ROMWBW.TXT new file mode 100644 index 00000000..3d2181d5 --- /dev/null +++ b/Source/Images/hd_zpm3/s0/u0/ROMWBW.TXT @@ -0,0 +1,51 @@ +This is a generic ZPM3 adaptation for RomWBW. + +To start ZPM3, first boot into CP/M 2.2 or ZSystem. Then +switch to the drive that contains the ZPM3 hard disk image +and run CPMLDR. You will be prompted for the disk unit +of the ZPM3 image. + +You may notice that there is a ZPMLDR application on the +hard disk image. This application is equivalent to CPMLDR, +but it has some issues with the number of drives that +RomWBW supports. So, as indicated above, use CPMLDR to +launch ZPM3. + +I have not found a way to make ZPM3 start up with any drive +other than A: as the system drive. So, during the load +process, the boot drive and drive A: are "swapped" so that +the boot drive is always drive A:. Use the ASSIGN +command after starting ZPM3 to see how the drives get +mapped. + +Per ZPM3 standard, files are distributed across different +user areas depending on their usage. Normal applications +are in user 15. Help files in user 10. Configuration +files in user 14. + +In addition to the applications provided in the ZPM3 +distributio, the normal CP/M 3 files are included in user +area 15. A few typical ZCPR utility programs are also included +in user area 15: + + - ALIAS + - ARUNZ + - ERASE + - HELPC (named ZHELP) + - LBREXT + - SALIAS + - SETPATH + - VERRROR + - VLU + - ZCNFG + - ERASE (named ZERASE) + - ZEX + - ZFILER + - ZP + - SHOW (named ZSHOW) + - ZXD + +It is a bit confusing, but the ZPM3 system file is called CPM3.SYS. +This is the ZPM3 default configuration and I guess it is done this +way to maximize compatibility with CP/M 3. You will notice that +the startup banner will indicate ZPM3. \ No newline at end of file diff --git a/Source/Images/hd_zpm3/s0/u0/WBW.TXT b/Source/Images/hd_zpm3/s0/u0/WBW.TXT deleted file mode 100644 index cea4a982..00000000 --- a/Source/Images/hd_zpm3/s0/u0/WBW.TXT +++ /dev/null @@ -1,20 +0,0 @@ -This an experimental adaptation of ZPM3 for RomWBW. - -Launch ZPM3 using CPMLDR. ZPMLDR is not working reliably -at this time. - -I have not found a way to make ZPM3 start up with any drive -other than A: as the system drive. So, during the load -process, the boot drive and drive A: are "swapped" so that -the boot drive is always drive A:. Use the ASSIGN -command after starting ZPM3 to see how the drives get -mapped. - -Per ZPM3 standard, files are distributed across different -user areas depending on their usage. Normal applications -are in user 15. Help files in user 10. Configuration -files in user 14. - -ZSID6.COM is the original DRI ZSID distribution, but -patched to use RST 6 instead of RST 7 to avoid conflicting -with mode 1 interrupts. diff --git a/Source/Images/hd_zpm3/s0/u10/HELP.HLP b/Source/Images/hd_zpm3/s0/u10/HELP.HLP deleted file mode 100644 index 428c767a..00000000 Binary files a/Source/Images/hd_zpm3/s0/u10/HELP.HLP and /dev/null differ diff --git a/Source/Images/hd_zpm3/s0/u10/ZHELP.COM b/Source/Images/hd_zpm3/s0/u10/ZHELP.COM deleted file mode 100644 index 714e1288..00000000 Binary files a/Source/Images/hd_zpm3/s0/u10/ZHELP.COM and /dev/null differ diff --git a/Source/Images/hd_zpm3/s0/u15/gencpm.com b/Source/Images/hd_zpm3/s0/u15/gencpm.com new file mode 100644 index 00000000..d9d67499 Binary files /dev/null and b/Source/Images/hd_zpm3/s0/u15/gencpm.com differ diff --git a/Source/ZPM3/Build.cmd b/Source/ZPM3/Build.cmd index be0b723d..9537f2e0 100644 --- a/Source/ZPM3/Build.cmd +++ b/Source/ZPM3/Build.cmd @@ -9,14 +9,13 @@ set ZXBINDIR=%TOOLS%/cpm/bin/ set ZXLIBDIR=%TOOLS%/cpm/lib/ set ZXINCDIR=%TOOLS%/cpm/include/ -copy ..\ZCCP\ccp.com . +copy ..\ZCCP\ccp.com zccp.com copy ..\ZCCP\zinstal.zpm . copy ..\ZCCP\startzpm.com . copy ..\CPM3\genbnk.dat . -copy ..\CPM3\swpbios3.spr bnkbios3.spr +copy ..\CPM3\zpmbios3.spr bnkbios3.spr copy ..\CPM3\gencpm.com . copy ..\CPM3\biosldr.rel . - copy ..\CPM3\cpmldr.com . rem ZPM Loader @@ -27,7 +26,7 @@ echo. zx LINK -ZPMLDR[L100]=ZPM3LDR,BIOSLDR rem pause -rem Banked CPM3 +rem Banked ZPM3 echo. echo. echo *** Banked ZPM3 *** @@ -45,17 +44,19 @@ echo *** Update Disk Image *** echo. for %%f in ( zpmldr.com + cpmldr.com autotog.com clrhist.com setz3.com cpm3.sys - ccp.com + zccp.com zinstal.zpm startzpm.com makedos.com + gencpm.dat + bnkbios3.spr bnkbdos3.spr resbdos3.spr - cpmldr.com ) do call :upd_img %%f goto :eof diff --git a/Source/ZPM3/Clean.cmd b/Source/ZPM3/Clean.cmd index 3349c63e..91ffcb36 100644 --- a/Source/ZPM3/Clean.cmd +++ b/Source/ZPM3/Clean.cmd @@ -1,7 +1,7 @@ @echo off setlocal -if exist ccp.com del ccp.com +if exist zccp.com del zccp.com if exist *.sys del *.sys if exist gencpm.dat del gencpm.dat if exist loader.cim del loader.cim