Compare commits

...

82 Commits

Author SHA1 Message Date
Wayne Warthen
a0d1825701 Bump Version 2025-05-08 16:46:30 -07:00
Wayne Warthen
cc2fda0cc2 Update pull_request_template.md 2025-05-08 16:42:51 -07:00
Wayne Warthen
e67b0f7e24 Restore EZZ80 Platform Config
Per Issue #541, a platform configuration file has been created for the EZZ80 platform.  The two ROM builds for this platform have changed prefix from RCZ80 to EZZ80.
2025-05-08 13:22:22 -07:00
Wayne Warthen
96d0900cf7 Merge pull request #542 from kiwisincebirth/map/doc-hw1
Reorganise HW Guide into sections per platform
2025-05-08 12:05:50 -07:00
Mark Pruden
98441355c9 Reorganise HW Guide into sections per platform 2025-05-08 19:48:31 +10:00
Wayne Warthen
2e0f7922ec Regen PDF Docs 2025-05-07 11:11:25 -07:00
Wayne Warthen
df3a9e7756 Merge pull request #539 from kiwisincebirth/map/improve-doc-platform
Documentation Improvements, fix omissions
2025-05-07 10:59:29 -07:00
Wayne Warthen
5e7f359b82 Merge branch 'master' into map/improve-doc-platform 2025-05-07 10:58:58 -07:00
Wayne Warthen
4ef452bcd8 Update System Guide Source
- The SystemGuide.md file associated with Issue #538 was accidentally omitted.  Thanks and credit to @kiwisincebirth for pointing this out!
2025-05-07 10:52:50 -07:00
Mark Pruden
d1af2ea8c0 Minor improvement to System Guide 2025-05-07 18:04:47 +10:00
Mark Pruden
cda51f7277 Documentation Improvements, fix omissions 2025-05-07 17:38:19 +10:00
Wayne Warthen
094545dcbb Missing Platform IDs in System Guide, Issue #538
Added missing platform IDs in the System Guide.  Thanks and credit to @hubertushirsch.
2025-05-03 11:35:28 -07:00
Wayne Warthen
d79dce64fe Regen Docs 2025-05-02 19:27:53 -07:00
Wayne Warthen
c1152cfe17 Merge pull request #537 from kiwisincebirth/map/doc-buffer_bank
Minor doc improvements
2025-05-02 19:22:16 -07:00
Mark Pruden
ea418f9dc4 Bugfix for SLABEL.COM 2025-05-02 22:04:47 +10:00
Wayne Warthen
5118ab8d0a Hardware Probing Conflicts, Issue #536
Mitigate issue where a hardware probe can corrupt the programming of a previously discovered device.
2025-04-29 13:55:35 -07:00
Wayne Warthen
e42c04d40f Bump Version for New Release Candidate 2025-04-25 13:55:20 -07:00
Wayne Warthen
3618e0a976 Font Map Images Update
- Cleanup of the .PNG images of the fonts.
2025-04-25 13:42:43 -07:00
Wayne Warthen
d0aad220df SLABEL Follow Up
- Source corrections related to TASM assembly
- Regen documentation
2025-04-25 10:57:11 -07:00
Wayne Warthen
98e633461f Merge pull request #534 from kiwisincebirth/map/slabel
New SLABEL.COM Utility
2025-04-25 10:04:25 -07:00
Wayne Warthen
cb33018341 Update Cowgol Disk Image
- Latest from Ladislau
- See <https://groups.google.com/g/rc2014-z80/c/sBCCIpOnnGg>

Co-Authored-By: ladislau szilagyi <87603175+Laci1953@users.noreply.github.com>
2025-04-24 18:00:16 -07:00
Wayne Warthen
07c08e2817 System Guide Doc Fix
- See discussion at <https://groups.google.com/g/rc2014-z80/c/TIQv8-q4R2s>
2025-04-24 17:42:03 -07:00
Mark Pruden
37f01810f5 Bugfix for SLABEL.COM 2025-04-23 10:28:59 +10:00
Mark Pruden
9b4dd7b1bb Minor correction to applicatons.md 2025-04-23 10:18:11 +10:00
Mark Pruden
98414da4d5 New SLABEL.COM Utility 2025-04-23 08:35:42 +10:00
Wayne Warthen
3450ce71a6 Bump Version for Release Candidate 2025-04-17 12:41:13 -07:00
Wayne Warthen
f162081ec1 Refactor ZMP Overlay
- ZMP was crashing in most scenarios.  This was corrected.
- Minor adjustments to ZMP usage
- Added ZMP documentation
2025-04-17 11:53:53 -07:00
Wayne Warthen
6222f7410a Document ZPM3 Cmd Line Keys, Issue #533
When Jon Saxton fixed some ZPM3 bugs, he also made some minor changes to the command line editing key bindings.  These changes have been better documented.

Thanks and credit to @jduraes for reporting this.
2025-04-13 15:05:23 -07:00
Wayne Warthen
665067eb25 Merge pull request #532 from kiwisincebirth/map/z80asm-rename
Corrected Naming of SLRNKP.COM (SLR Link Plus)
2025-04-12 18:12:44 -07:00
Mark Pruden
dd25180f7c Corrected Naming of SLRNKP.COM (SLR Link Plus) 2025-04-13 11:09:04 +10:00
Wayne Warthen
ea38e8e93b Regen Doc 2025-04-11 19:33:24 -07:00
Wayne Warthen
ddb2da2b8f Merge pull request #531 from kiwisincebirth/map/z80asm-doc3
Better documentation for the Z80ASM toolset.
2025-04-11 19:20:10 -07:00
Mark Pruden
3268d99b43 Better documentation 2025-04-12 11:52:15 +10:00
Wayne Warthen
a5314c992d Fix for SYSCOPY w/ CPM 3, Issue #529
- Corrected the size of CPMLDR.SYS to conform to the needs of  SYSCOPY and the RomWBW loader.
2025-04-10 15:44:06 -07:00
Wayne Warthen
683f31438f Regen Doc 2025-04-09 14:03:20 -07:00
Wayne Warthen
69e9eb0805 Merge pull request #526 from kiwisincebirth/map/z80asm-newer
Added Updated SLR Tools with newer or missing versions
2025-04-09 13:54:51 -07:00
Wayne Warthen
d18208ef6b Regen Doc 2025-04-09 13:46:11 -07:00
Wayne Warthen
9ec4b0aa4d Merge pull request #525 from codesmythe/typo
Fix a couple of typos.
2025-04-09 13:40:14 -07:00
Mark Pruden
10dcc4300e Added Updated SLR Tools with newer or missing versions 2025-04-09 19:31:25 +10:00
Rob Gowin
ce65f8dce0 Fix a couple of typos. 2025-04-07 21:25:58 -05:00
Wayne Warthen
ad4c4ac81b Merge pull request #524 from wwarthen/patch
Fix Baud Rate Reference in User Guide, Issue #523
2025-04-07 18:00:18 -07:00
Wayne Warthen
31dc8a72d4 Fix Baud Rate Reference in User Guide, Issue #523
Thanks and credit to @codesmythe.
2025-04-07 17:59:30 -07:00
Wayne Warthen
e4daa2d727 Merge pull request #522 from wwarthen/patch
Add Missing BCLOAD File
2025-04-06 13:46:23 -07:00
Wayne Warthen
a8d2017abc Add Missing BCLOAD File
Marshall Gates reported that the Microsoft BASIC Compiler disk image is missing the file called "BCLOAD".  Adding file back into disk image.
2025-04-06 13:43:15 -07:00
Wayne Warthen
f81e089d63 Finalize Version 3.5 2025-04-04 15:32:15 -07:00
Wayne Warthen
acc32dc819 Update Hardware Document 2025-04-04 14:59:51 -07:00
Wayne Warthen
ca29e429e7 Tweaks to System Guide 2025-04-04 09:28:46 -07:00
Wayne Warthen
39afeda279 Documentation Tweaks 2025-04-03 16:19:23 -07:00
Wayne Warthen
23c5f7b8c0 Merge pull request #519 from fraser125/fraser125-Front-Panel-Table
Update UserGuide.md - Front Panel Table
2025-04-03 15:26:52 -07:00
fraser
91c7349026 Update UserGuide.md - Front Panel Table
I thought a Table layout for the Front Panel switches would be a bit easier to follow.
2025-04-03 14:50:43 -07:00
Wayne Warthen
80995f5264 Update TE.COM
@Laci1953 updated TE under RomWBW to support up to 512K of RAM buffers.
2025-04-03 13:52:56 -07:00
Wayne Warthen
56c9edb547 Updates to TE and COWFE
- Minor updates to TE.COM and COWFE.COM provided by @Laci1953.
- Fixed typo in TE ReadMe identified by @stickbreaker.

Co-Authored-By: ladislau szilagyi <87603175+Laci1953@users.noreply.github.com>
2025-04-02 11:20:00 -07:00
Wayne Warthen
af21691d4e Add TE Editor
Added latest RomWBW version of TE Editor from @Laci1953.

Co-Authored-By: ladislau szilagyi <87603175+Laci1953@users.noreply.github.com>
2025-04-01 12:07:51 -07:00
Wayne Warthen
3a228e3c1f Merge pull request #517 from kiwisincebirth/map/doc-hdd
Improvements to User Guide by improving readability
2025-03-31 17:45:12 -07:00
Mark Pruden
d299a9009f Corrected unintended deleteion 2025-04-01 11:42:47 +11:00
Mark Pruden
667aeeb24d Improvements to User Guide by simplifying content 2025-04-01 11:36:15 +11:00
Wayne Warthen
067560ae74 More User Guide Improvements from Issue #516
Thanks and credit to @kiwisincebirth for the suggestions.
2025-03-31 16:50:29 -07:00
Wayne Warthen
ef0656f162 Improve User Guide per Issue #516
- Small changes to Combo Hard Disk Images section as suggested by @kiwisincebirth.
2025-03-31 13:50:50 -07:00
Wayne Warthen
a8a5a85c5c Update Cowgol Disk Image, Issue #506
Updated Cowgol disk image with the latest distribution from Ladislau Szilagyi.

Co-Authored-By: ladislau szilagyi <87603175+Laci1953@users.noreply.github.com>
2025-03-29 14:06:34 -07:00
Wayne Warthen
4dcd00089e Bump Version, Release Candidate 1 2025-03-28 19:44:46 -07:00
Wayne Warthen
f4caf244af Update Makefile
- Fix filename case
2025-03-28 17:32:40 -07:00
Wayne Warthen
a91deeb347 Add Peter Onion's ZDE ANSI Keyboard Support
- Added new ANSI keyboard support from Peter Onion.
- ZDE is now built as part of the RomWBW build itself.
- Did not yet include support for modified ZDE escape character.
- See <https://groups.google.com/g/rc2014-z80/c/hAZen3pZb7o>

Co-Authored-By: PeterOGB <7755057+peterogb@users.noreply.github.com>
2025-03-28 17:25:55 -07:00
Wayne Warthen
3804c69428 Minor Typos & Regen Doc 2025-03-26 12:51:47 -07:00
Wayne Warthen
1b45d32af2 Merge pull request #513 from kiwisincebirth/map/disk-doc
Revised Section 6.2.4 of UserGuide
2025-03-26 12:38:48 -07:00
Wayne Warthen
83e3b8f24f Resolve Merge Conflict 2025-03-26 11:55:51 -07:00
Wayne Warthen
29f6fea4aa Resolve Merge Conflict 2025-03-26 11:51:55 -07:00
Wayne Warthen
bf61350280 Regen Docs 2025-03-26 11:41:26 -07:00
Wayne Warthen
ecf2cdfba2 Fix Device Attribute Definition in System Guide, Issue #515 2025-03-26 11:37:41 -07:00
Wayne Warthen
9fc2c6129b Fix CIO Table in System Guide, Issue #514 2025-03-26 11:23:23 -07:00
Mark Pruden
8f80f2f9cd Revised Section 6.2.4 of UserGuide See Issue #508 2025-03-26 13:39:37 +11:00
Wayne Warthen
81d81952d3 Regen Docs 2025-03-24 11:30:12 -07:00
Wayne Warthen
ed532cb51b Fix Type in INTINF API Description, Issue #512 2025-03-24 11:20:27 -07:00
Wayne Warthen
a46e05258c Clarify .COM File Location and Naming. Issue #511 2025-03-24 11:17:30 -07:00
Wayne Warthen
a35dbefeda Fix System Guide Typo, Issue #510 2025-03-24 11:12:32 -07:00
Wayne Warthen
74f4149034 Merge pull request #509 from kiwisincebirth/map/drivereset
COPYSL : Reset CP/M Drives after Completion.
2025-03-22 18:40:19 -07:00
Mark Pruden
34cc40f459 Added Code to Reset All Drives after successful completion. 2025-03-22 22:10:32 +11:00
Wayne Warthen
6f5aa06fb3 Improve cpmtools Makefile, Issue #505
See issue #505.  This change should improve build compatibility if there are multiple variants of ncurses installed.

Thanks and credit to @mabartibin.

Co-Authored-By: mabartibin <16798058+mabartibin@users.noreply.github.com>
2025-03-21 18:50:49 -07:00
Wayne Warthen
b28e308bfd Include COPYSL in Build Process 2025-03-21 17:01:14 -07:00
Wayne Warthen
3d23cea071 Merge pull request #507 from kiwisincebirth/map/copysl
Source Code (Inactive) for CopySL Utility
2025-03-21 16:19:42 -07:00
Mark Pruden
f7b8efd964 Added source Code for copySL, build scripts not updated 2025-02-27 10:21:29 +11:00
Wayne Warthen
3c7e3d7586 Issue v3.5 Release Candidate 2025-02-24 12:30:05 -08:00
Wayne Warthen
f359f5fb61 Update SIMH Emulator 2025-02-22 16:19:08 -08:00
168 changed files with 51466 additions and 9695 deletions

View File

@@ -7,5 +7,7 @@ BEFORE YOU CREATE A PULL REQUEST:
Thank you for contributing to RomWBW! I will review your pull request as soon as possible.
-Wayne
DELETE EVERYTHING IN THIS COMMENT BLOCK AND REPLACE WITH YOUR COMMENTS
-->

View File

@@ -9,5 +9,8 @@ if exist Tunes\*.pt? del Tunes\*.pt?
if exist Tunes\*.mym del Tunes\*.mym
if exist Tunes\*.vgm del Tunes\*.vgm
if exist bbcbasic.txt del bbcbasic.txt
if exist *.cfg del *.cfg
if exist *.fon del *.fon
pushd Test && call Clean || exit /b 1 & popd
pushd ZDE && call Clean || exit /b 1 & popd

View File

