diff --git a/Doc/ChangeLog.txt b/Doc/ChangeLog.txt index e31c7dcf..d0e79583 100644 --- a/Doc/ChangeLog.txt +++ b/Doc/ChangeLog.txt @@ -42,6 +42,7 @@ Version 3.5 - MAP: Added new HBIOS function EXT_SLICE (orginally SYSGET_DIOMED) - MAP: ROMLDR now uses EXT_SLICE to get Slice Sector for boot - MAP: CBIOS now uses EXT_SLICE during drive selection +- M?R: Added REBOOT application Version 3.4 ----------- diff --git a/Doc/RomWBW Applications.pdf b/Doc/RomWBW Applications.pdf index 37b03ef9..12ce1528 100644 Binary files a/Doc/RomWBW Applications.pdf and b/Doc/RomWBW Applications.pdf differ diff --git a/Doc/RomWBW Disk Catalog.pdf b/Doc/RomWBW Disk Catalog.pdf index a1075823..0dfffa5c 100644 Binary files a/Doc/RomWBW Disk Catalog.pdf and b/Doc/RomWBW Disk Catalog.pdf differ diff --git a/Doc/RomWBW Errata.pdf b/Doc/RomWBW Errata.pdf index 9e9d71d9..718bd3e7 100644 Binary files a/Doc/RomWBW Errata.pdf and b/Doc/RomWBW Errata.pdf differ diff --git a/Doc/RomWBW System Guide.pdf b/Doc/RomWBW System Guide.pdf index 81ef8fa7..c2792844 100644 Binary files a/Doc/RomWBW System Guide.pdf and b/Doc/RomWBW System Guide.pdf differ diff --git a/Doc/RomWBW User Guide.pdf b/Doc/RomWBW User Guide.pdf index 62762828..ac64e4ce 100644 Binary files a/Doc/RomWBW User Guide.pdf and b/Doc/RomWBW User Guide.pdf differ diff --git a/ReadMe.md b/ReadMe.md index d50046ad..d611247c 100644 --- a/ReadMe.md +++ b/ReadMe.md @@ -1,293 +1,293 @@ - - -**RomWBW ReadMe** \ -Version 3.5 \ -Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \ -05 Oct 2024 - -# Overview - -RomWBW software provides a complete, commercial quality implementation -of CP/M (and workalike) operating systems and applications for modern -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/) - () - -A complete list of the currently supported platforms is found in the -\[Installation\] section. - -General features 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 -- OSes: CP/M 2.2, ZSDOS, CP/M 3, NZ-COM, ZPM3, QPM, p-System, and - FreeRTOS -- Built-in VT-100 terminal emulation support - -RomWBW is distributed as both source code and pre-built ROM and disk -images. 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 - -A dynamic disk drive letter assignment mechanism allows mapping -operating system drive letters to any available disk media. -Additionally, mass storage devices (IDE Disk, CF Card, SD Card, etc.) -support the use of multiple slices (up to 256 per device). Each slice -contains a complete CP/M filesystem and can be mapped independently to -any drive letter. This overcomes the inherent size limitations in legacy -OSes and allows up to 2GB of accessible storage on a single device. - -The pre-built ROM firmware images are generally suitable for most users. -However, it is also very easy to modify and build custom ROM images that -fully tailor the firmware to your specific preferences. All tools -required to build custom ROM firmware under Windows are included – no -need to install assemblers, etc. The firmware can also be built using -Linux or MacOS after confirming a few standard tools have been -installed. - -Multiple disk images are provided in the distribution. Most disk images -contain a complete, bootable, ready-to-run implementation of a specific -operating system. A “combo” disk image contains multiple slices, each -with a full operating system implementation. If you use this disk image, -you can easily pick whichever operating system you want to boot without -changing media. - -By design, RomWBW isolates all of the hardware specific functions in the -ROM chip itself. The ROM provides a hardware abstraction layer such that -all of the operating systems and applications on a disk will run on any -RomWBW-based system. To put it simply, you can take a disk (or CF/SD/USB -Card) and move it between systems transparently. - -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 -slices or on stand-alone media. This makes exchanging files with modern -OSes such as Windows, MacOS, and Linux very easy. - -# Acquiring RomWBW - -The [RomWBW Repository](https://github.com/wwarthen/RomWBW) -() on GitHub is the official -distribution location for all project source and documentation. The -fully-built distribution releases are available on the [RomWBW Releases -Page](https://github.com/wwarthen/RomWBW/releases) -() of the repository. On -this page, you will normally see a Development Snapshot as well as -recent stable releases. Unless you have a specific reason, I suggest you -stick to the most recent stable release. Expand the “Assets” drop-down -for the release you want to download, then select the asset named -RomWBW-vX.X.X-Package.zip. The Package asset includes all pre-built ROM -and Disk images as well as full source code. The other assets contain -only source code and do not have the pre-built ROM or disk images. - -All source code and distributions are maintained on GitHub. Code -contributions are very welcome. - -# Installation & Operation - -In general, installation of RomWBW on your platform is very simple. You -just need to program your ROM with the correct ROM image from the RomWBW -distribution. Subsequently, you can write disk images on your disk -drives (IDE disk, CF Card, SD Card, etc.) which then provides even more -functionality. - -Complete instructions for installation and operation of RomWBW are found -in the [RomWBW User -Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20User%20Guide.pdf). - -## Documentation - -Documentation for RomWBW includes: - -- [RomWBW User - Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20User%20Guide.pdf) -- [RomWBW System - Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20System%20Guide.pdf) -- [RomWBW - Applications](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Applications.pdf) -- [RomWBW - Errata](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Errata.pdf) - -# Acknowledgments - -I want to acknowledge that a great deal of the code and inspiration for -RomWBW has been provided by or derived from the work of others in the -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. - -- 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. - -- 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. - -- 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. - -- 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. - -- 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. - -- Phillip Stevens contributed support for FreeRTOS. - -- Curt Mayer contributed the original Linux / MacOS build process. - -- UNA BIOS and FDISK80 are the products of John Coffman. - -- FLASH4 is a product of Will Sowerbutts. - -- CLRDIR is a product of Max Scane. - -- Tasty Basic is a product of Dimitri Theulings. - -- 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. - -- 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. - -- Mark Pruden has also contributed a great deal of content to the User - Guide as well as the COPYSL utility. - -- 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. - -- 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. - -- 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. - -- Lars Nelson has contributed several generic utilities such as a - universal (OS agnostic) UNARC application. - -- Dylan Hall added support for specifying a secondary console. - -- Bill Shen has contributed boot loaders for several of his systems. - -- 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. - -- Les Bird has contributed support for the NABU w/ Option Board - -Contributions of all kinds to RomWBW are very welcome. - -# Licensing - -RomWBW is free software: you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation, either version 3 of the License, or (at your -option) any later version. - -RomWBW is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -more details. - -You should have received a copy of the GNU General Public License along -with RomWBW. If not, see . - -Portions of RomWBW were created by, contributed by, or derived from the -work of others. It is believed that these works are being used in -accordance with the intentions and/or licensing of their creators. - -If anyone feels their work is being used outside of its intended -licensing, please notify: - -> Wayne Warthen -> - -RomWBW is an aggregate work. It is composed of many individual, -standalone programs that are distributed as a whole to function as a -cohesive system. Each program may have its own licensing which may be -different from other programs within the aggregate. - -In some cases, a single program (e.g., CP/M Operating System) is -composed of multiple components with different licenses. It is believed -that in all such cases the licenses are compatible with GPL version 3. - -RomWBW encourages code contributions from others. Contributors may -assert their own copyright in their contributions by annotating the -contributed source code appropriately. Contributors are further -encouraged to submit their contributions via the RomWBW source code -control system to ensure their contributions are clearly documented. - -All contributions to RomWBW are subject to this license. - -# 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](https://www.retrobrewcomputers.org/forum/) -- [RC2014 Google - Group](https://groups.google.com/forum/#!forum/rc2014-z80) -- [retro-comp Google - Group](https://groups.google.com/forum/#!forum/retro-comp) - -Submission of issues and bugs are welcome at the [RomWBW GitHub -Repository](https://github.com/wwarthen/RomWBW). - -Also feel free to email Wayne Warthen at . + + +**RomWBW ReadMe** \ +Version 3.5 \ +Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \ +13 Oct 2024 + +# Overview + +RomWBW software provides a complete, commercial quality implementation +of CP/M (and workalike) operating systems and applications for modern +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/) + () + +A complete list of the currently supported platforms is found in the +\[Installation\] section. + +General features 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 +- OSes: CP/M 2.2, ZSDOS, CP/M 3, NZ-COM, ZPM3, QPM, p-System, and + FreeRTOS +- Built-in VT-100 terminal emulation support + +RomWBW is distributed as both source code and pre-built ROM and disk +images. 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 + +A dynamic disk drive letter assignment mechanism allows mapping +operating system drive letters to any available disk media. +Additionally, mass storage devices (IDE Disk, CF Card, SD Card, etc.) +support the use of multiple slices (up to 256 per device). Each slice +contains a complete CP/M filesystem and can be mapped independently to +any drive letter. This overcomes the inherent size limitations in legacy +OSes and allows up to 2GB of accessible storage on a single device. + +The pre-built ROM firmware images are generally suitable for most users. +However, it is also very easy to modify and build custom ROM images that +fully tailor the firmware to your specific preferences. All tools +required to build custom ROM firmware under Windows are included – no +need to install assemblers, etc. The firmware can also be built using +Linux or MacOS after confirming a few standard tools have been +installed. + +Multiple disk images are provided in the distribution. Most disk images +contain a complete, bootable, ready-to-run implementation of a specific +operating system. A “combo” disk image contains multiple slices, each +with a full operating system implementation. If you use this disk image, +you can easily pick whichever operating system you want to boot without +changing media. + +By design, RomWBW isolates all of the hardware specific functions in the +ROM chip itself. The ROM provides a hardware abstraction layer such that +all of the operating systems and applications on a disk will run on any +RomWBW-based system. To put it simply, you can take a disk (or CF/SD/USB +Card) and move it between systems transparently. + +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 +slices or on stand-alone media. This makes exchanging files with modern +OSes such as Windows, MacOS, and Linux very easy. + +# Acquiring RomWBW + +The [RomWBW Repository](https://github.com/wwarthen/RomWBW) +() on GitHub is the official +distribution location for all project source and documentation. The +fully-built distribution releases are available on the [RomWBW Releases +Page](https://github.com/wwarthen/RomWBW/releases) +() of the repository. On +this page, you will normally see a Development Snapshot as well as +recent stable releases. Unless you have a specific reason, I suggest you +stick to the most recent stable release. Expand the “Assets” drop-down +for the release you want to download, then select the asset named +RomWBW-vX.X.X-Package.zip. The Package asset includes all pre-built ROM +and Disk images as well as full source code. The other assets contain +only source code and do not have the pre-built ROM or disk images. + +All source code and distributions are maintained on GitHub. Code +contributions are very welcome. + +# Installation & Operation + +In general, installation of RomWBW on your platform is very simple. You +just need to program your ROM with the correct ROM image from the RomWBW +distribution. Subsequently, you can write disk images on your disk +drives (IDE disk, CF Card, SD Card, etc.) which then provides even more +functionality. + +Complete instructions for installation and operation of RomWBW are found +in the [RomWBW User +Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20User%20Guide.pdf). + +## Documentation + +Documentation for RomWBW includes: + +- [RomWBW User + Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20User%20Guide.pdf) +- [RomWBW System + Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20System%20Guide.pdf) +- [RomWBW + Applications](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Applications.pdf) +- [RomWBW + Errata](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Errata.pdf) + +# Acknowledgments + +I want to acknowledge that a great deal of the code and inspiration for +RomWBW has been provided by or derived from the work of others in the +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. + +- 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. + +- 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. + +- 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. + +- 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. + +- 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. + +- Phillip Stevens contributed support for FreeRTOS. + +- Curt Mayer contributed the original Linux / MacOS build process. + +- UNA BIOS and FDISK80 are the products of John Coffman. + +- FLASH4 is a product of Will Sowerbutts. + +- CLRDIR is a product of Max Scane. + +- Tasty Basic is a product of Dimitri Theulings. + +- 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. + +- 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. + +- Mark Pruden has also contributed a great deal of content to the User + Guide as well as the COPYSL utility. + +- 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. + +- 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. + +- 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. + +- Lars Nelson has contributed several generic utilities such as a + universal (OS agnostic) UNARC application. + +- Dylan Hall added support for specifying a secondary console. + +- Bill Shen has contributed boot loaders for several of his systems. + +- 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. + +- Les Bird has contributed support for the NABU w/ Option Board + +Contributions of all kinds to RomWBW are very welcome. + +# Licensing + +RomWBW is free software: you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation, either version 3 of the License, or (at your +option) any later version. + +RomWBW is distributed in the hope that it will be useful, but WITHOUT +ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +more details. + +You should have received a copy of the GNU General Public License along +with RomWBW. If not, see . + +Portions of RomWBW were created by, contributed by, or derived from the +work of others. It is believed that these works are being used in +accordance with the intentions and/or licensing of their creators. + +If anyone feels their work is being used outside of its intended +licensing, please notify: + +> Wayne Warthen +> + +RomWBW is an aggregate work. It is composed of many individual, +standalone programs that are distributed as a whole to function as a +cohesive system. Each program may have its own licensing which may be +different from other programs within the aggregate. + +In some cases, a single program (e.g., CP/M Operating System) is +composed of multiple components with different licenses. It is believed +that in all such cases the licenses are compatible with GPL version 3. + +RomWBW encourages code contributions from others. Contributors may +assert their own copyright in their contributions by annotating the +contributed source code appropriately. Contributors are further +encouraged to submit their contributions via the RomWBW source code +control system to ensure their contributions are clearly documented. + +All contributions to RomWBW are subject to this license. + +# 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](https://www.retrobrewcomputers.org/forum/) +- [RC2014 Google + Group](https://groups.google.com/forum/#!forum/rc2014-z80) +- [retro-comp Google + Group](https://groups.google.com/forum/#!forum/retro-comp) + +Submission of issues and bugs are welcome at the [RomWBW GitHub +Repository](https://github.com/wwarthen/RomWBW). + +Also feel free to email Wayne Warthen at . diff --git a/ReadMe.txt b/ReadMe.txt index 440fbc13..bb3239dc 100644 --- a/ReadMe.txt +++ b/ReadMe.txt @@ -1,298 +1,299 @@ -RomWBW ReadMe -Wayne Warthen (wwarthen@gmail.com) -05 Oct 2024 - - - -OVERVIEW - - -RomWBW software provides a complete, commercial quality implementation -of CP/M (and workalike) operating systems and applications for modern -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/) - -A complete list of the currently supported platforms is found in the -[Installation] section. - -General features 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 -- OSes: CP/M 2.2, ZSDOS, CP/M 3, NZ-COM, ZPM3, QPM, p-System, and - FreeRTOS -- Built-in VT-100 terminal emulation support - -RomWBW is distributed as both source code and pre-built ROM and disk -images. 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 - -A dynamic disk drive letter assignment mechanism allows mapping -operating system drive letters to any available disk media. -Additionally, mass storage devices (IDE Disk, CF Card, SD Card, etc.) -support the use of multiple slices (up to 256 per device). Each slice -contains a complete CP/M filesystem and can be mapped independently to -any drive letter. This overcomes the inherent size limitations in legacy -OSes and allows up to 2GB of accessible storage on a single device. - -The pre-built ROM firmware images are generally suitable for most users. -However, it is also very easy to modify and build custom ROM images that -fully tailor the firmware to your specific preferences. All tools -required to build custom ROM firmware under Windows are included – no -need to install assemblers, etc. The firmware can also be built using -Linux or MacOS after confirming a few standard tools have been -installed. - -Multiple disk images are provided in the distribution. Most disk images -contain a complete, bootable, ready-to-run implementation of a specific -operating system. A “combo” disk image contains multiple slices, each -with a full operating system implementation. If you use this disk image, -you can easily pick whichever operating system you want to boot without -changing media. - -By design, RomWBW isolates all of the hardware specific functions in the -ROM chip itself. The ROM provides a hardware abstraction layer such that -all of the operating systems and applications on a disk will run on any -RomWBW-based system. To put it simply, you can take a disk (or CF/SD/USB -Card) and move it between systems transparently. - -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 -slices or on stand-alone media. This makes exchanging files with modern -OSes such as Windows, MacOS, and Linux very easy. - - - -ACQUIRING ROMWBW - - -The RomWBW Repository (https://github.com/wwarthen/RomWBW) on GitHub is -the official distribution location for all project source and -documentation. The fully-built distribution releases are available on -the RomWBW Releases Page (https://github.com/wwarthen/RomWBW/releases) -of the repository. On this page, you will normally see a Development -Snapshot as well as recent stable releases. Unless you have a specific -reason, I suggest you stick to the most recent stable release. Expand -the “Assets” drop-down for the release you want to download, then select -the asset named RomWBW-vX.X.X-Package.zip. The Package asset includes -all pre-built ROM and Disk images as well as full source code. The other -assets contain only source code and do not have the pre-built ROM or -disk images. - -All source code and distributions are maintained on GitHub. Code -contributions are very welcome. - - - -INSTALLATION & OPERATION - - -In general, installation of RomWBW on your platform is very simple. You -just need to program your ROM with the correct ROM image from the RomWBW -distribution. Subsequently, you can write disk images on your disk -drives (IDE disk, CF Card, SD Card, etc.) which then provides even more -functionality. - -Complete instructions for installation and operation of RomWBW are found -in the RomWBW User Guide. - -Documentation - -Documentation for RomWBW includes: - -- RomWBW User Guide -- RomWBW System Guide -- RomWBW Applications -- RomWBW Errata - - - -ACKNOWLEDGMENTS - - -I want to acknowledge that a great deal of the code and inspiration for -RomWBW has been provided by or derived from the work of others in the -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. - -- 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. - -- 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. - -- 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. - -- 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. - -- 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. - -- Phillip Stevens contributed support for FreeRTOS. - -- Curt Mayer contributed the original Linux / MacOS build process. - -- UNA BIOS and FDISK80 are the products of John Coffman. - -- FLASH4 is a product of Will Sowerbutts. - -- CLRDIR is a product of Max Scane. - -- Tasty Basic is a product of Dimitri Theulings. - -- 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. - -- 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. - -- Mark Pruden has also contributed a great deal of content to the User - Guide as well as the COPYSL utility. - -- 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. - -- 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. - -- 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. - -- Lars Nelson has contributed several generic utilities such as a - universal (OS agnostic) UNARC application. - -- Dylan Hall added support for specifying a secondary console. - -- Bill Shen has contributed boot loaders for several of his systems. - -- 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. - -- Les Bird has contributed support for the NABU w/ Option Board - -Contributions of all kinds to RomWBW are very welcome. - - - -LICENSING - - -RomWBW is free software: you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation, either version 3 of the License, or (at your -option) any later version. - -RomWBW is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -more details. - -You should have received a copy of the GNU General Public License along -with RomWBW. If not, see https://www.gnu.org/licenses/. - -Portions of RomWBW were created by, contributed by, or derived from the -work of others. It is believed that these works are being used in -accordance with the intentions and/or licensing of their creators. - -If anyone feels their work is being used outside of its intended -licensing, please notify: - - Wayne Warthen - wwarthen@gmail.com - -RomWBW is an aggregate work. It is composed of many individual, -standalone programs that are distributed as a whole to function as a -cohesive system. Each program may have its own licensing which may be -different from other programs within the aggregate. - -In some cases, a single program (e.g., CP/M Operating System) is -composed of multiple components with different licenses. It is believed -that in all such cases the licenses are compatible with GPL version 3. - -RomWBW encourages code contributions from others. Contributors may -assert their own copyright in their contributions by annotating the -contributed source code appropriately. Contributors are further -encouraged to submit their contributions via the RomWBW source code -control system to ensure their contributions are clearly documented. - -All contributions to RomWBW are subject to this license. - - - -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 - -Submission of issues and bugs are welcome at the RomWBW GitHub -Repository. - -Also feel free to email Wayne Warthen at wwarthen@gmail.com. +RomWBW ReadMe +Wayne Warthen (wwarthen@gmail.com) +13 Oct 2024 + + + +OVERVIEW + + +RomWBW software provides a complete, commercial quality implementation +of CP/M (and workalike) operating systems and applications for modern +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/) + +A complete list of the currently supported platforms is found in the +[Installation] section. + +General features 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 +- OSes: CP/M 2.2, ZSDOS, CP/M 3, NZ-COM, ZPM3, QPM, p-System, and + FreeRTOS +- Built-in VT-100 terminal emulation support + +RomWBW is distributed as both source code and pre-built ROM and disk +images. 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 + +A dynamic disk drive letter assignment mechanism allows mapping +operating system drive letters to any available disk media. +Additionally, mass storage devices (IDE Disk, CF Card, SD Card, etc.) +support the use of multiple slices (up to 256 per device). Each slice +contains a complete CP/M filesystem and can be mapped independently to +any drive letter. This overcomes the inherent size limitations in legacy +OSes and allows up to 2GB of accessible storage on a single device. + +The pre-built ROM firmware images are generally suitable for most users. +However, it is also very easy to modify and build custom ROM images that +fully tailor the firmware to your specific preferences. All tools +required to build custom ROM firmware under Windows are included – no +need to install assemblers, etc. The firmware can also be built using +Linux or MacOS after confirming a few standard tools have been +installed. + +Multiple disk images are provided in the distribution. Most disk images +contain a complete, bootable, ready-to-run implementation of a specific +operating system. A “combo” disk image contains multiple slices, each +with a full operating system implementation. If you use this disk image, +you can easily pick whichever operating system you want to boot without +changing media. + +By design, RomWBW isolates all of the hardware specific functions in the +ROM chip itself. The ROM provides a hardware abstraction layer such that +all of the operating systems and applications on a disk will run on any +RomWBW-based system. To put it simply, you can take a disk (or CF/SD/USB +Card) and move it between systems transparently. + +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 +slices or on stand-alone media. This makes exchanging files with modern +OSes such as Windows, MacOS, and Linux very easy. + + + +ACQUIRING ROMWBW + + +The RomWBW Repository (https://github.com/wwarthen/RomWBW) on GitHub is +the official distribution location for all project source and +documentation. The fully-built distribution releases are available on +the RomWBW Releases Page (https://github.com/wwarthen/RomWBW/releases) +of the repository. On this page, you will normally see a Development +Snapshot as well as recent stable releases. Unless you have a specific +reason, I suggest you stick to the most recent stable release. Expand +the “Assets” drop-down for the release you want to download, then select +the asset named RomWBW-vX.X.X-Package.zip. The Package asset includes +all pre-built ROM and Disk images as well as full source code. The other +assets contain only source code and do not have the pre-built ROM or +disk images. + +All source code and distributions are maintained on GitHub. Code +contributions are very welcome. + + + +INSTALLATION & OPERATION + + +In general, installation of RomWBW on your platform is very simple. You +just need to program your ROM with the correct ROM image from the RomWBW +distribution. Subsequently, you can write disk images on your disk +drives (IDE disk, CF Card, SD Card, etc.) which then provides even more +functionality. + +Complete instructions for installation and operation of RomWBW are found +in the RomWBW User Guide. + + +Documentation + +Documentation for RomWBW includes: + +- RomWBW User Guide +- RomWBW System Guide +- RomWBW Applications +- RomWBW Errata + + + +ACKNOWLEDGMENTS + + +I want to acknowledge that a great deal of the code and inspiration for +RomWBW has been provided by or derived from the work of others in the +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. + +- 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. + +- 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. + +- 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. + +- 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. + +- 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. + +- Phillip Stevens contributed support for FreeRTOS. + +- Curt Mayer contributed the original Linux / MacOS build process. + +- UNA BIOS and FDISK80 are the products of John Coffman. + +- FLASH4 is a product of Will Sowerbutts. + +- CLRDIR is a product of Max Scane. + +- Tasty Basic is a product of Dimitri Theulings. + +- 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. + +- 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. + +- Mark Pruden has also contributed a great deal of content to the User + Guide as well as the COPYSL utility. + +- 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. + +- 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. + +- 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. + +- Lars Nelson has contributed several generic utilities such as a + universal (OS agnostic) UNARC application. + +- Dylan Hall added support for specifying a secondary console. + +- Bill Shen has contributed boot loaders for several of his systems. + +- 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. + +- Les Bird has contributed support for the NABU w/ Option Board + +Contributions of all kinds to RomWBW are very welcome. + + + +LICENSING + + +RomWBW is free software: you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation, either version 3 of the License, or (at your +option) any later version. + +RomWBW is distributed in the hope that it will be useful, but WITHOUT +ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +more details. + +You should have received a copy of the GNU General Public License along +with RomWBW. If not, see https://www.gnu.org/licenses/. + +Portions of RomWBW were created by, contributed by, or derived from the +work of others. It is believed that these works are being used in +accordance with the intentions and/or licensing of their creators. + +If anyone feels their work is being used outside of its intended +licensing, please notify: + + Wayne Warthen + wwarthen@gmail.com + +RomWBW is an aggregate work. It is composed of many individual, +standalone programs that are distributed as a whole to function as a +cohesive system. Each program may have its own licensing which may be +different from other programs within the aggregate. + +In some cases, a single program (e.g., CP/M Operating System) is +composed of multiple components with different licenses. It is believed +that in all such cases the licenses are compatible with GPL version 3. + +RomWBW encourages code contributions from others. Contributors may +assert their own copyright in their contributions by annotating the +contributed source code appropriately. Contributors are further +encouraged to submit their contributions via the RomWBW source code +control system to ensure their contributions are clearly documented. + +All contributions to RomWBW are subject to this license. + + + +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 + +Submission of issues and bugs are welcome at the RomWBW GitHub +Repository. + +Also feel free to email Wayne Warthen at wwarthen@gmail.com. diff --git a/Source/Apps/Build.cmd b/Source/Apps/Build.cmd index 130996b3..4a754e6b 100644 --- a/Source/Apps/Build.cmd +++ b/Source/Apps/Build.cmd @@ -28,6 +28,7 @@ pushd ZMD && call Build || exit /b & popd pushd Dev && call Build || exit /b & popd pushd VGM && call Build || exit /b & popd pushd cpuspd && call Build || exit /b & popd +pushd reboot && call Build || exit /b & popd pushd Survey && call Build || exit /b & popd pushd HTalk && call Build || exit /b & popd pushd BBCBASIC && call Build || exit /b & popd diff --git a/Source/Apps/Clean.cmd b/Source/Apps/Clean.cmd index 6db02516..af7592b0 100644 --- a/Source/Apps/Clean.cmd +++ b/Source/Apps/Clean.cmd @@ -17,6 +17,7 @@ pushd ZMD && call Clean || exit /b 1 & popd pushd Dev && call Clean || exit /b 1 & popd pushd VGM && call Clean || exit /b 1 & popd pushd cpuspd && call Clean || exit /b 1 & popd +pushd reboot && call Clean || exit /b 1 & popd pushd Survey && call Clean || exit /b 1 & popd pushd HTalk && call Clean || exit /b 1 & popd pushd BBCBASIC && call Clean || exit /b 1 & popd diff --git a/Source/Apps/Makefile b/Source/Apps/Makefile index 8c2a2a5e..ebc293f6 100644 --- a/Source/Apps/Makefile +++ b/Source/Apps/Makefile @@ -1,6 +1,6 @@ OBJECTS = sysgen.com syscopy.com assign.com format.com talk.com \ mode.com rtc.com timer.com rtchb.com -SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd Survey BBCBASIC copysl +SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd reboot Survey BBCBASIC copysl DEST = ../../Binary/Apps TOOLS =../../Tools diff --git a/Source/Apps/reboot/Build.cmd b/Source/Apps/reboot/Build.cmd new file mode 100644 index 00000000..cb64d1fe --- /dev/null +++ b/Source/Apps/reboot/Build.cmd @@ -0,0 +1,10 @@ +@echo off +setlocal + +set TOOLS=../../../Tools +set PATH=%TOOLS%\tasm32;%PATH% +set TASMTABS=%TOOLS%\tasm32 + +tasm -t180 -g3 -fFF reboot.asm reboot.com reboot.lst || exit /b + +copy /Y reboot.com ..\..\..\Binary\Apps\ || exit /b diff --git a/Source/Apps/reboot/Clean.cmd b/Source/Apps/reboot/Clean.cmd new file mode 100644 index 00000000..9ecb428f --- /dev/null +++ b/Source/Apps/reboot/Clean.cmd @@ -0,0 +1,6 @@ +@echo off +setlocal + +if exist *.com del *.com +if exist *.lst del *.lst +if exist *.bin del *.bin diff --git a/Source/Apps/reboot/Makefile b/Source/Apps/reboot/Makefile new file mode 100644 index 00000000..b3b30efc --- /dev/null +++ b/Source/Apps/reboot/Makefile @@ -0,0 +1,7 @@ +OBJECTS = reboot.com +DEST = ../../../Binary/Apps +TOOLS =../../../Tools + +USETASM=1 + +include $(TOOLS)/Makefile.inc \ No newline at end of file diff --git a/Source/Apps/reboot/reboot.asm b/Source/Apps/reboot/reboot.asm new file mode 100644 index 00000000..702a38f9 --- /dev/null +++ b/Source/Apps/reboot/reboot.asm @@ -0,0 +1,299 @@ +;============================================================================== +; REBOOT - Allows the user to Cold or Warm Boot the RomWBW System +; Version 1.0 12-October-2024 +;============================================================================== +; +; Author: MartinR (October 2024) +; Based **very heavily** on code by Wayne Warthen (wwarthen@gmail.com) +;______________________________________________________________________________ +; +; Usage: +; REBOOT [/C] [/W] [/?] +; ex: REBOOT Display version and usage +; REBOOT /? Display version and usage +; REBOOT /C Cold boot RomWBW system +; REBOOT /W Warm boot RomWBW system +; +; Operation: +; Cold or warm boots a RomWBW system depending on the user option selected. +; +; This code will only execute on a Z80 CPU (or derivitive) +; +; This source code assembles with TASM V3.2 under Windows-11 using the +; following command line: +; tasm -80 -g3 -l REBOOT.ASM REBOOT.COM +; ie: Z80 CPU; output format 'binary' named .COM (rather than .OBJ) +; and includes a symbol table as part of the listing file. +;______________________________________________________________________________ +; +; Change Log: +; 2024-09-11 [WBW] Release of RomWBW CPU Speed Selector v1.0 used as the basis +; 2024-10-12 [MR ] Initial release of version 1.0 +;______________________________________________________________________________ +; +; Include Files +; +#include "../../ver.inc" ; Used for building RomWBW +#include "../../HBIOS/hbios.inc" + +;#include "ver.inc" ; Used for testing purposes.... +;#include "hbios.inc" ; ....during code development +; +;=============================================================================== +; +; 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 +; +bf_sysreset .equ $F0 ; restart system +bf_sysres_int .equ $00 ; reset hbios internal +bf_sysres_warm .equ $01 ; warm start (restart boot loader) +bf_sysres_cold .equ $02 ; cold start +; +ident .equ $FFFE ; loc of RomWBW HBIOS ident ptr +; +;=============================================================================== +; + .org $0100 ; standard CP/M TPA executable +; + ; setup stack (save old value) + ld (stksav),sp ; save stack + ld sp,stack ; set new stack +; + call crlf + ld de,str_banner ; banner + call prtstr +; + ; initialization + call init ; initialize + jr nz,exit ; abort if init fails +; + call main ; do the real work +; +exit: + ; clean up and return to command processor + call crlf ; formatting + ld sp,(stksav) ; restore stack + jp restart ; return to CP/M via restart +; +; +;=============================================================================== +; Main Program +;=============================================================================== +; +; 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: + ; skip to start of first command line parameter + ld ix,$0081 ; point to start of parm area (past length byte) + call nonblank ; skip to next non-blank char + cp '/' ; option prefix? + jr nz,usage ; display help info & exit if nothing to do +; + ; process any options + inc ix ; fetch next character and process + ld a,(ix) + call upcase ; ensure it's an upper case character + cp 'C' ; if it's a 'C' then + jr z,cboot ; do a cold boot. + cp 'W' ; if it's a 'W' then + jr z,wboot ; do a warm boot. + cp '?' ; if it's a '?' then + jr z,usage ; display usage info and exit. + jr err_parm ; or not a recognised option, so report and exit. +; +; Handle Usage Information +; +usage: + call crlf2 ; display the options for this utility + ld de,str_usage + call prtstr + or $FF + ret ; exit back out to CP/M CCP +; +; Handle Warm Boot +; +wboot: + ld de,str_warmboot ; message + call prtstr ; display it + ld b,bf_sysreset ; system restart + ld c,bf_sysres_warm ; warm start + call $fff0 ; call hbios +; +; Handle Cold Boot +; +cboot: + ld de,str_coldboot ; message + call prtstr ; display it + ld b,bf_sysreset ; system restart + ld c,bf_sysres_cold ; cold start + call $fff0 ; call hbios +; +;=============================================================================== +; 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_ret: + call crlf2 + call prtstr + or $FF ; signal error + ret +; +;=============================================================================== +; Utility Routines +;=============================================================================== +; +; Print character in A without destroying any registers +; +prtchr: + push af + push bc ; save registers + 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 new line +; +crlf2: + call crlf ; two of them +crlf: + push af ; preserve AF + ld a,13 ; + call prtchr ; print it + ld a,10 ; + 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 +; +; Get the next non-blank character from (ix) +; +nonblank: + ld a,(ix) ; load next character + or a ; string ends with a null + ret z ; if null, return pointing to null + cp ' ' ; check for blank + ret nz ; return if not blank + inc ix ; if blank, increment character pointer + jr nonblank ; 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 +; +;=============================================================================== +; Constants +;=============================================================================== +; +str_banner .db "RomWBW Reboot Utility, Version 1.0, 12-Oct-2024\r\n" + .db " Wayne Warthen (wwarthen@gmail.com) & MartinR",0 +; +str_warmboot .db "\r\n\r\nWarm booting...\r\n",0 +str_coldboot .db "\r\n\r\nCold booting...\r\n",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 (REBOOT /? for usage)",0 +; +str_usage .db " Usage: REBOOT /? - Display this help info.\r\n" + .db " REBOOT /W - Warm boot system\r\n" + .db " REBOOT /C - Cold boot system\r\n" + .db " Options are case insensitive.\r\n",0 +; +;=============================================================================== +; Working data +;=============================================================================== +; +stksav .dw 0 ; stack pointer saved at start + .fill stksiz,0 ; stack +stack .equ $ ; stack top +; +;=============================================================================== +; + .end \ No newline at end of file diff --git a/Source/Doc/Applications.md b/Source/Doc/Applications.md index 74645de9..fbac6e99 100644 --- a/Source/Doc/Applications.md +++ b/Source/Doc/Applications.md @@ -403,7 +403,7 @@ CP/M, while others rely on particular hardware or aspects of RomWBW itself. Those that are written specific to RomWBW include: ASSIGN, -CPUSPD, FDU, FORMAT, FLASH, FDISK80, MODE, RTC, SYSCOPY, +CPUSPD, FDU, FORMAT, FLASH, FDISK80, MODE, REBOOT, RTC, SYSCOPY, TALK, TIMER, XM, and COPYSL. The CP/M utilities supplied with RomWBW warrant more detailed descriptions, @@ -905,6 +905,7 @@ incuded within RomWBW may be found with in the Binary/Apps directory. | FORMAT | Yes | Yes | | HTALK | Yes | Yes | | MODE | Yes | Yes | +| REBOOT | Yes | Yes | | RTC | Yes | Yes | | SURVEY | Yes | Yes | | SYSCOPY | Yes | Yes | @@ -918,7 +919,7 @@ incuded within RomWBW may be found with in the Binary/Apps directory. All of the CP/M applications may be found in the RomWBW Binary/Apps directory and a user may copy those they need to their own customised disk/slice. -Independantly of whether the CP/M system was started from ROM or a boot disk, +Independently of whether the CP/M system was started from ROM or a boot disk, such as a floppy disk or a slice on a CF or uSD memory card, applications may be located on and executed from either the ROM-disk itself or from other media. There are multiple disk images available for CP/M (eg floppy, legacy hard-disk and new @@ -1753,6 +1754,50 @@ provided in the RomWBW distribution. `\clearpage`{=latex} +## REBOOT + +| REBOOT | | +| --------------------|---| +| ROM-based |Yes| +| Disk-based |Yes| + +The `REBOOT` application is used to restart a running system from an +operating system prompt. It can invoke either a warm or cold restart +via command line switches. + +#### Syntax + +| `REBOOT /W` +| `REBOOT /C` +| `REBOOT /?` + +- /C initiates a cold restart +- /W initiates a warm restart +- /? displays command line usage + +#### Usage + +Entering `REBOOT` with no parameters will display the usage and +version information. Use /C or /W to immediately initiate a +cold or warm restart. + +#### Notes + +A warm restart just returns to the Boot Loader menu. + +A cold restart will reinitialize the system as though power had +been recycled. + +#### Etymology + +The `REBOOT` application was custom written for RomWBW by MartinR. All +of the hardware interface code is specific to RomWBW and the application +will not operate correctly on non-RomWBW systems. + +The source code is provided in the RomWBW distribution. + +`\clearpage`{=latex} + ## RTC | RTC | | diff --git a/Source/Images/fd_bp.txt b/Source/Images/fd_bp.txt index 0fbfb8d0..53234ff5 100644 --- a/Source/Images/fd_bp.txt +++ b/Source/Images/fd_bp.txt @@ -12,6 +12,7 @@ #../../Binary/Apps/*.com 15: ../../Binary/Apps/assign.com 15: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/fat.com 15: ../../Binary/Apps/fdu.com 15: ../../Binary/Apps/fdu.doc 15: diff --git a/Source/Images/fd_cpm22.txt b/Source/Images/fd_cpm22.txt index e83c35b3..a1c8964c 100644 --- a/Source/Images/fd_cpm22.txt +++ b/Source/Images/fd_cpm22.txt @@ -8,6 +8,7 @@ d_cpm22/ReadMe.txt 0: #../../Binary/Apps/*.com 0: ../../Binary/Apps/assign.com 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/fat.com 0: ../../Binary/Apps/fdu.com 0: ../../Binary/Apps/fdu.doc 0: diff --git a/Source/Images/fd_cpm3.txt b/Source/Images/fd_cpm3.txt index d932c40f..ee2fe4f8 100644 --- a/Source/Images/fd_cpm3.txt +++ b/Source/Images/fd_cpm3.txt @@ -24,6 +24,7 @@ #../../Binary/Apps/*.com 0: ../../Binary/Apps/assign.com 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/fat.com 0: ../../Binary/Apps/fdu.com 0: ../../Binary/Apps/fdu.doc 0: diff --git a/Source/Images/fd_nzcom.txt b/Source/Images/fd_nzcom.txt index 96f4ba01..5ce162f6 100644 --- a/Source/Images/fd_nzcom.txt +++ b/Source/Images/fd_nzcom.txt @@ -14,6 +14,7 @@ d_cpm22/u0/XSUB.COM 15: #../../Binary/Apps/*.com 15: ../../Binary/Apps/assign.com 15: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/fat.com 15: ../../Binary/Apps/fdu.com 15: ../../Binary/Apps/rtc.com 15: diff --git a/Source/Images/fd_qpm.txt b/Source/Images/fd_qpm.txt index 6aeaae6a..9759f4cf 100644 --- a/Source/Images/fd_qpm.txt +++ b/Source/Images/fd_qpm.txt @@ -12,6 +12,7 @@ d_cpm22/u0/*.* 0: #../../Binary/Apps/*.com 0: ../../Binary/Apps/assign.com 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/fat.com 0: ../../Binary/Apps/fdu.com 0: ../../Binary/Apps/fdu.doc 0: diff --git a/Source/Images/fd_zpm3.txt b/Source/Images/fd_zpm3.txt index efc30026..2175a1c3 100644 --- a/Source/Images/fd_zpm3.txt +++ b/Source/Images/fd_zpm3.txt @@ -23,6 +23,7 @@ #../../Binary/Apps/*.com 15: ../../Binary/Apps/assign.com 15: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/fat.com 15: ../../Binary/Apps/fdu.com 15: #../../Binary/Apps/fdu.doc 15: diff --git a/Source/Images/fd_zsdos.txt b/Source/Images/fd_zsdos.txt index 42af49e3..719d41b6 100644 --- a/Source/Images/fd_zsdos.txt +++ b/Source/Images/fd_zsdos.txt @@ -21,6 +21,7 @@ d_cpm22/u0/XSUB.COM 0: #../../Binary/Apps/*.com 0: ../../Binary/Apps/assign.com 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/fat.com 0: ../../Binary/Apps/fdu.com 0: ../../Binary/Apps/fdu.doc 0: diff --git a/Source/Images/hd_bp.txt b/Source/Images/hd_bp.txt index 14a04378..49459a31 100644 --- a/Source/Images/hd_bp.txt +++ b/Source/Images/hd_bp.txt @@ -14,6 +14,7 @@ ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 15: diff --git a/Source/Images/hd_cpm22.txt b/Source/Images/hd_cpm22.txt index 9b9cca8b..6dff8024 100644 --- a/Source/Images/hd_cpm22.txt +++ b/Source/Images/hd_cpm22.txt @@ -10,6 +10,7 @@ d_cpm22/ReadMe.txt 0: ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 0: diff --git a/Source/Images/hd_cpm3.txt b/Source/Images/hd_cpm3.txt index 9f49c67f..49ef0ec5 100644 --- a/Source/Images/hd_cpm3.txt +++ b/Source/Images/hd_cpm3.txt @@ -26,6 +26,7 @@ ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 0: diff --git a/Source/Images/hd_nzcom.txt b/Source/Images/hd_nzcom.txt index 1a35ebb8..5d0b07a7 100644 --- a/Source/Images/hd_nzcom.txt +++ b/Source/Images/hd_nzcom.txt @@ -33,6 +33,7 @@ d_zsdos/u0/*.DAT 15: ../../Binary/Apps/bbcbasic.com 15: ../../Binary/Apps/bbcbasic.txt 10: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 15: diff --git a/Source/Images/hd_qpm.txt b/Source/Images/hd_qpm.txt index f97b1cba..ab16a818 100644 --- a/Source/Images/hd_qpm.txt +++ b/Source/Images/hd_qpm.txt @@ -14,6 +14,7 @@ d_cpm22/u0/*.* 0: ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 0: diff --git a/Source/Images/hd_zpm3.txt b/Source/Images/hd_zpm3.txt index c47f9164..c22ecb9d 100644 --- a/Source/Images/hd_zpm3.txt +++ b/Source/Images/hd_zpm3.txt @@ -25,6 +25,7 @@ ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 15: +../../Binary/Apps/reboot.com 15: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 15: diff --git a/Source/Images/hd_zsdos.txt b/Source/Images/hd_zsdos.txt index 97b89c6b..82440d53 100644 --- a/Source/Images/hd_zsdos.txt +++ b/Source/Images/hd_zsdos.txt @@ -23,6 +23,7 @@ d_cpm22/u0/XSUB.COM 0: ../../Binary/Apps/bbcbasic.com 0: ../../Binary/Apps/bbcbasic.txt 0: ../../Binary/Apps/cpuspd.com 0: +../../Binary/Apps/reboot.com 0: ../../Binary/Apps/copysl.com 0: ../../Binary/Apps/copysl.doc 0: ../../Binary/Apps/fat.com 0: diff --git a/Source/RomDsk/Build.cmd b/Source/RomDsk/Build.cmd index 1d094702..e069c5a4 100644 --- a/Source/RomDsk/Build.cmd +++ b/Source/RomDsk/Build.cmd @@ -10,7 +10,7 @@ set TASMTABS=%TOOLS%\tasm32 set CPMDIR80=%TOOLS%/cpm/ set RomApps1=assign mode rtc syscopy xm -set RomApps2=fdu format survey sysgen talk timer cpuspd +set RomApps2=fdu format survey sysgen talk timer cpuspd reboot :: :: Make all variants of the ROM Disk contents image. Three sizes are diff --git a/Source/RomDsk/Makefile b/Source/RomDsk/Makefile index 1f067db1..bddab70a 100644 --- a/Source/RomDsk/Makefile +++ b/Source/RomDsk/Makefile @@ -7,7 +7,7 @@ include $(TOOLS)/Makefile.inc .SHELLFLAGS = -ce ROMAPPS1 := assign mode rtc syscopy xm -ROMAPPS2 := fdu format survey sysgen talk timer cpuspd +ROMAPPS2 := fdu format survey sysgen talk timer cpuspd reboot rom128_%.dat: DISKDEF=wbw_rom128 rom256_%.dat: DISKDEF=wbw_rom256