@@ -1,6 +1,6 @@
TOOLS = ../../Tools
MOREDIFF := $(shell $(TOOLS)/unix/casefn.sh *.com)
SUBDIRS = Test
SUBDIRS = Test ZDE
include $(TOOLS)/Makefile.inc
@@ -8,4 +8,4 @@ all::
mkdir -p Tunes
clean::
@rm -f *.bin *.com *.img *.rom *.pdf *.log *.eeprom *.ovr *.hlp *.doc *.COM *.BIN Tunes/*.mym Tunes/*.pt? Tunes/*.vgm bbcbasic.txt
@rm -f *.bin *.com *.img *.rom *.pdf *.log *.eeprom *.ovr *.hlp *.doc *.COM *.BIN Tunes/*.mym Tunes/*.pt? Tunes/*.vgm bbcbasic.txt *.cfg *.fon

View File

@@ -0,0 +1,4 @@
@echo off
setlocal
if exist *.com del *.com

6
Binary/Apps/ZDE/Makefile Normal file
View File

@@ -0,0 +1,6 @@
TOOLS = ../../../Tools
include $(TOOLS)/Makefile.inc
clean::
@rm -f *.com

View File

@@ -0,0 +1,10 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory contains the ZDE executable binaries. They are
in their original, unconfigured state.

View File

@@ -1,3 +1,12 @@
Version 3.5.1
-------------
- WBW: Fix CPMLDR.SYS & ZPMLDR.SYS for SYSCOPY (reported by Guido Santer)
- MAP: Enhanced SLR Tools Disk Image with Plus versions
- WBW: Add missing BCLOAD file to MS BASIC Compiler Disk Image (reported by Marshall Gates)
- WBW: Doc improvements (per Fraser and Rob Gowin)
- WBW: Correct ZMP application crash
- MAP: Contribution of the SLABEL.COM tool for displaying and changing slice labels.
Version 3.5
-----------
- M?F: Fix for hours display in HBRTC application
@@ -56,6 +65,8 @@ Version 3.5
- D?M: Added NetBoot support for Duodyne
- WBW: Add options to TUNE/HBIOS to force detection of MSX and RC AY/YM standard PSG ports
- MAP: Added /B=OPTIONS for automated drive assignment to ASSIGN.COM
- WBW: Added TE Editor (Ladislau Szilagyi)
- WBW: Refrech Cowgol disk image (Ladislau Szilagyi)
Version 3.4
-----------

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -51,7 +51,7 @@ release of RomWBW.
allows OS to recover from applications that reprogram the TMS
video display controller.
- Implemented "application" RAM banks that can be discovered bia
- Implemented "application" RAM banks that can be discovered via
the HBIOS API.
- Documentation improvements (Mark Pruden), including:
@@ -67,6 +67,8 @@ release of RomWBW.
- `COPYSL` slice copy application (Mark Pruden).
- `SLABEL` slice label display/edit tool (Mark Pruden).
- Improved disk slice management and protection (Mark Pruden).
- Initial NVRAM configuration support (Mark Pruden).

View File

@@ -7,7 +7,7 @@
**RomWBW Introduction** \
Version 3.5 \
Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \
22 Feb 2025
08 May 2025
# Overview

View File

@@ -1,6 +1,6 @@
RomWBW Introduction
Wayne Warthen (wwarthen@gmail.com)
22 Feb 2025
08 May 2025
@@ -17,11 +17,11 @@ Z80/180/280 retro-computing hardware systems.
A wide variety of platforms are supported including those produced by
these developer communities:
- RetroBrew Computers (https://www.retrobrewcomputers.org)
- RC2014 (https://rc2014.co.uk),
RC2014-Z80 (https://groups.google.com/g/rc2014-z80)
- Retro Computing (https://groups.google.com/g/retro-comp)
- Small Computer Central (https://smallcomputercentral.com/)
- RetroBrew Computers (https://www.retrobrewcomputers.org)
- RC2014 (https://rc2014.co.uk),
RC2014-Z80 (https://groups.google.com/g/rc2014-z80)
- Retro Computing (https://groups.google.com/g/retro-comp)
- Small Computer Central (https://smallcomputercentral.com/)
A complete list of the currently supported platforms is found in RomWBW
Hardware .
@@ -41,16 +41,16 @@ Card) and move it between systems transparently.
Supported hardware features of RomWBW include:
- Z80 Family CPUs including Z80, Z180, and Z280
- Banked memory services for several banking designs
- Disk drivers for RAM, ROM, Floppy, IDE ATA/ATAPI, CF, SD, USB, Zip,
Iomega
- Serial drivers including UART (16550-like), ASCI, ACIA, SIO
- Video drivers including TMS9918, SY6545, MOS8563, HD6445
- Keyboard (PS/2) drivers via VT8242 or PPI interfaces
- Real time clock drivers including DS1302, BQ4845
- Support for CP/NET networking using Wiznet, MT011 or Serial
- Built-in VT-100 terminal emulation support
- Z80 Family CPUs including Z80, Z180, and Z280
- Banked memory services for several banking designs
- Disk drivers for RAM, ROM, Floppy, IDE ATA/ATAPI, CF, SD, USB, Zip,
Iomega
- Serial drivers including UART (16550-like), ASCI, ACIA, SIO
- Video drivers including TMS9918, SY6545, MOS8563, HD6445
- Keyboard (PS/2) drivers via VT8242 or PPI interfaces
- Real time clock drivers including DS1302, BQ4845
- Support for CP/NET networking using Wiznet, MT011 or Serial
- Built-in VT-100 terminal emulation support
A dynamic disk drive letter assignment mechanism allows mapping
operating system drive letters to any available disk media.
@@ -73,22 +73,22 @@ changing media.
Some of the included software:
- Operating Systems (CP/M 2.2, ZSDOS, NZ-COM, CP/M 3, ZPM3, Z3PLUS,
QPM )
- Support for other operating systems, p-System, FreeRTOS, and FUZIX.
- Programming Tools (Z80ASM, Turbo Pascal, Forth, Cowgol)
- C Compilers including Aztec-C, and HI-TECH C
- Microsoft Basic Compiler, and Microsoft Fortran
- Some games such as Colossal Cave, Zork, etc
- Wordstar Word processing software
- Operating Systems (CP/M 2.2, ZSDOS, NZ-COM, CP/M 3, ZPM3, Z3PLUS, QPM
)
- Support for other operating systems, p-System, FreeRTOS, and FUZIX.
- Programming Tools (Z80ASM, Turbo Pascal, Forth, Cowgol)
- C Compilers including Aztec-C, and HI-TECH C
- Microsoft Basic Compiler, and Microsoft Fortran
- Some games such as Colossal Cave, Zork, etc
- Wordstar Word processing software
Some of the provided software can be launched directly from the ROM
firmware itself:
- System Monitor
- Operating Systems (CP/M 2.2, ZSDOS)
- ROM BASIC (Nascom BASIC and Tasty BASIC)
- ROM Forth
- System Monitor
- Operating Systems (CP/M 2.2, ZSDOS)
- ROM BASIC (Nascom BASIC and Tasty BASIC)
- ROM Forth
A tool is provided that allows you to access a FAT-12/16/32 filesystem.
The FAT filesystem may be coresident on the same disk media as RomWBW
@@ -174,25 +174,24 @@ Documentation
There are several documents that form the core of the RomWBW
documentation:
- RomWBW User Guide is the main user guide for RomWBW, it covers the
major topics of how to install, manage and use RomWBW, and includes
additional guidance to the use of some of the operating systems
supported by RomWBW
- RomWBW User Guide is the main user guide for RomWBW, it covers the
major topics of how to install, manage and use RomWBW, and includes
additional guidance to the use of some of the operating systems
supported by RomWBW
- RomWBW Hardware contains a description of all the hardware
platforms, and devices supported by RomWBW.
- RomWBW Hardware contains a description of all the hardware platforms,
and devices supported by RomWBW.
- RomWBW Applications is a reference for the ROM-hosted and OS-hosted
applications created or customized to enhance the operation of
RomWBW.
- RomWBW Applications is a reference for the ROM-hosted and OS-hosted
applications created or customized to enhance the operation of RomWBW.
- RomWBW Disk Catalog is a reference for the contents of the disk
images provided with RomWBW, with a description of many of the files
on each image
- RomWBW Disk Catalog is a reference for the contents of the disk images
provided with RomWBW, with a description of many of the files on each
image
- RomWBW System Guide discusses much of the internal design and
construction of RomWBW. It includes a reference for the RomWBW HBIOS
API functions.
- RomWBW System Guide discusses much of the internal design and
construction of RomWBW. It includes a reference for the RomWBW HBIOS
API functions.
Each of the operating systems and ROM applications included with RomWBW
are sophisticated tools in their own right. It is not reasonable to
@@ -217,9 +216,9 @@ Getting Assistance
The best way to get assistance with RomWBW or any aspect of the
RetroBrew Computers projects is via one of the community forums:
- RetroBrew Computers Forum
- RC2014 Google Group
- retro-comp Google Group
- RetroBrew Computers Forum
- RC2014 Google Group
- retro-comp Google Group
Submission of issues and bugs are welcome at the RomWBW GitHub
Repository.
@@ -244,110 +243,108 @@ RetroBrew Computers Community. I sincerely appreciate all of their
contributions. The list below is probably missing many names please
let me know if I missed you!
- Andrew Lynch started it all when he created the N8VEM Z80 SBC which
became the first platform RomWBW supported. Some of his original
code can still be found in RomWBW.
- Andrew Lynch started it all when he created the N8VEM Z80 SBC which
became the first platform RomWBW supported. Some of his original code
can still be found in RomWBW.
- Dan Werner wrote much of the code from which RomWBW was originally
derived and he has always been a great source of knowledge and
advice.
- Dan Werner wrote much of the code from which RomWBW was originally
derived and he has always been a great source of knowledge and advice.
- Douglas Goodall contributed code, time, testing, and advice in “the
early days”. He created an entire suite of application programs to
enhance the use of RomWBW. Unfortunately, they have become unusable
due to internal changes within RomWBW. As of RomWBW 2.6, these
applications are no longer provided.
- Douglas Goodall contributed code, time, testing, and advice in “the
early days”. He created an entire suite of application programs to
enhance the use of RomWBW. Unfortunately, they have become unusable
due to internal changes within RomWBW. As of RomWBW 2.6, these
applications are no longer provided.
- Sergey Kiselev created several hardware platforms for RomWBW
including the very popular Zeta.
- Sergey Kiselev created several hardware platforms for RomWBW including
the very popular Zeta.
- David Giles created support for the Z180 CSIO which is now included
SD Card driver.
- David Giles created support for the Z180 CSIO which is now included SD
Card driver.
- Phil Summers contributed the Forth and BASIC adaptations in ROM, the
AY-3-8910 sound driver, DMA support, and a long list of general code
and documentation enhancements.
- Phil Summers contributed the Forth and BASIC adaptations in ROM, the
AY-3-8910 sound driver, DMA support, and a long list of general code
and documentation enhancements.
- Ed Brindley contributed some of the code that supports the RCBus
platform.
- Ed Brindley contributed some of the code that supports the RCBus
platform.
- Spencer Owen created the RC2014 series of hobbyist kit computers
which has exponentially increased RomWBW usage. Some of his kits
include RomWBW.
- Spencer Owen created the RC2014 series of hobbyist kit computers which
has exponentially increased RomWBW usage. Some of his kits include
RomWBW.
- Stephen Cousins has likewise created a series of hobbyist kit
computers at Small Computer Central and is distributing RomWBW with
many of them.
- Stephen Cousins has likewise created a series of hobbyist kit
computers at Small Computer Central and is distributing RomWBW with
many of them.
- Alan Cox has contributed some driver code and has provided a great
deal of advice.
- Alan Cox has contributed some driver code and has provided a great
deal of advice.
- The CP/NET client files were developed by Douglas Miller.
- The CP/NET client files were developed by Douglas Miller.
- Phillip Stevens contributed support for FreeRTOS.
- Phillip Stevens contributed support for FreeRTOS.
- Curt Mayer contributed the original Linux / MacOS build process.
- Curt Mayer contributed the original Linux / MacOS build process.
- UNA BIOS and FDISK80 are the products of John Coffman.
- UNA BIOS and FDISK80 are the products of John Coffman.
- FLASH4 is a product of Will Sowerbutts.
- FLASH4 is a product of Will Sowerbutts.
- CLRDIR is a product of Max Scane.
- CLRDIR is a product of Max Scane.
- Tasty Basic is a product of Dimitri Theulings.
- Tasty Basic is a product of Dimitri Theulings.
- Dean Netherton contributed eZ80 CPU support, the sound driver
interface, and the SN76489 sound driver.
- Dean Netherton contributed eZ80 CPU support, the sound driver
interface, and the SN76489 sound driver.
- The RomWBW Disk Catalog document was produced by Mykl Orders.
- The RomWBW Disk Catalog document was produced by Mykl Orders.
- Rob Prouse has created many of the supplemental disk images
including Aztec C, HiTech C, SLR Z80ASM, Turbo Pascal, Microsoft
BASIC Compiler, Microsoft Fortran Compiler, and a Games compendium.
- Rob Prouse has created many of the supplemental disk images including
Aztec C, HiTech C, SLR Z80ASM, Turbo Pascal, Microsoft BASIC Compiler,
Microsoft Fortran Compiler, and a Games compendium.
- Martin R has provided substantial help reviewing and improving the
User Guide and Applications documents.
- Martin R has provided substantial help reviewing and improving the
User Guide and Applications documents.
- Mark Pruden has made a wide variety of contributions including:
- Mark Pruden has made a wide variety of contributions including:
- significant content in the Disk Catalog and User Guide
- creation of the Introduction and Hardware documents
- Z3PLUS operating system disk image
- COPYSL utility
- a feature for RomWBW configuration by NVRAM
- the /B bulk mode of disk assignment to the ASSIGN utility
- significant content in the Disk Catalog and User Guide
- creation of the Introduction and Hardware documents
- Z3PLUS operating system disk image
- COPYSL utility
- a feature for RomWBW configuration by NVRAM
- the /B bulk mode of disk assignment to the ASSIGN utility
- Jacques Pelletier has contributed the DS1501 RTC driver code.
- Jacques Pelletier has contributed the DS1501 RTC driver code.
- Jose Collado has contributed enhancements to the TMS driver
including compatibility with standard TMS register configuration.
- Jose Collado has contributed enhancements to the TMS driver including
compatibility with standard TMS register configuration.
- Kevin Boone has contributed a generic HBIOS date/time utility
(WDATE).
- Kevin Boone has contributed a generic HBIOS date/time utility (WDATE).
- Matt Carroll has contributed a fix to XM.COM that corrects the port
specification when doing a send.
- Matt Carroll has contributed a fix to XM.COM that corrects the port
specification when doing a send.
- Dean Jenkins enhanced the build process to accommodate the Raspberry
Pi 4.
- Dean Jenkins enhanced the build process to accommodate the Raspberry
Pi 4.
- Tom Plano has contributed a new utility (HTALK) to allow talking
directly to HBIOS COM ports.
- Tom Plano has contributed a new utility (HTALK) to allow talking
directly to HBIOS COM ports.
- Lars Nelson has contributed several generic utilities such as a
universal (OS agnostic) UNARC application.
- Lars Nelson has contributed several generic utilities such as a
universal (OS agnostic) UNARC application.
- Dylan Hall added support for specifying a secondary console.
- Dylan Hall added support for specifying a secondary console.
- Bill Shen has contributed boot loaders for several of his systems.
- Bill Shen has contributed boot loaders for several of his systems.
- Laszlo Szolnoki has contributed an EF9345 video display controller
driver.
- Laszlo Szolnoki has contributed an EF9345 video display controller
driver.
- Ladislau Szilagyi has contributed an enhanced version of CP/M Cowgol
that leverages RomWBW memory banking.
- Ladislau Szilagyi has contributed an enhanced version of CP/M Cowgol
that leverages RomWBW memory banking.
- Les Bird has contributed support for the NABU w/ Option Board
- Les Bird has contributed support for the NABU w/ Option Board
Related Projects

View File

@@ -29,6 +29,8 @@ call :build Survey || exit /b
call :build HTalk || exit /b
call :build BBCBASIC || exit /b
call :build copysl || exit /b
call :build slabel || exit /b
call :build ZDE || exit /b
goto :eof

View File

@@ -24,6 +24,8 @@ call :clean Survey || exit /b
call :clean HTalk || exit /b
call :clean BBCBASIC || exit /b
call :clean copysl || exit /b
call :clean slabel || exit /b
call :clean ZDE || exit /b
goto :eof

View File

@@ -1,5 +1,5 @@
SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd reboot Survey BBCBASIC copysl \
sysgen syscopy assign format talk mode rtc timer
slabel sysgen syscopy assign format talk mode rtc timer ZDE
TOOLS =../../Tools
include $(TOOLS)/Makefile.inc

View File

@@ -291,7 +291,7 @@ EXTRA3:
BIOID DB 0 ; BIOS ID, 1=HBIOS, 2=UBIOS
CPUSPD DB 10 ; CPU speed in MHz
RCVSCL DW 6600 ; RECV loop timeout scalar
UNIT DB 0 ; BIOS serial device unit number
UNIT DB 0FFH ; BIOS serial device unit number
BIOSBID DB 00H ; BIOS bank id
;
TAG DB "RomWBW, 30-May-2020$"
@@ -330,7 +330,7 @@ HB_JPTBL:
JP HB_GETCHR ; get character from modem
JP HB_RCVRDY ; check receive ready
JP HB_SNDRDY ; check send ready
JP HB_SPEED ; get speed value for file transfer time
JP HB_SPEED ; get speed value for file transfer time
;
;-----------------------------------------------------------------------
;
@@ -819,7 +819,6 @@ UF_INIT:
; Send character on top of stack
;
UF_SENDR:
POP AF ; get character to send from stack
OUT (0FFH),A ; write to fifo
UF_SCDP EQU $-1 ; data port

35
Source/Apps/ZDE/Build.cmd Normal file
View File

@@ -0,0 +1,35 @@
@echo off
setlocal
set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%TOOLS%\zxcc;%PATH%
set TASMTABS=%TOOLS%\tasm32
set CPMDIR80=%TOOLS%/cpm/
:: These variations of ZDE are built here as reference copies. They
:: are not copied anywhere else during the build.
:: The resulting .COM files are manually
:: copied to /Source/Images/d_ws/u1 as needed.
zxcc ZMAC -ZDE16 -/P -/H || exit /b
zxcc MLOAD25 ZDE16 || exit /b
copy /Y zde16.com ..\..\..\Binary\Apps\ZDE\ || exit /b
zxcc ZMAC ZDE16A.PAT -/H || exit /b
zxcc MLOAD25 ZDE16A=ZDE16.COM,ZDE16A.HEX || exit /b
copy /Y zde16a.com ..\..\..\Binary\Apps\ZDE\ || exit /b
zxcc ZMAC -ZDE17 -/P -/H || exit /b
zxcc MLOAD25 ZDE17 || exit /b
copy /Y zde17.com ..\..\..\Binary\Apps\ZDE\ || exit /b
zxcc ZMAC -ZDE18 -/P -/H || exit /b
zxcc MLOAD25 ZDE18 || exit /b
copy /Y zde18.com ..\..\..\Binary\Apps\ZDE\ || exit /b
zxcc ZMAC -ZDE19 -/P -/H || exit /b
zxcc MLOAD25 ZDE19 || exit /b
copy /Y zde19.com ..\..\..\Binary\Apps\ZDE\ || exit /b

View File

@@ -0,0 +1,9 @@
@echo off
setlocal
if exist *.prn del *.prn
if exist *.err del *.err
if exist *.rel del *.rel
if exist *.com del *.com
if exist *.hex del *.hex
if exist *.sym del *.sym

15
Source/Apps/ZDE/Makefile Normal file
View File

@@ -0,0 +1,15 @@
# These variations of ZDE are built here as reference copies. They
# are not copied anywhere else during the build.
# The resulting .COM files are manually
# copied to /Source/Images/d_ws/u1 as needed.
OBJECTS = zde16.com zde16a.com zde17.com zde18.com zde19.com
DEST = ../../../Binary/Apps/ZDE
TOOLS = ../../../Tools
OTHERS = *.hex
include $(TOOLS)/Makefile.inc
zde16a.com: zde16.com zde16a.pat
$(ZXCC) ZMAC zde16a.pat -/H
$(ZXCC) MLOAD25 zde16a=zde16.com,zde16a.hex || exit /b

38
Source/Apps/ZDE/ReadMe.md Normal file
View File

@@ -0,0 +1,38 @@
# ZDE 1.6 (Z-System Display Editor) reconstituted source - MECPARTS
11/19/2020
Using the source code of [VDE 2.67]
(http://www.classiccmp.org/cpmarchives/cpm/Software/WalnutCD/enterprs/cpm/utils/s/vde267sc.lbr)
as a guide, I've reconstituted the source code for [ZDE 1.6](http://www.classiccmp.org/cpmarchives/cpm/Software/WalnutCD/cpm/editor/zde16.lbr).
The resulting source code is available from the GitHub repository
https://github.com/mecparts/zde.
The source has been assembled with:
* Al Hawley's ZMAC: assemble as is.
* MicroSoft's M80: rename to ZDE16.MAC, un-comment the first two lines
and assemble. Use RELHEX to create ZDE16.HEX.
* ZASM (Cromemco's ASMB): Rename to ZDE16.Z80 and assemble. Use RELHEX
to create ZDE16.HEX.
Use MLOAD to create ZDE16.COM.
There are still a couple of routines new to ZDE that I haven't figured
out (yet). But most of them have been sussed out.
## ZDE 1.7 - MECPARTS 11/24/2020
I've fixed the "doesn't preserve timestamps for files larger than a
single extent under ZSDOS" bug that was present in v1.6. The existing
ZDENST16.COM program will work with the 1.7 to set the program up for
your terminal and printer.
## ZDE 1.8 - Lars Nelson 12/3/2022
Added routine to save create time stamp under CP/M Plus since
CP/M Plus, unlike ZSDOS, has no native ability to set time stamps.
## ZDE 1.9 - Peter Onion 03/27/2025
- Added support for ANSI PgUp, PgDn, Home, & End.
- Support ANSI F1 key for menu/error escape.

8111
Source/Apps/ZDE/zde16.z80 Normal file

File diff suppressed because it is too large Load Diff

102
Source/Apps/ZDE/zde16a.pat Normal file
View File

@@ -0,0 +1,102 @@
; This patch file modifies the officially-distributed .COM file
; for ZDE Ver 1.6 (copyright by Carson Wilson) to:
; - Correct a bug which did not preserve create times when
; editing files > 1 extent.
; - Use an apparently 'dead' byte in the configuration area as
; a configuration flag to allow disabling the 'Auto-Indent'
; feature which was always 'on' in ZDE1.6.
;
; With the second change, you may configure the 'Auto-Indent'
; feature to be active (as distributed) or disabled (as this patch
; is configured) by altering the DB at label 'AIDflt' in the
; second part of this patch file below.
;
; Assemble this file to a .HEX file (example uses ZMAC) as:
;
; ZMAC ZDE16A.PAT /H
;
; then overlay the resulting ZDE16.HEX onto ZDE16.COM with MYLOAD
; (or equivalent) as:
;
; MYLOAD ZDE.COM=ZDE.COM,ZDE16.HEX
;
; The resulting ZDE.COM will be identified as 'ZDE 1.6a' in the
; text identification string near the beginning of the .COM file.
;
; Harold F. Bower, 18 July 2001.
;
; CP/M Standard Equates
;
BDOS EQU 0005H
FCB EQU 005CH
DMA EQU 0080H
TPA EQU 0100H
;
SDMA EQU 26 ; CP/M Function to set DMA Address
;
; Needed locations within ZDE 1.6
;
Fill EQU TPA+0F8BH ; For Date Patch
TimBuf EQU TPA+3B3FH ; " " "
;
VTFlg EQU TPA+3ADAH ; For Auto-Ins Patch
HCRFlg EQU TPA+3AE3H ; " " " "
LfMarg EQU TPA+3AFDH ; " " " "
;
; ----------- Begin Patch File -----------
;
; --- Fix Create Time Stamp Preservation Error ---
ORG TPA+0029H
; was:
DB 'a, (C)' ; DB ', Copr.'
ORG TPA+2461H
; was:
LD (FCB+13),A ; CALL ClUsrF
;
ORG TPA+2F10H
; was:
LD B,4 ; CALL ClUsrF
CALL ClUsrF ; LD DE,TimBuf
LD DE,TimBuf ; LD C,SDMA
CALL SetDMA ; CALL BDOS
;
ORG TPA+30AAH
; was:
LD DE,DMA ; LD C,SDMA
SetDMA: LD C,SDMA ; LD DE,DMA
;
ORG TPA+30B4H
; was:
ClUsrF: XOR A ; XOR A
EX DE,HL ; LD (FCB+13),A
JP Fill ; RET
;
; --- Usurp Config Flag for Auto-Insert use, sense on startup ---
;
ORG TPA+0057H
; was: 0FFH
AIDflt: DB 00H ; Set Desired default (0=Off, FF=On)
;
ORG TPA+262AH
; was:
LD (LfMarg),HL ; LD HL,0101H
XOR A ; LD (LfMarg),HL
LD (VTFlg),A ; XOR A
LD (HCRFlg),A ; LD (VTFlg),A
NOP ; LD (HCRFlg),A
LD A,(AIDflt) ; DEC A
;
ORG TPA+2711H
; was:
NOP ; LD A,(0157H) {Unknown Use}
NOP ; OR A
NOP ; JP Z,Error2
NOP
NOP
NOP
NOP
;
;------------ End of Patch File ------------
END


8111
Source/Apps/ZDE/zde17.z80 Normal file

File diff suppressed because it is too large Load Diff

8567
Source/Apps/ZDE/zde18.z80 Normal file

File diff suppressed because it is too large Load Diff

8598
Source/Apps/ZDE/zde19.z80 Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -81,7 +81,7 @@ MINIT1:
SUB '0' ; Got it, convert to binary
LD (UNIT),A ; Save it
LD A,' ' ; Space character to accum
LD (HL),A ; Remove numberic from FCB
LD (HL),A ; Remove numeric from FCB
JR MINIT3 ; Proceed with initialization
MINIT2:
@@ -188,7 +188,6 @@ MINIT_UB1:
LD (UNIT),A ; and save it
;
MINIT_UB2:
;
JP UB_INIT ; UNA BIOS init
;
MINIT_RET:
@@ -221,7 +220,6 @@ MINIT_RET:
;
; Return with CPU speed in A
LD A,(CPUSPD) ; A := CPU speed in MHz
LD HL,(RCVSCL) ; HL := receive scalar
RET ; and return
;
;-----------------------------------------------------------------------
@@ -307,6 +305,22 @@ FAIL:
CALL BDOS ; Do it
JP 0 ; Bail out!
;
; Adjust CPUSPD to account for overhead of HBIOS or UBIOS. It appears
; that dividing CPU speed in MHz by 8 results in timeouts that are
; roughly correct.
;
SLOW:
LD A,(CPUSPD) ; Get true CPU speed
ADD A,4 ; Add for rounding
SRL A ; Divide by 8
SRL A
SRL A
JR NZ,SLOW1 ; If not zero, we are good
LD A,1 ; else, make it 1
SLOW1:
LD (CPUSPD),A ; Save it
RET
;
;-----------------------------------------------------------------------
;
; The following are all dummy routines that are unused because MINIT
@@ -326,7 +340,6 @@ EXTRA3:
;
BIOID DB 0 ; BIOS ID, 1=HBIOS, 2=UBIOS
CPUSPD DB 10 ; CPU speed in MHz
RCVSCL DW 6600 ; RECV loop timeout scalar
UNIT DB 0FFH ; BIOS serial device unit number
BIOSBID DB 00H ; BIOS bank id
;
@@ -373,8 +386,7 @@ HB_JPTBL:
; HBIOS initialization
;
HB_INIT:
LD HL,2150 ; Smaller receive loop timeout scalar
LD (RCVSCL),HL ; ... to compensate for BIOS overhead
CALL SLOW ; Adjust CPUSPD for HBIOS overhead
;
; Patch SENDR w/ FastPath addresses
LD BC,0F801H ; Get CIO func/data adr
@@ -412,10 +424,6 @@ HB_INIT:
RST 08
JP NZ,APIERR ; handle API error
LD (HB_SRFN),HL ; Plug in func adr
;
; Claim 1 MHz CPU to offset overhead of HBIOS
LD A,1
LD (CPUSPD),A ; Save it
;
LD HL,HB_JPTBL
LD DE,HB_LBL
@@ -564,14 +572,8 @@ UB_INIT:
;
; TODO:
; - TEST!!!
; - ADJUST RCVSCL?
;
LD HL,3000 ; Smaller receive loop timeout scalar
LD (RCVSCL),HL ; ... to compensate for BIOS overhead
;
; Claim 1 MHz CPU to offset overhead of HBIOS
LD A,1
LD (CPUSPD),A ; Save it
CALL SLOW ; Adjust CPUSPD for UBIOS overhead
;
LD HL,UB_JPTBL
LD DE,UB_LBL
@@ -721,9 +723,6 @@ UA_JPTBL:
; UART initialization
;
UA_INIT:
LD DE,13000 ; receive loop timeout scalar
LD (RCVSCL),DE ; ... for UART RCVRDY timing
;
LD A,L ; get base I/O port address
LD (UA_SCP),A ; set port value in SENDR
LD (UA_GCP),A ; set port value in GETCHR
@@ -842,9 +841,6 @@ UF_JPTBL:
; USB-FIFO initialization
;
UF_INIT:
LD DE,12000 ; receive loop timeout scalar
LD (RCVSCL),DE ; ... for UART RCVRDY timing
;
LD A,L ; get base I/O port address (data port)
LD (UF_SCDP),A ; set data port in SENDR
LD (UF_GCDP),A ; set data port in GETCHR/MDIN
@@ -863,7 +859,6 @@ UF_INIT:
; Send character on top of stack
;
UF_SENDR:
POP AF ; get character to send from stack
OUT (0FFH),A ; write to fifo
UF_SCDP EQU $-1 ; data port

View File

@@ -7,10 +7,13 @@ set PATH=%TOOLS%\zxcc;%PATH%
set CPMDIR80=%TOOLS%/cpm/
zxcc Z80ASM -ZMO-RW01/H || exit /b
zxcc MLOAD25 -ZMP.COM=ZMPX.COM,ZMO-RW01 || exit /b
:: zxcc Z80ASM -ZMO-RW01/LH || exit /b
zxcc Z80ASM -ZMO-WBW/LH || exit /b
zxcc MLOAD25 -ZMP.COM=ZMPX.COM,ZMO-WBW || exit /b
copy /Y zmp.com ..\..\..\Binary\Apps\ || exit /b
copy /Y *.ovr ..\..\..\Binary\Apps\ || exit /b
copy /Y zmp.cfg ..\..\..\Binary\Apps\ || exit /b
copy /Y zmp.fon ..\..\..\Binary\Apps\ || exit /b
copy /Y *.hlp ..\..\..\Binary\Apps\ || exit /b
copy /Y zmp.doc ..\..\..\Binary\Apps\ || exit /b

View File

@@ -1,10 +1,10 @@
OBJECTS = zmp.com *.ovr *.hlp zmp.doc
OBJECTS = zmp.com *.ovr zmp.cfg zmp.fon *.hlp zmp.doc
DEST = ../../../Binary/Apps
TOOLS = ../../../Tools
OTHERS = *.hex
NODELETE = *.ovr zmp.doc *.hlp
NODELETE = *.ovr zmp.doc zmp.cfg zmp.fon *.hlp
include $(TOOLS)/Makefile.inc
zmp.com: zmo-rw01.hex
$(ZXCC) MLOAD25 -ZMP.COM=ZMPX.COM,ZMO-RW01
zmp.com: zmo-wbw.hex
$(ZXCC) MLOAD25 -ZMP.COM=ZMPX.COM,ZMO-WBW

View File

@@ -27,4 +27,15 @@ as at Aug 23rd, 2021.
Untested on Ron Murrays ZMP15
- Space getting short so messages shortened.
--PMS 8/24/2021
--PMS 8/24/2021
- Refactored overlay to resolve some stack issues.
- Removed support for setport because it didn't make much sense
with ability to specify port on command line.
- Added an equate (pcfg) which controls whether port configuration
is implemented. It is set to false (no port configuration).
because ZMP it is unable to handle many RomWBW serial port settings
(notably the hard-wired 115200 baud of many RCBus systems). You
must now used MODE to configure port before starting ZMP.
--WBW 1:55 PM 4/16/2025

Binary file not shown.

Binary file not shown.

844
Source/Apps/ZMP/zmo-wbw.z80 Normal file
View File

@@ -0,0 +1,844 @@
;-----------------------------------------------------------------------------
;
; Overlay for ZMP (Z-Modem Program)
;
; Name ZMO-WBW.Z80
;
; Dated April 14, 2025
;
; Written by -
; Phil Summers, Wayne Warthen
;
; ROMWBW version using HBIOS and https://github.com/mecparts/zmp
; version of zmodem
;
; - All modem/serial i/o is through RomWBW HBIOS.
;
; - Data bits, stop bits, and parity are determined by HBIOS.
; The ZMP settings will have no effect. Use RomWBW MODE
; command to set serial port config before starting ZMP.
;
; - Timing delay calculations based on HBIOS reported CPU speed.
;
; - The pcfg equate determines whether the overlay will
; implement port initialization. Normally, pcfg will be
; set to false because ZMP does not allow configuring
; many HBIOS speeds (notably the 115200 baud hardwired
; into many RCBus systems). In this case, you must
; configure the modem port using the RomWBW
; MODE command as desired before starting ZMP.
;
; - The modem port is assigned to an HBIOS character unit. By
; default, the modem is assigned to HBIOS character unit 1.
; An alternate HBIOS character unit may be specified as a
; parameter on the command line as a single number. For
; example, the following will assign HBIOS port 3 as the
; ZMP modem port:
;
; ZMP 3
;
; - The original version of ZMP from Ron Murray allows you to
; select from 2 logical modem ports. This overlay ignores
; any attempt to select ports from within ZMP. The desired
; modem port should be assigned using the command line
; parameter as described above.
;
; - Teraterm users may need to change the ZmodemWinSize value
; to 1024 in the teraterm.ini configuration file.
;
;-----------------------------------------------------------------------------
;
;
; System-dependent code overlay for ZMODEM
;
;
;
; Insert your own code as necessary in this file. Code contained herein
; has been written in Z80 code for use with M80 or SLR. Assemble as follows:
;
; SLR ZMO-xx01/h
; MLOAD ZMP.COM=ZMODEM.COM,ZMO-xx01.HEX
; or
; M80 =ZMO-xx01.Z80
; RELHEX ZMO-xx01
; MLOAD ZMP.COM=ZMODEM.COM,ZMO-xx01.HEX
;
;
; (Don't use L80 without changing the source for assembly as a
; cseg file.)
;
;-----------------------------------------------------------------------------
;
;
; Notes on modifying this file:
;
; C requires that functions do not change either index register (IX or IY).
; If your overlay requires either of these to be changed, ensure they are
; restored to the original values on return.
; Since collecting parameters from C functions can be tricky, only change
; the parts marked 'Insert your own code here'. Do NOT modify the jump
; table at the start. Do NOT modify the entry/exit sections of each
; function. Do NOT pass 'GO'. Do NOT collect $200.
; Apart from defining modem functions, this file also defines terminal
; characteristics. Examples provided are for ADM-3A (with a few of my own
; additions). Modify to suit your own terminal. An inline print routine
; is provided for printing strings in the usual way: usage is
;
; call print
; db 'required string',0
;
;-----------------------------------------------------------------------------
;
;
; Don't forget to set your clock speed at the clkspd variable.
;
;
; If you find your overlay exceeds the maximum size (currently 0400h),
; you will have to contact me for another version. If too many people need
; to do it, we haven't allowed enough room.
;
; Ron Murray 15/8/88
;
;
;
;---------------------------------------------------------------------------
false equ 0
true equ not false
;------------------------------------------------------------------------------
; User-set variables:
debug equ false ; to allow debugging of overlay with Z8E etc.
clkspd equ 8 ; Processor clock speed in MHz
pcfg equ false ; Allow ZMP to configure port
;
;Set the following two equates to the drive and user area which will contain
; ZMP's .OVR files, .CFG file, .FON file and .HLP file. Set both to zero
; (null) to locate them on the drive from which ZMP was invoked.
overdrive equ 0 ; Drive to find overlay files on ('A'-'P')
overuser equ 0 ; User area to find files
;------------------------------------------------------------------------------
; NOT user-set variables
userdef equ 0145h ; origin of this overlay
; This address should not change with
; subsequent revisions.
mspeed equ 03ch ; location of current baud rate.
ovsize equ 0400h ; max size of this overlay
fcb equ 05ch ; primary command line CP/M fcb
.z80 ; use z80 code
aseg ; absolute
if debug
org 100h ; so you can debug it with cebug, zsid, etc
else
org userdef
endif
esc equ 1bh
ctrlq equ 11h
cr equ 0dh
lf equ 0ah
bdos equ 5
codebgn equ $
;Jump table for the overlay: do NOT change this
jump_tab:
jp scrnpr ; screen print
jp mrd ; modem read with timeout
jp mchin ; get a character from modem
jp mchout ; send a character to the modem
jp mordy ; test for tx buffer empty
jp mirdy ; test for character received
jp sndbrk ; send break
jp cursadd ; cursor addressing
jp cls ; clear screen
jp invon ; inverse video on
jp invoff ; inverse video off
jp hide ; hide cursor
jp show ; show cursor
jp savecu ; save cursor position
jp rescu ; restore cursor position
jp mint ; service modem interrupt
jp invec ; initialise interrupt vectors
jp dinvec ; de-initialise interrupt vectors
jp mdmerr ; test uart flags for error
jp dtron ; turn DTR on
jp dtroff ; turn DTR OFF
jp init ; initialise uart
jp wait ; wait seconds
jp mswait ; wait milliseconds
jp userin ; user-defined entry routine
jp userout ; user-defined exit routine
jp getvars ; get system variables
jp setport ; set port (0 or 1)
; Spare jumps for compatibility with future versions
jp spare ; spare for later use
jp spare ; spare for later use
jp spare ; spare for later use
jp spare ; spare for later use
jp spare ; spare for later use
jp spare ; spare for later use
; Local storage
hbunit db 1 ; Active HBIOS unit for modem I/O
cpumhz db clkspd ; CPU clock speed in MHz
;
; Main code starts here
;
;Screen print function
scrnpr:
; <== Insert your own code here
call print
db 'Screen print not supported.',cr,lf,0
; <== End of your own code
spare:
ret
; User-defined entry routine: leave empty if not needed
userin:
push bc
push de
push hl
call print
db cr,lf,'ZMP Overlay for RomWBW HBIOS v1.0',cr,lf,0
; Scan and parse default FCB to initialize HBIOS unit if
; specified.
ld a,(fcb + 1) ; get parm from fcb
cp ' ' ; anything there?
jr z,userin1 ; if empty, done
sub '0' ; ASCII to binary
jr c,parmerr ; less than 0, parm error
cp 10 ; >= 10?
jr nc,parmerr ; greater than 9, parm error
ld (hbunit),a ; save it
userin1:
call showcom ; show com port info
; check that unit is actually available in HBIOS
ld bc,0f800h ; get HBIOS char unit count
rst 8 ; do it
ld a,(hbunit) ; get active modem unit
cp e ; compare to units available
jr nc,porterr ; unit too high, port error
if pcfg
; Force port initialization by setting an invalid
; baud rate (mspeed).
; speed to an arbitrary value of 8 (9600 baud).
ld a,-1
ld (mspeed),a
else
; We don't support port configuration. Here we set the modem
; speed to an arbitrary value of 8 (9600 baud).
ld a,8
ld (mspeed),a
endif
ld bc,0f8f0h ; HBIOS func get CPU info
rst 08 ; do it, l = CPU speed in MHz
ld a,l ; to accum
ld (cpumhz),a ; and save it for wait loop
ld hl,2
call waithls
pop hl
pop de
pop bc
ret
parmerr:
; Handle a bad parameter
call print ; print error message
db cr,lf,'ZMP parameter error!',cr,lf,0
rst 0 ; bail out to OS
porterr:
; Handle a bad port
call print ; print error message
db cr,lf,'Invalid HBIOS unit for ZMP Modem port!',cr,lf,0
rst 0 ; bail out to OS
showcom:
; Display the HBIOS unit to be used for the ZMP Modem
call print
db cr,lf,'ZMP Modem on HBIOS Unit #',0
ld a,(hbunit)
add a,'0'
call cout
call print
db cr,lf,0
; User-defined exit routine: leave empty if not needed
userout:
ret
;Get a character from the modem: return in HL
mchin:
push bc
; <== Insert your own code here
ld a,(hbunit)
ld c,a
ld b,00h
rst 08
ld a,e
; <== End of your own code
ld l,a ; put in HL
ld h,0
or a ; set/clear Z
pop bc
ret
;Send a character to the modem
mchout:
ld hl,2 ; get the character
add hl,sp
ld a,(hl)
; <== Insert your own code here
push bc
ld e,a
ld a,(hbunit)
ld c,a
ld b,01h
rst 08
pop bc
; <== End of your own code
ret ; done
;Test for output ready: return TRUE (1) in HL if ok
mordy:
; <== Insert your own code here
push bc
ld a,(hbunit)
ld c,a
ld b,03h
rst 08
ld h,0
ld l,a
pop bc
; <== End of your own code
ld a,l ; set/clear Z
or a
ret
;Test for character at modem: return TRUE (1) in HL if so
mirdy:
; <== Insert your own code here
push bc
ld a,(hbunit)
ld c,a
ld b,02h
rst 08
ld h,0
ld l,a
pop bc
; <== End of your own code
ld a,l ; set/clear Z
or a
ret
;Send a break to the modem: leave empty if your system can't do it
sndbrk:
; <== Insert your own code here
ld hl,300 ; wait 300 mS
call waithlms
; <== End of your own code
ret
;
;Test UART flags for error: return TRUE (1) in HL if error.
mdmerr:
; <== Insert your own code here
xor a ; not implemented
; <== End of your own code
ld a,l ; set/clear Z
or a
ret
;Turn DTR ON
dtron:
; <== Insert your own code here
; <== End of your own code
ret
;Turn DTR OFF
dtroff:
; <== Insert your own code here
; <== End of your own code
ret
;Initialise the uart
init:
ld hl,2 ; get parameters
add hl,sp
ex de,hl
call getparm ; in HL
ld (brate),hl ; baud rate
call getparm
ld (parity),hl ; parity
call getparm
ld (data),hl ; data bits (BINARY 7 or 8)
call getparm
ld (stop),hl ; stop bits (BINARY 1 or 2)
; <== Insert your own code here
; using values below
; don't forget to load mspeed with the
; current brate value if the new rate is
; valid. See table of values below.
push bc
; If pcfg is true, attempt to initialize the active
; HBIOS unit. If false, initialization if bypassed with
; the assumption that the RomWBW MODE command was used
; to initialize the port priot to running ZMP.
if pcfg
call print
db 'Initializing device: ',0
call diport
ld a,(hbunit) ; get device type
ld c,a
ld b,06h
rst 08
or a ; check if valid
jr nz,initerr
ld a,(brate) ; get baud rate to set
ld c,a
ld b,0
ld hl,baudtbl
add hl,bc
ld a,(hl) ; convert to encoded hbios
cp a,-1
jr z,initerr
push af
ld a,(hbunit) ; get line characteristics
ld c,a
ld b,05h
rst 08
ld a,d ; mask out exisitng
and 11100000b ; replace with rate
ld d,a
pop af
or d
ld d,a
ld b,04h ; set new
ld a,(hbunit) ; speed
ld c,a
rst 08
or a
jr nz,initerr
ld a,(brate) ; load mspeed with the current brate value if
ld (mspeed),a ; the new rate is valid. See table of values below.
call print
db lf,lf,'Initization completed, device: ',0
call diport
jr init_z
initerr:call print
db lf,lf,'Initization failed, device: ',0
call diport
jr init_z
diport: ld a,(hbunit) ; Display port
diport1:add a,'0'
call cout
call print
db cr,lf,0
ld hl,2
call waithls
ret
else
;call print
;db cr,lf,'Modem port initialization...',0
;ld hl,2
;call waithls
ld b,05h ; HBIOS port reset function
ld a,(hbunit) ; get active modem port
ld c,a ; and put in accum
rst 8 ; reset port
or a ; check result
jr nz,init1 ; if error, handle it
ld a,8 ; dummy value for speed
ld (mspeed),a ; save it
jr init_z ; done
init1:
; Handle error return from initialization
call print
db cr,lf,'Modem port initialization failed!',cr,lf,0
ld hl,2
call waithls
jr init_z
endif
init_z:
pop bc
; <== End of your own code
ret
;--------------------------------------------------------------------------
stop: dw 1 ; stop bits
parity: dw 'N' ; parity
data: dw 8 ; data bits
brate: dw 7 ; baud rate:
;--------------------------------------------------------------------------
;
;Values of brate for each baud rate
;
; hb encode baud rate brate
;
baudtbl:
db -1 ; 110 0 not supported
db 2 ; 300 1
db 17 ; 450 2
db 3 ; 600 3
db -1 ; 710 4 not supported
db 4 ; 1200 5
db 5 ; 2400 6
db 6 ; 4800 7
db 7 ; 9600 8
db 8 ; 19200 9
db 9 ; 38400 10
db 24 ; 57600 11
db 10 ; 76800 12
;
; Set the port. ZMP supplies either 0 or 1 as a parameter. You're on your
; own here -- your system is bound to be different from any other! You may
; implement a software switch on all the modem-dependent routines, or perhaps
; you can have one or two centralised routines for accessing the UARTs and
; modify the code from this routine to select one or the other. (Who said
; there was anything wrong with self-modifying code?). If you have only one
; UART port, or if you don't want to go through all the hassles, just have
; this routine returning with no changes made. Note that ZMP calls this
; routine with both values for the port on initialisation.
;
; Only originl ZMP calls setport. MECPARTS variant does not.
;
; We ignore this call. Since we are using a command line parameter
; to specify the desired modem port, it makes no sense.
;
setport:
ld hl,2 ; get port number
add hl,sp
ex de,hl
call getparm ; in HL (values are 0 and 1)
; <== Insert your own code here
; <== End of your own code
ret
;
;****************************************************************************
;Video terminal sequences: these are for VT-100: Modify as you wish
;Cursor addressing:
cursadd:
ld hl,2 ; get parameters
add hl,sp
ex de,hl
call getparm ; in HL
inc hl
ld (row),hl ; row
call getparm
inc hl
ld (col),hl ; column
;
push bc
call print
db esc,'[',0
ld a,(row) ; row first
call cursconv
ld a,';'
call cout
ld a,(col) ; same for column
call cursconv
ld a,'H'
call cout
pop bc
ret
;
cursconv:
ld b,a
xor a
ca1: add a,1
daa
djnz ca1
ld (num),a
and 0f0h
jr z,ca2
srl a
srl a
srl a
srl a
or '0'
call cout
ca2: ld a,(num)
and 0fh
or '0'
call cout
ret
;
row: ds 2 ; row
col: ds 2 ; column
num: ds 1
;
;Clear screen:
cls:
call print
db esc,"[H",esc,"[2J",0
ret
;
;Inverse video on:
invon:
call print
db esc,"[7m",0
ret
;
;Inverse video off:
invoff:
call print
db esc,"[m",0
ret
;
;Turn off cursor:
hide:
call print
db esc,'[?25l',0
ret
;
;Turn on cursor:
show:
call print
db esc,'[?25h',0
ret
;
;Save cursor position:
savecu:
call print
db esc,'[7',0
ret
;
;Restore cursor position:
rescu:
call print
db esc,'[8',0
ret
;****************************************************************************
;Service modem interrupt:
mint:
ret ; handled in HBIOS
;Initialise interrupt vectors:
invec:
ret ; ditto
;De-initialise interrupt vectors:
dinvec:
ret ; ditto
;****************** End of user-defined code ********************************
; Do not change anything below here.
;Modem character test for 100 ms
mrd:
push bc ; save bc
ld bc,100 ; set limit
mrd1:
call mirdy ; char at modem?
jr nz,mrd2 ; yes, exit
ld hl,1 ; else wait 1ms
call waithlms
dec bc ; loop till done
ld a,b
or c
jr nz,mrd1
ld hl,0 ; none there, result=0
xor a
mrd2:
pop bc
ret
; Inline print routine: destroys A and HL
print:
ex (sp),hl ; get address of string
ploop:
ld a,(hl) ; get next
inc hl ; bump pointer
or a ; done if zero
jr z,pdone
call cout ; else print
jr ploop ; and loop
pdone:
ex (sp),hl ; restore return address
ret ; and quit
;
;Output a character in A to the console
;
cout:
push bc ; save regs
push de
push hl
ld e,a ; character to E
ld c,2
call bdos ; print it
pop hl
pop de
pop bc
ret
;Wait seconds
wait:
ld hl,2
add hl,sp
ex de,hl ; get delay size
call getparm
; fall thru to..
;Wait seconds in HL
waithls:
push hl ; save loop control
ld hl,1000 ; 1000ms = 1 second
call waithlms
pop hl ; restore loop control
dec hl
ld a,h
or l
jr nz,waithls
ret
;Wait milliseconds
mswait:
ld hl,2
add hl,sp
ex de,hl ; get delay size
call getparm
; fall thru to..
;Wait milliseconds in HL
waithlms:
; burn 1000us (1ms)
ld a,(cpumhz)
ld e,a
hlms1:
; burn 1000 t-states
; 50 * 20 = 1000 t-states
ld d,50
hlms2:
nop ; 4
dec d ; 4
jr nz,hlms2 ; 12 20
dec e
jr nz,hlms1
dec hl
ld a,h
or l
jr nz,waithlms
ret
;Get next parameter from (de) into hl
getparm:
ex de,hl ; get address into hl
ld e,(hl) ; get lo
inc hl
ld d,(hl) ; then hi
inc hl ; bump for next
ex de,hl ; result in hl, address still in de
ret
;Get address of user-defined variables
getvars:
ld hl,uservars
ret
uservars:
dw overdrive ; .OVR etc. drive/user
dw overuser
if ($ - codebgn) gt ovsize
toobig: jp errval ; Overlay too large!
endif
end


View File

@@ -26,11 +26,11 @@
; has been written in Z80 code for use with M80 or SLR. Assemble as follows:
;
; SLR ZMO-xx01/h
; MLOAD ZMP.COM=ZMODEM.COM,ZMO-xx01.HEX
; MLOAD ZMP.COM=ZMPX.COM,ZMO-xx01.HEX
; or
; M80 =ZMO-xx01.Z80
; RELHEX ZMO-xx01
; MLOAD ZMP.COM=ZMODEM.COM,ZMO-xx01.HEX
; MLOAD ZMP.COM=ZMPX.COM,ZMO-xx01.HEX
;
;
; (Don't use L80 without changing the source for assembly as a
@@ -570,4 +570,3 @@ toobig: jp errval ; Overlay too large!
endif
end


View File

@@ -12,6 +12,10 @@ awhile (some, a few decades):
* In keyboard macros, ! translates to a CR now, not CR/LF.
* \ escapes ! and ~ so those literal characters can be used in
keyboard macros.
* Waits in keyboard macros now allow characters from the modem to
be handled.
* Keys in keyboard macros now have 25ms waits between them as to
not overrun the remove system.
* Long distance access code has been removed.
* Quick dialing letters limited to A-T.
@@ -23,5 +27,5 @@ version in ZMP15.LBR. So, to quote the original author,
new one with the config option. There have again been changes to
the format of this file."
June 7, 2021
August 15, 2023


Binary file not shown.

View File

@@ -1,8 +1,11 @@
@echo off
setlocal
:: copysl.com is currently distributed as a binary application, so
:: it is not built here.
set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t80 -g3 -fFF copysl.asm copysl.com copysl.lst || exit /b
copy /Y copysl.com ..\..\..\Binary\Apps\ || exit /b
copy /Y copysl.doc ..\..\..\Binary\Apps\ || exit /b

View File

@@ -1,5 +1,6 @@
@echo off
setlocal
:: copysl.com is currently distributed as a binary application, so
:: we do not delete the .COM file.
if exist *.com del *.com
if exist *.lst del *.lst
if exist *.bin del *.bin

View File

@@ -1,7 +1,9 @@
OBJECTS = copysl.com
NODELETE = $(OBJECTS)
DOCS = copysl.doc
DEST = ../../../Binary/Apps
DOCDEST = ../../../Binary/Apps
TOOLS=../../../Tools
include $(TOOLS)/Makefile.inc
TOOLS =../../../Tools
USETASM=1
include $(TOOLS)/Makefile.inc

View File

@@ -0,0 +1,16 @@
;
bdos .EQU 5
;
; Force BDOS to reset (logout) all drives
;
drvrst:
ld c,$0D ; BDOS Reset Disk function
call bdos ; do it
;
ld c,$25 ; BDOS Reset Multiple Drives
ld de,$FFFF ; all drives
call bdos ; do it
;
xor a ; signal success
ret
;

328
Source/Apps/copysl/cio.asm Normal file
View File

@@ -0,0 +1,328 @@
BDOS .EQU 5
; bdos commands
CONIN .EQU 1
CONOUT .EQU 2
DIRCONIO .EQU 6
; TODO for more routines see assign.asm
; ===============
; INPUT
; Console Input
getchr:
PUSH BC
PUSH DE
PUSH HL
LD C,CONIN
CALL BDOS
POP HL
POP DE
POP BC
RET
; direct console io
; BDOS 6 - FF FE FD - commands
conread:
RET
constatus:
RET
coninput:
RET
; =======================================
; STANDARD OUTPUT
;
; Print character in A without destroying any registers
;
prtchr:
; PUSH AF
PUSH HL ; We must preserve HL, as the BDOS call sets it
PUSH BC
PUSH DE
LD C, CONOUT
LD E, A
CALL BDOS
POP DE
POP BC
POP HL
; POP AF
RET
;
prtdot:
push af
ld a, '.'
call prtchr
pop af
ret
;
; Print a zero terminated string at (HL) without destroying any registers
;
prtstr:
PUSH AF
PUSH BC
push de
prtstr1:
ld a,(hl)
or 0
jr z,prtstr2
ld c, CONOUT
ld e,a
push hl
call BDOS
pop hl
inc hl
jr prtstr1
prtstr2:
pop de
pop bc
pop af
ret
;
; Print the value in A in hex without destroying any registers
;
prthex:
push af ; save AF
push de ; save DE
call hexascii ; convert value in A to hex chars in DE
ld a,d ; get the high order hex char
call prtchr ; print it
ld a,e ; get the low order hex char
call prtchr ; print it
pop de ; restore DE
pop af ; restore AF
ret ; done
;
; print the hex word value in bc
;
prthexword:
push af
ld a,b
call prthex
ld a,c
call prthex
pop af
ret
;
; Convert binary value in A to ascii hex characters in DE
;
hexascii:
ld d,a ; save A in D
call hexconv ; convert low nibble of A to hex
ld e,a ; save it in E
ld a,d ; get original value back
rlca ; rotate high order nibble to low bits
rlca
rlca
rlca
call hexconv ; convert nibble
ld d,a ; save it in D
ret ; done
;
; Convert low nibble of A to ascii hex
;
hexconv:
and 0Fh ; low nibble only
add a,90h
daa
adc a,40h
daa
ret
;
; Print the decimal value of A, with leading zero suppression
;
prtdec:
push hl
ld h,0
ld l,a
call prtdecword ; print it
pop hl
ret
;
; Print the Decimal value (word) in HL
;
prtdecword:
push af
push bc
push de
push hl
call prtdec0
pop hl
pop de
pop bc
pop af
ret
;
prtdec0:
ld e,'0'
ld bc,-10000
call prtdec1
ld bc,-1000
call prtdec1
ld bc,-100
call prtdec1
ld c,-10
call prtdec1
ld e,0
ld c,-1
prtdec1:
ld a,'0' - 1
prtdec2:
inc a
add hl,bc
jr c,prtdec2
sbc hl,bc
cp e
ret z
ld e,0
call prtchr
ret
;
; Print a byte buffer in hex pointed to by DE
; Register A has size of buffer
;
prthexbuf:
or a
ret z ; empty buffer
prthexbuf1:
ld a,' '
call prtchr
ld a,(de)
call prthex
inc de
djnz prthexbuf1
ret
;
; Start a new Line
;
prtcrlf2:
call prtcrlf
prtcrlf:
push hl
ld hl, prtcrlf_msg
call prtstr
pop hl
ret
prtcrlf_msg:
.DB 13,10,0
; =================================
; following is from dmamon util.asm
;
; IMMEDIATE PRINT
; =================================
;
; PRINT A CHARACTER REFERENCED BY POINTER AT TOP OF STACK
; USAGE:
; CALL IPRTCHR
; .DB 'X'
;
iprtchr:
EX (SP),HL
PUSH AF
LD A,(HL)
CALL prtchr
POP AF
INC HL
EX (SP),HL
RET
; Print a string referenced by pointer at top of stack
; Usage
; call iprtstr
; .DB "text", 0
;
iprtstr:
EX (SP),HL
CALL prtstr
INC HL
EX (SP),HL
RET
;
; ===========================================================
;
; Following is for INPUT, used to process command line args
;
; ===========================================================
;
; Skip whitespace at buffer adr in DE, returns with first
; non-whitespace character in A.
;
skipws:
ld a,(hl) ; get next char
or a ; check for eol
ret z ; done if so
cp ' ' ; blank?
ret nz ; nope, done
inc hl ; bump buffer pointer
jr skipws ; and loop
;
; Uppercase character in A
;
upcase:
cp 'a' ; below 'a'?
ret c ; if so, nothing to do
cp 'z'+1 ; above 'z'?
ret nc ; if so, nothing to do
and ~020h ; convert character to lower
ret ; done
;
; Get numeric chars at HL and convert to number returned in A
; Carry flag set on overflow
; C is used as a working register
;
getnum:
ld c,0 ; C is working register
getnum1:
ld a,(hl) ; get the active char
cp '0' ; compare to ascii '0'
jr c,getnum2 ; abort if below
cp '9' + 1 ; compare to ascii '9'
jr nc,getnum2 ; abort if above
;
ld a,c ; get working value to A
rlca ; multiply by 10
ret c ; overflow, return with carry set
rlca ; ...
ret c ; overflow, return with carry set
add a,c ; ...
ret c ; overflow, return with carry set
rlca ; ...
ret c ; overflow, return with carry set
ld c,a ; back to C
ld a,(hl) ; get new digit
sub '0' ; make binary
add a,c ; add in working value
ret c ; overflow, return with carry set
ld c,a ; back to C
;
inc hl ; bump to next char
jr getnum1 ; loop
;
getnum2:
ld a,c ; return result in A
or a ; with flags set, CF is cleared
ret
;
; Is character in A numeric? NZ if not
;
isnum:
cp '0' ; compare to ascii '0'
jr c,isnum1 ; abort if below
cp '9' + 1 ; compare to ascii '9'
jr nc,isnum1 ; abort if above
cp a ; set Z
ret
isnum1:
or 0FFh ; set NZ
ret ; and done

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -1,6 +1,6 @@
==========================================================================
CopySlice Utility v0.2 for RomWbW computers
written by Mark Pruden (Sept 2024)
CopySlice Utility v0.3 for RomWbW computers
written by Mark Pruden (March 2025)
==========================================================================
Purpose:
@@ -12,37 +12,37 @@ from one disk slice to another slice
Background
----------
This tool is only supported by RomWBW HBIOS, it uses HDIOS for all its
disk IO. UNA UBIOS is not supported by this tool.
This tool is only supported by RomWBW HBIOS, it uses HDIOS for all its
disk IO. UNA UBIOS is not supported by this tool.
This tool is running on CP/M 2.2 or 3.0 and has access to full 64kb of
RAM, with a minimum of 48kb TPA
This tool only works with hard disk devices, other media types like
floppy, are not supported at this time. This tool works across different
This tool only works with hard disk devices, other media types like
floppy, are not supported at this time. This tool works across different
hard disk device types, even of different physical type
Both hd1k and hd512 are fully supported, however copying from one layout
Both hd1k and hd512 are fully supported, however copying from one layout
type to the other is not supported.
During operation data is copied in a single read/write pass, data is not
During operation data is copied in a single read/write pass, data is not
verified by default. If there is a write error, it will be reported, and
operation will stop.
General Usage
-------------
This tool operates at the disk level via RomWBW, thus all disk identifiers
This tool operates at the disk level via RomWBW, thus all disk identifiers
are in the RomWBW <disk>.<unit> format
The syntax (similar to copy) for the command is:
COPYSL <destunit>[.<slice>]=<srcunit>[.<slice>] [/options]
E.g.
COPYSL 3.3=2.10 /U
Means copy from slice 10 on disk 2, onto disk 3 slice 3. This is in
Means copy from slice 10 on disk 2, onto disk 3 slice 3. This is in
unattended mode, so you will not be asked to confirm the copy operation.
Options
@@ -54,39 +54,40 @@ V - Verify. Does an additional read and verify after write.
Description
-----------
When run COPYSL will perform command line argument validation and display
When run COPYSL will perform command line argument validation and display
an error if they are illegal. Also any disk IO errors will cause COPYSL
to exit.
When specifying slice number(s) a check is made that the slice number is
valid, i.e. not too large that it would extend past the end of the
When specifying slice number(s) a check is made that the slice number is
valid, i.e. not too large that it would extend past the end of the
partition (hd1k), or the end of the media (hd512). For hd512 a check is
also performed to ensure that the slice would not extend into the first
also performed to ensure that the slice would not extend into the first
defined partition.
The copy operation will be faster if the source disk has been formatted
with the CP/M file system, since during copy the CP/M directory is scanned,
and unused blocks are not copied.
with the CP/M file system, since during copy the CP/M directory is scanned,
and unused blocks are not copied.
If a filesystem is not found, (or the /F option is chosen) all data is
If a filesystem is not found, (or the /F option is chosen) all data is
copied.
Verification (if option chosen) will do an aditional read (after write)
and compare the data read matches what was written. This compare is only
on every 32'nd byte. This is done for efficiency.
on every 32'nd byte. This is done for efficiency.
During copy dots "." will be displayed to indicate progress of the copy.
Each "." represents 16 kBytes of data. Each line of "." 's is 1 mBytes.
Testing
-------
This tool has been writen and tested on a SC126 computer. Testing been on both
This tool has been writen and tested on a SC126 computer. Testing been on both
SD and CF media types, and with both hd1k and hd512 formats
History
-------
* v 0.1 Initial Release
* v 0.2 Added the /v command option to read and verify after write
* v 0.3 Refresh CP/M disk buffers after completion
Future
------
@@ -95,4 +96,3 @@ Future
This would be at the cost of performance
* ability to abort once the copy has started <ctrl><c>


110
Source/Apps/copysl/crc.asm Normal file
View File

@@ -0,0 +1,110 @@
;
; Simple Block Compare for Comparison purposes
; Both HL and DL contain Block pointers to compare
; HL MUST start on an even block e.g. 8000h
; RET NZ - Failure, Z if no issue
;
_cmp20block
; inc de ; uncommnet to test crc fail!
ld bc, 20h ; 10t Size of Pointer Increment
_cmp20block1:
ld a, (de) ; 7t Do The comparison itself
cp (hl) ; 7t
JR NZ, _cmp20block2 ; 7t / 12t = 21t
add hl, bc ; 11t Add the Increment to both pointers
ex de, hl ; 4t
add hl, bc ; 11t
ex de, hl ; 4t = 30t
ld a, h ; 4t High order byte on Even Boundary
bit 4, a ; 8t has bit 4 been set then exceeded 1000h (4k boundary)
JR Z, _cmp20block1 ; 12t / 7t = 24t
xor a ; 4t
RET ; 10t Return Success
_cmp20block2:
scf ; signal CARRY FLAG Also
RET ; This is the error
; clock cycles for above
; add 40h -> 64 (loop) * 73t =>> 4,672 - 1.56%
; add 20h ->128 (loop) * 73t =>> 9,344 - 3.13% <= WENT WITH THIS
; add 10h ->256 (loop) * 73t =>> 18,688 - 6.25%
; accuracy = 88/4096 => 2.1%
; =====================================================================
; From : https://tomdalby.com/other/crc.html
; And : https://map.grauw.nl/sources/external/z80bits.html#6.1
; =====================================================================
;
; =====================================================================
; input - hl=start of memory to check, de=length of memory to check
; returns - a=result crc
; 20b
; =====================================================================
; THE COMMNETED LINES NEED TO BE UNCOMMENTED
_crc8b:
xor a ; 4t - initial value so first byte can be XORed in (CCITT)
; ld c, 07h ; 7t - c=polyonimal used in loop (small speed up)
_byteloop8b:
xor (hl) ; 7t - xor in next byte, for first pass a=(hl)
inc hl ; 6t - next mem
; ld b, 8 ; 7t - loop over 8 bits
_rotate8b:
; add a,a ; 4t - shift crc left one
; jr nc, _nextbit8b ; 12/7t - only xor polyonimal if msb set (carry=1)
; xor c ; 4t - CRC8_CCITT = 0x07
_nextbit8b:
; djnz _rotate8b ; 13/8t
ld b,a ; 4t - preserve a in b
dec de ; 6t - counter-1
ld a,d ; 4t - check if de=0
or e ; 4t
ld a,b ; 4t - restore a
jr nz, _byteloop8b ; 12/7t
ret ; 10t
; Clock Cycle For above with 4k bypes
; Loop = 4096 * 47 cycles + 11 => 192,523 x 2 (src/dest) => 385,046
; acuracy = 1 / 256 => 0.4 %
; =====================================================================
; CRC-CCITT
;
; CCITT polynomial 1021h
; Initial Value FFFFh
;
; input - de=start of memory to check, bc=length of memory to check
; returns - hl=result crc
; =====================================================================
_crc16:
ld hl, 0ffffh ; 10t - initial crc = $ffff
_byte16:
; push bc ; 11t - preserve counter
ld a,(de) ; 7t - get byte
inc de ; 6t - next mem
; xor h ; 4t - xor byte into crc high byte
; ld h,a ; 4t - back into high byte
; ld b,8 ; 7t - rotate 8 bits
_rotate16:
; add hl,hl ; 11t - rotate crc left one
; jr nc,_nextbit16 ; 12/7t - only xor polyonimal if msb set
; ld a,h ; 4t
; xor 10h ; 7t - high byte with $10
; ld h,a ; 4t
; ld a,l ; 4t
; xor 21h ; 7t - low byte with $21
; ld l,a ; 4t - hl now xor $1021
_nextbit16:
; djnz _rotate16 ; 13/8t - loop over 8 bits
; pop bc ; 10t - bring back main counter
dec bc ; 6t
ld a,b ; 4t
or c ; 4t
jr nz,_byte16 ; 12/7t
ret ; 10t
;

View File

@@ -0,0 +1,178 @@
;
; HBIOS FUNCTIONS
;
;
BF_DIO .EQU 010H
BF_DIOSTATUS .EQU BF_DIO + 0 ; DISK STATUS
BF_DIORESET .EQU BF_DIO + 1 ; DISK RESET
BF_DIOSEEK .EQU BF_DIO + 2 ; DISK SEEK
BF_DIOREAD .EQU BF_DIO + 3 ; DISK READ SECTORS
BF_DIOWRITE .EQU BF_DIO + 4 ; DISK WRITE SECTORS
BF_DIOVERIFY .EQU BF_DIO + 5 ; DISK VERIFY SECTORS
BF_DIOFORMAT .EQU BF_DIO + 6 ; DISK FORMAT TRACK
BF_DIODEVICE .EQU BF_DIO + 7 ; DISK DEVICE INFO REPORT
BF_DIOMEDIA .EQU BF_DIO + 8 ; DISK MEDIA REPORT
BF_DIODEFMED .EQU BF_DIO + 9 ; DEFINE DISK MEDIA
BF_DIOCAP .EQU BF_DIO + 10 ; DISK CAPACITY REPORT
BF_DIOGEOM .EQU BF_DIO + 11 ; DISK GEOMETRY REPORT
;
BF_SYS .EQU 0F0H
BF_SYSRESET .EQU BF_SYS + 0 ; SOFT RESET HBIOS
BF_SYSVER .EQU BF_SYS + 1 ; GET HBIOS VERSION
BF_SYSSETBNK .EQU BF_SYS + 2 ; SET CURRENT BANK
BF_SYSGETBNK .EQU BF_SYS + 3 ; GET CURRENT BANK
BF_SYSSETCPY .EQU BF_SYS + 4 ; BANK MEMORY COPY SETUP
BF_SYSBNKCPY .EQU BF_SYS + 5 ; BANK MEMORY COPY
BF_SYSALLOC .EQU BF_SYS + 6 ; ALLOC HBIOS HEAP MEMORY
BF_SYSFREE .EQU BF_SYS + 7 ; FREE HBIOS HEAP MEMORY
BF_SYSGET .EQU BF_SYS + 8 ; GET HBIOS INFO
BF_SYSSET .EQU BF_SYS + 9 ; SET HBIOS PARAMETERS
BF_SYSPEEK .EQU BF_SYS + 10 ; GET A BYTE VALUE FROM ALT BANK
BF_SYSPOKE .EQU BF_SYS + 11 ; SET A BYTE VALUE IN ALT BANK
BF_SYSINT .EQU BF_SYS + 12 ; MANAGE INTERRUPT VECTORS
;
BF_SYSGET_CIOCNT .EQU 00h ; GET CHAR UNIT COUNT
BF_SYSGET_CIOFN .EQU 01h ; GET CIO UNIT FN/DATA ADR
BF_SYSGET_DIOCNT .EQU 10h ; GET DISK UNIT COUNT
BF_SYSGET_DIOFN .EQU 11h ; GET DIO UNIT FN/DATA ADR
BF_SYSGET_RTCCNT .EQU 20h ; GET RTC UNIT COUNT
BF_SYSGET_DSKYCNT .EQU 30h ; GET DSKY UNIT COUNT
BF_SYSGET_VDACNT .EQU 40h ; GET VDA UNIT COUNT
BF_SYSGET_VDAFN .EQU 41h ; GET VDA UNIT FN/DATA ADR
BF_SYSGET_SNDCNT .EQU 50h ; GET VDA UNIT COUNT
BF_SYSGET_SNDFN .EQU 51h ; GET SND UNIT FN/DATA ADR
BF_SYSGET_TIMER .EQU 0D0h ; GET CURRENT TIMER VALUE
BF_SYSGET_SECS .EQU 0D1h ; GET CURRENT SECONDS VALUE
BF_SYSGET_BOOTINFO .EQU 0E0h ; GET BOOT INFORMATION
BF_SYSGET_CPUINFO .EQU 0F0h ; GET CPU INFORMATION
BF_SYSGET_MEMINFO .EQU 0F1h ; GET MEMORY CAPACTITY INFO
BF_SYSGET_BNKINFO .EQU 0F2h ; GET BANK ASSIGNMENT INFO
BF_SYSGET_CPUSPD .EQU 0F3h ; GET CLOCK SPEED & WAIT STATES
BF_SYSGET_PANEL .EQU 0F4h ; GET FRONT PANEL SWITCHES VAL
BF_SYSGET_APPBNKS .EQU 0F5h ; GET APP BANK INFORMATION
;
; MEDIA ID VALUES
;
MID_NONE .EQU 0
MID_MDROM .EQU 1
MID_MDRAM .EQU 2
MID_RF .EQU 3
MID_HD .EQU 4
MID_FD720 .EQU 5
MID_FD144 .EQU 6
MID_FD360 .EQU 7
MID_FD120 .EQU 8
MID_FD111 .EQU 9
MID_HDNEW .EQU 10
; -----------------
;
; Read timer in sconds.
;
sysgetseconds:
ld b,BF_SYSGET
ld c,BF_SYSGET_SECS
rst 08 ; do it
ret
; -----------------
;
; Return non zero if A (media ID)
; is a type of hard drive
; If not A=0 and Z flag is set
;
isaharddrive:
cp MID_HD
jr z, ishdd1
cp MID_HDNEW
jr z, ishdd1
xor a ; clear A and set Z flag
ret
ishdd1:
or a ; set Z flag and return
ret
; -------------------------------------
;
; used to pass the buffer address argument
;
bankid .DB 0 ; bank id used for read writes
dma .DW 8000h ; address argument for read write
;
;
; basic setup for disk io
; call to get the current bank IO
;
initdiskio:
; Get current RAM bank
ld b,BF_SYSGETBNK ; HBIOS GetBank function
RST 08 ; do it via RST vector, C=bank id
JP NZ, err_hbios
ld a,c ; put bank id in A
ld (bankid),a ; put bank id in Argument
RET
;
;
; Read disk sector(s)
; DE:HL is LBA, B is sector count, C is disk unit
; (dma) is the buffer address
; (bankid) is the memory bank
; Returns E sectors read, and A status
;
diskread:
; Seek to requested sector in DE:HL
push bc ; save unit & count
set 7,d ; set LBA access flag
ld b,BF_DIOSEEK ; HBIOS func: seek
rst 08 ; do it
pop bc ; recover unit & count
jp nz,err_diskio ; handle error
; Read sector(s) into buffer
ld e,b ; transfer count
ld b,BF_DIOREAD ; HBIOS func: disk read
ld hl,(dma) ; read into info sec buffer
ld a,(bankid) ; user bank
ld d,a
rst 08 ; do it
jp nz,err_diskio ; handle error
xor a ; signal success
ret ; and done
;
; Write disk sector(s)
; DE:HL is LBA, B is sector count, C is disk unit
; (dma) is the buffer address
; (bankid) is the memory bank
; Returns E sectors written, and A status
;
diskwrite:
; Seek to requested sector in DE:HL
push bc ; save unit & count
set 7,d ; set LBA access flag
ld b,BF_DIOSEEK ; HBIOS func: seek
rst 08 ; do it
pop bc ; recover unit & count
jp nz,err_diskio ; handle error
; Write sector(s) from buffer
ld e,b ; transfer count
ld b,BF_DIOWRITE ; HBIOS func: disk write
ld hl,(dma) ; write from sec buffer
ld a,(bankid) ; user bank
ld d,a
rst 08 ; do it
jp nz,err_diskio ; handle error
xor a ; signal success
ret ; and done
;
err_diskio:
; push hl
; ld hl,str_err_prefix
; call prtstr
; pop hl
; or 0ffh ; signal error
ret ; done
;str_err_prefix db 13,10,13,10,"*** ",0

View File

@@ -0,0 +1,10 @@
@echo off
setlocal
set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t80 -g3 -fFF slabel.asm slabel.com slabel.lst || exit /b
copy /Y slabel.com ..\..\..\Binary\Apps\ || exit /b

View File

@@ -0,0 +1,6 @@
@echo off
setlocal
if exist *.com del *.com
if exist *.lst del *.lst
if exist *.bin del *.bin

View File

@@ -0,0 +1,7 @@
OBJECTS = slabel.com
DEST = ../../../Binary/Apps
TOOLS =../../../Tools
USETASM=1
include $(TOOLS)/Makefile.inc

View File

@@ -0,0 +1,763 @@
;==============================================================================
; SLICE LABEL - Update Disk Labels
; Version December-2024
;==============================================================================
;
; Author: Mark Pruden
;______________________________________________________________________________
;
; Usage:
; SLABEL [unit.slice,label] [/?]
; ex: SLABEL Display current list of Labels
; SLABEL unit.slice=label Assign a disk Label to the Slice on Unit
; SLABEL /? Display version and usage
;
; Operation:
; Print and Assign a Disk Label to a Hard Disk Slice.
;
; Technical:
; On the third sector of "bootable" Disk Slice there is metadata used by RomWBW to know how
; to boot the OS found on the slice. This includes a Label for the volume, which is printed
; out by RomWBW during the boot process.
; Note this label is not associated to any label the OS may assign to the volume.
; See loader.asm in each of the O/S directories e.g. /src/CPM22 which describe these sectors
;
; This ony works on slices which have existing media information in the third sector.
; There is no capabiity to write this information on demand.
;
; known Issues:
; - Listing the slabel for all slices can be time consuming, because of the use of the EXT_MEDIA
; function call. This function reads the partition table (on each call) to assert (if valid)
; the LBA location of the requested slice. Ideally we would only need to read the partition
; table once (per device), and work out all the LBA's from this single read.
; Note this doesnt omit the fact that the 3 rd sector of each slice wold need to be read regarless.
; To slightly reduce some IO only slices < 64 are considered.
;
; This code will only execute on a Z80 CPU (or derivitive)
; This code requirs the use of HBIOS
;
;______________________________________________________________________________
;
; Change Log:
; 2024-12-11 [MAP] Started - Reboot v1.0 used as the basis for this code
; 2024-12-14 [MAP] Initial 0.9 alpha with basic working functionality
; 2025-04-21 [MAP] Initial v1.0 release for distribution, fixing all issues
;______________________________________________________________________________
;
; Include Files
;
#include "../../ver.inc" ; to ensure it is the correct ver
#include "../../HBIOS/hbios.inc"
;
;===============================================================================
;
; General operational equates (should not requre adjustment)
;
stksiz .equ $40 ; Working stack size
;
restart .equ $0000 ; CP/M restart vector
bdos .equ $0005 ; BDOS invocation vector
cmdbuf .equ $0081 ; CPM command buffer
;
bf_sysreset .equ $F0 ; restart system
bf_sysres_int .equ $00 ; reset hbios internal
bf_sysres_warm .equ $01 ; warm start (restart boot loader)
;
ident .equ $FFFE ; loc of RomWBW HBIOS ident ptr
;
sigbyte1 .equ $A5 ; 1st sig byte boot info sector (bb_sig)
sigbyte2 .equ $5A ; 2nd sig byte boot info sector (bb_sig)
;
labelterm .equ '$' ; terminating charater for disk label
;
;===============================================================================
;
.org $0100 ; standard CP/M TPA executable
;
ld (stksav),sp ; save stack
ld sp,stack ; set new stack
;
ld de,str_banner
call prtstr ; print the banner
;
call init ; initialize
jr nz,exit ; abort if init fails
;
call main ; do the real work
;
exit:
call crlf ; print terminating crlf
ld sp,(stksav) ; restore stack to prior state
jp restart ; return to CP/M via restart
;
;===============================================================================
; Initialization
;
init:
; check for UNA (UBIOS)
ld a,($FFFD) ; fixed location of UNA API vector
cp $C3 ; jp instruction?
jr nz,initwbw ; if not, not UNA
ld hl,($FFFE) ; get jp address
ld a,(hl) ; get byte at target address
cp $FD ; first byte of UNA push ix instruction
jr nz,initwbw ; if not, not UNA
inc hl ; point to next byte
ld a,(hl) ; get next byte
cp $E5 ; second byte of UNA push ix instruction
jr nz,initwbw ; if not, not UNA
jp err_una ; UNA not supported
;
initwbw:
; get location of config data and verify integrity
ld hl,(ident) ; HL := adr or RomWBW HBIOS ident
ld a,(hl) ; get first byte of RomWBW marker
cp 'W' ; match?
jp nz,err_inv ; abort with invalid config block
inc hl ; next byte (marker byte 2)
ld a,(hl) ; load it
cp ~'W' ; match?
jp nz,err_inv ; abort with invalid config block
inc hl ; next byte (major/minor version)
ld a,(hl) ; load it
cp rmj << 4 | rmn ; match?
jp nz,err_ver ; abort with invalid os version
;
initz:
; initialization complete
xor a ; signal success
ret ; return
;
;===============================================================================
; Main Execution
;
main:
call initdiskio ; initi DiskIO routines (bank ID)
;
ld de,cmdbuf ; start of command input buffer
call skipws ; skip whitespace on cmd line
;
ld a,(de) ; get first non-ws char
or a ; test for terminator, no parms
jr z,prtslc ; if so, print details, and return
;
call isnum ; do we have a number?
jp z,setlabel ; if so, then we are setting Label.
;
jp usage ; otherwise print usage and return
ret ; and exit
;
;===============================================================================
; Print Usage /? Information
;
usage:
ld de,str_usage ; display the cmd options for this utility
call prtstr
;
ret ; exit back out to CP/M CCP
;
;===============================================================================
; Print list of all slices
;
prtslc:
ld de,PRTSLC_HDR ; Header for list of Slices
call prtstr ; Print It
;
ld bc,BC_SYSGET_DIOCNT ; FUNC: SYSTEM INFO GET DISK DRIVES
rst 08 ; E := UNIT COUNT
;
ld b,e ; MOVE Disk CNT TO B FOR LOOP COUNT
ld c,0 ; C WILL BE UNIT INDEX
prtslc1:
ld a,b ; loop counter
or a ; set flags
ret z ; IF no more drives, finished
;
ld a,c ; unit index
ld (currunit),a ; store the unit number
;
push bc ; save loop vars
call prtslc2 ; for each disk Unit, print its details
pop bc ; restore loop variables
;
inc c ; bump the unit number
djnz prtslc1 ; main disk loop
;
ret ; loop has finished
;
;-------------------------------------------------------------------------------
; Print list of All Slices for a given Unit
;
prtslc2:
; get the media infor
ld b,BF_DIOMEDIA ; get media information
ld e,1 ; with media discovery
rst 08 ; do media discovery
ret nz ; an error
;
ld a,MID_HD ; hard disk
cp e ; is it hard disk
ret nz ; if not noting to do
;
; setup the loop
ld b,64 ; arbitrary (?) number of slices to check.
; NOTE: could be higher, but each slice check has disk IO
ld c,0 ; starting at slice 0
;
prtslc2a:
ld a,c ; slice number
ld (currslice),a ; save slice number
;
push bc ; save loop
call prtslc3 ; print detals of the slice
pop bc ; restore loop
ret nz ; if error dont continie
;
inc c ; next slice number
djnz prtslc2a ; loop if more slices
;
ret ; return from Slice Loop
;
;-------------------------------------------------------------------------------
; Print details of a Slice for a given Unit/Slice
;
prtslc3:
; get the details of the device / slice
ld a,(currunit)
ld d,a ; unit
ld a,(currslice)
ld e,a ; slice
ld b,BF_EXTSLICE ; EXT function to check compute slice offset
rst 08 ; noting this call checks partition table.
ret NZ ; an error, for lots of reasons, e.g. Slice not valid
;
call thirdsector ; point to the third sector of partition
;
call diskread ; do the sector read
ret nz ; read error. exit the slice loop
;
; Check signature
ld bc,(bb_sig) ; get signature read
ld a,sigbyte1 ; expected value of first byte
cp b ; compare
jr nz,prtslc5 ; ignore missing signature and loop
ld a,sigbyte2 ; expected value of second byte
cp c ; compare
jr nz,prtslc5 ; ignore missing signature and loop
;
; Print volume label string at HL, '$' terminated, 16 chars max
ld a,(currunit)
call prtdecb ; print unit number as decimal
call pdot ; print a DOT
ld a,(currslice)
call prtdecb
ld a,' '
call cout ; print a space
call cout ; print a space
ld hl,bb_label ; point to label
call pvol ; print it
call crlf
;
prtslc5:
xor a
ret
;
;-------------------------------------------------------------------------------
; Print volume label string at HL, '$' terminated, 16 chars max
;
pvol:
ld b,16 ; init max char downcounter
pvol1:
ld a,(hl) ; get next character
cp labelterm ; set flags based on terminator $
inc hl ; bump pointer regardless
ret z ; done if null
call cout ; display character
djnz pvol1 ; loop till done
ret ; hit max of 16 chars
;
;===============================================================================
; Set Label Information onto disk
;
setlabel:
call getnum ; parse a number
jp c,err_parm ; handle overflow error
ld (currunit),a ; save boot unit
xor a ; zero accum
ld (currslice),a ; save default slice
call skipws ; skip possible whitespace
ld a,(de) ; get separator char
or a ; test for terminator
jp z,err_parm ; if so, incomplete
cp '=' ; otherwise, is ','?
jr z,setlabel4 ; if so, skip the Slice parm
cp '.' ; otherwise, is '.'?
jp NZ,err_parm ; if not, format error
;
inc de ; bump past separator
call skipws ; skip possible whitespace
call isnum ; do we have a number?
jp nz,err_parm ; if not, format error
call getnum ; get number
jp c,err_parm ; handle overflow error
ld (currslice),a ; save boot slice
setlabel3:
call skipws ; skip possible whitespace
ld a,(de) ; get separator char
or a ; test for terminator
jp z,err_parm ; if so, then an error
cp '=' ; otherwise, is ','?
jp nz,err_parm ; if not, format error
setlabel4:
inc de ; bump past separator
call skipws ; skip possible whitespace
ld (newlabel),de ; address of disk label after '='
;
ld a,(currunit) ; passing boot unit
ld d,a
ld a,(currslice) ; and slice
ld e,a
ld b,BF_EXTSLICE ; HBIOS func: SLICE CALC - extended
rst 08 ; info for the Device, and Slice
;
; Check errors from the Function
cp ERR_NOUNIT ; compare to no unit error
jp z,err_nodisk ; handle no disk err
cp ERR_NOMEDIA ; no media in the device
jp z,err_nomedia ; handle the error
cp ERR_RANGE ; slice is invalid
jp z,err_badslice ; bad slice, handle err
or a ; any other error
jp nz,err_diskio ; handle as general IO error
;
call thirdsector ; point to the third sector of partition
;
call diskread ; read the sector
jp nz,err_diskio ; abort on error
;
; Check signature
ld de,(bb_sig) ; get signature read
ld a,sigbyte1 ; expected value of first byte
cp d ; compare
jp nz,err_sig ; handle error
ld a,sigbyte2 ; expected value of second byte
cp e ; compare
jp nz,err_sig ; handle error
;
ld b,16 ; loop down counter (max size of label)
ld de,(newlabel) ; reading from cmd line
ld hl,bb_label ; writing to disk label in sector buffer
updatelabel:
ld a,(de) ; read input
or a ; look for string terminator
jr z,updatelabel2 ; if terminator then complete
ld (hl),a ; store char in sector buff
inc de ; update pointers
inc hl
djnz updatelabel ; loop for next character
updatelabel2:
ld a,labelterm
ld (hl),a ; store the final terminator $ char
writelabel:
; write the sector
ld hl,(lba) ; lba, low word, same as read sector
ld de,(lba+2) ; lba, high word
call diskwrite ; write the sector back to disk
jp nz,err_diskio ; abort on error
;
; print the outcome.
ld de,PRTSLC_HDR ; Header for list of Slices
call prtstr ; Print header
call prtslc3 ; print updated label for unit/slice
;
ret
;
;-------------------------------------------------------------------------------
; advance the DE HL LBA sector by 2, ie third sector
;
thirdsector:
ld bc,2 ; sector offset
add hl,bc ; add to LBA value low word
jr nc,sectornum ; check for carry
inc de ; if so, bump high word
sectornum:
ld (lba),hl ; update lba, low word
ld (lba+2),de ; update lba, high word
ret
;
;===============================================================================
; Error Handlers
;
err_una:
ld de,str_err_una
jr err_ret
err_inv:
ld de,str_err_inv
jr err_ret
err_ver:
ld de,str_err_ver
jr err_ret
err_parm:
ld de,str_err_parm
jr err_ret
err_nodisk:
ld de,str_err_nodisk
jr err_ret
err_nomedia:
ld de,str_err_nomedia
jr err_ret
err_badslice:
ld de,str_err_badslc
jr err_ret
err_sig:
ld de,str_err_sig
jr err_ret
err_diskio:
ld de,str_err_diskio
jr err_ret
err_ret:
call crlf2
call prtstr
or $FF ; signal error
ret
;
;===============================================================================
; Utility Routines
;-------------------------------------------------------------------------------
; Print a dot on console
;
pdot:
push af
ld a,'.'
call cout
pop af
ret
;
;-------------------------------------------------------------------------------
; Print character in A without destroying any registers
;
prtchr:
cout:
push af ; save registers
push bc
push de
push hl
ld e,a ; character to print in E
ld c,$02 ; BDOS function to output a character
call bdos ; do it
pop hl ; restore registers
pop de
pop bc
pop af
ret
;
;-------------------------------------------------------------------------------
; Start a newline on console (cr/lf)
;
crlf2:
call crlf ; two of them
crlf:
push af ; preserve AF
ld a,13 ; <CR>
call prtchr ; print it
ld a,10 ; <LF>
call prtchr ; print it
pop af ; restore AF
ret
;
;-------------------------------------------------------------------------------
; Print a zero terminated string at (de) without destroying any registers
;
prtstr:
push af
push de
;
prtstr1:
ld a,(de) ; get next char
or a
jr z,prtstr2
call prtchr
inc de
jr prtstr1
;
prtstr2:
pop de ; restore registers
pop af
ret
;
;-------------------------------------------------------------------------------
; Print value of a in decimal with leading zero suppression
;
prtdecb:
push hl
push af
ld l,a
ld h,0
call prtdec
pop af
pop hl
ret
;
;-------------------------------------------------------------------------------
; Print value of HL in decimal with leading zero suppression
;
prtdec:
push bc
push de
push hl
ld e,'0'
ld bc,-10000
call prtdec1
ld bc,-1000
call prtdec1
ld bc,-100
call prtdec1
ld c,-10
call prtdec1
ld e,0
ld c,-1
call prtdec1
pop hl
pop de
pop bc
ret
prtdec1:
ld a,'0' - 1
prtdec2:
inc a
add hl,bc
jr c,prtdec2
sbc hl,bc
cp e
jr z,prtdec3
ld e,0
call cout
prtdec3:
ret
;
;-------------------------------------------------------------------------------
; INPUT ROUTINES
;-------------------------------------------------------------------------------
; Skip whitespace at buffer adr in DE, returns with first
; non-whitespace character in A.
;
skipws:
ld a,(de) ; get next char
or a ; check for eol
ret z ; done if so
cp ' ' ; blank?
ret nz ; nope, done
inc de ; bump buffer pointer
jr skipws ; and loop
;
;-------------------------------------------------------------------------------
; Convert character in A to uppercase
;
upcase:
cp 'a' ; if below 'a'
ret c ; ... do nothing and return
cp 'z' + 1 ; if above 'z'
ret nc ; ... do nothing and return
res 5,a ; clear bit 5 to make lower case -> upper case
ret ; and return
;
;-------------------------------------------------------------------------------
; Get numeric chars at DE and convert to number returned in A
; Carry flag set on overflow
;
getnum:
ld c,0 ; C is working register
getnum1:
ld a,(de) ; get the active char
cp '0' ; compare to ascii '0'
jr c,getnum2 ; abort if below
cp '9' + 1 ; compare to ascii '9'
jr nc,getnum2 ; abort if above
;
; valid digit, add new digit to C
ld a,c ; get working value to A
rlca ; multiply by 10
ret c ; overflow, return with carry set
rlca ; ...
ret c ; overflow, return with carry set
add a,c ; ...
ret c ; overflow, return with carry set
rlca ; ...
ret c ; overflow, return with carry set
ld c,a ; back to C
ld a,(de) ; get new digit
sub '0' ; make binary
add a,c ; add in working value
ret c ; overflow, return with carry set
ld c,a ; back to C
;
inc de ; bump to next char
jr getnum1 ; loop
;
getnum2: ; return result
ld a,c ; return result in A
or a ; with flags set, CF is cleared
ret
;
;-------------------------------------------------------------------------------
; Is character in A numeric? NZ if not
;
isnum:
cp '0' ; compare to ascii '0'
jr c,isnum1 ; abort if below
cp '9' + 1 ; compare to ascii '9'
jr nc,isnum1 ; abort if above
cp a ; set Z
ret
isnum1:
or $FF ; set NZ
ret ; and done
;
;-------------------------------------------------------------------------------
; DISK IO ROUTINES
;-------------------------------------------------------------------------------
; Init Disk IO
;
initdiskio:
; Get current RAM bank
ld b,BF_SYSGETBNK ; HBIOS GetBank function
RST 08 ; do it via RST vector, C=bank id
RET NZ ; had to replace this line below.
ld a,c ; put bank id in A
ld (BID_USR),a ; put bank id in Argument
RET
;
;-------------------------------------------------------------------------------
; Read disk sector(s)
; DE:HL is LBA, B is sector count, C is disk unit
;
diskread:
;
; Seek to requested sector in DE:HL
ld a,(currunit)
ld c,a ; from the specified unit
set 7,d ; set LBA access flag
ld b,BF_DIOSEEK ; HBIOS func: seek
rst 08 ; do it
ret nz ; handle error
;
; Read sector(s) into buffer
ld a,(currunit)
ld c,a ; from the specified unit
ld e,1 ; read 1 sector
ld hl,(dma) ; read into info sec buffer
ld a,(BID_USR) ; get user bank to accum
ld d,a ; and move to D
ld b,BF_DIOREAD ; HBIOS func: disk read
rst 08 ; do it
ret ; and done
;
;-------------------------------------------------------------------------------
; WRITE disk sector(s)
; DE:HL is LBA, B is sector count, C is disk unit
;
diskwrite:
;
ld a,(currunit) ; disk unit to read
ld c,a ; put in C
ld b,1 ; one sector
;
; Seek to requested sector in DE:HL
push bc ; save unit & count
set 7,d ; set LBA access flag
ld b,BF_DIOSEEK ; HBIOS func: seek
rst 08 ; do it
pop bc ; recover unit & count
ret nz ; handle error
;
; Read sector(s) into buffer
ld e,b ; transfer count
ld b,BF_DIOWRITE ; HBIOS func: disk read
ld hl,(dma) ; read into info sec buffer
ld a,(BID_USR) ; get user bank to accum
ld d,a ; and move to D
rst 08 ; do it
ret ; and done
;
;===============================================================================
; Constants
;===============================================================================
;
str_banner .db "\r\n"
.db "Slice Label, v1.0, April 2025 - M.Pruden",0
;
str_err_una .db " ERROR: UNA not supported by application",0
str_err_inv .db " ERROR: Invalid BIOS (signature missing)",0
str_err_ver .db " ERROR: Unexpected HBIOS version",0
str_err_parm .db " ERROR: Parameter error (SLABEL /? for usage)",0
str_err_nodisk .db " ERROR: Disk unit not available",0
str_err_nomedia .db " ERROR: Media not present",0
str_err_badslc .db " ERROR: Slice specified is illegal",0
str_err_sig .db " ERROR: No system image on disk",0
str_err_diskio .db " ERROR: Disk I/O failure",0
;
str_usage .db "\r\n\r\n"
.db " Usage: SLABEL - list current labels\r\n"
.db " SLABEL unit[.slice]=label - Defines a label\r\n"
.db " SLABEL /? - Display this help info.\r\n"
.db " Options are case insensitive.\r\n",0
;
PRTSLC_HDR .TEXT "\r\n\r\n"
.TEXT "Un.Sl Drive \r\n"
.TEXT "----- ----------------\r\n"
.DB 0
;
;===============================================================================
; Working data
;===============================================================================
;
currunit .db 0 ; parameters for disk unit, current unit
currslice .db 0 ; parameters for disk slice, current slice
lba .dw 0, 0 ; lba address (4 bytes), of slice
newlabel .dw 0 ; address of parameter, new label to write
;
BID_USR .db 0 ; Bank ID for user bank
dma .dw bl_infosec ; address for disk buffer
;
stksav .dw 0 ; stack pointer saved at start
.fill stksiz,0 ; stack
stack .equ $ ; stack top
;
;===============================================================================
; Disk Buffer
;===============================================================================
;
; define origin of disk buffer above 8000 for performance.
.org $8000
;
; Below is copied from ROM LDR
; Boot info sector is read into area below.
; The third sector of a disk device is reserved for boot info.
;
bl_infosec .equ $
.ds (512 - 128)
bb_metabuf .equ $
bb_sig .ds 2 ; signature (0xA55A if set)
bb_platform .ds 1 ; formatting platform
bb_device .ds 1 ; formatting device
bb_formatter .ds 8 ; formatting program
bb_drive .ds 1 ; physical disk drive #
bb_lu .ds 1 ; logical unit (lu)
.ds 1 ; msb of lu, now deprecated
.ds (bb_metabuf + 128) - $ - 32
bb_protect .ds 1 ; write protect boolean
bb_updates .ds 2 ; update counter
bb_rmj .ds 1 ; rmj major version number
bb_rmn .ds 1 ; rmn minor version number
bb_rup .ds 1 ; rup update number
bb_rtp .ds 1 ; rtp patch level
bb_label .ds 16 ; 16 character drive label
bb_term .ds 1 ; label terminator ('$')
bb_biloc .ds 2 ; loc to patch boot drive info
bb_cpmloc .ds 2 ; final ram dest for cpm/cbios
bb_cpmend .ds 2 ; end address for load
bb_cpment .ds 2 ; CP/M entry point (cbios boot)
;
;===============================================================================
;
.end

View File

@@ -668,15 +668,15 @@ lba ds 4 ; current lba
stack equ $
stksav ds 2
csvbufs equ 256
alvbufs equ 512
dirbufs equ 512
dtabufs equ 512
; CPMLDR.SYS must be a multiple of 512 bytes (one sector)
; for the RomWBW loader. Below padding as needed to force
; this.
ds 80h
;csvbuf ds 256 ; length (CSV) = ((DRM+1)/4)
;alvbuf ds 512 ; length (ALV) = ((DSM+1)/4)
;dirbuf ds 512 ; sector buffer
;dtabuf ds 512 ; sector buffer
csvbufs equ 256 ; length (CSV) = ((DRM+1)/4)
alvbufs equ 512 ; length (ALV) = ((DSM+1)/4)
dirbufs equ 512 ; sector buffer
dtabufs equ 512 ; sector buffer
; Trying to save space. The loader must fit underneath
; the start of BNKBDOS3 and we have a big BNKBDOS because

View File

@@ -1286,7 +1286,7 @@ provided in the RomWBW distribution.
`\clearpage`{=latex}
## BBCBASIC
## BBCBASIC (BBC BASIC)
| BBCBASIC | |
| --------------------|---|
@@ -1330,7 +1330,7 @@ The adaptation to RomWBW was minimal and includes:
`\clearpage`{=latex}
## CLRDIR
## CLRDIR (Clear Directory)
| CLRDIR | |
| --------------------|---|
@@ -1370,7 +1370,7 @@ reinitialised and the data previously stored will be lost.
`\clearpage`{=latex}
## CPUSPD
## CPUSPD (CPU Speed)
| CPUSPD | |
| --------------------|---|
@@ -1457,7 +1457,7 @@ The source code is provided in the RomWBW distribution.
`\clearpage`{=latex}
## COPYSL
## COPYSL (Copy Slice)
| COPYSL | |
| --------------------|---|
@@ -1547,7 +1547,7 @@ by Mark Pruden.
`\clearpage`{=latex}
## FAT
## FAT (FAT Utility)
| FAT | |
| --------------------|---|
@@ -1748,7 +1748,7 @@ Please contact John Coffman if you would like a copy of the source.
`\clearpage`{=latex}
## FDU
## FDU (Floppy Disk Utility)
| FDU | |
| --------------------|---|
@@ -1789,7 +1789,7 @@ provided in the RomWBW distribution.
`\clearpage`{=latex}
## FLASH
## FLASH (Flash EEPROM)
| FLASH | |
| --------------------|---|
@@ -1896,7 +1896,7 @@ provided in the RomWBW distribution.
`\clearpage`{=latex}
## HTALK
## HTALK (HBIOS Talk)
| HTALK | |
| --------------------|---|
@@ -2047,7 +2047,7 @@ The source code is provided in the RomWBW distribution.
`\clearpage`{=latex}
## RTC
## RTC (Real Time Clock)
| RTC | |
| --------------------|---|
@@ -2103,6 +2103,56 @@ support most of the hardware variations included with RomWBW.
`\clearpage`{=latex}
## SLABEL (Slice Label)
| SLABEL | |
| --------------------|-----|
| ROM-based | No |
| Disk-based | Yes |
Display or change the label of a disk slice.
The label applied is only used as informational purposes, displayed by RomWBW
when an OS is booted. It has no correlation with any OS volume label scheme
that may exist. i.e. It does not affect the CP/M 3 disk label as applied by
the `SET` command
#### Syntax
`SLABEL [unit.slice=label] [/?]`
`unit.slice` the disk unit and slice number to apply the new label to. This
is in the same format as when booting the system to a disk
`label` is the new disk label to apply to the disk
#### Usage
`SLABEL` with no arguments will list All existing labels across All disks
`SLABEL 2.5=MYDRIVE` will set the disk label of the 6th slice of disk unit 2
`SLABEL /?` (or other unrecognised parameters) will display a usage message.
#### Notes
There is no capability to update a label onto media that currently does not have
existing media information in the third sector, typically this means only
bootable media.
This will only display labels for the first 64 slices of any device. Slices
higher than this are currently ignored.
Only bootable RomWBW disk images have a label, which is defined by the OS
which is booted. i.e. NZ-COM has a label of "ZSDOS 1.1" since that is the
booted OS. Prior to RomWBW 3.5 all disk images were defined with the label
"Unlabeled".
#### Etymology
The `SLABEL` application was custom written for RomWBW and contributed
by Mark Pruden.
## SURVEY
| SURVEY | |
@@ -2142,7 +2192,7 @@ discover ports that are 'write-only'.
`\clearpage`{=latex}
## SYSCOPY
## SYSCOPY (System Copy)
| SYSCOPY | |
| --------------------|---|
@@ -2282,7 +2332,7 @@ provided in the RomWBW distribution.
`\clearpage`{=latex}
## TBASIC
## TBASIC (Tasty BASIC)
| TBASIC | |
| --------------------|---|
@@ -2467,7 +2517,7 @@ The source code is provided in the RomWBW distribution.
`\clearpage`{=latex}
## VGMPLAY
## VGMPLAY (Video Game Music Play)
| VGMPLAY | |
| --------------------|---|
@@ -2550,7 +2600,7 @@ RomWBW distribution.
`\clearpage`{=latex}
## WDATE
## WDATE (WBW DATE)
| WDATE | |
| --------------------|---|
@@ -2637,7 +2687,7 @@ The source code is available on GitHub at
`\clearpage`{=latex}
## XM
## XM (X-Modem)
| XM | |
| --------------------|---|
@@ -2655,15 +2705,25 @@ files between systems using a serial port.
| `XM LK `*`<library> <filename>`*
| `XM R `*`<filename>`*
`S`: Send a file
`L`: Send a file from a library
`R`: Receive a file
`K`: Use 1K blocksize for transfer
The following may be added to the action codes:
| `S`: Send a file
| `L`: Send a file from a library
| `R`: Receive a file
| `K`: Use 1K blocksize (send operations)
| `C`: Force use of checksum (receive operations)
| `X`: Force 128-byte protocol (receive operations)
| `0`-`9`: Specifies HBIOS character unit for transfers
*`<filename>`* is the name of a file to send or receive
*`<library>`* is the name of a library (.lbr) to extract a file to send
For example, the following command will receive a file
using checksums on HBIOS character unit 3 and will name the
received file `MYFILE.TXT`.
`XM RC3 MYFILE.TXT`
#### Usage
To transfer a file from your host computer to your RomWBW computer, do
@@ -2689,9 +2749,10 @@ emulation software for specific instructions on how to use XModem.
#### Notes
The XModem adaptation that comes with RomWBW will automatically use
the primary character device unit (character device unit 0) for the
file transfer.
The XModem adaptation that comes with RomWBW will default to using
the current HBIOS console port for transfers. Note that if you
change your console port at the OS level (e.g., STAT CON:=UC1:),
this does not change the HBIOS console.
`XM` attempts to determine the best way to drive the serial port based
on your hardware configuration. When possible, it will bypass the
@@ -2722,7 +2783,7 @@ The source code is provided in the RomWBW distribution.
`\clearpage`{=latex}
## ZMD
## ZMD (Z-Modem)
| ZMD | |
| --------------------|---|
@@ -2732,6 +2793,9 @@ The source code is provided in the RomWBW distribution.
An adaptation of Robert Kramer's Remote CP/M File Transfer Program
with support for XModem and YModem transfers.
**NOTE**: ZMD does not do ZModem transfers. The Z in ZMD refers
to Z-System compatibility.
#### Syntax
`ZMD` *\<mode\>\<protocol\>\<unit\>* [*\<filename\>*]
@@ -2755,10 +2819,43 @@ the RomWBW Character Unit to use for the file transfer.
#### Usage
To transfer a file from your host computer to your RomWBW computer, do
the following:
1. Enter one of the `ZMD` receive commands specifying the name you want
to give to the received file (no filename required for ZModem transfers).
2. On your host computer select a file to send and initiate an XModem or
YModem send operation.
To transfer a file from your RomWBW computer to your host computer, do
the following:
1. Enter one of the `ZMD` send commands specifying the name of the file
to be sent.
2. On your host computer, specify the name to assign to the received
file and initiate an XModem or YModem receive operation.
Please refer to the documentation of your host computer's terminal
emulation software for specific instructions on how to use XModem.
#### Notes
If no *\<unit\>* is specified, ZMD will use the current HBIOS
console for the file transfer.
The ZMP adaptation that comes with RomWBW will default to using
the current HBIOS console port for transfers. Note that if you
change your console port at the OS level (e.g., STAT CON:=UC1:),
this does not change the HBIOS console.
`ZMP` attempts to determine the best way to drive the serial port based
on your hardware configuration. When possible, it will bypass the
HBIOS for faster operation. However, in many cases, it will use HBIOS
so that flow control can be used.
`ZMP` is dependent on a reliable communications channel. You must
ensure that the serial port can be serviced fast enough by either
using a baud rate that is low enough or ensuring that hardware flow
control is fully functional (end to end).
#### Etymology
@@ -2767,32 +2864,68 @@ uses the RomWBW HBIOS serial API.
`\clearpage`{=latex}
## ZMP
## ZMP (Z-Modem Program)
| ZMP | |
| --------------------|---|
| ROM-based |No |
| Disk-based |Yes|
`ZMP` is a terminal program for interacting with a modem attached to
your system. It includes X/Y/ZModem file transfer protocols. An
actual modem is not required, but you must have a port for ZMP to use
that is independent of the console running `ZMP`.
#### Syntax
`ZMD` *[\<unit\>]*
*\<unit\>* can specify a single digit (0-9) indicating
the RomWBW Character Unit to use for the modem port.
#### Usage
Refer to the file `ZMP.DOC` found on all disk images that include
the `ZMP` application.
#### Notes
`ZMP` requires access to multiple overlay and configuration files
to run. It will look for these on the default driver and user area.
Depending the operating system used, you may be able to set up a
search path and locate these files in other locations. The files
used by `ZMP` are:
- `ZMP.HLP`
- `ZMP.DOC`
- `ZMP.CFG`
- `ZMP.FON`
- `ZMXFER.OVR`
- `ZMTERM.OVR`
- `ZMINIT.OVR`
- `ZMCONFIG.OVR`
The `ZMP` console is always the active OS console.
If no *\<unit\>* is specified on the command line, `ZMP` will
default to using HBIOS Character Unit 1 as the modem port. Take care
to avoid using the same HBIOS Character Unit as both the console and
the modem or various strangeness will occur.
`ZMP` is a full screen application and is configured to use
ANSI/VT-100 screen control.
`ZMP` does not support the range of port configurations provided by
RomWBW. The RomWBW adaptation of `ZMP` ignores the port configuration
options within `ZMP`. Instead, you should configure the HBIOS Character
Unit using the RomWBW MODE command before launching `ZMP`.
`ZMP` is written in C. As a result, file transfers will be noticeably
slower than other assembly language file transfer tools.
#### Etymology
ZMP was produced by Ron Murray and was based on HMODEM II. Wayne
Hortensius updated the source to compile with the latest version
of Hi-Tech C and implemented a few enhancements.
The RomWBW overlay was developed by Phil Summers.

View File

@@ -688,34 +688,34 @@ RomWBW enhancements. These applications are typically documented in the
"RomWBW Applications.pdf" document in the Doc directory of the
RomWBW Distribution.
| **File** | **Source** | **Description** |
|----------------|-----------------|---------------------------------------------------------------|
| `ASSIGN.COM` | RomWBW | Assign,remove,swap drive letters of RomWBW disk slices |
| `CLRDIR.COM` | Max Scane | Initializes the directory area of a disk |
| `COPYSL.COM` | M.Pruden | Copy CPM Hard Disk Slices |
| `COPYSL.DOC` | M.Pruden | Documentation for COPYSL.COM |
| `CPUSPD.COM` | RomWBW | CPU Speed |
| `FAT.COM` | RomWBW | MS-DOS FAT filesystem tool (list, copy, delete, format, etc.) |
| `FDISK80.COM` | John Coffman | Hard disk partitioning tool |
| `FDU.COM` | RomWBW | Floppy Disk Utility, Test and format floppy disks |
| `FDU.DOC` | RomWBW | Documentation for FDU |
| `FLASH.COM` | Will Sowerbutts | Program FLASH chips in-situ |
| `FLASH.DOC` | Will Sowerbutts | Documentation for FLASH |
| `FORMAT.COM` | RomWBW | Placeholder application with formatting instructions |
| `HTALK.COM` | Tom Plano | Terminal utility talking directly to HBIOS Character Units |
| `MODE.COM` | RomWBW | Change serial line characteristics (baud rate, etc.) |
| `REBOOT.COM` | MartinR | Cold or Warm Boot the RomWBW System |
| `RTC.COM` | Andrew Lynch | Test real time clock hardware on your system |
| `SURVEY.COM` | RomWBW | Display system resources summary |
| `SYSCOPY.COM` | RomWBW | Copy system tracks to disks (make bootable) |
| `TALK.COM` | RomWBW | Route console I/O to & from specified serial port |
| `TIMER.COM` | RomWBW | Test and display system timer ticks |
| `TUNE.COM` | RomWBW | Play .PT2, .PT3, and .MYM audio files on supported hardware |
| `VGMPLAY.COM` | | Simple player for VGM (Video Game Music) files. |
| `WDATE.COM` | Kevin Boone | Utility to configure RTC Date. |
| `XM.COM` | RomWBW | XModem file transfer application |
| **File** | **Source** | **Description** |
|----------------|-------------------|---------------------------------------------------------------|
| `ASSIGN.COM` | RomWBW | Assign,remove,swap drive letters of RomWBW disk slices |
| `CLRDIR.COM` | Max Scane | Initializes the directory area of a disk |
| `COPYSL.COM` | M.Pruden | Copy CPM Hard Disk Slices |
| `COPYSL.DOC` | M.Pruden | Documentation for COPYSL.COM |
| `CPUSPD.COM` | RomWBW | CPU Speed |
| `FAT.COM` | RomWBW | MS-DOS FAT filesystem tool (list, copy, delete, format, etc.) |
| `FDISK80.COM` | John Coffman | Hard disk partitioning tool |
| `FDU.COM` | RomWBW | Floppy Disk Utility, Test and format floppy disks |
| `FDU.DOC` | RomWBW | Documentation for FDU |
| `FLASH.COM` | Will Sowerbutts | Program FLASH chips in-situ |
| `FLASH.DOC` | Will Sowerbutts | Documentation for FLASH |
| `FORMAT.COM` | RomWBW | Placeholder application with formatting instructions |
| `HTALK.COM` | Tom Plano | Terminal utility talking directly to HBIOS Character Units |
| `MODE.COM` | RomWBW | Change serial line characteristics (baud rate, etc.) |
| `REBOOT.COM` | MartinR | Cold or Warm Boot the RomWBW System |
| `RTC.COM` | Andrew Lynch | Test real time clock hardware on your system |
| `SURVEY.COM` | RomWBW | Display system resources summary |
| `SYSCOPY.COM` | RomWBW | Copy system tracks to disks (make bootable) |
| `TALK.COM` | RomWBW | Route console I/O to & from specified serial port |
| `TIMER.COM` | RomWBW | Test and display system timer ticks |
| `TUNE.COM` | RomWBW | Play .PT2, .PT3, and .MYM audio files on supported hardware |
| `VGMPLAY.COM` | | Simple player for VGM (Video Game Music) files. |
| `WDATE.COM` | Kevin Boone | Utility to configure RTC Date. |
| `XM.COM` | RomWBW | XModem file transfer application |
Then we have some more general purpose applcations.
Then we have some more general purpose applications.
In general, there is no documentation for these applications included with the RomWBW
distribution. Some provide command line help themselves. Some are fairly obvious.
@@ -742,7 +742,9 @@ distribution. Some provide command line help themselves. Some are fairly obvio
| `SUPERSUB.DOC` | | Documentation for SUPERSUB |
| `SYSGEN.COM` | DRI | Copy system tracks to disks |
| `TBASIC.COM` | Dimitri Theulings | Tasty Basic. This also exists as a Rom appication |
| `TDLBASIC.COM` | | TDL Zapple 12K BASIC language interpreter |
| `TDLBASIC.COM` | | TDL Zapple 12K BASIC language interpreter |
| `TE.COM` | Ladislau Szilagyi | RomWBW enhanced version of TE editor |
| `TE.DOC` | Ladislau Szilagyi | TE Editor Documentation |
| `UNARC.COM` | | Extract file(s) from .ARC or .ARK archive |
| `UNARC.DOC` | | Documentation for UNARC |
| `UNCR.COM` | | Decompress Crunched file(s). See CRUNCH.COM |
@@ -1307,7 +1309,7 @@ Also contained on this image in User Area 1 are.
| Floppy Disk Image: **fd_z80asm.img**
| Hard Disk Image: **hd_z80asm.img**
This disk contains 4 major components
This disk contains 6 major components
* Z80ASM is a relocating macro assembler for CP/M. It takes assembly language
source statements from a disk file, converts them into their binary equivalent,
@@ -1317,22 +1319,30 @@ listing output may be sent to a disk file, the console and/or the printer, in
any combination. Output files may also be generated containing cross-reference
information on each symbol used.
* Z80ASMP (Z80ASM Plus). Referred to as the "Virtual Memory" version which
uses disk for working storage, thus not constrained by RAM.
* SLR180 is a powerful relocating macro assembler for Z80
compatible CP/M systems. It takes assembly language source
statements from a disk file, converts them into their binary
equivalent, and stores the output in either a core-image, Intel
hex format, or relocatable object file. The mnemonics recognized
are those of Zilog/Hitachi. The optional listing output may be
are those of Zilog (Z180)/Hitachi. The optional listing output may be
sent to a disk file, the console and/or the printer, in any
combination. Output files may also be generated containing
cross-reference information on each symbol used.
* SLRMAC relocating macro assembler for Intel 8080 mnemonics
* SLRNK is a powerful linking loader for Z80-based CP/M systems.
It takes relocatable binary information in either Microsoft or
SLR Systems format from a disk file, resolves external and entry
point references, and stores the output in memory for execution
or outputs it to a disk file.
* SLRNKP (SLRNK Plus). Referred to as the "Virtual Memory" version which
uses disk for working storage, thus not constrained by RAM.
* Z80DIS is an entirely new disassembler for Z80 based CP/M sys-
tems. Z80DIS is written in TURBO PASCAL. Z80DIS generates Z80
mnemonics and prepares an assembly language file with many
@@ -1364,18 +1374,21 @@ User Area 0 - Assembler
| 180FIG.COM | Configuration utility for SLR180.COM |
| 8080.MAC | ? |
| CONFIG.COM | Configuration utility for Z80ASM.COM |
| CONFIGP.COM | Configuration utility for Z80ASMP.COM |
| DUMP.* | Sample Program |
| MAKESYM.COM | Symbol File .SYM file generation |
| MAKESYM.DOC | Documentation for MAKESYM.COM |
| SLR180.COM | HD64180 Relocating Macro Assembler |
| SLR180.COM | HD64180 (Z180) Relocating Macro Assembler |
| SLR180.DOC | Release Notes for SLR180.COM |
| SLRMAC.COM | 8080 Relocating Macro Assembler |
| SYNTAX.HLP | Documentation basic usage for all SLR Tools |
| SYNTAX.TXT | Documentation basic usage for all SLR Tools |
| TEST.* | Sample Program |
| Z80ASM.COM | Z80 Relocating Macro Assembler |
| Z80ASMP.COM | Z80 Relocating Macro Assembler (PLUS) |
| Z80ASM.DOC | Release Notes for Z80ASM.COM |
User Area 1 - Linker
User Area 1 - Linker and Library Management
| **File** | **Description** |
|--------------|-----------------------------------------------|
@@ -1383,6 +1396,7 @@ User Area 1 - Linker
| NZLNKFIX.ZEX | ? |
| SLRIB.COM | SuperLibrarian, library manager |
| SLRNK.COM | SuperLinker, the main linker tool |
| SLRNKP.COM | SuperLinker (PLUS) |
| SLRNK.DOC | Release Notes for SLRNK.COM |
| SLRNKFIX.ZEX | ? |
| SYNTAX.HLP | Documentation basic usage for all SLR Tools |

File diff suppressed because it is too large Load Diff

View File

@@ -199,7 +199,7 @@ please let me know if I missed you!
- significant content in the Disk Catalog and User Guide
- creation of the Introduction and Hardware documents
- Z3PLUS operating system disk image
- COPYSL utility
- COPYSL and SLABEL utility
- a feature for RomWBW configuration by NVRAM
- the /B bulk mode of disk assignment to the ASSIGN utility

View File

@@ -16,7 +16,7 @@ constraints, new hardware platforms can be supported by simply
adjusting values in a build configuration file.
RomWBW is geared toward hardware being developed in modern
retro-computing hobbyist communities, not as a replacement for
retro-computing hobbyist communities, not as replacement software for
legacy hardware. As a result, RomWBW requires at least 128KB
of bank switched RAM.
@@ -42,11 +42,11 @@ RomWBW firmware (ROM) includes:
It is appropriate to note that much of the code and components that make
up a complete RomWBW package are derived from pre-existing work. Most
notably, the embedded operating system is simply a ROM-based copy of
notably, the embedded operating systems are simply ROM-based copies of
generic CP/M or ZSDOS. Much of the hardware support code was originally
produced by other members of the RetroBrew Computers Community.
The remainder of this document focuses on HBIOS which is the
The remainder of this document focuses on RomWBW HBIOS which is the
fundamental basis of RomWBW.
# Background
@@ -61,13 +61,13 @@ space that is much larger than the CPU address space (typically 512K or
the CPU using a technique called bank switching. To achieve this, the
physical memory is divided up into chunks (banks) of 32K each. A
designated area of the CPU's 64K address space is then reserved to "map"
any of the physical memory chunks. You can think of this as a window
any of the physical memory chunks. You can think of this as a window
that can be adjusted to view portions of the physical memory in 32K
blocks. In the case of RomWBW, the lower 32K of the CPU address space is
used for this purpose (the window). The upper 32K of CPU address space
used for this purpose (the window). The upper 32K of CPU address space
is assigned a fixed 32K area of physical memory that never changes. The
lower 32K can be "mapped" on the fly to any of the 32K banks of physical
memory at a time. The only constraint is that the CPU cannot be
memory at a time. The primary constraint is that the CPU cannot be
executing code in the lower 32K of CPU address space at the time that a
bank switch is performed.
@@ -91,6 +91,17 @@ operating system is unaware this has occurred. As control is returned to
the operating system, the lower 32KB of memory is switched back to the
original memory bank.
The HBIOS functions are invoked simply by placing function parameters
in Z80 registers and calling an address within the HBIOS proxy.
Additionally, HBIOS implements a complete hardware interrupt management
framework. When a hardware interrupt occurs, control vectors through
the HBIOS proxy which saves the machine state, selects the HBIOS
driver bank into memory, and transfers control to the registered
driver's interrupt handler. Upon completion of interrupt processing,
control returns via the HBIOS proxy, machine state is restored, and
normal processing resumes. The interrupt management framework supports
Z80 interrupt modes 1, 2, and 3 (Z280).
HBIOS is completely agnostic with respect to the operating system (it
does not know or care what operating system is using it). The operating
system makes simple calls to HBIOS to access any desired hardware
@@ -124,8 +135,23 @@ execution.
# Runtime Memory Layout
![Bank Switched Memory Layout](Graphics/BankSwitchedMemory){ width=100% }
RomWBW divides the standard 64KB Z80 address space into 2 sections.
The lower 32KB is the "banked" area. This is the area that will
contain any of the 32KB chunks of physical RAM based on which bank is
currently selected. The upper 32KB is "fixed". This area of memory
is never swapped out and is used to contain software and operating
systems that must remain in the Z80 address space.
Figure 4.1 depicts the memory layout for a system running the CP/M
operating system. Applications residing in TPA invoke BDOS services
of CP/M, BDOS invokes the custom CBIOS APIs, and finally CBIOS
invokes HBIOS functions as needed by calling into the HBIOS proxy.
The HBIOS proxy swaps in the HBIOS bank as needed to perform the
requested function.
Additional banks of RAM are used to create a virtual disk drive.
![Bank Switched Memory Layout](Graphics/BankSwitchedMemory){ width=100% }
## Bank Id
@@ -139,16 +165,17 @@ a ROM bank is being referred to. If it is 1, it indicates a RAM bank
is being referred to.
For example, let's say we have a typical system with 512KB of ROM and
512KB of RAM. The Bank Ids would look like this:
512KB of RAM. The following table demonstrates how Bank Ids represent
areas of physical memory.
| Physical Memory | Type | Physical Bank | Bank Id |
|-------------------|------|---------------|-----------|
| 0x000000-0x007FFF | ROM | 0 | 0x00 |
| 0x008000-0x00FFFF | ROM | 1 | 0x01 |
| 0x010000-0x07FFFF | ROM | 2-15 | 0x02-0x0F |
| 0x080000-0x087FFF | RAM | 16 | 0x80 |
| 0x088000-0x08FFFF | RAM | 17 | 0x81 |
| 0x090000-0x0FFFFF | RAM | 18-31 | 0x82-0x8F |
| **Physical Memory** | **Type** | **Physical Bank** | **Bank Id** |
|-----------------------|----------|-------------------|---------------|
| 0x000000-0x007FFF | ROM | 0 | 0x00 |
| 0x008000-0x00FFFF | ROM | 1 | 0x01 |
| 0x010000-0x07FFFF | ROM | 2-15 | 0x02-0x0F |
| 0x080000-0x087FFF | RAM | 16 | 0x80 |
| 0x088000-0x08FFFF | RAM | 17 | 0x81 |
| 0x090000-0x0FFFFF | RAM | 18-31 | 0x82-0x8F |
Note that Bank Id 0x00 is **always** the first bank of ROM and 0x80 is
**always** the first bank of RAM. If there were more banks of physical ROM,
@@ -170,23 +197,23 @@ table describes the way the banks are assigned. The Typical column
shows the specific values that would be assigned for a common system
with 512KB of ROM and 512KB of RAM (nROM=16, nRAM=16).
| Bank Id | Identity | Typical | Purpose |
|-------------------|-----------|---------|------------------------------------------|
| 0x00 |BID_BOOT | 0x00 | Boot Bank (HBIOS image) |
| 0x01 |BID_IMG0 | 0x01 | Boot Loader, Monitor, ROM OSes, ROM Apps |
| 0x02 |BID_IMG1 | 0x02 | ROM Apps |
| 0x03 |BID_IMG2 | 0x03 | \<Reserved\> |
| 0x04 |BID_ROMD0 | 0x04 | First ROM Disk Bank |
| nROM - 1 | | 0x0F | Last ROM Disk Bank |
| 0x80 |BID_BIOS | 0x80 | HBIOS (working copy) |
| 0x81 |BID_RAMD0 | 0x81 | First RAM Disk Bank |
| 0x80 + nRAM - 8 | | 0x88 | Last RAM Disk Bank |
| 0x80 + nRAM - 7 |BID_APP0 | 0x89 | First Application Bank |
| 0x80 + nRAM - 5 | | 0x8B | Last Application Bank |
| 0x80 + nRAM - 4 |BID_BUF | 0x8C | OS Disk Buffers |
| 0x80 + nRAM - 3 |BID_AUX | 0x8D | OS Code Bank |
| 0x80 + nRAM - 2 |BID_USR | 0x8E | User Bank (CP/M TPA) |
| 0x80 + nRAM - 1 |BID_COM | 0x8F | Common Bank |
| **Bank Id** | **Identity** | **Typical** | **Purpose** |
|---------------------|--------------|-------------|--------------------------------------------|
| 0x00 | BID_BOOT | 0x00 | Boot Bank (HBIOS image) |
| 0x01 | BID_IMG0 | 0x01 | Boot Loader, Monitor, ROM OSes, ROM Apps |
| 0x02 | BID_IMG1 | 0x02 | ROM Apps |
| 0x03 | BID_IMG2 | 0x03 | \<Reserved\> |
| 0x04 | BID_ROMD0 | 0x04 | First ROM Disk Bank |
| nROM - 1 | | 0x0F | Last ROM Disk Bank |
| 0x80 | BID_BIOS | 0x80 | HBIOS (working copy) |
| 0x81 | BID_RAMD0 | 0x81 | First RAM Disk Bank |
| 0x80 + nRAM - 8 | | 0x88 | Last RAM Disk Bank |
| 0x80 + nRAM - 7 | BID_APP0 | 0x89 | First Application Bank |
| 0x80 + nRAM - 5 | | 0x8B | Last Application Bank |
| 0x80 + nRAM - 4 | BID_BUF | 0x8C | OS Disk Buffers |
| 0x80 + nRAM - 3 | BID_AUX | 0x8D | OS Code Bank |
| 0x80 + nRAM - 2 | BID_USR | 0x8E | User Bank (CP/M TPA) |
| 0x80 + nRAM - 1 | BID_COM | 0x8F | Common Bank |
In this table, nROM and nRAM refer to the number of corresponding
ROM and RAM banks in the the system.
@@ -265,28 +292,72 @@ hence the name "Common".
# Disk Layout
RomWBW supports two hard disk layouts: the Classic layout used by
RomWBW with 512 directory entries per slice and a Modern layout with
1024 directory entries per slice. These layouts are referred to as
hd512 and hd1k respectively.
## Floppy Disk Layout
RomWBVW generally handles floppy disks in the same physical formats
as MS-DOS. However, the filesystem will normally be CP/M. The following
table lists the floppy disk formats used by RomWBW. In all cases,
the sector size is 512 bytes.
| **HBIOS Media ID** | **Capacity** | **Tracks** | **Heads** | **Sectors** |
|--------------------|-------------:|-----------:|----------:|------------:|
| MID_FD720 | 720KB | 80 | 2 | 9 |
| MID_FD144 | 1440KB | 80 | 2 | 18 |
| MID_FD360 | 360KB | 40 | 2 | 9 |
| MID_FD120 | 1200KB | 80 | 2 | 15 |
| MID_FD111 | 1155KB | 77 | 2 | 15 |
## Hard Disk Layout
RomWBW supports the use of PC MBR hard disk partitioning (see
<https://en.wikipedia.org/wiki/Disk_partitioning>). When accessing
a hard disk device, HBIOS will look for a partition with type id 0x2E
and will use that partition exclusively for all storage. If a hard
disk does not have a valid partition table with a partition of type
0x2E, the HBIOS will treat the hard disk as dedicated storage and
will store data starting at the first sector of the disk.
The use of a partition of type 0x2E is preferred for RomWBW and is
referred to as a "Modern" disk layout. If there is no RomWBW
partition on the disk, then the disk is designated as having a
"Classic" disk layout.
When a disk uses a RomWBW partition (type 0x2E) for storage (Modern
layout), the CP/M filesystems on that disk will utilize a format with
1,024 directory entries per filesystem. If there is no RomWBW
partition, the CP/M filesystems will have 512 directory entries per
filesystem. As a result, the Modern disk layout with a RomWBW partition
is also referred to as the "hd1k" layout indicating 1024 directory
entries. Similarly, the Classic disk layout (no partition of type 0x2E)
is also referred to as the "hd512" layout indicating 512 directory
entries.
The layout type of any hard disk is simply dictated by the existence of
a RomWBW partition. This also means that if you add or remove a
partition table entry of type 0x2E on existing hard disk media, you will
lose access to any pre-existing CP/M data on the disk. If used,
partitioning should be done before putting any data on the disk.
WARNING: You **can not** mix the two hard disk layouts on one hard
disk device. You can use different layouts on different hard disk
devices in a single system though.
RomWBW determines which of the hard disk layouts to use for a given
hard disk device based on whether there is a RomWBW hard disk
partition on the disk containing the slices. If there is no RomWBW
partition, then RomWBW will assume the 512 directory entry format for
all slices and will assume the slices start at the first sector of
the hard disk. If there is a RomWBW partition on the hard disk
device, then RomWBW will assume the 1024 directory entry format for
all slices and will assume the slices are located in the defined
partition.
Regardless of whether a disk is Modern or Classic, RomWBW supports
the concept of CP/M filesystem slices. In general, CP/M filesystems are
limited to 8MB. Since current disk media is dramatically larger than
this, RomWBW implements a mechanism to put many (up to 256) CP/M
filesystems on a single disk. Each such filesystem is called a slice
referring to the idea that the disk has been sliced into many
independent CP/M filesystems. RomWBW allows the disk slices to be
mapped to the limited (16) drive letters of CP/M. The mapping can be
modified on-the-fly on a running system as desired.
RomWBW supports up to 256 CP/M slices (0-255). Under hd512, the slices
begin at the start of the hard disk. Under hd1k, the slices reside
within partition type 0x2E.
If the case of a Modern disk layout (with a RomWBW partition), the
slices are contained within the defined partition area and the number
of slices is dictated by the size of the partition. In the case of a
Classic disk layout (no RomWBW partition), the slices are located at the
start of the disk (first sector). In either case, the slices are just
sequential areas of space on the hard disk.
RomWBW accesses all hard disks using Logical Block Addressing (pure
sector offset). When necessary, RomWBW simulates the following disk
@@ -315,17 +386,16 @@ and CP/M knows nothing about the FAT partition. However, the FAT
application can be run under CP/M to access the FAT partition
programmatically.
A CP/M slice is (re)initialized using the CP/M command CLRDIR. A CP/M
slice can be made bootable by copying system image to the System Area
using SYSCOPY.
Before being used, A CP/M slice must be (re)initialized using the CP/M
command CLRDIR. A CP/M slice can be made bootable by copying a system
image to the System Area using SYSCOPY.
The FAT partition can be created from CP/M using the FDISK80 application.
The FAT partition can be initialized using the FAT application from CP/M
using the command `FAT FORMAT n:` where n is the RomWBW disk unit
number containing the FAT partition to be formatted.
## Modern Disk Layout (hd1k)
### Modern Hard Disk Layout (hd1k)
![Modern Disk Layout](Graphics/hd1k)
@@ -336,7 +406,7 @@ The CP/M slices reside entirely within a hard disk partition of type
0x2E. The number of slices is determined by the number of slices that
fit within the partition spaces allocated up to the maximum of 256.
## Classic Disk Layout (hd512)
### Classic Hard Disk Layout (hd512)
![Classic Disk Layout](Graphics/hd512)
@@ -363,27 +433,25 @@ application. The user is responsible for ensuring that the start of the
FAT partition does not overlap with the area they intend to use for
CP/M slices. FDISK80 has a Reserve option to assist with this.
## Mapping to Media ID
### Mapping to Media ID
HBIOS has a definition of "Media ID", which defines the type and physical
properties of disk media provided by an underlying storage device. For a
complete list of Media ID's please see the following section
[Disk Input/Output (DIO)]
complete list of Media ID's please see [Disk Input/Output (DIO)].
There are two important Media ID's relating to Hard Disk Layouts:
| **Media** | **ID** | **Format / Meaning** |
|------------|-------:|-------------------------------------------------------------|
| MID_HD | 4 | Classic Disk Layout (hd512) *--and--* HBIOS Hard Disk Drive |
| MID_HDNEW | 10 | Modern Disk Layout (hd1k) |
| **Media** | **ID** | **Format / Meaning** |
|----------------|-------:|-------------------------------------------------------------|
| MID_HD | 4 | Classic Disk Layout (hd512) *--and--* HBIOS Hard Disk Drive |
| MID_HDNEW | 10 | Modern Disk Layout (hd1k) |
HBIOS typically does not understand the format of data on a device,
instead just treating all hard disks as raw sectors. `MID_HD` is the typical
Media ID used by HBIOS to describe high capaity hard disk media
Media ID used by HBIOS to describe high capacity hard disk media
When the Modern Disk Layout was added, the `MID_HDNEW`, was added to
differentiate (at the oerating system level) between the Classic and Modern layouts.
differentiate (at the operating system level) between the Classic and Modern layouts.
However HBIOS itself typically does NOT make this distinction, since the use
of these two formats is determined by the operating system based on the
@@ -464,8 +532,10 @@ of a system image before programming it to the ROM; or 2) easily switch
between system images on the fly.
During the RomWBW build process, one of the output files produced is an
actual CP/M application (an executable .COM program file). Once you have
a running CP/M (or compatible) system, you can upload/copy this
actual CP/M application (an executable .COM program file). Like the
normal .ROM files, this file is placed in the Binary directory with the
same name as the ROM file, but with the file extension of .ROM. Once
you have a running CP/M (or compatible) system, you can upload/copy this
application file to the filesystem. By executing this file, you will
initiate an Application Boot using the system image contained in the
application file itself.
@@ -501,7 +571,7 @@ and control is passed to the Boot Loader.
## Boot Recovery
To assist users when driver faults or misconfiguration causes a boot
To assist users when driver faults or mis-configuration causes a boot
failure, RomWBW supports a limited recovery capability. This is
achieved by allowing the user to reboot their machine, loading
a minimal driver set. Implementation of this feature requires a
@@ -638,7 +708,7 @@ CRT character device, the data is actually passed to a built-in terminal
emulator which, in turn, utilizes a set of VDA (Video Display Adapter)
functions (such as cursor positioning, scrolling, etc.).
Figure 7.1 depicts the relationship between these components
Figure 9.1 depicts the relationship between these components
of HBIOS video processing:
![Character / Emulation / Video Services](Graphics/CharacterEmulationVideoServices){ width=100% }
@@ -689,7 +759,7 @@ must be careful not to modify the operating environment in any way that
the operating system does not expect.
In general, the desired function is placed in the B register. Register C
is frequently used to specify a subfunction or a target device unit
is frequently used to specify a sub-function or a target device unit
number. Additional registers are used as defined by the specific
function. Register A should be used to return function result
information. See below for result code definitions.
@@ -712,7 +782,7 @@ lower 32K of CPU address space. For optimal performance, such buffers
should be placed in the upper 32K of CPU address space.
HBIOS also implements a small number of core functions in the HBIOS
proxy area at the top of RAM. These exist primarily to faciliate the
proxy area at the top of RAM. These exist primarily to facilitate the
operation of normal HBIOS function calls. However, they are available
to be used by OSes and applications. These functions can only be
invoked by calling into a jump table in upper RAM.
@@ -766,10 +836,11 @@ below enumerates these values.
| CIODEV_DUART | 0x09 | SCC2681 Family Dual UART | duart.asm |
| CIODEV_Z2U | 0x0A | Zilog Z280 Built-in Serial Ports | z2u.asm |
| CIODEV_LPT | 0x0B | Parallel I/O Controller | lpt.asm |
| CIODEV_ESPCON | 0x0B | ESP32 VGA Console | esp.asm |
| CIODEV_ESPSER | 0x0B | ESP32 Serial Port | esp.asm |
| CIODEV_SCON | 0x0B | S100 Console | scon.asm |
| CIODEV_EZ80UART | 0x11 | eZ80 Built-in UART0 Interface | ez80uart.asm |
| CIODEV_ESPCON | 0x0C | ESP32 VGA Console | esp.asm |
| CIODEV_ESPSER | 0x0D | ESP32 Serial Port | esp.asm |
| CIODEV_SCON | 0x0E | S100 Console | scon.asm |
| CIODEV_SSER | 0x0F | Simple Serial Console | sser.asm |
| CIODEV_EZ80UART | 0x10 | eZ80 Built-in UART0 Interface | ez80uart.asm |
Character devices can usually be configured with line characteristics
such as speed, framing, etc. A word value (16 bit) is used to describe
@@ -906,7 +977,9 @@ Returns the current Line Characteristics (DE) of the specified Character
Returns device information for the specified Character Unit (C). The
status (A) is a standard HBIOS result code.
Device Attribute (C) values are: 0 = RS/232, 1 = Terminal, 2 = Parallel.
The two high bits of Device Attribute (C) are: 00 = RS/232, 01 = Terminal,
10 = Parallel. The remaining bits should be ignored and are used
internally.
Device Type (D) indicates the specific hardware driver that handles the
specified Character Unit. Values are listed at the start of this
@@ -932,7 +1005,7 @@ during the boot process that identifies all disk devices uniquely.
All character units are assigned a Device Type ID which indicates
the specific hardware device driver that handles the unit. The table
below enumerates there values.
below enumerates their values.
| **Device Type** | **ID** | **Description** | **Driver** |
|-----------------|-------:|------------------------------------------|------------|
@@ -1074,6 +1147,13 @@ contain all sectors requested. Disk data transfers will be faster if
the buffer resides in the top 32K of memory because it avoids a
double buffer copy.
Also for buffers in the top 32K of memory the Bank ID is not
strictly required as this memory is alway mapped to the common bank.
For buffers in the bottom 32KB ram, the Bank ID is used to identify
the bank to use for the buffer. If you do not wih to use banked memory
you will need to provide the current Bank ID, which can be obtained
using [Function 0xF3 -- System Get Bank (SYSGETBNK)]
### Function 0x14 -- Disk Write (DIOWRITE)
| **Entry Parameters** | **Returned Values** |
@@ -1618,7 +1698,7 @@ keyboard functions should return a failure status.
All video units are assigned a Device Type ID which indicates
the specific hardware device driver that handles the unit. The table
below enumerates there values.
below enumerates their values.
| **Device Type** | **ID** | **Description** | **Driver** |
|-----------------|-------:|------------------------------------------|------------|
@@ -1981,15 +2061,19 @@ standard HBIOS result code.
| | E: Keycode |
Read the next key data from keyboard of the specified Video Unit (C). If
a keyboard buffer is used, return the next key code in the buffer. If
a keyboard buffer is used, return the next Keycode in the buffer. If
no key data is available, this function will wait indefinitely for a
keypress. The Status (A) is a standard HBIOS result code.
The Scancode (C) value is the raw scancode from the keyboard for the
keypress. Scancodes are from the PS/2 scancode set 2 standard.
keypress. Scancodes are optional and may not be implemented by the
driver. The Scancode values are driver dependent. In the case of a
PS/2 keyboard driver, they should be the PS/2 scancode. Other keyboard
drivers may return values appropriate for their specific keyboard. If
the driver does not implement this, it should return 0 in C.
The Keystate (D) is a bitmap representing the value of all modifier keys
and shift states as they existed at the time of the keystroke. The
and shift states as they existed at the time of the keystroke. The
bitmap is defined as:
| **Bit** | **Keystate Indication** |
@@ -2003,6 +2087,9 @@ bitmap is defined as:
| 1 | Control key was held down |
| 0 | Shift key was held down |
Not all of these bits may be relevant for all keyboards. Any bit that
is not relevant should be returned as 0.
The Keycode (E) is generally returned as appropriate ASCII values, if
possible. Special keys, like function keys and arrows, are returned as
reserved codes as described at the start of this section.
@@ -2331,7 +2418,7 @@ start of the Slice (E). The Status (A) is a standard HBIOS result code.
This function extends upon [Function 0x18 -- Disk Media (DIOMEDIA)] for hard
disk media by scanning for a partition to determine if the disk uses HD512
or HD1K, correctly reporting MID_HD or MID_HDNEW respectively.
See the folowing for some background [Mapping to Media ID]
See the following for some background [Mapping to Media ID]
It will also return the sector number of the first sector in the
slice if the slice number is valid. If the slice number is invalid
@@ -2410,26 +2497,34 @@ version 3.1.0, build 2.
The hardware Platform (L) is identified as follows:
| **Name** | **Id** | **Platform ** |
| **Name** | **Id** | **Platform ** |
|---------------|-------:|-----------------------------------------|
| PLT_SBC |1 | ECB Z80 SBC |
| PLT_ZETA |2 | ZETA Z80 SBC |
| PLT_ZETA2 |3 | ZETA Z80 V2 SBC |
| PLT_N8 |4 | N8 (HOME COMPUTER) Z180 SBC |
| PLT_MK4 |5 | MARK IV |
| PLT_UNA |6 | UNA BIOS |
| PLT_RCZ80 |7 | RCBUS W/ Z80 |
| PLT_RCZ180 |8 | RCBUS W/ Z180 |
| PLT_EZZ80 |9 | EASY/TINY Z80 |
| PLT_SCZ180 |10 | RCBUS SC126, SC130, SC131, SC140 |
| PLT_DYNO |11 | DYNO MICRO-ATX MOTHERBOARD |
| PLT_RCZ280 |12 | RCBUS W/ Z280 |
| PLT_MBC |13 | NHYODYNE MULTI-BOARD COMPUTER |
| PLT_RPH |14 | RHYOPHYRE GRAPHICS SBC |
| PLT_Z80RETRO |15 | Z80 RETRO COMPUTER |
| PLT_S100 |16 | S100 COMPUTERS Z180 |
| PLT_DUO |17 | DUODYNE Z80 SYSTEM |
| PLT_RCEZ80 |24 | RCBUS W/ eZ80 |
| PLT_SBC | 1 | ECB Z80 SBC |
| PLT_ZETA | 2 | ZETA Z80 SBC |
| PLT_ZETA2 | 3 | ZETA Z80 V2 SBC |
| PLT_N8 | 4 | N8 (HOME COMPUTER) Z180 SBC |
| PLT_MK4 | 5 | MARK IV |
| PLT_UNA | 6 | UNA BIOS |
| PLT_RCZ80 | 7 | RCBUS W/ Z80 |
| PLT_RCZ180 | 8 | RCBUS W/ Z180 |
| PLT_EZZ80 | 9 | EASY/TINY Z80 |
| PLT_SCZ180 | 10 | SMALL COMPUTER CENTRAL Z180 |
| PLT_DYNO | 11 | DYNO MICRO-ATX MOTHERBOARD |
| PLT_RCZ280 | 12 | RCBUS W/ Z280 |
| PLT_MBC | 13 | NHYODYNE MULTI-BOARD COMPUTER |
| PLT_RPH | 14 | RHYOPHYRE GRAPHICS SBC |
| PLT_Z80RETRO | 15 | Z80 RETRO COMPUTER |
| PLT_S100 | 16 | S100 COMPUTERS Z180 |
| PLT_DUO | 17 | DUODYNE Z80 SYSTEM |
| PLT_HEATH | 18 | HEATHKIT H8 Z80 SYSTEM |
| PLT_EPITX | 19 | Z180 MINI-ITX |
| PLT_MON | 20 | MONSPUTER (DEPRECATED) |
| PLT_GMZ180 | 21 | GENESIS Z180 SYSTEM |
| PLT_NABU | 22 | NABU PC W/ ROMWBW OPTION BOARD |
| PLT_FZ80 | 23 | S100 FPGA Z80 |
| PLT_RCEZ80 | 24 | RCBUS W/ eZ80 |
For more information on these platforms see $doc_hardware$
### Function 0xF2 -- System Set Bank (SYSSETBNK)
@@ -2721,7 +2816,7 @@ Switches may be returned as a 16 bit (HL) or 8 bit (L) value. It is up to the ca
to process the returned value correctly. Note for Switch 0xFF (status) the returned value
is primarily in the Status (A) register.
Errors are signalled in the return by setting the NZ flag. When set the
Errors are signaled in the return by setting the NZ flag. When set the
(A) register may contain an error code, but this code does not conform to RomWBW standard
Success is indicated by setting the Z flag
@@ -3039,7 +3134,7 @@ Status (A) is a standard HBIOS result code.
This function allows the caller to query information about the interrupt
configuration of the running system and allows adding or hooking
interrupt handlers dynamically. Register C is used to specify a
subfunction. Additional input and output registers may be used as
sub-function. Additional input and output registers may be used as
defined by the sub-function. The Status (A) is a standard
HBIOS result code.
@@ -3099,13 +3194,11 @@ with the handler prior to uninstalling it.
| C: 0x00 | D: Interrupt Mode |
| | E: IVT Size |
Return current Interrupt Mode (D) of the system. Also return the
number of Interrupt Vector Table (IVT) entries in IVT Size (E).
interrupt mode in D and size of interrupt vector table in E. For
IM1, the size of the table is the number of vectors chained together.
For IM2, the size of the table is the number of slots in the vector
table. The Status (A) is a standard
HBIOS result code.
Return current Interrupt Mode (D) of the system. Also return the number
of Interrupt Vector Table (IVT) entries in IVT (E). For IM1, the size
of the table is the number of vectors chained together. For IM2, the
size of the table is the number of slots in the vector table. The
Status (A) is a standard HBIOS result code.
#### SYSINT Subfunction 0x10 -- Get Interrupt (INTGET)
@@ -3468,5 +3561,3 @@ The following section outlines the read only data referenced by the
| DCNTL* | 14 | 1 | Z180 DMA/WAIT CONTROL |
* ONLY PRESENT FOR Z180 BUILDS

View File

@@ -67,7 +67,7 @@ The Binary directory of the distribution contains the pre-built ROM images.
Refer to $doc_hardware$ to identify the correct ROM image for your system.
A complete list of the currently supported platforms is found in
$doc_hardware$ . You must burn the correct ROM image that matches your hardware
$doc_hardware$. You must burn the correct ROM image that matches your hardware
Once you have a running RomWBW system, you can generally update your ROM
to a newer version in-situ with the included ROM Flashing tool (Will
@@ -83,8 +83,8 @@ be able to boot and check out your system with just the ROM.
Connect a serial terminal or computer with terminal emulation software
to the primary serial port of your CPU board. You may need to refer to
your hardware provider's documentation for details. A null-modem
connection may be required. Set the baud rate as indicated in the table
above. Set the line characteristics to 8 data bits, 1 stop bit, no
connection may be required. Set the baud rate as indicated in $doc_hardware$.
Set the line characteristics to 8 data bits, 1 stop bit, no
parity, and no flow control. If possible, select ANSI or VT-100 terminal
emulation. Hardware flow control is not required for terminal
operation, but may be necessary for [Serial Port Transfers].
@@ -833,24 +833,63 @@ disk device performs I/O, the LED will light while the disk is active.
This is only possible for the first 8 disk units.
The second row of the front panel is composed of switches that allow
you to control a few aspects of the system startup.
you to control a few aspects of the system startup. The switches are
also re-read during warm boot, so confirm the switch settings are your
desired boot configuration before executing 'REBOOT /W'.
The first two switches affect the device used as the initial console.
| CRT/Serial | Sec/Pri | Explanation |
|------------|---------|-------------------------------------------------------------|
| CRT | Pri | Primary Cathode Ray Tube device (high speed console) |
| CRT | Sec | Secondary Cathode Ray Tube device (high speed console) |
| Serial | Pri | Boot Console is Primary Serial Port |
| Serial | Sec | Boot Console is Secondary Serial Port |
The first two switches affect the device used as the console initially.
Setting the CRT/Serial switch will cause the system to boot directly
to an attached CRT device (if available). Setting the Pri/Sec switch
will cause the system to boot to the secondary Serial or CRT device
(depending on the setting of the first switch).
If not available (default): "Char Unit 0" is used
The final six switches allow you to cause the system to automatically
boot into a desired function. The Auto/Menu switch must be set to
enable this, otherwise the normal ROM Loader prompt will be used.
If the Disk/ROM switch is not set, then you can use the last 3
switches to select a ROM app to auto-start. If the Disk/ROM switch is
set, then the system will attempt a disk boot based on the following
switches. The Floppy/Hard switch can be used to boot to a Floppy or
Hard Disk. In either case, the first Floppy or Hard Disk will be used
for the boot. If a Hard Disk boot is selected, then the last three
switches can be used to select any of the first 8 slices.
The final six switches allow you to select the desired boot device.
+-----------+----------+-------------+--------------------------+-------------------------------------------------+
| | | | ROM/App/Boot Slice | |
| Auto / | Disk / | Floppy / +--------+--------+--------+-------------------------------------------------+
| Menu | ROM | Hard | 4 | 2 | 1 | Explanation |
+===========+==========+=============+========+========+========+=================================================+
| Menu | -- | -- | -- | -- | -- | Boot to RomWBW Menu |
+-----------+----------+-------------+--------+--------+--------+-------------------------------------------------+
| Auto | Disk | Floppy | # | # | # | Boot Selected Floppy Disk Index |
+-----------+----------+-------------+--------+--------+--------+-------------------------------------------------+
| Auto | Disk | Hard | # | # | # | Boot Selected Hard Disk Index |
+-----------+----------+-------------+--------+--------+--------+-------------------------------------------------+
| Auto | ROM | -- | # | # | # | Boot selected ROM Index |
+-----------+----------+-------------+--------+--------+--------+-------------------------------------------------+
If not available: Boot Loader Command Prompt \
'--' Ignored \
'#' bit flag to select any three bits 4,2,1
ROM or Hard Disk - First 8 Drive Images
+-------+-----------------+-----------+
| | Floppy / Hard \ | |
| 4 2 1 | Drive Index | ROM Index |
+=======+=================+===========+
| 0 0 0 | Zero | Monitor |
+-------+-----------------+-----------+
| 0 0 1 | One | BASIC |
+-------+-----------------+-----------+
| 0 2 0 | Two | Forth |
+-------+-----------------+-----------+
| 0 2 1 | Three | Game |
+-------+-----------------+-----------+
| 4 0 0 | Four | CP/M |
+-------+-----------------+-----------+
| 4 0 1 | Five | Z-System |
+-------+-----------------+-----------+
| 4 2 0 | Six | Net Boot |
+-------+-----------------+-----------+
| 4 2 1 | Seven | User |
+-------+-----------------+-----------+
# Disk Management
@@ -1293,7 +1332,7 @@ disk drive space to store a sequential series of slices that contain the
actual CP/M filesystems referred to by drive letters by the operating
system.
Two physical layout schemes exist:
Two hard disk layout schemes exist:
* Modern (hd1k)
* Legacy (hd512)
@@ -1309,6 +1348,7 @@ recommended for the following reasons:
* Larger number of directory entries per filesystem
* Simplifies creation of coresident FAT filesystem
* Reduces chances of data corruption
* Each slice occupies exactly 8MB (an exact power of 2) in size
Both the legacy and modern disk layouts continue to be fully supported
by RomWBW. There are no plans to deprecate the legacy layout.
@@ -1830,20 +1870,21 @@ command prompt.
Keeping in mind that a RomWBW hard disk (including CF/SD/USB devices)
allows you to have multiple slices (CP/M filesystems), there are a
couple ways to image hard disk media. The easiest approach is to
use the "combo" disk image. This image is already prepared
use the Combo Disk Image. This hard disk image is already prepared
with 6 slices containing 5 ready-to-run OSes and a slice with
the WordStar application files.
Alternatively, you can create your own
hard disk image with the specific slice contents you choose.
Alternatively, you can create your own hard disk image with the specific
slice contents you choose.
### Standard Hard Disk Physical Layout
### Standard Hard Disk Layout
As previously described in [Hard Disk Layouts], the exact placement of
slices and optional FAT partition will vary depending on which disk
layout (hd512 or hd1k) you are using and your partition table entries.
To simplify the use of hard disk images, RomWBW has adopted standard
partition table entries for disk image files provided.
To simplify the use of hard disk images, RomWBW has adopted a standard
partition layout for disk image files provided. This standard
layout is used to produce the Combo Disk Images described below.
These partition sizes and locations were chosen to:
@@ -1851,72 +1892,43 @@ These partition sizes and locations were chosen to:
- Allow for 64 CP/M filesystem slices
- Allow for a 384KB FAT filesystem
**NOTE:** RomWBW is not limited to these partition table entries. You
can change the size and location of the RomWBW and/or FAT partitions to
increase/decrease the number of slices or FAT filesystem size.
The standard partition table table entries are:
+---------------------------------+-------------------------------+-------------------------------+
| | **--- Legacy (hd512) ---** | **--- Modern (hd1k) ---** |
| | **--- Modern (hd1k) ---** | **--- Legacy (hd512) ---** |
| +---------------+---------------+---------------+---------------+
| | Byte(s) | Sector(s) | Byte(s) | Sector(s) |
+=================================+==============:+==============:+==============:+==============:+
| RomWBW (slices) Start | 0 | 0 | 1,048,576 | 2,048 |
| RomWBW Partition Start | 1 MB | 2,048 | -- | -- |
+---------------------------------+---------------+---------------+---------------+---------------+
| RomWBW (slices) Size | 545,259,520 | 1,064,960 | 536,870,912 | 1,048,576 |
| RomWBW Partition Size | 512 MB | 1,048,576 | -- | -- |
+---------------------------------+---------------+---------------+---------------+---------------+
| FAT Filesystem Start | 545,259,520 | 1,064,960 | 537,919,488 | 1,050,624 |
| FAT Filesystem Start | 513 MB | 1,050,624 | 520 MB | 1,064,960 |
+---------------------------------+---------------+---------------+---------------+---------------+
| FAT Filesystem Size | 402,653,184 | 786,432 | 402,653,184 | 786,432 |
| FAT Filesystem Size | 384 MB | 786,432 | 384 MB | 786,432 |
+---------------------------------+---------------+---------------+---------------+---------------+
| \<end\> | 947,912,704 | 1,851,392 | 940,572,672 | 1,837,056 |
| \<end\> | 897 MB | 1,851,392 | 904 MB | 1,837,056 |
+---------------------------------+---------------+---------------+---------------+---------------+
The above partition table entries will result in the following locations and sizes of
filesystems on the RomWBW disk images.
**NOTE:** RomWBW is not limited to these partition table entries. You
can change the size and location of the RomWBW and/or FAT partitions to
increase/decrease the number of slices or FAT filesystem size. Doing
so would require using `FDISK80` to define your own custom disk layout
and initializing your filesystems manually.
The $doc_sys$ has more information on the standard disk layouts as
implemented in the Combo Disk Images. Additionally, there is a document
called "Hard Disk Anatomy.pdf" in the Doc directory of the RomWBW
distribution with detailed information on the standard disk
layouts.
+---------------------------------+-------------------------------+-------------------------------+
| | **--- Legacy (hd512) ---** | **--- Modern (hd1k) ---** |
| +---------------+---------------+---------------+---------------+
| | Byte(s) | Sector(s) | Byte(s) | Sector(s) |
+=================================+==============:+==============:+==============:+==============:+
| Prefix Start | -- | -- | 0 | 0 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Prefix Size | -- | -- | 1,048,576 | 2,048 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice Size | 8,519,680 | 16,640 | 8,388,608 | 16,384 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 0 Start | 0 | 0 | 1,048,576 | 2,048 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 1 Start | 8,519,680 | 16,640 | 9,437,184 | 18,432 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 2 Start | 17,039,360 | 33,280 | 17,825,792 | 34,816 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 3 Start | 25,559,040 | 49,920 | 26,214,400 | 51,200 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 4 Start | 34,078,720 | 66,560 | 34,603,008 | 67,584 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 5 Start | 42,598,400 | 83,200 | 42,991,616 | 83,968 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 6 Start | 51,118,080 | 99,840 | 51,380,224 | 100,352 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 7 Start | 59,637,760 | 116,480 | 59,768,832 | 116,736 |
+---------------------------------+---------------+---------------+---------------+---------------+
| Slice 63 Start | 536,739,840 | 1,048,320 | 529,530,880 | 1,034,240 |
+---------------------------------+---------------+---------------+---------------+---------------+
| FAT Filesystem Start | 545,259,520 | 1,064,960 | 537,919,488 | 1,050,624 |
+---------------------------------+---------------+---------------+---------------+---------------+
| FAT Filesystem Size | 402,653,184 | 786,432 | 402,653,184 | 786,432 |
+---------------------------------+---------------+---------------+---------------+---------------+
| \<end\> | 947,912,704 | 1,851,392 | 940,572,672 | 1,837,056 |
+---------------------------------+---------------+---------------+---------------+---------------+
### Combo Hard Disk Image
#### Combo Hard Disk Image
The combo disk image is essentially just a single image that has several
of the individual filesystem images (slices) already concatenated
together. The combo disk image contains the following 6 slices in the
positions indicated:
The Combo Disk Image is essentially just a single disk image that has
several of the individual filesystem images (slices) already
concatenated together using the standard disk layout described above.
The Combo Disk Image includes the partition table of the standard disk
layout and the following 6 slices in the positions indicated:
| **Slice** | **Description** |
|------------|-----------------------------------------|
@@ -1928,68 +1940,67 @@ positions indicated:
| Slice 5 | WordStar v4 & ZDE Applications |
| Slice 6-63 | _blank unformatted_ |
There are actually 2 primary combo disk images in the
distribution. One for an hd512 disk layout (hd512_combo.img) and one
There are actually 2 Combo Disk Images in the
distribution. One for an hd512 disk layout (hd512_combo.img) and one
for an hd1k disk layout (hd1k_combo.img). Simply use the image file that
corresponds to your desired hard disk layout. Review the information
in [Hard Disk Layouts] if you need more information of the disk layout
options.
> **Note**: Apart from the hd512 and hd1k combo disk images (mentioned above)
> there are actaully a number of other `hd1k_*_combo.img` files. These
> additional combo files are platform (generally romless) specific,
> **Note**: Apart from the hd512 and hd1k Combo Disk Images (mentioned above)
> there are actually a number of other `hd1k_*_combo.img` files. These
> additional combo files are platform (generally romless) specific,
> and should be ignored unless you are on one of these platforms.
> If you are on one of these platforms you must use the correct combo file
The combo disk image actaully only contains the initial partition table,
and the first 6 slices (Slice 0 to 5), this is approximately 49MB in size.
While the partition table reserves space to store 64 CP/M filesystem
slices as well as a single 384MB FAT filesystem, these area remain
empty, and must be manuall initialized manually.
The Combo Disk Image actually only contains the initial partition table,
and the first 6 slices (Slice 0 to 5), this is approximately 49MB in
size. While the partition table reserves space to store 64 CP/M
filesystem slices as well as a single 384MB FAT filesystem, these areas
remain empty, and must be initialized manually using `CLRDIR` for CP/M
filesystems and `FAT FORMAT` for the FAT filesystem.
#### Combo Image Capacity
#### Combo Disk Image Capacity
The combo disk image layout was designed to fit well on a 1GB hard disk.
The 64 CP/M slices (approximately 512MB) and 384MB FAT filesystem all
fit well within a 1GB hard disk. This size choice was a bit arbitrary,
but based on the idea that 1GB CF/SD/USB Media is easy and cheap to
acquire.
The standard hard disk layout used by the Combo Disk Image was designed
to fit well on a 1GB hard disk. The 64 CP/M slices (approximately 512MB)
and 384MB FAT filesystem all fit well within a 1GB hard disk. This
size choice was a bit arbitrary, but based on the idea that 1GB
CF/SD/USB Media is easy and cheap to acquire.
It is fine if your hard disk is smaller than 1GB. It just
means that it will not be possible to use the pre-allocated FAT
filesystem partition and any CP/M filesystem slices that don't fit.
The true number of CP/M filesystem slices that
will fit on your specific physical hard disk can be calculated as
described in [Hard Disk Capacity].
It is fine if your hard disk is smaller than 1GB. It just means that it
will not be possible to use the pre-allocated FAT filesystem partition
and any CP/M filesystem slices that don't fit. The true number of CP/M
filesystem slices that will fit on your specific physical hard disk can
be calculated as described in [Hard Disk Capacity].
If you attempt to access a slice past the end of the
physical hard disk you will get "no disk" errors.
You should calculate the maximum number of slices your hard disk
will support and do not exceed this number.
If you attempt to access a slice past the end of the physical hard disk
you will get "no disk" errors. You should calculate the maximum number
of slices your hard disk will support and do not exceed this number.
#### Combo Image Advice
#### Combo Disk Image Advice
A great way to maintain your own data on a hard disk is to put this
data in slices beyond the first 6. By doing so, you can always
"re-image" your drive media with the combo image without overlaying the data
A great way to maintain your own data on a hard disk is to put your data
in slices beyond the first 6. By doing so, you can always "re-image"
your drive media with the Combo Disk Image without overlaying the data
stored in the slices beyond the first 6. Just be very careful to use
the same combo image layout (hd512 or hd1k) as you used originally.
### Custom Hard Disk Image
For hard disks, each .img file represents a single slice (CP/M
filesystem). Since a hard disk can contain many slices, you can just
For hard disks, each .img file represents a single slice (CP/M
filesystem). Since a hard disk can contain many slices, you can just
concatenate the slices (.img files) together to create your desired hard
disk image.
disk image.
If you look in the Binary directory of the distribution, you will see
that there are more disk (slice) images than the 6 that are included
in the "combo" disk images. These images are identified by looking
for the files that start with hd1k_ or hd512_.
that there are more disk (slice) images than the 6 that are included in
the Combo Disk Images. These supplemental disk images are identified by
looking for the files that start with hd1k_ or hd512_.
#### Adding Slices to Combo Image
You can add slices to the combo disk images simply by tacking
You can add slices to the Combo Disk Images simply by tacking
slices onto the end. For example, if you want to add a slice
containing the MSX ROMs to the end of the combo image, you could
use one of the following command lines depending on your operating
@@ -2052,7 +2063,7 @@ please refer to the ReadMe.txt file in the Source/Images directory.
### Writing Hard Disk Images
Once you have chosen a combo hard disk image file or prepared your own
Once you have chosen a Combo Hard Disk Image file or prepared your own
custom hard disk image file, it will need to be written to the media
using your modern computer. When using this method,
the disk will be partitioned and setup with 1 or more slices containing
@@ -2117,13 +2128,13 @@ survive re-imaging, you **must** follow these rules:
This section covers techniques to copy partial images onto pre-existing media,
in effect performing a selective slice copy. These techniques currently **only** apply to
hd1k formatted media, which has a convenient 1MB size metric.
hd1k formatted media, which has a partition table entry, and a convenient 1MB size metric.
However adapting to hd512 is possible, but left to the user.
On Linux/MacOS the `dd` command can be used to write data in a controlled manner.
Although Windows does not have a native `dd` command, there are multiple
options for installing it including [MSYS2](https://www.msys2.org/),
[CygWin](https://www.cygwin.com/),
You will need to have access to a Linux/MacOS machine, or have the
Linux tools for Windows installed, including the `dd` command line tool.
For Windows there are multiple options for installing `dd` including
[MSYS2](https://www.msys2.org/), [CygWin](https://www.cygwin.com/),
and [dd for Windows](http://www.chrysocome.net/dd).
**WARNING**: The `dd` command is a low-level utility that writes
@@ -2146,21 +2157,80 @@ From the documentation of `dd` the following options are important.
of the default 512
```
In the following examples we use the above options, noting the `of=` option
is specific to your computer but defines the block device that the target
media is mounted to in the operating system,
and `bs=1MB` defines the block size used in other parameters which is convienient
since it aligns perfectly with slices which are exactly 8MB
and the initial partition table is exactly 1MB.
The best approach is to copy data to the RomWBW partition. To do this, you
must first determine the name that your operating system is using for the
RomWBW disk and partition. An easy way to determine this may be the linux `mount`
command, which lists the currently mounted partitions. From here you can more easily
determine the naming scheme used by your operating system.
Typically disk devices are named something like `/dev/disk9` or `/dev/sdg`, noting above
the `g` is a alphabetic and it could be any letter. This naming is arbitrary
and depend on the operating system, and the specific hardware connecting the device
Partitions are typically named by simply adding a number after the name of the hard disk
device. For example, the first partition could be `/dev/disk9s1`, `/dev/sdg1`, or `/dev/sdgp1`.
In the following examples we use the above `dd` options, noting the `of=` option
is the RomWBW target partition.
** NOTE ** A second approach (Examples 3 and 4) is to address the hard
disk as a raw disk device and we take explicit steps to calculate the
start of the RomWBW partition. While this works, it is better to use the
partition relative approach.
The commands in the examples below are run from the `Binary` folder of RomWBW distribution.
#### Example 1 : Copy the Combo Image without replacing partition table
#### Example 1 : Copy the Games image to an empty slice of our media
In this example we will copy the (hd1k) combo image over our media
without replacing the partition table. In this example we assume the media
has already been formated with the combo image, and we have modified
the partition table, which we do not want to overrite.
In this example we will copy the (hd1k) games image to Slice 6 (free)
of our existing media. In this example we assume the media
has already been formatted with the combo image, which already
contains 6 slices (numbered from 0 to 5).
We are just copying the needed slice to the existing media
as a new slice (number 6) after the existing slices making it the 7th slice.
```
Binary % sudo dd if=hd1k_games.img of=/dev/sdg1 seek=6 bs=8M
Password:
1+0 records in
1+0 records out
8388608 bytes transferred in 1.917296 secs (4375228 bytes/sec)
```
Since bs=8MB the `seek=6` skips the first 6 (8MB slices) slices (in the target image)
and writes the games image to the 7th slice.
#### Example 2 : Copy the entire Combo Image without replacing partition table
In all of the following examples we use `bs=1MB` to defines the block size used
in other parameters. This is convenient since the combo image reserves 1MB for
the partition table at the start of the disk.
In this example we will copy the (hd1k) combo image (which includes a partition table)
over our media without replacing the partition table. In this example we assume the media
has already been formatted with the combo image, and we have modified the partition table,
which we do not want to overwrite.
```
Binary % sudo dd if=hd1k_combo.img of=/dev/sdg1 skip=1 bs=1M
Password:
48+0 records in
48+0 records out
50331648 bytes transferred in 11.503776 secs (4745528 bytes/sec)
```
The `skip=1` skips the first 1MB (partition table) in the input file,
effectively stripping out the combo images partition table, before overwriting
the slices in the target partition.
#### Example 3 : Copy the Combo Image without replacing partition table
This example is identical to Example 2 except it writes to the target
disk device itself (`of=/dev/disk9`), not the target partition.
```
Binary % sudo dd if=hd1k_combo.img of=/dev/disk9 skip=1 seek=1 bs=1M
@@ -2174,14 +2244,14 @@ Password:
The `skip=1` skips the first 1MB in the input file, and likewise
`seek=1` skips the first 1MB of the target media file we are writing to,
tus in effect we are skipping the first 1MB, which contains the
thus in effect we are skipping the first 1MB, which contains the
partition table itself.
#### Example 2 : Copy the Games image to an empty slice of our media
#### Example 4 : Copy the Games image to an empty slice of our media
In this example we will copy the (hd1k) games image to Slice 6 (free)
of our existing media. In this example we assume the media
has already been formated with the combo image, which already
has already been formatted with the combo image, which already
contains 6 slices (numbered from 0 to 5)
We are just coping the needed slice to this existing media
as a new slice (number 6) after the existing slices making it the 7th slice.
@@ -2203,27 +2273,6 @@ and 1 is the size of the partition table im megabytes.
Thus we are skipping 6 slices (in the combo image)
and writing to the 7th slice.
#### Example 3 : Copy image using partition
In the previous examples, the hard disk is addressed as a raw disk
device and we took steps to calculate the assumed start of the RomWBW
partition. However, as long as the hd1k format is in use, it is
also possible to just point `dd` directly to the partition itself.
To do this, you must first determine the name that your operating
system is using for the desired partition. Frequently, partitions
are named by simply adding a number after the name of the hard disk
device. For example, if the hard disk is /dev/sdg, the first
partition is frequently /dev/sdg1 or /dev/sdgp1.
Taking advantage of this, it is safer and easier to calculate the
offset of a slice within the partition. It is simply the slice
number \* 8MB. Example 2 above, could now be performed as:
```
Binary % sudo dd if=hd1k_games.img of=/dev/sdg1 seek=48 bs=1M
```
# Operating Systems
One of the primary goals of RomWBW is to expose a set of generic
@@ -2687,7 +2736,14 @@ a variety of common ZCPR3 utilities.
#### Documentation
ZPM3 has no real documentation. You are expected to understand both
CP/M 3 and ZCPR 3.
CP/M 3 and ZCPR 3. The best source of information is:
* [CPM3 Users Guide]($doc_root$/CPM/CPM3 Users Guide.pdf)
* [CPM3 Command Summary]($doc_root$/CPM/CPM3 Command Summary.pdf)
* [CPM3 Programmers Guide]($doc_root$/CPM/CPM3 Programmers Guide.pdf)
* [CPM3 System Guide]($doc_root$/CPM/CPM3 System Guide.pdf)
* [Z-System Users Guide]($doc_root$/CPM/Z-System Users Guide.pdf)
* [ZCPR3.3 User Guide]($doc_root$/CPM/ZCPR3.3 User Guide.pdf)
#### Boot Disk
@@ -2747,6 +2803,39 @@ The CP/M 3 `DEVICE` command is used to manipulate the device mappings.
I believe it was done this way to make it easier for users to
transition from CP/M 3 to ZPM3.
- The command line editing key bindings were slightly modified by
Jon Saxton when he applied a few ZPM3 fixes. This is explained
in the file zpm3fix.txt in the distribution folder Source/ZPM3.
The current key bindings are from the "New" column below.
| **Old** | **New** | **Function** |
|---------|---------|-------------------------------------------|
| ^A | ^A | one word left |
| ^B | ^B | to beginning/end of line |
| ^C | ^C | reboot if at start of line |
| ^D | ^D | right one char |
| ^E | ^E | get previous line |
| ^F | ^F | right one word |
| ^G | ^G | delete char at cursor |
| ^H | ^H | destructive backspace |
| ^I | ^I | (TAB) ignored here |
| ^J | ^J | (LF) exit editor |
| ^K | ^K | delete all to the right |
| ^L | ^L | ignored |
| ^M | ^M | (CR) exit editor |
| ^N | ^N | ignored |
| ^O | ^O | ignored |
| ^P | ^P | toggle printer echoing |
| ^Q | ^Q | toggle autoprompt (if enabled) |
| ^R | ^R | ignored |
| ^S | ^S | left one char |
| ^T | ^T | delete word at cursor |
| ^U | ^U | add line to history |
| ^V | ^V | clear line, delete from history |
| ^W | ^X | get next line from history |
| ^X | ^W | delete all to the left |
| ^Y | ^Y | clear line |
## QP/M
QP/M is another OS providing compatibility with and enhancements
@@ -2819,7 +2908,7 @@ is analogous to the CP/M 2.2 `STAT` command. Do **not** use the CP/M
Source/Images/d_qpm/u0 directory.
- The QPM disk image is not included as one of the slices on the
RomWBW combo disk image. If you want to include QPM, you can do
RomWBW Combo Disk Image. If you want to include QPM, you can do
so by following the directions in Source/Images/Readme.txt.
## UCSD p-System

Binary file not shown.

Before

Width:  |  Height:  |  Size: 8.6 KiB

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.2 KiB

After

Width:  |  Height:  |  Size: 9.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.6 KiB

After

Width:  |  Height:  |  Size: 5.6 KiB

BIN
Source/Fonts/fontcga.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.1 KiB

BIN
Source/Fonts/fontvgarc.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -71,7 +71,7 @@ Bank ID Usage
0x82 User TPA
0x83 Common
ROMless Standard Bank Layout (512K)
ROMless Standard Bank Layout (512K): ZRC, ZRC512, EZ512, Z1RCC, ZZRCC, FZ80
Bank ID Usage
------- ------

View File

@@ -229,8 +229,8 @@ call Build MK4 std || exit /b
call Build RCZ80 std || exit /b
call Build RCEZ80 std || exit /b
call Build RCZ80 kio_std || exit /b
call Build RCZ80 easy_std || exit /b
call Build RCZ80 tiny_std || exit /b
call Build EZZ80 easy_std || exit /b
call Build EZZ80 tiny_std || exit /b
call Build RCZ80 skz_std || exit /b
call Build RCZ80 zrc_std || exit /b
call Build RCZ80 zrc_ram_std || exit /b

View File

@@ -27,7 +27,7 @@ $ErrorAction = 'Stop'
# UNA BIOS is simply imbedded, it is not built here.
#
$PlatformListZ80 = "SBC", "MBC", "ZETA", "ZETA2", "RCZ80", "Z80RETRO", "DUO", "UNA", "HEATH", "MON", "NABU", "FZ80", "RCEZ80"
$PlatformListZ80 = "SBC", "MBC", "ZETA", "ZETA2", "RCZ80", "EZZ80", "Z80RETRO", "DUO", "UNA", "HEATH", "MON", "NABU", "FZ80", "RCEZ80"
$PlatformListZ180 = "N8", "MK4", "RCZ180", "SCZ180", "DYNO", "RPH", "S100", "EPITX", "GMZ180"
$PlatformListZ280 = "RCZ280"

View File

@@ -21,8 +21,8 @@ if [ "${ROM_PLATFORM}" == "dist" ] ; then
ROM_PLATFORM="RCEZ80"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="kio_std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="easy_std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="tiny_std"; bash Build.sh
ROM_PLATFORM="EZZ80"; ROM_CONFIG="easy_std"; bash Build.sh
ROM_PLATFORM="EZZ80"; ROM_CONFIG="tiny_std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="skz_std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="zrc_std"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="zrc_ram_std"; bash Build.sh

View File

@@ -46,9 +46,7 @@
#DEFINE AUTO_CMD "" ; AUTO CMD WHEN BOOT_TIMEOUT IS ENABLED
#DEFINE DEFSERCFG SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL CONFIGURATION
;
#INCLUDE "cfg_RCZ80.asm"
;
PLATFORM .SET PLT_EZZ80 ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCEZ80|RCZ180|EZZ80|SCZ180|GMZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
#INCLUDE "cfg_EZZ80.asm"
;
BOOT_TIMEOUT .SET -1 ; AUTO BOOT TIMEOUT IN SECONDS, -1 TO DISABLE, 0 FOR IMMEDIATE
BOOT_PRETTY .SET FALSE ; BOOT WITH PRETTY PLATFORM NAME

View File

@@ -46,9 +46,7 @@
#DEFINE AUTO_CMD "" ; AUTO CMD WHEN BOOT_TIMEOUT IS ENABLED
#DEFINE DEFSERCFG SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL CONFIGURATION
;
#INCLUDE "cfg_RCZ80.asm"
;
PLATFORM .SET PLT_EZZ80 ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCEZ80|RCZ180|EZZ80|SCZ180|GMZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
#INCLUDE "cfg_EZZ80.asm"
;
BOOT_TIMEOUT .SET -1 ; AUTO BOOT TIMEOUT IN SECONDS, -1 TO DISABLE, 0 FOR IMMEDIATE
BOOT_PRETTY .SET FALSE ; BOOT WITH PRETTY PLATFORM NAME

View File

@@ -1,7 +1,7 @@
DIST_OBJECTS := \
DYNO_std MK4_std N8_std RCZ180_ext RCZ180_nat RCZ180_z1rcc \
RCZ280_ext RCZ280_nat RCZ280_zz80mb RCZ280_zzrcc RCZ280_zzrcc_ram \
RCZ80_std RCZ80_kio RCZ80_easy RCZ80_tiny RCZ80_skz RCZ80_zrc \
RCZ80_std RCZ80_kio EZZ80_easy EZZ80_tiny RCZ80_skz RCZ80_zrc \
RCZ80_zrc_ram RCZ80_zrc512 RPH_std SBC_std SBC_simh MBC_std \
DUO_std SCZ180_sc126 SCZ180_sc130 SCZ180_sc131 SCZ180_sc140 \
SCZ180_sc503 SCZ180_sc700 S100_std UNA_std Z80RETRO_std \

399
Source/HBIOS/cfg_EZZ80.asm Normal file
View File

@@ -0,0 +1,399 @@
;
;==================================================================================================
; ROMWBW PLATFORM CONFIGURATION DEFAULTS FOR PLATFORM: EZZ80
;==================================================================================================
;
; THIS FILE DEFINES THE DEFAULT CONFIGURATION SETTINGS FOR THE PLATFORM
; INDICATED ABOVE. THIS FILE SHOULD *NOT* NORMALLY BE CHANGED. INSTEAD,
; YOU SHOULD OVERRIDE SETTINGS YOU WANT USING A CONFIGURATION FILE IN
; THE CONFIG DIRECTORY UNDER THIS DIRECTORY.
;
; THIS FILE SHOULD *NOT* NORMALLY BE CHANGED. IT IS MAINTAINED BY THE
; AUTHORS OF ROMWBW. TO OVERRIDE SETTINGS YOU SHOULD USE A
; CONFIGURATION FILE IN THE CONFIG DIRECTORY UNDER THIS DIRECTORY.
;
; ROMWBW USES CASCADING CONFIGURATION FILES AS INDICATED BELOW:
;
; cfg_MASTER.asm - MASTER: CONFIGURATION FILE DEFINES ALL POSSIBLE ROMWBW SETTINGS
; |
; +-> cfg_<platform>.asm - PLATFORM: DEFAULT SETTINGS FOR SPECIFIC PLATFORM
; |
; +-> Config/<plt>_std.asm - BUILD: SETTINGS FOR EACH OFFICIAL DIST BUILD
; |
; +-> Config/<plt>_<cust>.asm - USER: CUSTOM USER BUILD SETTINGS
;
; THE TOP (MASTER CONFIGURATION) FILE DEFINES ALL POSSIBLE ROMWBW
; CONFIGURATION SETTINGS. EACH FILE BELOW THE MASTER CONFIGURATION FILE
; INHERITS THE CUMULATIVE SETTINGS OF THE FILES ABOVE IT AND MAY
; OVERRIDE THESE SETTINGS AS DESIRED.
;
; OTHER THAN THE TOP MASTER FILE, EACH FILE MUST "#INCLUDE" ITS PARENT
; FILE (SEE #INCLUDE STATEMENT BELOW). THE TOP TWO FILES SHOULD NOT BE
; MODIFIED. TO CUSTOMIZE YOUR BUILD SETTINGS YOU SHOULD MODIFY THE
; DEFAULT BUILD SETTINGS (Config/<platform>_std.asm) OR PREFERABLY
; CREATE AN OPTIONAL CUSTOM USER SETTINGS FILE THAT INCLUDES THE DEFAULT
; BUILD SETTINGS FILE (SEE EXAMPLE Config/SBC_user.asm).
;
; BY CREATING A CUSTOM USER SETTINGS FILE, YOU ARE LESS LIKELY TO BE
; IMPACTED BY FUTURE CHANGES BECAUSE YOU WILL BE INHERITING MOST
; OF YOUR SETTINGS WHICH WILL BE UPDATED BY AUTHORS AS ROMWBW EVOLVES.
;
; *** WARNING: ASIDE FROM THE MASTER CONFIGURATION FILE, YOU MUST USE
; ".SET" TO OVERRIDE SETTINGS. THE ASSEMBLER WILL ERROR IF YOU ATTEMPT
; TO USE ".EQU" BECAUSE IT WON'T LET YOU REDEFINE A SETTING WITH ".EQU".
;
#DEFINE PLATFORM_NAME "EZZ80", " [", CONFIG, "]" ; TEXT LABEL OF THIS CONFIG IN STARTUP MESSAGES
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD FOR EMPTY CMD LINE
#DEFINE AUTO_CMD "" ; AUTO CMD WHEN BOOT_TIMEOUT IS ENABLED
#DEFINE DEFSERCFG SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL CONFIGURATION
;
#INCLUDE "cfg_MASTER.asm"
;
PLATFORM .SET PLT_EZZ80 ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCEZ80|RCZ180|EZZ80|SCZ180|GMZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
CPUFAM .SET CPU_Z80 ; CPU FAMILY: CPU_[Z80|Z180|Z280|EZ80]
BIOS .SET BIOS_WBW ; HARDWARE BIOS: BIOS_[WBW|UNA]
BATCOND .SET FALSE ; ENABLE LOW BATTERY WARNING MESSAGE
HBIOS_MUTEX .SET FALSE ; ENABLE REENTRANT CALLS TO HBIOS (ADDS OVERHEAD)
USELZSA2 .SET TRUE ; ENABLE FONT COMPRESSION
TICKFREQ .SET 50 ; DESIRED PERIODIC TIMER INTERRUPT FREQUENCY (HZ)
;
BOOT_TIMEOUT .SET -1 ; AUTO BOOT TIMEOUT IN SECONDS, -1 TO DISABLE, 0 FOR IMMEDIATE
BOOT_DELAY .SET 0 ; FIXED BOOT DELAY IN SECONDS PRIOR TO CONSOLE OUTPUT
BOOT_PRETTY .SET FALSE ; BOOT WITH PRETTY PLATFORM NAME
BT_REC_TYPE .SET BT_REC_NONE ; BOOT RECOVERY METHOD TO USE: BT_REC_[NONE|FORCE|SBCB0|SBC1B|SBCRI|DUORI]
AUTOCON .SET TRUE ; ENABLE CONSOLE TAKEOVER AT LOADER PROMPT
STRICTPART .SET TRUE ; ENFORCE STRICT PARTITION TABLE VALIDATION
;
CPUSPDCAP .SET SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .SET SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .SET 7372800 ; CPU OSC FREQ IN MHZ
INTMODE .SET 1 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
;
RAMSIZE .SET 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .SET 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
APP_BNKS .SET $FF ; BANKS TO RESERVE FOR APP USE ($FF FOR AUTO SIZING)
MEMMGR .SET MM_Z2 ; MEMORY MANAGER: MM_[SBC|Z2|N8|Z180|Z280|MBC|RPH|MON|EZ512]
MPGSEL_0 .SET $78 ; Z2 MEM MGR BANK 0 PAGE SELECT REG (WRITE ONLY)
MPGSEL_1 .SET $79 ; Z2 MEM MGR BANK 1 PAGE SELECT REG (WRITE ONLY)
MPGSEL_2 .SET $7A ; Z2 MEM MGR BANK 2 PAGE SELECT REG (WRITE ONLY)
MPGSEL_3 .SET $7B ; Z2 MEM MGR BANK 3 PAGE SELECT REG (WRITE ONLY)
MPGENA .SET $7C ; Z2 MEM MGR PAGING ENABLE REGISTER (BIT 0, WRITE ONLY)
;
RTCIO .SET $C0 ; RTC LATCH REGISTER ADR
;
KIOENABLE .SET FALSE ; ENABLE ZILOG KIO SUPPORT
KIOBASE .SET $80 ; KIO BASE I/O ADDRESS
;
CTCENABLE .SET FALSE ; ENABLE ZILOG CTC SUPPORT
CTCDEBUG .SET FALSE ; ENABLE CTC DRIVER DEBUG OUTPUT
CTCBASE .SET $88 ; CTC BASE I/O ADDRESS
CTCTIMER .SET FALSE ; ENABLE CTC PERIODIC TIMER
CTCMODE .SET CTCMODE_TIM16 ; CTC MODE: CTCMODE_[NONE|CTR|TIM16|TIM256]
CTCPRE .SET 256 ; PRESCALE CONSTANT (1-256)
CTCPRECH .SET 2 ; PRESCALE CHANNEL (0-3)
CTCTIMCH .SET 3 ; TIMER CHANNEL (0-3)
CTCOSC .SET CPUOSC ; CTC CLOCK FREQUENCY
;
PCFENABLE .SET FALSE ; ENABLE PCF8584 I2C CONTROLLER
PCFBASE .SET $F0 ; PCF8584 BASE I/O ADDRESS
;
EIPCENABLE .SET FALSE ; EIPC: ENABLE Z80 EIPC (Z84C15) INITIALIZATION
;
SKZENABLE .SET FALSE ; ENABLE SERGEY'S Z80-512K FEATURES
SKZDIV .SET DIV_1 ; UART CLK (CLK2) DIVIDER FOR Z80-512K
;
WDOGMODE .SET WDOG_NONE ; WATCHDOG MODE: WDOG_[NONE|EZZ80|SKZ]
WDOGIO .SET $6F ; WATCHDOG REGISTER ADR
;
FPLED_ENABLE .SET FALSE ; FP: ENABLES FRONT PANEL LEDS
FPLED_IO .SET $00 ; FP: PORT ADDRESS FOR FP LEDS
FPLED_INV .SET FALSE ; FP: LED BITS ARE INVERTED
FPLED_DSKACT .SET TRUE ; FP: ENABLES DISK I/O ACTIVITY ON FP LEDS
FPSW_ENABLE .SET FALSE ; FP: ENABLES FRONT PANEL SWITCHES
FPSW_IO .SET $00 ; FP: PORT ADDRESS FOR FP SWITCHES
FPSW_INV .SET FALSE ; FP: SWITCH BITS ARE INVERTED
;
DIAGLVL .SET DL_CRITICAL ; ERROR LEVEL REPORTING
;
LEDENABLE .SET FALSE ; ENABLES STATUS LED (SINGLE LED)
LEDMODE .SET LEDMODE_STD ; LEDMODE_[STD|SC|RTC|NABU]
LEDPORT .SET $0E ; STATUS LED PORT ADDRESS
LEDDISKIO .SET TRUE ; ENABLES DISK I/O ACTIVITY ON STATUS LED
;
DSKYENABLE .SET FALSE ; ENABLES DSKY FUNCTIONALITY
DSKYDSKACT .SET TRUE ; ENABLES DISK ACTIVITY ON DSKY DISPLAY
ICMENABLE .SET FALSE ; ENABLES ORIGINAL DSKY ICM DRIVER (7218)
ICMPPIBASE .SET $60 ; BASE I/O ADDRESS OF ICM PPI
PKDENABLE .SET FALSE ; ENABLES DSKY NG PKD DRIVER (8259)
PKDPPIBASE .SET $60 ; BASE I/O ADDRESS OF PKD PPI
PKDOSC .SET 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .SET FALSE ; ENABLES HEATH H8 FRONT PANEL
LCDENABLE .SET FALSE ; ENABLE LCD DISPLAY
LCDBASE .SET $DA ; BASE I/O ADDRESS OF LCD CONTROLLER
GM7303ENABLE .SET FALSE ; ENABLES THE GM7303 BOARD WITH 16X2 LCD
;
BOOTCON .SET 0 ; BOOT CONSOLE DEVICE
SECCON .SET $FF ; SECONDARY CONSOLE DEVICE
CRTACT .SET FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .SET EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .SET $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
ANSITRACE .SET 1 ; ANSI DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPKTRACE .SET 1 ; PPK DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
KBDTRACE .SET 1 ; KBD DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPKKBLOUT .SET KBD_US ; PPK KEYBOARD LANGUAGE: KBD_[US|DE]
KBDKBLOUT .SET KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
MKYKBLOUT .SET KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
KBDINTS .SET FALSE ; ENABLE KBD (PS2) KEYBOARD INTERRUPTS
;
DSRTCENABLE .SET TRUE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
DSRTCMODE .SET DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTCMODE_[STD|MFPIC|K80W]
DSRTCCHG .SET FALSE ; DSRTC: FORCE BATTERY CHARGE ON (USE WITH CAUTION!!!)
;
DS1501RTCENABLE .SET FALSE ; DS1501RTC: ENABLE DS-1501 CLOCK DRIVER (DS1501RTC.ASM)
DS1501RTC_BASE .SET $50 ; DS1501RTC: I/O BASE ADDRESS
;
BQRTCENABLE .SET FALSE ; BQRTC: ENABLE BQ4845 CLOCK DRIVER (BQRTC.ASM)
BQRTC_BASE .SET $50 ; BQRTC: I/O BASE ADDRESS
;
INTRTCENABLE .SET FALSE ; ENABLE PERIODIC INTERRUPT CLOCK DRIVER (INTRTC.ASM)
;
RP5RTCENABLE .SET FALSE ; RP5C01 RTC BASED CLOCK (RP5RTC.ASM)
;
HTIMENABLE .SET FALSE ; ENABLE SIMH TIMER SUPPORT
SIMRTCENABLE .SET FALSE ; ENABLE SIMH CLOCK DRIVER (SIMRTC.ASM)
;
DS7RTCENABLE .SET FALSE ; DS7RTC: ENABLE DS-1307 I2C CLOCK DRIVER (DS7RTC.ASM)
DS7RTCMODE .SET DS7RTCMODE_PCF ; DS7RTC: OPERATING MODE: DS7RTCMODE_[PCF]
;
DS5RTCENABLE .SET FALSE ; DS5RTC: ENABLE DS-1305 SPI CLOCK DRIVER (DS5RTC.ASM)
;
SSERENABLE .SET FALSE ; SSER: ENABLE SIMPLE SERIAL DRIVER (SSER.ASM)
SSERCFG .SET SER_9600_8N1 ; SSER: SERIAL LINE CONFIG
SSERSTATUS .SET $FF ; SSER: STATUS PORT
SSERDATA .SET $FF ; SSER: DATA PORT
SSERIRDY .SET %00000001 ; SSER: INPUT READY BIT MASK
SSERIINV .SET FALSE ; SSER: INPUT READY BIT INVERTED
SSERORDY .SET %00000010 ; SSER: OUTPUT READY BIT MASK
SSEROINV .SET FALSE ; SSER: OUTPUT READY BIT INVERTED
;
DUARTENABLE .SET FALSE ; DUART: ENABLE 2681/2692 SERIAL DRIVER (DUART.ASM)
DUARTCNT .SET 1 ; DUART: NUMBER OF CHIPS TO DETECT (1-2)
DUART0BASE .SET $A0 ; DUART 0: BASE ADDRESS OF CHIP
DUART0ACFG .SET DEFSERCFG ; DUART 0A: SERIAL LINE CONFIG
DUART0BCFG .SET DEFSERCFG ; DUART 0B: SERIAL LINE CONFIG
DUART1BASE .SET $40 ; DUART 1: BASE ADDRESS OF CHIP
DUART1ACFG .SET DEFSERCFG ; DUART 1A: SERIAL LINE CONFIG
DUART1BCFG .SET DEFSERCFG ; DUART 1B: SERIAL LINE CONFIG
;
UARTENABLE .SET FALSE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
UARTCNT .SET 4 ; UART: NUMBER OF CHIPS TO DETECT (1-8)
UARTOSC .SET 1843200 ; UART: OSC FREQUENCY IN MHZ
UARTINTS .SET FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
UART4UART .SET FALSE ; UART: SUPPORT 4UART ECB BOARD
UART4UARTBASE .SET $C0 ; UART: BASE IO ADDRESS OF 4UART ECB BOARD
UART0BASE .SET $80 ; UART 0: REGISTERS BASE ADR
UART0CFG .SET DEFSERCFG ; UART 0: SERIAL LINE CONFIG
UART1BASE .SET $88 ; UART 1: REGISTERS BASE ADR
UART1CFG .SET DEFSERCFG ; UART 1: SERIAL LINE CONFIG
UART2BASE .SET $A0 ; UART 2: REGISTERS BASE ADR
UART2CFG .SET DEFSERCFG ; UART 2: SERIAL LINE CONFIG
UART3BASE .SET $A8 ; UART 3: REGISTERS BASE ADR
UART3CFG .SET DEFSERCFG ; UART 3: SERIAL LINE CONFIG
UART4BASE .SET $FF ; UART 4: REGISTERS BASE ADR
UART4CFG .SET DEFSERCFG ; UART 4: SERIAL LINE CONFIG
UART5BASE .SET $FF ; UART 5: REGISTERS BASE ADR
UART5CFG .SET DEFSERCFG ; UART 5: SERIAL LINE CONFIG
UART6BASE .SET $FF ; UART 6: REGISTERS BASE ADR
UART6CFG .SET DEFSERCFG ; UART 6: SERIAL LINE CONFIG
UART7BASE .SET $FF ; UART 7: REGISTERS BASE ADR
UART7CFG .SET DEFSERCFG ; UART 7: SERIAL LINE CONFIG
;
ASCIENABLE .SET FALSE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
;
Z2UENABLE .SET FALSE ; Z2U: ENABLE Z280 UART SERIAL DRIVER (Z2U.ASM)
;
ACIAENABLE .SET FALSE ; ACIA: ENABLE MOTOROLA 6850 ACIA DRIVER (ACIA.ASM)
ACIADEBUG .SET FALSE ; ACIA: ENABLE DEBUG OUTPUT
ACIACNT .SET 1 ; ACIA: NUMBER OF CHIPS TO DETECT (1-2)
ACIA0BASE .SET $80 ; ACIA 0: REGISTERS BASE ADR
ACIA0CLK .SET CPUOSC ; ACIA 0: OSC FREQ IN HZ
ACIA0DIV .SET 1 ; ACIA 0: SERIAL CLOCK DIVIDER
ACIA0CFG .SET DEFSERCFG ; ACIA 0: SERIAL LINE CONFIG (SEE STD.ASM)
ACIA1BASE .SET $40 ; ACIA 1: REGISTERS BASE ADR
ACIA1CLK .SET CPUOSC ; ACIA 1: OSC FREQ IN HZ
ACIA1DIV .SET 1 ; ACIA 1: SERIAL CLOCK DIVIDER
ACIA1CFG .SET DEFSERCFG ; ACIA 1: SERIAL LINE CONFIG (SEE STD.ASM)
;
SIOENABLE .SET FALSE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
SIODEBUG .SET FALSE ; SIO: ENABLE DEBUG OUTPUT
SIOBOOT .SET 0 ; SIO: REBOOT ON RCV CHAR (0=DISABLED)
SIOCNT .SET 2 ; SIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
SIOINTS .SET TRUE ; SIO: INCLUDE SIO INTERRUPT SUPPORT UNDER IM1/2/3
SIO0MODE .SET SIOMODE_RC ; SIO 0: CHIP TYPE: SIOMODE_[STD|RC|SMB|ZP|Z80R]
SIO0BASE .SET $80 ; SIO 0: REGISTERS BASE ADR
SIO0ACLK .SET CPUOSC ; SIO 0A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0ACFG .SET DEFSERCFG ; SIO 0A: SERIAL LINE CONFIG
SIO0ACTCC .SET -1 ; SIO 0A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO0BCLK .SET CPUOSC ; SIO 0B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0BCFG .SET DEFSERCFG ; SIO 0B: SERIAL LINE CONFIG
SIO0BCTCC .SET -1 ; SIO 0B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO1MODE .SET SIOMODE_RC ; SIO 1: CHIP TYPE: SIOMODE_[STD|RC|SMB|ZP|Z80R]
SIO1BASE .SET $84 ; SIO 1: REGISTERS BASE ADR
SIO1ACLK .SET CPUOSC ; SIO 1A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO1ACFG .SET DEFSERCFG ; SIO 1A: SERIAL LINE CONFIG
SIO1ACTCC .SET -1 ; SIO 1A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO1BCLK .SET CPUOSC ; SIO 1B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO1BCFG .SET DEFSERCFG ; SIO 1B: SERIAL LINE CONFIG
SIO1BCTCC .SET -1 ; SIO 1B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
;
XIOCFG .SET DEFSERCFG ; XIO: SERIAL LINE CONFIG
;
VDUENABLE .SET FALSE ; VDU: ENABLE VDU VIDEO/KBD DRIVER (VDU.ASM)
CVDUENABLE .SET FALSE ; CVDU: ENABLE CVDU VIDEO/KBD DRIVER (CVDU.ASM)
GDCENABLE .SET FALSE ; GDC: ENABLE 7220 GDC VIDEO/KBD DRIVER (GDC.ASM)
TMSENABLE .SET FALSE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
TMSMODE .SET TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MSX|MSXKBD|MSXMKY|MBC|COLECO|DUO|NABU]
TMS80COLS .SET FALSE ; TMS: ENABLE 80 COLUMN SCREEN, REQUIRES V9958
TMSTIMENABLE .SET FALSE ; TMS: ENABLE TIMER INTERRUPTS (REQUIRES IM1)
VGAENABLE .SET FALSE ; VGA: ENABLE VGA VIDEO/KBD DRIVER (VGA.ASM)
VRCENABLE .SET FALSE ; VRC: ENABLE VGARC VIDEO/KBD DRIVER (VRC.ASM)
SCONENABLE .SET FALSE ; SCON: ENABLE S100 CONSOLE DRIVER (SCON.ASM)
EFENABLE .SET FALSE ; EF: ENABLE EF9345 VIDEO DRIVER (EF.ASM)
FVENABLE .SET FALSE ; FV: ENABLE FPGA VGA VIDEO DRIVER (FV.ASM)
;
MDENABLE .SET TRUE ; MD: ENABLE MEMORY (ROM/RAM) DISK DRIVER (MD.ASM)
MDROM .SET TRUE ; MD: ENABLE ROM DISK
MDRAM .SET TRUE ; MD: ENABLE RAM DISK
MDTRACE .SET 1 ; MD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
MDFFENABLE .SET FALSE ; MD: ENABLE FLASH FILE SYSTEM
;
FDENABLE .SET FALSE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)
FDMODE .SET FDMODE_RCWDC ; FD: DRIVER MODE: FDMODE_[DIO|ZETA|ZETA2|DIDE|N8|DIO3|RCSMC|RCWDC|DYNO|EPFDC|MBC]
FDCNT .SET 2 ; FD: NUMBER OF FLOPPY DRIVES ON THE INTERFACE (1-2)
FDTRACE .SET 1 ; FD: TRACE LEVEL (0=NO,1=FATAL,2=ERRORS,3=ALL)
FDMAUTO .SET TRUE ; FD: AUTO SELECT DEFAULT/ALTERNATE MEDIA FORMATS
FD0TYPE .SET FDT_3HD ; FD 0: DRIVE TYPE: FDT_[3DD|3HD|5DD|5HD|8]
FD1TYPE .SET FDT_3HD ; FD 1: DRIVE TYPE: FDT_[3DD|3HD|5DD|5HD|8]
;
RFENABLE .SET FALSE ; RF: ENABLE RAM FLOPPY DRIVER
;
IDEENABLE .SET FALSE ; IDE: ENABLE IDE DISK DRIVER (IDE.ASM)
IDETRACE .SET 1 ; IDE: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
IDECNT .SET 1 ; IDE: NUMBER OF IDE INTERFACES TO DETECT (1-3), 2 DRIVES EACH
IDE0MODE .SET IDEMODE_RC ; IDE 0: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC|GIDE]
IDE0BASE .SET $10 ; IDE 0: IO BASE ADDRESS
IDE0DATLO .SET $00 ; IDE 0: DATA LO PORT FOR 16-BIT I/O
IDE0DATHI .SET $00 ; IDE 0: DATA HI PORT FOR 16-BIT I/O
IDE0A8BIT .SET TRUE ; IDE 0A (MASTER): 8 BIT XFER
IDE0B8BIT .SET TRUE ; IDE 0B (MASTER): 8 BIT XFER
IDE1MODE .SET IDEMODE_RC ; IDE 1: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC|GIDE]
IDE1BASE .SET $18 ; IDE 1: IO BASE ADDRESS
IDE1DATLO .SET $00 ; IDE 1: DATA LO PORT FOR 16-BIT I/O
IDE1DATHI .SET $00 ; IDE 1: DATA HI PORT FOR 16-BIT I/O
IDE1A8BIT .SET TRUE ; IDE 1A (MASTER): 8 BIT XFER
IDE1B8BIT .SET TRUE ; IDE 1B (MASTER): 8 BIT XFER
IDE2MODE .SET IDEMODE_RC ; IDE 2: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC|GIDE]
IDE2BASE .SET $20 ; IDE 2: IO BASE ADDRESS
IDE2DATLO .SET $00 ; IDE 2: DATA LO PORT FOR 16-BIT I/O
IDE2DATHI .SET $00 ; IDE 2: DATA HI PORT FOR 16-BIT I/O
IDE2A8BIT .SET TRUE ; IDE 2A (MASTER): 8 BIT XFER
IDE2B8BIT .SET TRUE ; IDE 2B (MASTER): 8 BIT XFER
;
PPIDEENABLE .SET FALSE ; PPIDE: ENABLE PARALLEL PORT IDE DISK DRIVER (PPIDE.ASM)
PPIDETRACE .SET 1 ; PPIDE: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPIDECNT .SET 1 ; PPIDE: NUMBER OF PPI CHIPS TO DETECT (1-3), 2 DRIVES PER CHIP
PPIDE0BASE .SET $20 ; PPIDE 0: PPI REGISTERS BASE ADR
PPIDE0A8BIT .SET FALSE ; PPIDE 0A (MASTER): 8 BIT XFER
PPIDE0B8BIT .SET FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
PPIDE1BASE .SET $00 ; PPIDE 1: PPI REGISTERS BASE ADR
PPIDE1A8BIT .SET FALSE ; PPIDE 1A (MASTER): 8 BIT XFER
PPIDE1B8BIT .SET FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
PPIDE2BASE .SET $00 ; PPIDE 2: PPI REGISTERS BASE ADR
PPIDE2A8BIT .SET FALSE ; PPIDE 2A (MASTER): 8 BIT XFER
PPIDE2B8BIT .SET FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
;
SDENABLE .SET FALSE ; SD: ENABLE SD CARD DISK DRIVER (SD.ASM)
SDMODE .SET SDMODE_PIO ; SD: DRIVER MODE: SDMODE_[JUHA|N8|CSIO|PPI|UART|DSD|MK4|SC|MT|USR|PIO|Z80R|EPITX|FZ80|GM|EZ512|K80W]
SDPPIBASE .SET $60 ; SD: BASE I/O ADDRESS OF PPI FOR PPI MODDE
SDCNT .SET 2 ; SD: NUMBER OF SD CARD DEVICES (1-2), FOR DSD/SC/MT ONLY
SDTRACE .SET 1 ; SD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
SDCSIOFAST .SET FALSE ; SD: ENABLE TABLE-DRIVEN BIT INVERTER IN CSIO MODE
SDMTSWAP .SET FALSE ; SD: SWAP THE LOGICAL ORDER OF THE SPI PORTS OF THE MT011
;
CHENABLE .SET FALSE ; CH: ENABLE CH375/376 USB SUPPORT
CHTRACE .SET 1 ; CH: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
CHUSBTRACE .SET 1 ; CHUSB: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
CHSDTRACE .SET 1 ; CHSD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
CHCNT .SET 2 ; CH: NUMBER OF BOARDS TO DETECT (1-2)
CH0BASE .SET $3E ; CH 0: BASE I/O ADDRESS
CH0USBENABLE .SET TRUE ; CH 0: ENABLE USB DISK
CH0SDENABLE .SET FALSE ; CH 0: ENABLE SD DISK
CH1BASE .SET $3C ; CH 1: BASE I/O ADDRESS
CH1USBENABLE .SET TRUE ; CH 1: ENABLE USB DISK
CH1SDENABLE .SET FALSE ; CH 1: ENABLE SD DISK
;
PRPENABLE .SET FALSE ; PRP: ENABLE ECB PROPELLER IO BOARD DRIVER (PRP.ASM)
;
PPPENABLE .SET FALSE ; PPP: ENABLE ZETA PARALLEL PORT PROPELLER BOARD DRIVER (PPP.ASM)
;
ESPENABLE .SET FALSE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)
;
HDSKENABLE .SET FALSE ; HDSK: ENABLE SIMH HDSK DISK DRIVER (HDSK.ASM)
;
PIOENABLE .SET FALSE ; PIO: ENABLE ZILOG PIO DRIVER (PIO.ASM)
PIOCNT .SET 2 ; PIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
PIO0BASE .SET $B8 ; PIO 0: REGISTERS BASE ADR
PIO1BASE .SET $BC ; PIO 1: REGISTERS BASE ADR
;
LPTENABLE .SET FALSE ; LPT: ENABLE CENTRONICS PRINTER DRIVER (LPT.ASM)
LPTMODE .SET LPTMODE_MG014 ; LPT: DRIVER MODE: LPTMODE_[NONE|SPP|MG014]
LPTCNT .SET 1 ; LPT: NUMBER OF CHIPS TO DETECT (1-2)
LPTTRACE .SET 1 ; LPT: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
LPT0BASE .SET $0C ; LPT 0: REGISTERS BASE ADR
LPT1BASE .SET $00 ; LPT 1: REGISTERS BASE ADR
;
PPAENABLE .SET FALSE ; PPA: ENABLE IOMEGA ZIP DRIVE (PPA) DISK DRIVER (PPA.ASM)
PPACNT .SET 1 ; PPA: NUMBER OF PPA DEVICES (1-2)
PPATRACE .SET 1 ; PPA: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPAMODE .SET PPAMODE_MG014 ; PPA: DRIVER MODE: PPAMODE_[NONE|SPP|MG014]
PPA0BASE .SET LPT0BASE ; PPA 0: BASE I/O ADDRESS OF PPI FOR PPA
PPA1BASE .SET LPT1BASE ; PPA 1: BASE I/O ADDRESS OF PPI FOR PPA
;
IMMENABLE .SET FALSE ; IMM: ENABLE IOMEGA ZIP PLUS DRIVE (IMM) DISK DRIVER (IMM.ASM)
IMMCNT .SET 1 ; IMM: NUMBER OF IMM DEVICES (1-2)
IMMTRACE .SET 1 ; IMM: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
IMMMODE .SET IMMMODE_MG014 ; IMM: DRIVER MODE: IMMMODE_[NONE|SPP|MG014]
IMM0BASE .SET LPT0BASE ; IMM 0: BASE I/O ADDRESS OF PPI FOR IMM
IMM1BASE .SET LPT1BASE ; IMM 1: BASE I/O ADDRESS OF PPI FOR IMM
;
SYQENABLE .SET FALSE ; SYQ: ENABLE SYQUEST SPARQ DISK DRIVER (SYQ.ASM)
SYQCNT .SET 1 ; SYQ: NUMBER OF SYQ DEVICES (1-2)
SYQTRACE .SET 1 ; SYQ: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
SYQMODE .SET IMMMODE_MG014 ; SYQ: DRIVER MODE: SYQMODE_[NONE|SPP|MG014]
SYQ0BASE .SET LPT0BASE ; SYQ 0: BASE I/O ADDRESS OF PPI FOR SYQ
SYQ1BASE .SET LPT1BASE ; SYQ 1: BASE I/O ADDRESS OF PPI FOR SYQ
;
PIO_4P .SET FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR ECB 4P BOARD
PIO_ZP .SET FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR ECB ZILOG PERIPHERALS BOARD (PIO.ASM)
PIO_SBC .SET FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR 8255 CHIP
;
UFENABLE .SET FALSE ; UF: ENABLE ECB USB FIFO DRIVER (UF.ASM)
;
SN76489ENABLE .SET FALSE ; SN: ENABLE SN76489 SOUND DRIVER
AUDIOTRACE .SET FALSE ; ENABLE TRACING TO CONSOLE OF SOUND DRIVER
SN7CLK .SET 3579545 ; SN: PSG CLOCK FREQ, ASSUME MSX STD
SNMODE .SET SNMODE_RC ; SN: DRIVER MODE: SNMODE_[NONE|RC|VGM|DUO]
;
AY38910ENABLE .SET FALSE ; AY: ENABLE AY-3-8910 / YM2149 SOUND DRIVER
AY_CLK .SET 1789772 ; AY: PSG CLOCK FREQ, ASSUME MSX STD
AYMODE .SET AYMODE_RCZ80 ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO|NABU]
AY_FORCE .SET FALSE ; AY: BYPASS AUTO-DETECT, FORCED PRESENT
;
SPKENABLE .SET FALSE ; SPK: ENABLE RTC LATCH IOBIT SOUND DRIVER (SPK.ASM)
;
DMAENABLE .SET FALSE ; DMA: ENABLE DMA DRIVER (DMA.ASM)
DMABASE .SET $E0 ; DMA: DMA BASE ADDRESS
DMAMODE .SET DMAMODE_RC ; DMA: DMA MODE (NONE|ECB|Z180|Z280|RC|MBC|DUO)
;
YM2612ENABLE .SET FALSE ; YM2612: ENABLE YM2612 DRIVER
VGMBASE .SET $C0 ; YM2612: BASE ADDRESS FOR VGM BOARD (YM2612/SN76489s/CTC)

View File

@@ -3,6 +3,8 @@
; ROMWBW PLATFORM CONFIGURATION DEFAULTS FOR PLATFORM: MON
;==================================================================================================
;
; *** SUPPORT FOR THE MONSPUTER IS DEPRECATED ***
;
; THIS FILE DEFINES THE DEFAULT CONFIGURATION SETTINGS FOR THE PLATFORM
; INDICATED ABOVE. THIS FILE SHOULD *NOT* NORMALLY BE CHANGED. INSTEAD,
; YOU SHOULD OVERRIDE SETTINGS YOU WANT USING A CONFIGURATION FILE IN

View File

@@ -2950,6 +2950,46 @@ NXTMIO: LD A,(HL)
#ENDIF
;
;--------------------------------------------------------------------------------------------------
; ENABLE INTERRUPTS
;--------------------------------------------------------------------------------------------------
;
#IFDEF TESTING
;
INTTEST:
; TEST TO SEE IF SOMEBODY ENABLED INTS EARLY!
LD A,I
JP PO,INTTEST_Z ; IF PO, INTS DISABLED AS EXPECTED
PRTX(STR_INTWARN) ; WARNING
JR INTTEST_Z ; CONTINUE
;
STR_INTWARN .TEXT "\r\n\r\nWARNING: INTERRUPTS ENABLED TOO EARLY!!!$"
;
INTTEST_Z:
;
#ENDIF
;
HB_EI ; INTERRUPTS SHOULD BE OK NOW
;
; PERFORM A RESET OPERATION ON ALL CHARACTER DEVICES THAT HAVE BEEN
; INSTALLED. THIS SHOULD CORRECT ANY PROBLEMS IF A PROBE DESTROYED
; THE PROGRAMMING OF ANOTHER DEVICE.
;
LD A,(CIO_CNT) ; NUMBER OF CHARACTER DEVICES
OR A ; CHECK FOR ZERO TO AVOID CRASHING
JR Z,HB_CHRES_Z ; BYPASS IF NONE
LD B,A ; SETUP LOOP COUNTER
LD C,0 ; DEVICE INDEX
HB_CHRES:
PUSH BC ; SAVE LOOP CONTROL
LD B,BF_CIOINIT ; HBIOS RESET FUNCTION
LD DE,$FFFF ; NO CONFIG CHANGES
CALL CIO_DISPATCH ; CALL CIO DISPATCHER DIRECTLY
POP BC ; RECOVER LOOP CONTROL
INC C ; NEXT DEVICE
DJNZ HB_CHRES ; LOOP AS NEEDED
HB_CHRES_Z:
;
;--------------------------------------------------------------------------------------------------
; ANNOUNCE HBIOS
;--------------------------------------------------------------------------------------------------
;
@@ -3053,27 +3093,6 @@ HB_SPDTST:
#ENDIF
;
;--------------------------------------------------------------------------------------------------
; ENABLE INTERRUPTS
;--------------------------------------------------------------------------------------------------
;
#IFDEF TESTING
;
INTTEST:
; TEST TO SEE IF SOMEBODY ENABLED INTS EARLY!
LD A,I
JP PO,INTTEST_Z ; IF PO, INTS DISABLED AS EXPECTED
PRTX(STR_INTWARN) ; WARNING
JR INTTEST_Z ; CONTINUE
;
STR_INTWARN .TEXT "\r\n\r\nWARNING: INTERRUPTS ENABLED TOO EARLY!!!$"
;
INTTEST_Z:
;
#ENDIF
;
HB_EI ; INTERRUPTS SHOULD BE OK NOW
;
;--------------------------------------------------------------------------------------------------
; DISPLAY PLATFORM INFORMATION
;--------------------------------------------------------------------------------------------------
;
@@ -8429,7 +8448,7 @@ PS_SERIAL:
CALL NEWLINE
RET
;
; PRINT CHARACTER TYPE (SERIAL ATTRIBUTE IN E)
; PRINT CHARACTER TYPE (SERIAL ATTRIBUTE IN C)
;
PS_PRTST:
LD HL,PS_STPPT

View File

@@ -194,7 +194,7 @@ PLT_UNA .EQU 6 ; UNA BIOS
PLT_RCZ80 .EQU 7 ; RCBUS W/ Z80
PLT_RCZ180 .EQU 8 ; RCBUS W/ Z180
PLT_EZZ80 .EQU 9 ; EASY Z80
PLT_SCZ180 .EQU 10 ; SCZ180
PLT_SCZ180 .EQU 10 ; SMALL COMPUTER CENTRAL Z180
PLT_DYNO .EQU 11 ; DYNO MICRO-ATX MOTHERBOARD
PLT_RCZ280 .EQU 12 ; RCBUS W/ Z280
PLT_MBC .EQU 13 ; MULTI BOARD COMPUTER
@@ -204,9 +204,9 @@ PLT_S100 .EQU 16 ; S100 COMPUTERS Z180 SYSTEM
PLT_DUO .EQU 17 ; DUODYNE Z80 SYSTEM
PLT_HEATH .EQU 18 ; HEATHKIT H8 Z80 SYSTEM
PLT_EPITX .EQU 19 ; Z180 MINI-ITX
PLT_MON .EQU 20 ; MONSPUTER
PLT_MON .EQU 20 ; MONSPUTER (DEPRECATED)
PLT_GMZ180 .EQU 21 ; GENESIS Z180 SYSTEM
PLT_NABU .EQU 22 ; NABU PERSONAL COMPUTER
PLT_NABU .EQU 22 ; NABU PC W/ ROMWBW OPTION BOARD
PLT_FZ80 .EQU 23 ; S100 FPGA Z80
PLT_RCEZ80 .EQU 24 ; RCBUS W/ eZ80
;
@@ -393,9 +393,8 @@ CIODEV_LPT .EQU $0B
CIODEV_ESPCON .EQU $0C
CIODEV_ESPSER .EQU $0D
CIODEV_SCON .EQU $0E
CIODEV_EF .EQU $0F
CIODEV_SSER .EQU $10
CIODEV_EZ80UART .EQU $11
CIODEV_SSER .EQU $0F
CIODEV_EZ80UART .EQU $10
;
; SUB TYPES OF CHAR DEVICES
;

View File

@@ -615,6 +615,12 @@ CPUKHZ .SET CPUKHZ / 2 ; Z180 PHI IS ALWAYS 1/2 OSC
#ENDIF
;
CPUMHZ .EQU CPUKHZ / 1000 ; CPU FREQ IN MHZ
;
SYSECHO "CPU SPEED: "
SYSECHO CPUKHZ
SYSECHO " KHZ\n"
;
; DISPLAY INTERRUPT MODE
;
SYSECHO "INTERRUPTS: "
#IF (INTMODE == 0)
@@ -653,10 +659,10 @@ SYSTIM .SET TM_CTC
#ENDIF
#ENDIF
;
#IF (TMSENABLE & (INTMODE == 1))
#IF (TMSENABLE & (INTMODE > 0))
#IF (TMSTIMENABLE)
SYSTIM .SET TM_TMS
SYSECHO " TMS9918/V9958"
SYSECHO " TMS"
#ENDIF
#ENDIF
;

View File

@@ -0,0 +1,207 @@
The version of TE included with RomWBW is provided by Ladislau Szilagyi.
It is distributed from his GitHub repository at
https://github.com/Laci1953/RC2014-CPM/tree/main/System/te%20text%20editor.
RomWBW includes the RomWBW specific version of TE (TEWBW), but is called
just TE. TEWBW is distributed as a hex file. It has already been
converted to a .COM file in the RomWBW distribution.
The following is a copy of the ReadMe file from the TE distribution.
-- WBW 11:14 AM 4/1/2025
# Updated on April 2025
-----------------------------
The text editor TE was written by Miguel Garcia.
It's simple, user friendly, and edits the text in the RAM (it's fast...).
But, because the CP/M's 64KB RAM is limited as capacity (the operating system, the program and the text file must fit inside these 64KB RAM), the original TE allowed only small files to be edited (up to 20K).
I made this adaptation to harness the advantages of being provided with some extra RAM, in certain Z80 hardware platforms.
This version of the text editor TE works on the following hardware environments:
TE64 - any RC2014 with 64KB RAM
TE128 - Z80 systems provided with SC108, SC114, SC118, SC150, SC152 or the Phillip Stevens memory module (128 KB RAM),
TE512 - Z80 systems provided with the 512KB RAM + 512KB ROM module
TEZ80ALL - Z80ALL (25MHz Z80, 4 x 32KB RAM, VGA 48x64, keyboard) (see https://github.com/Laci1953/Software-for-Z80ALL-retro-computer/tree/main/TE)
TES80 - Simple80 (2 x 64KB RAM)
TEWBW - RC2014 running RomWBW
Use the HiTech tools to compile & link the sources.
Settings:
TE64: 64K RAM systems - up to 2048 lines, VT100 compatible, with WordStar style keyboard (accepts also arrow keys)
TE128: 128K RAM systems - up to 4093 lines, VT100 compatible, with WordStar style keyboard (accepts also arrow keys)
TE512: 512K RAM systems - up to 8192 lines, VT100 compatible, with WordStar style keyboard (accepts also arrow keys)
TEZ80ALL: Z80ALL standalone retro computer - up to 8192 lines, VGA 48x64, with WordStar style keyboard (accepts also arrow keys)
TES80: 128K RAM systems - up to 4093 lines, VT100 compatible, with WordStar style keyboard (accepts also arrow keys)
TEWBW: up to 4096 lines, VT100 compatible, with WordStar style keyboard (accepts also arrow keys)
Design details and some constraints:
1. For the 512KB version:
-------------------------
To handle the memory allocation requests, a new memory allocator was written.
How it works:
The 512KB RAM module uses 32 16KB "virtual" RAM pages, mapped to one of 4 "physical" pages 0000-3FFF, 4000-7FFF, 8000-BFFF and C000-FFFF.
Any virtual page can be mapped to any physical page.
The memory physical area from 8000H to BFFFH (let's name-it "work area") is used to load one of the 32 "virtual" 16KB pages from the 512KB RAM, and the memory allocator returns a pointer to the available buffer and a byte containing the index of the 16KB page that contains this buffer (let's name-it "page index").
When that buffer needs to be accessed for read/write operations, the 16KB RAM page must be first loaded into the "work area",
using a function call with the "page index" as parameter.
Of course, to "free" the allocated buffer, this "page index" must be provided too.
Text files up to 400KB can be edited.
The 512KB version can be run on any CP/M version, regardless of its TPA area size.
2. For the 128KB version:
-------------------------
To handle the memory allocation requests, a new memory allocator was written.
How it works:
The 128KB RAM is divided into 2 "virtual" 64KB banks: the lower and the upper bank. A port selects which "virtual" 64KB RAM bank is mapped to the physical 64KB RAM.
In order to execute code that switches from the lower to the upper bank (and back...),
that piece of code must be present at the same physical address in both of banks (the so called "shadow code)".
It is impossible to store shadow code in the upper bank using only programs resident in RAM,
for this only ROM-based code may help; SCM contains an API function ( $2B ) which moves a byte to a given address of the upper RAM bank.
In early SCM version (e.g. v1.0), this API call is not documented (it cannot be found in the SCM manual), I've found-it by browsing through the SCM source code...
Therefore, by using this $2B SCM API call, the shadow code can be moved to the upper RAM bank.
As a second possibility, this routine can be stored also, at a fixed address (7F00H) in the EPROM used to boot CP/M (see https://github.com/Laci1953/RC2014-CPM/tree/main/BOOT ).
But, for the memory allocator, we have also another important constraint: the shadow code must be stored in top of the physical 64KB RAM, in order to offer as much possible RAM available to be allocated (storing at the bottom of the physical 64KB RAM is out of question, we have there the 100H BIOS buffers area). There is only one possible solution: storing a small shadow code on top of CP/M's BIOS. My shadow code is less than 40H.
Studying the "classic" RC2014 CP/M that is currently used with 64/128MB CF's, I discovered that the BIOS "eats" practically all the space to FFFF ! There was no room for my shadow code!
I solved this issue by building a smaller CP/M, for both 64MB & 128MB CF's. You may find this CP/M in the PutSys folder.
The algorithm used to allocate memory is the following: if the usual call to malloc fails, the new allocator accesses the upper 64KB RAM bank and allocates there the buffer.
Besides the address of the buffer, a byte containing the RAM bank index is returned too (0=lower 64KB RAM, 1=upper 64KB RAM).
To access a buffer reserved in the upper 64KB RAM bank, special functions must be used to read/write a byte, a word, or a string.
Text files up to 80KB can be edited.
But, this comes with a cost: when opening a file to be edited, the editor reads all the text and store this text in the dynamic memory, and this takes time, because every single byte that has to be moved to the upper RAM bank is not simply moved, as in case of the lower bank, but is passed to the shadow code in order to be stored in the upper RAM bank. Also, a buffer for every new text line that is read must be allocated, and this allocation means also accessing the shadow code, in order to manage (read/write) the data structures that handle the available memory pool.
Once the file is read, the browse/search operations prove to be quick (compared for example with the performance of WordStar), because no more file read operations are needed, all the text is in the memory.
As a conclusion: the TE editor 128KB version will work only for RC2014 systems provided with my "custom CP/M"
Comparing the two versions of TE (128KB vs. 512KB), the 512KB version is by far the best.
First, the size of files that can be edited is larger (400KB vs. 80KB).
Then, the initial phase of file reading when starting the editor is faster.
But, I consider both versions of the TE editor as a step forward in the right direction, allowing larger files to be edited in memory, with an elegant an efficient user interface.
February 2022
-------------
TE now supports TABs.
The files, when loaded, will be displayed using TABs indentation.
The TAB interval (4 or 8) may be set from the command line: >TE file.ext [ 4 | 8 ] ; default = 8.
March 2023
----------
I made some improvements mainly related to the usability of the tool.
1. First, I opted to display a small help message, in the case when RE is executed without parameters; the message is showing all the available options.
-------------
D>te
TE text editor
Copyright (c) 2015-2021 Miguel Garcia / FloppySoftware
Adapted for 128KB RAM by Ladislau Szilagyi
Use: >TE [options] [filename]
where options (lowercase or uppercase) are:
-Tn (n = 4 or 8) sets the tabs to n spaces, default is 8
-Hnn sets the screen height (up to 99, default is 24)
-Wnnn sets the screen width (up to 200, default is 80)
Continue? (N/n = quit) :
------------
You can press N/n to quit to CP/M, or any other key to continue TE, being presented with an empty screen, ready for text input...
2. Tabs can be used freely in the text; you have two options related to TAB's alignment ( 4 or 8 ); the default is 8.
You can change-it to 4 using the option -T in the command line.
It important to mention that the use of TABs does not increase the size of the text file, nor the size of buffers allocated in memory to store the text; this is because TABs are inflated/deflated to/from blanks only when needed, (e.g.) when displayed on screen.
3. When reading/writing files, a line containing a counter of the lines being processed is displayed, to offer to the user a clue related to the status of the I/O operation.
4. The number of columns/lines can now be selected directly in the command line, using the -W or -H options; default values are 24 for lines, and 80 for columns.
I opted to unify the two versions of source code (128/512), now there is a single set of source files for both 128KB and 512KB TE versions.
As a reminder, the TE128 can edit files with sizes up to 80KB, and TE512 up to 400KB.
April 2023
----------
I made a major improvement, allowing text files with long lines to be processed (lines with up to 145 chars for 80 column screens, up to 115 chars for 64 column screens).
I have now also a TE adapted for Bill Shen's Z80ALL (Z80 at 25MHz, 4 x 32KB RAM, VGA 48x64, keyboard).
Text files up to 64KB can be edited.
This version is fast enough to allow handling large files without the handicap of long waiting interval until the whole file is read - some seconds are enough...
September 2023
--------------
I improved the code related to cursor placement, in the line and up/down between lines; this involves keeping track of TAB's, and assuring that the cursor is always positioned to a position containing a "real" character (e.g. when moving the cursor in a line containing multiple TAB's, the cursor is never placed to a position that does not contain a character or a TAB)
Also, BackSpace behavior was aligned to the above rule.
October 2023
--------------
The 128KB RAM version is now capable to edit text files with size up to 80KB; also, the initial "read file" step is faster.
March 2025
----------
Besides the "arrow" keys (UP, DOWN, LEFT, RIGHT), in the TE version 1.12, also the following keys can be used to move the cursor:
-PgUp (displays the previous page of text),
-PgDn (displays the next page of text),
-Home (displays the first page of text),
-End (displays the last page of text)
Also, here are some clarifications related to the "text blocks handling" feature:
TE is able to select, copy, paste and delete contiguous sets of lines of text (blocks).
Use ^KB to mark the starting line of a block and ^KK to mark the ending line of a block.
Then, you may use block-related operations, e.g.:
Type ^O to copy this block to the clipboard (the block will be displayed on video reverse),
move the cursor to another place in the file and type ^W to paste the block.
April 2025
----------
The TEWBW.HEX file is built to be used on RC2014 computers running RomWBW (version 3.5.0 or later)
The size of the files that can be edited depends on the RomWBW configuration (more exactly on the number of RAM banks available for apps).
For example, if installing RCZ80_std.rom on a RC2014 provided with 512KB ROM + 512KB RAM, we get 3 x 32KB = 96KB available to store the files.
Files up to 4096 lines are accepted.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -7,11 +7,11 @@ from his GitHub repository at https://github.com/Laci1953/Cowgol_on_CP_M.
The COWFE program included here is the RomWBW-specific version that
is tailored to RomWBW memory management.
The primary distribution site for Cowgol 2.0 is at
Ladislau's distribution is derived from Cowgol 2.0 by David Given at
https://github.com/davidgiven/cowgol.
The user manual is available in the Doc/Language directory
Cowgol Language.pdf
The user manual is available in the RomWBW distribution in the
Doc/Language directory. The file is "Cowgol Language.pdf"
The Hi-Tech C compiler components were sourced from the updated
version by Tony Nicholson at https://github.com/agn453/HI-TECH-Z80-C.
@@ -28,7 +28,7 @@ There are two example Cowgol applications included:
application (no assembler or C components). The command
line to build the application is:
COWGOL HEXDUMP.COW
COWGOL -M HEXDUMP.COW
- DYNMSORT demonstrates a sort algorithm and is composed of
Cowgol, C, and assembler components. The command line to
@@ -47,7 +47,7 @@ applications which can be used as follows:
The Adventure game program source has been added. The command to
build the source is:
COWGOL ADVENT.COW ADVMAIN.COW XRND.AS
COWGOL -O MISC.COO STRING.COO RANFILE.COO ADVENT.COW ADVTRAV.COW ADVMAIN.COW
or you can use the SUBMIT file:
@@ -57,3 +57,8 @@ WARNING: You will need to build this application under CP/M 3 because
COWGOL needs more main memory than is available under CP/M 2.2.
-- WBW 11:43 AM 2/25/2024
The Cowgol distribution has been updated based on the latest
release by Ladislau Szilagyi as of 2/25/2025.
-- WBW 1:24 PM 3/29/2025

File diff suppressed because it is too large Load Diff

View File

@@ -1,2 +1,2 @@
COWGOL -O ADVENT.COW ADVMAIN.COW XRND.AS
COWGOL -O MISC.COO STRING.COO RANFILE.COO ADVENT.COW ADVTRAV.COW ADVMAIN.COW


File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,587 @@
##
## This is Daimler's 350-point "Adventure" (circa June 1990, according
## to Russel Dalenberg). Its version information lists
##
## -Conversion to BDS C by J. R. Jaeger
## -Unix standardization by Jerry D. Pohl.
## -OS/2 Conversion by Martin Heller
## -Conversion to TurboC 2.0 by Daimler
##
## It contains Jerry Pohl's original ADVENT.DOC (dated 12 JUNE 1984),
## plus comments from Martin Heller (dated 30-Aug-1988). Strangely for
## an expansion, Daimler's version actually introduces a number of typos
## into the data files, and disables a handful of inessential verbs
## (READ, EAT, FILL) with the comment that there is "no room" for them
## (presumably in the PC's limited memory).
## -------------------------------------------------------------------
## Adapted for HiTech C Z80 under CP/M by Ladislau Szilagyi, Oct. 2023
## Uncommented Daimler's disabled verbs - game is complete again !
## Added a new pseudo-random number generator (Xorshift)
## Adapted to Cowgol language by Ladislau Szilagyi, Feb. 2025
include "misc.coh";
include "string.coh";
@decl sub get_dbugflg(): (ret: int16) @extern("get_dbugflg");
@decl sub bug(n: uint8) @extern("bug");
@decl sub set_newloc(v: int16) @extern("set_newloc");
@decl sub set_oldloc(v: int16) @extern("set_oldloc");
@decl sub set_oldloc2(v: int16) @extern("set_oldloc2");
@decl sub toting(item: uint16): (ret: uint8) @extern("toting");
@decl sub at(item: uint16): (ret: uint8) @extern("at");
@decl sub get_prop(obj: uint8): (ret: int16) @extern("get_prop");
@decl sub badmove(motion: int16, verb: int16) @extern("badmove");
@decl sub rspeak(msg: uint8) @extern("rspeak");
@decl sub spcmove(rdest: uint16) @extern("spcmove");
@decl sub forced(atloc: uint16): (ret: uint8) @extern("forced");
@decl sub set_motion(v: int16) @extern("set_motion");
var dummy: [uint8];
const MAXTRAV := (16+1); # max # of travel directions from loc
# +1 for terminator travel[x].tdest=-1
record trav is
tdest: int16;
tverb: int16;
tcond: int16;
end record;
var travel: trav[MAXTRAV];
# WARNING: the travel array for the cave is stored as MAXLOC
# strings. the strings are an array of 1..MAXTRAV
# LONG INTEGERS. this requires 32 bit LONG INTEGERS.
# these values are used in database.c "gettrav".
# tdset*1000000 + tverb*1000 + tcond = value stored
var cave: [uint8][] :=
{
"2002,2044,2029,3003,3012,3019,3043,4005,4013,4014,4046,4030,5006,5045,5043,8063,",
"1002000,1012000,1007000,1043000,1045000,1030000,5006000,5045000,5046000,",
"1003000,1011000,1032000,1044000,11062000,33065000,79005000,79014000,",
"1004000,1012000,1045000,5006000,5043000,5044000,5029000,7005000,7046000,7030000,8063000,",
"4009000,4043000,4030000,5006050,5007050,5045050,6006000,5044000,5046000,",
"1002000,1045000,4009000,4043000,4044000,4030000,5006000,5046000,",
"1012000,4004000,4045000,5006000,5043000,5044000,8005000,8015000,8016000,8046000,595060000,595014000,595030000,",
"5006000,5043000,5046000,5044000,1012000,7004000,7013000,7045000,9003303,9019303,9030303,593003000,",
"8011303,8029303,593011000,10017000,10018000,10019000,10044000,14031000,11051000,",
"9011000,9020000,9021000,9043000,11019000,11022000,11044000,11051000,14031000,",
"8063303,9064000,10017000,10018000,10023000,10024000,10043000,12025000,12019000,12029000,12044000,3062000,14031000,",
"8063303,9064000,11030000,11043000,11051000,13019000,13029000,13044000,14031000,",
"8063303,9064000,11051000,12025000,12043000,14023000,14031000,14044000,",
"8063303,9064000,11051000,13023000,13043000,20030150,20031150,20034150,15030000,16033000,16044000,",
"1803,1804,1700,1703,1704,1901,1903,1904,2202,2203,2203,2203,2202,2204,1402,3405,",
"14001000,",
"15038000,15043000,596039312,21007412,597041412,597042412,597044412,597069412,27041000,",
"15038000,15011000,15045000,",
"15010000,15029000,15043000,28045311,28036311,29046311,29037311,30044311,30007311,32045000,74049035,32049211,74066000,",
"001000,",
"001000,",
"15001000,",
"67043000,67042000,68044000,68061000,25030000,25031000,648052000,",
"67029000,67011000,",
"23029000,23011000,31056724,26056000,",
"88001000,",
"596039312,21007412,597041412,597042412,597043412,597069412,17041000,40045000,41044000,",
"19038000,19011000,19046000,33045000,33055000,36030000,36052000,",
"19038000,19011000,19045000,",
"19038000,19011000,19043000,62044000,62029000,",
"89001524,90001000,",
"19001000,",
"3065000,28046000,34043000,34053000,34054000,35044000,302071159,100071000,",
"33030000,33055000,15029000,",
"33043000,33055000,20039000,",
"37043000,37017000,28029000,28052000,39044000,65070000,",
"36044000,36017000,38030000,38031000,38056000,",
"37056000,37029000,37011000,595060000,595014000,595030000,595004000,595005000,",
"36043000,36023000,64030000,64052000,64058000,65070000,",
"41001000,",
"42046000,42029000,42023000,42056000,27043000,59045000,60044000,60017000,",
"41029000,42045000,43043000,45046000,80044000,",
"42044000,44046000,45043000,",
"43043000,48030000,50046000,82045000,",
"42044000,43045000,46043000,47046000,87029000,87030000,",
"45044000,45011000,",
"45043000,45011000,",
"44029000,44011000,",
"50043000,51044000,",
"44043000,49044000,51030000,52046000,",
"49044000,50029000,52043000,53046000,",
"50044000,51043000,52046000,53029000,55045000,86030000,",
"51044000,52045000,54046000,",
"53044000,53011000,",
"52044000,55045000,56030000,57043000,",
"55029000,55011000,",
"13030000,13056000,55044000,58046000,83045000,84043000,",
"57043000,57011000,",
"27001000,",
"41043000,41029000,41017000,61044000,62045000,62030000,62052000,",
"60043000,62045000,107046100,",
"60044000,63045000,30043000,61046000,",
"62046000,62011000,",
"39029000,39056000,39059000,65044000,65070000,103045000,103074000,106043000,",
"64043000,66044000,556046080,68061000,556029080,70029050,39029000,556045060,72045075,71045000,556030080,106030000,",
"65047000,67044000,556046080,77025000,96043000,556050050,97072000,",
"66043000,23044000,23042000,24030000,24031000,",
"23046000,69029000,69056000,65045000,",
"68030000,68061000,120046331,119046000,109045000,113075000,",
"71045000,65030000,65023000,111046000,",
"65048000,70046000,110045000,",
"65070000,118049000,73045000,97048000,97072000,",
"72046000,72017000,72011000,",
"19043000,120044331,121044000,75030000,",
"76046000,77045000,",
"75045000,",
"75043000,78044000,66045000,66017000,",
"77046000,",
"3001000,",
"42045000,80044000,80046000,81043000,",
"80044000,80011000,",
"44046000,44011000,",
"57046000,84043000,85044000,",
"57045000,83044000,114050000,",
"83043000,83011000,",
"52029000,52011000,",
"45029000,45030000,",
"25030000,25056000,25043000,20039000,92044000,92027000,",
"25001000,",
"23001000,",
"95045000,95073000,95023000,72030000,72056000,",
"88046000,93043000,94045000,",
"92046000,92027000,92011000,",
"92046000,92027000,92023000,95045309,95003309,95073309,611045000,",
"94046000,94011000,92027000,91044000,",
"66044000,66011000,",
"66048000,72044000,72017000,98029000,98045000,98073000,",
"97046000,97072000,99044000,",
"98050000,98073000,301043000,301023000,100043000,",
"301044000,301023000,301011000,99044000,302071159,33071000,101047000,101022000,",
"100046000,100071000,100011000,",
"103030000,103074000,103011000,",
"102029000,102038000,104030000,618046114,619046115,64046000,",
"103029000,103074000,105030000,",
"104029000,104011000,103074000,",
"64029000,65044000,108043000,",
"131046000,132049000,133047000,134048000,135029000,136050000,137043000,138044000,139045000,61030000,",
"556043095,556045095,556046095,556047095,556048095,556049095,556050095,556029095,556030095,106043000,626044000,",
"69046000,113045000,113075000,",
"71044000,20039000,",
"70045000,50030040,50039040,50056040,53030050,45030000,",
"131049000,132045000,133043000,134050000,135048000,136047000,137044000,138030000,139029000,140046000,",
"109046000,109011000,109109000,",
"84048000,",
"116049000,",
"115047000,593030000,",
"118049000,660041233,660042233,660069233,660047233,661041332,303041000,21039332,596039000,",
"72030000,117029000,",
"69045000,69011000,653043000,65307000,",
"69045000,74043000,",
"74043000,74011000,653045000,653007000,",
"123047000,660041233,660042233,660069233,660049233,303041000,596039000,124077000,126028000,129040000,",
"122044000,124043000,124077000,126028000,129040000,",
"123044000,125047000,125036000,128048000,128037000,128030000,126028000,129040000,",
"124046000,124077000,126045000,126028000,127043000,127017000,",
"125046000,125023000,125011000,124077000,610030000,610039000,",
"125044000,125011000,125017000,124077000,126028000,",
"124045000,124029000,124077000,129046000,129030000,129040000,126028000,",
"128044000,128029000,124077000,130043000,130019000,130040000,130003000,126028000,",
"129044000,124077000,126028000,",
"107044000,132048000,133050000,134049000,135047000,136029000,137030000,138045000,139046000,112043000,",
"107050000,131029000,133045000,134046000,135044000,136049000,137047000,138043000,139030000,112048000,",
"107029000,131030000,132044000,134047000,135049000,136043000,137045000,138050000,139048000,112046000,",
"107047000,131045000,132050000,133048000,135043000,136030000,137046000,138029000,139044000,112049000,",
"107045000,131048000,132030000,133046000,134043000,136044000,137049000,138047000,139050000,112029000,",
"107043000,131044000,132029000,133049000,134030000,135046000,137050000,138048000,139047000,112045000,",
"107048000,131047000,132046000,133030000,134029000,135050000,136045000,138049000,139043000,112044000,",
"107030000,131043000,132047000,133029000,134044000,135045000,136046000,137048000,139049000,112050000,",
"107049000,131050000,132043000,133044000,134045000,135030000,136048000,137029000,138046000,112047000,",
"112045000,112011000,"
};
var caveend: [uint8][] :=
{
"000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
"6000,6000,7000,8000,4000,0000,0000,5000,9150,1150,4150,5150,3150,3150,9000,5000,",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
",",
","
};
# Routine to fill travel array for a given location
sub gettrav(loc: uint8) @extern("gettrav") is
var i: uint8;
var t: int32;
var p1: [uint8];
var q1: [uint8];
var p2: [uint8];
var q2: [uint8];
var buf1: uint8[256];
var buf2: uint8[256];
var aptr: [uint8];
var atrav: uint8[256];
var hasend: uint8 := 1;
dummy := strcpy(&buf1[0], cave[loc - 1]);
p1 := &buf1[0];
dummy := strcpy(&buf2[0], caveend[loc - 1]);
p2 := &buf2[0];
if [p2] == ',' then
hasend := 0;
end if;
aptr := &atrav[0];
q1 := strchr(p1, ',');
while q1 != nil loop
[q1] := 0;
dummy := strcpy(aptr, p1);
p1 := q1 + 1;
if hasend == 1 then
q2 := strchr(p2, ',');
[q2] := 0;
dummy := strcat(aptr, p2);
p2 := q2 + 1;
end if;
q1 := strchr(p1, ',');
#print(aptr); print_nl();
aptr := aptr + strlen(aptr) + 1;
end loop;
[aptr] := 0;
aptr := &atrav[0];
i := 0;
while i < MAXTRAV loop
t := atol(aptr); # convert to long int
travel[i].tcond := (t % 1000) as int16;
t := t / 1000;
travel[i].tverb := (t % 1000) as int16;
t := t / 1000;
travel[i].tdest := (t % 1000) as int16;
aptr := aptr + strlen(aptr) + 1;
if [aptr] == 0 then
i := i + 1;
travel[i].tdest := -1; # end of array
if get_dbugflg() == 1 then
i := 0;
while travel[i].tdest != -1 loop
print("cave[");
print(itoa(loc as int16));
print("] = ");
print(itoa(travel[i].tdest));
print_char(' ');
print(itoa(travel[i].tverb));
print_char(' ');
print(itoa(travel[i].tcond));
print_nl();
i := i + 1;
end loop;
end if;
return;
end if;
i := i + 1;
end loop;
bug(33);
end sub;
# Routine to figure out a new location
# given current location and a motion.
sub dotrav(loc: int16, motion: int16, verb:int16) @extern("dotrav") is
var mvflag: uint8;
var hitflag: uint8;
var kk: uint8;
var rdest: int16;
var rverb: int16;
var rcond: int16;
var robject: int16;
var pctt: uint16;
set_newloc(loc);
mvflag := 0;
hitflag := 0;
pctt := xrnd() % 100;
kk := 0;
while travel[kk].tdest >= 0 and mvflag == 0 loop
rdest := travel[kk].tdest;
rverb := travel[kk].tverb;
rcond := travel[kk].tcond;
robject := rcond % 100;
if get_dbugflg() == 1 then
print("rdest = ");
print(itoa(rdest));
print(", rverb = ");
print(itoa(rverb));
print(", rcond = ");
print(itoa(rcond));
print(", robject = ");
print(itoa(robject));
print(" in dotrav\n");
end if;
if rverb != 1 and rverb != motion and hitflag == 0 then
kk := kk + 1;
continue;
end if;
hitflag := hitflag + 1;
var r := rcond;
r := r / 100;
if r == 3 or r == 4 or r == 5 then r := 7; end if;
case r is
when 0:
if rcond == 0 or pctt < rcond as uint16 then
mvflag := mvflag + 1;
end if;
if rcond == 1 and get_dbugflg() == 1 then
print("%% move ");
print(itoa(pctt as int16));
print_char(' ');
print(itoa(mvflag as int16));
print_nl();
end if;
when 1:
if robject == 0 or toting(robject as uint16) == 1 then
mvflag := mvflag + 1;
end if;
when 2:
if toting(robject as uint16) == 1 or at(robject as uint16) == 1 then
mvflag := mvflag + 1;
end if;
#when 3:
#when 4:
#when 5:
when 7:
if get_prop(robject as uint8) != (rcond/100)-3 then
mvflag := mvflag + 1;
end if;
when else:
bug(37);
end case;
kk := kk + 1;
end loop;
if mvflag == 0 then
badmove(motion, verb);
elseif rdest > 500 then
rspeak((rdest-500) as uint8);
elseif rdest>300 then
spcmove(rdest as uint16);
else
set_newloc(rdest);
if get_dbugflg() == 1 then
print("newloc in dotrav = ");
print(itoa(rdest)); #newloc
print_nl();
end if;
end if;
end sub;
# Routine to copy a travel array
sub copytrv(trav1: [trav], trav2: [trav]) is
var i: uint8;
i := 0;
while i < MAXTRAV loop
[trav2].tdest := [trav1].tdest;
[trav2].tverb := [trav1].tverb;
[trav2].tcond := [trav1].tcond;
trav1 := @next trav1;
trav2 := @next trav2;
i := i + 1;
end loop;
end sub;
# Routine to handle request to return
# from whence we came!
sub goback(loc: int16, oldloc: int16, oldloc2: int16, verb: int16) @extern("goback") is
var kk: uint8;
var k2: uint8;
var want: int16;
var temp: int16;
var strav: trav[MAXTRAV];
if forced(oldloc as uint16) == 1 then
want := oldloc2;
else
want := oldloc;
end if;
set_oldloc2(oldloc);
oldloc2 := oldloc;
set_oldloc(loc);
oldloc := loc;
k2 := 0;
if want == loc then
rspeak(91);
return;
end if;
copytrv(&travel[0], &strav[0]);
kk := 0;
while travel[kk].tdest != 0xFFFF loop
if travel[kk].tcond == 0 and travel[kk].tdest == want then
set_motion(travel[kk].tverb);
dotrav(loc, travel[kk].tverb, verb);
return;
end if;
if travel[kk].tcond == 0 then
k2 := kk;
temp := travel[kk].tdest;
gettrav(temp as uint8);
if forced(temp as uint16) == 1 and travel[0].tdest == want then
k2 := temp as uint8;
end if;
copytrv(&strav[0], &travel[0]);
end if;
kk := kk + 1;
end loop;
if k2 > 0 then
set_motion(travel[k2].tverb);
dotrav(loc, travel[k2].tverb, verb);
else
rspeak(140);
end if;
end sub;

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,32 @@
include "misc.coh";
var fp: int16;
sub factorial(n: int16): (ret: int16) is
var tmp: int16;
if n == 1 then
ret := 1;
else
# ret := n * factorial(n - 1);
@asm "ld hl,(", n, ")";
@asm "push hl";
n := n - 1;
@asm "ld hl,(", n, ")";
@asm "ld ix,(", fp, ")";
@asm "ld de, 1f";
@asm "push de";
@asm "jp (ix)";
@asm "1:";
@asm "ld (", tmp, "),hl"; #tmp = factorial(n-1)
@asm "pop hl";
@asm "ld (", n, "),hl";
ret := n * tmp;
end if;
end sub;
#setup pointer to factorial
@asm "ld hl,", factorial;
@asm "ld (", fp, "),hl";
print_i16(factorial(5));

Some files were not shown because too many files have changed in this diff Show More