Browse Source

Merge pull request #66 from wwarthen/master

Resync
pull/459/head
b1ackmai1er 1 year ago
committed by GitHub
parent
commit
02895a7d84
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 142
      .gitignore
  2. 4
      .vscode/settings.json
  3. 1
      Binary/Apps/Clean.cmd
  4. 2
      Binary/Apps/Makefile
  5. 44
      Binary/Apps/Test/inttest.doc
  6. 4
      Binary/CPM22/Clean.cmd
  7. 7
      Binary/CPM22/Makefile
  8. 23
      Binary/CPM22/ReadMe.txt
  9. 3
      Binary/Clean.cmd
  10. 2
      Binary/Makefile
  11. 4
      Binary/QPM/Clean.cmd
  12. 7
      Binary/QPM/Makefile
  13. 21
      Binary/QPM/ReadMe.txt
  14. 165
      Binary/ReadMe.txt
  15. 4
      Binary/ZSDOS/Clean.cmd
  16. 7
      Binary/ZSDOS/Makefile
  17. 23
      Binary/ZSDOS/ReadMe.txt
  18. 0
      Doc/CPM/CPM Manual.pdf
  19. 0
      Doc/CPM/CPM3 Command Summary.pdf
  20. 0
      Doc/CPM/CPM3 Programmers Guide.pdf
  21. 0
      Doc/CPM/CPM3 System Guide.pdf
  22. 0
      Doc/CPM/CPM3 Users Guide.pdf
  23. 0
      Doc/CPM/NZCOM Users Manual.pdf
  24. 70
      Doc/CPM/ReadMe.txt
  25. BIN
      Doc/CPM/Z-System Users Guide.pdf
  26. 6773
      Doc/CPM/Z3PLUS Users Manual.pdf
  27. 0
      Doc/CPM/ZCPR Manual.pdf
  28. 0
      Doc/CPM/ZCPR-DJ.doc
  29. BIN
      Doc/CPM/ZCPR3.3 User Guide.pdf
  30. 0
      Doc/CPM/ZSDOS Manual.pdf
  31. 0
      Doc/CPM/qcp27.pdf
  32. 0
      Doc/CPM/qdos27.pdf
  33. 0
      Doc/CPM/qpm27.pdf
  34. 36
      Doc/ChangeLog.txt
  35. BIN
      Doc/Contrib/AY-3-8910 Registers.xlsx
  36. 6
      Doc/Contrib/ZSystem.txt
  37. BIN
      Doc/Hard Disk Anatomy.pdf
  38. 0
      Doc/Language/Aztec_C_1.06_User_Manual_Mar84.pdf
  39. 0
      Doc/Language/Cowgol Language.pdf
  40. 0
      Doc/Language/HI-TECH Z80 C Compiler Manual.txt
  41. 0
      Doc/Language/Microsoft Basic-80 Reference Manual v5.0.pdf
  42. 0
      Doc/Language/Microsoft_FORTRAN-80_Users_Manual_1977.pdf
  43. 62
      Doc/Language/ReadMe.txt
  44. 0
      Doc/Language/Turbo_Pascal_Version_3.0_Reference_Manual_1986.pdf
  45. 0
      Doc/Language/z80asm (SLR Systems).pdf
  46. 107
      Doc/ReadMe.txt
  47. BIN
      Doc/RomWBW Applications.pdf
  48. BIN
      Doc/RomWBW Disk Catalog.pdf
  49. BIN
      Doc/RomWBW Errata.pdf
  50. BIN
      Doc/RomWBW ROM Applications.pdf
  51. BIN
      Doc/RomWBW System Guide.pdf
  52. BIN
      Doc/RomWBW User Guide.pdf
  53. 144
      Doc/Testing Notes.txt
  54. BIN
      Doc/The Cowgol language.pdf
  55. 48
      Dockerfile
  56. 2
      Makefile
  57. 24
      ReadMe.md
  58. 13
      ReadMe.txt
  59. 23
      Source/Apps/BBCBASIC/Build.cmd
  60. 9
      Source/Apps/BBCBASIC/Clean.cmd
  61. 11
      Source/Apps/BBCBASIC/Makefile
  62. 1010
      Source/Apps/BBCBASIC/asmb.z80
  63. 455
      Source/Apps/BBCBASIC/bbcbasic.txt
  64. 1494
      Source/Apps/BBCBASIC/cmos.z80
  65. 69
      Source/Apps/BBCBASIC/data.z80
  66. 241
      Source/Apps/BBCBASIC/dist.z80
  67. 2587
      Source/Apps/BBCBASIC/eval.z80
  68. 3274
      Source/Apps/BBCBASIC/exec.z80
  69. 64
      Source/Apps/BBCBASIC/hook.z80
  70. 2237
      Source/Apps/BBCBASIC/main.z80
  71. 2267
      Source/Apps/BBCBASIC/math.z80
  72. 62
      Source/Apps/Build.cmd
  73. 45
      Source/Apps/Clean.cmd
  74. 8
      Source/Apps/Makefile
  75. 4
      Source/Apps/Test/2piotst/Build.cmd
  76. 50
      Source/Apps/Test/Build.cmd
  77. 1
      Source/Apps/Test/Clean.cmd
  78. 6
      Source/Apps/Test/I2C/Build.cmd
  79. 6
      Source/Apps/Test/Makefile
  80. 3
      Source/Apps/Test/inttest/Build.cmd
  81. 2
      Source/Apps/Test/inttest/Makefile
  82. 6
      Source/Apps/Test/inttest/inttest.asm
  83. 44
      Source/Apps/Test/inttest/inttest.doc
  84. 2
      Source/Apps/Test/kbdtest/Build.cmd
  85. 2
      Source/Apps/Test/piomon/Build.cmd
  86. 2
      Source/Apps/Test/ppidetst/Build.cmd
  87. 2
      Source/Apps/Test/ps2info/Build.cmd
  88. 19
      Source/Apps/Test/ps2info/ps2info.asm
  89. 2
      Source/Apps/Test/ramtest/Makefile
  90. 10
      Source/Apps/Test/testh8p/Build.cmd
  91. 6
      Source/Apps/Test/testh8p/Clean.cmd
  92. 9
      Source/Apps/Test/testh8p/Makefile
  93. 238
      Source/Apps/Test/testh8p/testh8p.asm
  94. 2
      Source/Apps/Test/tstdskng/Build.cmd
  95. 4
      Source/Apps/Test/vdctest/Build.cmd
  96. 6
      Source/Apps/Tune/Build.cmd
  97. 31
      Source/Apps/Tune/tune.asm
  98. 4
      Source/Apps/VGM/Build.cmd
  99. 12
      Source/Apps/XM/xmdm125.asm
  100. 1972
      Source/Apps/assign.asm

142
.gitignore

@ -77,6 +77,7 @@ Tools/unix/zx/zx
!Source/ver.lib
!Source/Apps/FAT/FAT.COM
!Source/Apps/copysl/copysl.com
!Source/Apps/ZMP/zmpx.com
!Source/Apps/ZMD/zmdsubs.rel
!Source/Apps/Test/vdctest/font.asm
@ -99,6 +100,7 @@ Tools/unix/zx/zx
!Source/ZRC512/*.bin
!Source/Z1RCC/*.bin
!Source/ZZRCC/*.bin
!Source/FZ80/*.bin
!Tools/cpm/**
!Tools/unix/zx/*
!Tools/zx/*
@ -109,4 +111,142 @@ Source/ZPM3/zccp.com
Source/ZPM3/zpmldr.com
Source/ZPM3/genbnk.dat
Source/ZSDOS/zsdos.err
Source/ZSDOS/zsdos.err
# Lets explicit list all generate untracked binary files
Binary/Apps/Tunes/bgm.vgm
Binary/Apps/Tunes/ending.vgm
Binary/Apps/Tunes/inchina.vgm
Binary/Apps/Tunes/shirakaw.vgm
Binary/Apps/Tunes/startdem.vgm
Binary/Apps/Tunes/wonder01.vgm
Binary/Apps/fdu.doc
Binary/Apps/zmconfig.ovr
Binary/Apps/zminit.ovr
Binary/Apps/zmp.doc
Binary/Apps/zmp.hlp
Binary/Apps/zmterm.ovr
Binary/Apps/zmxfer.ovr
Binary/CPM3/bdos3.spr
Binary/CPM3/bios3.spr
Binary/CPM3/bnkbdos3.spr
Binary/CPM3/bnkbios3.spr
Binary/CPM3/cpm3fix.pat
Binary/CPM3/genbnk.dat
Binary/CPM3/gencpm.dat
Binary/CPM3/genres.dat
Binary/CPM3/readme.1st
Binary/CPM3/resbdos3.spr
Binary/CPNET/cpn12duo.lbr
Binary/CPNET/cpn12mt.lbr
Binary/CPNET/cpn12ser.lbr
Binary/CPNET/cpn3duo.lbr
Binary/CPNET/cpn3mt.lbr
Binary/CPNET/cpn3ser.lbr
Binary/RCEZ80_std.upd
Binary/RCZ80_std.upd
Binary/ZPM3/bnkbdos3.spr
Binary/ZPM3/bnkbios3.spr
Binary/ZPM3/gencpm.dat
Binary/ZPM3/resbdos3.spr
Binary/ZPM3/zinstal.zpm
Binary/hd1k_prefix.dat
Source/BPBIOS/def-ww.lib
Source/CPNET/cpn12duo.lbr
Source/CPNET/cpn12mt.lbr
Source/CPNET/cpn12ser.lbr
Source/CPNET/cpn3duo.lbr
Source/CPNET/cpn3mt.lbr
Source/CPNET/cpn3ser.lbr
Source/Fonts/font8x11c.asm
Source/Fonts/font8x11c.bin
Source/Fonts/font8x11u.asm
Source/Fonts/font8x16c.asm
Source/Fonts/font8x16c.bin
Source/Fonts/font8x16u.asm
Source/Fonts/font8x8c.asm
Source/Fonts/font8x8c.bin
Source/Fonts/font8x8u.asm
Source/Fonts/fontcgac.asm
Source/Fonts/fontcgac.bin
Source/Fonts/fontcgau.asm
Source/Fonts/fontvgarcc.asm
Source/Fonts/fontvgarcc.bin
Source/Fonts/fontvgarcu.asm
Source/HBIOS/RCEZ80_std.upd
Source/HBIOS/RCZ80_std.upd
Source/HBIOS/build_env.cmd
Source/HBIOS/hbios_env.sh
Source/Images/blank144
Source/Images/blankhd1k
Source/Images/blankhd512
Source/Images/fd144_aztecc.img
Source/Images/fd144_bascomp.img
Source/Images/fd144_cowgol.img
Source/Images/fd144_cpm22.img
Source/Images/fd144_cpm3.img
Source/Images/fd144_fortran.img
Source/Images/fd144_games.img
Source/Images/fd144_hitechc.img
Source/Images/fd144_nzcom.img
Source/Images/fd144_qpm.img
Source/Images/fd144_tpascal.img
Source/Images/fd144_ws4.img
Source/Images/fd144_z80asm.img
Source/Images/fd144_zpm3.img
Source/Images/fd144_zsdos.img
Source/Images/hd1k_aztecc.img
Source/Images/hd1k_bascomp.img
Source/Images/hd1k_blank.img
Source/Images/hd1k_bp.img
Source/Images/hd1k_combo.img
Source/Images/hd1k_cowgol.img
Source/Images/hd1k_cpm22.img
Source/Images/hd1k_cpm3.img
Source/Images/hd1k_fortran.img
Source/Images/hd1k_games.img
Source/Images/hd1k_hitechc.img
Source/Images/hd1k_nzcom.img
Source/Images/hd1k_qpm.img
Source/Images/hd1k_tpascal.img
Source/Images/hd1k_ws4.img
Source/Images/hd1k_z80asm.img
Source/Images/hd1k_zpm3.img
Source/Images/hd1k_zsdos.img
Source/Images/hd512_aztecc.img
Source/Images/hd512_bascomp.img
Source/Images/hd512_blank.img
Source/Images/hd512_combo.img
Source/Images/hd512_cowgol.img
Source/Images/hd512_cpm22.img
Source/Images/hd512_cpm3.img
Source/Images/hd512_dos65.img
Source/Images/hd512_fortran.img
Source/Images/hd512_games.img
Source/Images/hd512_hitechc.img
Source/Images/hd512_nzcom.img
Source/Images/hd512_qpm.img
Source/Images/hd512_tpascal.img
Source/Images/hd512_ws4.img
Source/Images/hd512_z80asm.img
Source/Images/hd512_zpm3.img
Source/Images/hd512_zsdos.img
Source/RomDsk/rom0_una.dat
Source/RomDsk/rom0_wbw.dat
Source/RomDsk/rom128_una.dat
Source/RomDsk/rom128_wbw.dat
Source/RomDsk/rom256_una.dat
Source/RomDsk/rom256_wbw.dat
Source/RomDsk/rom384_una.dat
Source/RomDsk/rom384_wbw.dat
Source/RomDsk/rom896_una.dat
Source/RomDsk/rom896_wbw.dat
Source/ZCPR-DJ/zcprdemo.com
Source/ZPM3/autotog.com
Source/ZPM3/clrhist.com
Source/ZPM3/cpmldr.com
Source/ZPM3/setz3.com
Tools/unix/OpenSpin/build/
Tools/unix/zxcc/config.h
Tools/unix/zxcc/zxcc
Binary/Apps/bbcbasic.txt

4
.vscode/settings.json

@ -0,0 +1,4 @@
{
"files.trimTrailingWhitespace": false,
"files.eol": "\r\n"
}

1
Binary/Apps/Clean.cmd

@ -8,5 +8,6 @@ if exist *.hlp del *.hlp
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
pushd Test && call Clean || exit /b 1 & popd

2
Binary/Apps/Makefile

@ -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
@rm -f *.bin *.com *.img *.rom *.pdf *.log *.eeprom *.ovr *.hlp *.doc *.COM *.BIN Tunes/*.mym Tunes/*.pt? Tunes/*.vgm bbcbasic.txt

44
Binary/Apps/Test/inttest.doc

@ -0,0 +1,44 @@
INTTEST
=======
RomWBW includes an API allowing applications to "hook" interrupts.
The `INTTEST` utility allows you to test this functionality.
** Syntax **
`INTTEST`
** Usage **
`INTTEST` is an interactive application. At startup, it will display
a list of the interrupt vector slots in your system along with the
current vector address for each of them.
It then prompts you to enter the slot number (in hex) of a vector to
hook. After entering this, the application will watch the hooked
vector and countdown from 0xFF to 0x00 as interrupts are noted.
When the counter reaches 0x00, the interrupt is unhooked and the
application terminates. The application can also be terminated by
pressing <esc>.
** Notes **
If your system is running without interrupts active, the application
will terminate immediately.
All slots have vectors even if the corresponding interrupt is not
doing anything. In this case, the vector is pointing to the "bad
interrupt" handler.
If you hook a vector that is not receiving any interrupts, the
down-counter will not do anything.
** Etymology* *
The `INTTEST` command is an original product and the source code is
provided in the RomWBW distribution.

4
Binary/CPM22/Clean.cmd

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

7
Binary/CPM22/Makefile

@ -0,0 +1,7 @@
TOOLS = ../../Tools
MOREDIFF := $(shell $(TOOLS)/unix/casefn.sh *.spr)
include $(TOOLS)/Makefile.inc
clean::
@rm -f *.sys

23
Binary/CPM22/ReadMe.txt

@ -0,0 +1,23 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory contains the CP/M 2.2 system files for the RomWBW CP/M 2.2
adaptation. All of these files are already included on the CP/M
boot disk images. However if you are creating a CP/M boot disk
manually, you should copy all of these files to the boot disk.
Note: Two file have been provided one for RomWBW HBIOS, and one for UNA
BIOS. One of these files must be installed on the system boot track.
This is usually achieved by the SYSCOPY utility e.g.
SYSCOPY a:=cpm_wbw.sys
These files should also be copied to any CP/M 2.2 boot disks on your
system when you upgrade your ROM firmware. Some of these files
*must* match the version of the RomWBW firmware you are using for
proper operation of your system.

3
Binary/Clean.cmd

@ -12,6 +12,9 @@ if exist *.pdf del *.pdf
if exist *.eeprom del *.eeprom
pushd Apps && call Clean || exit /b 1 & popd
pushd CPM22 && call Clean || exit /b 1 & popd
pushd CPM3 && call Clean || exit /b 1 & popd
pushd QPM && call Clean || exit /b 1 & popd
pushd ZSDOS && call Clean || exit /b 1 & popd
pushd ZPM3 && call Clean || exit /b 1 & popd
pushd CPNET && call Clean || exit /b 1 & popd

2
Binary/Makefile

@ -1,6 +1,6 @@
TOOLS = ../Tools
MOREDIFF := $(shell $(TOOLS)/unix/casefn.sh *.img *.rom *.com *.eeprom)
SUBDIRS = Apps CPM3 ZPM3 CPNET
SUBDIRS = Apps CPM22 CPM3 QPM ZSDOS ZPM3 CPNET
include $(TOOLS)/Makefile.inc

4
Binary/QPM/Clean.cmd

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

7
Binary/QPM/Makefile

@ -0,0 +1,7 @@
TOOLS = ../../Tools
MOREDIFF := $(shell $(TOOLS)/unix/casefn.sh *.spr)
include $(TOOLS)/Makefile.inc
clean::
@rm -f *.sys *.bin

21
Binary/QPM/ReadMe.txt

@ -0,0 +1,21 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory contains the QPM 2.7 system files for the RomWBW QPM 2.7
adaptation. All of these files are already included on the QPM
boot disk images. However if you are creating a QPM boot disk
manually, you should copy all of these files to the boot disk.
Note: Two file have been provided one for RomWBW HBIOS, and one for UNA
BIOS. One of these files must be installed on the system boot track.
Refer to the QPM Documentation for installing QPM
These files should also be copied to any QPM boot disks on your
system when you upgrade your ROM firmware. Some of these files
*must* match the version of the RomWBW firmware you are using for
proper operation of your system.

165
Binary/ReadMe.txt

@ -6,37 +6,37 @@
*** ***
***********************************************************************
This directory ("Binary") is part of the RomWBW System Software
distribution archive. It contains the completed binary outputs of
the build process. As described below, these files are used to
This directory ("Binary") is part of the RomWBW System Software
distribution archive. It contains the completed binary outputs of
the build process. As described below, these files are used to
assemble a working RetroBrew Computers system.
The files in this directory are created by the build process that is
documented in the ReadMe.txt file in the Source directory. When
released the directory is populated with the default output files.
However, the output of custom builds will be placed in this directory
The files in this directory are created by the build process that is
documented in the ReadMe.txt file in the Source directory. When
released the directory is populated with the default output files.
However, the output of custom builds will be placed in this directory
as well.
If you only see a few files in this directory, then you downloaded
just the source from GitHub. To retrieve the full release download
package, go to https://github.com/wwarthen/RomWBW. On this page,
look for the text "XX releases" where XX is a number. Click on this
text to go to the releases page. On this page, you will see the
latest releases listed. For each release, you will see a package
file called something like "RomWBW-2.9.0-Package.zip". Click on the
If you only see a few files in this directory, then you downloaded
just the source from GitHub. To retrieve the full release download
package, go to https://github.com/wwarthen/RomWBW. On this page,
look for the text "XX releases" where XX is a number. Click on this
text to go to the releases page. On this page, you will see the
latest releases listed. For each release, you will see a package
file called something like "RomWBW-2.9.0-Package.zip". Click on the
package file for the release you want to download.
ROM Firmware Images (<plt>_<cfg>.rom)
-------------------------------------
The files with a ".rom" extension are binary images ready to program
into an appropriate PROM. These files are named with the format
<plt>_<cfg>.rom. <plt> refers to the primary platform such as Zeta,
N8, Mark IV, etc. <cfg> refers to the specific configuration. In
general, there will be a standard configuration ("std") for each
platform. So, for example, the file called MK4_std.rom is a ROM
image for the Mark IV with the standard configuration. If a custom
configuration called "custom" is created and built, a new file called
The files with a ".rom" extension are binary images ready to program
into an appropriate PROM. These files are named with the format
<plt>_<cfg>.rom. <plt> refers to the primary platform such as Zeta,
N8, Mark IV, etc. <cfg> refers to the specific configuration. In
general, there will be a standard configuration ("std") for each
platform. So, for example, the file called MK4_std.rom is a ROM
image for the Mark IV with the standard configuration. If a custom
configuration called "custom" is created and built, a new file called
MK4_custom.rom will be added to this directory.
Documentation of the pre-built ROM Images is contained in
@ -54,52 +54,52 @@ contents. Refer to the RomWBW User Guide for more information.
ROM Executable Images (<plt>_<cfg>.com)
---------------------------------------
When a ROM image (".rom") is created, an executable version of the
ROM is also created. These files have the same naming convention as
the ROM Image files, but have the extension ".com". These files can
When a ROM image (".rom") is created, an executable version of the
ROM is also created. These files have the same naming convention as
the ROM Image files, but have the extension ".com". These files can
be copied to a working system and run like a normal CP/M application.
When run on the target system, they install in RAM just like they had
When run on the target system, they install in RAM just like they had
been loaded from ROM. This allows a new ROM build to be tested
without reprogramming the actual ROM.
WARNING: In a few cases the .com file is too big to load. If you get
a message like "Full" or "BAD LOAD" when trying to load one of the
.com files, it is too big. In these cases, you will not be able to
WARNING: In a few cases the .com file is too big to load. If you get
a message like "Full" or "BAD LOAD" when trying to load one of the
.com files, it is too big. In these cases, you will not be able to
test the ROM prior to programming it.
VDU ROM Image (vdu.rom)
-----------------------
The VDU video board requires a dedicated onboard ROM containing the
font data. The "vdu.rom" file contains the binary data to program
The VDU video board requires a dedicated onboard ROM containing the
font data. The "vdu.rom" file contains the binary data to program
onto that chip.
Disk Images (fd_*.img, hd_*.img, psys.img)
------------------------------------------
Disk Images (fd_*.img, hd_*.img)
--------------------------------
RomWBW includes a mechanism for generating floppy disk and hard disk
binary images that are ready to copy directly to a floppy, hard disk,
CF Card, or SD Card which will then be ready for use in any
RomWBW includes a mechanism for generating floppy disk and hard disk
binary images that are ready to copy directly to a floppy, hard disk,
CF Card, or SD Card which will then be ready for use in any
RomWBW-based system.
Essentially, these files contain prepared floppy and hard disk images
with a large set of programs and related files. By copying the
contents of these files to appropriate media as described below, you
Essentially, these files contain prepared floppy and hard disk images
with a large set of programs and related files. By copying the
contents of these files to appropriate media as described below, you
can quickly create ready-to-use media. Win32DiskImager or
RawWriteWin can be used to copy images directly to media. These
programs are included in the RomWBW Tools directory.
The fd_*.img files are floppy disk images. They are sized for 1.44MB
floppy media and can be copied to actual floppy disks using
RawWriteWin (as long as you have access to a floppy drive on your
Windows computer). The resulting floppy disks will be usable on any
The fd_*.img files are floppy disk images. They are sized for 1.44MB
floppy media and can be copied to actual floppy disks using
RawWriteWin (as long as you have access to a floppy drive on your
Windows computer). The resulting floppy disks will be usable on any
RomWBW-based system with floppy drive(s).
Likewise, the hd512_*.img and hd1k_*.img files are hard disk images.
Each file is intended to be copied to the start of any type of hard
disk media (typically a CF Card or SD Card). The resulting media will
be usable on any RomWBW-based system that accepts the corresponding
Likewise, the hd512_*.img and hd1k_*.img files are hard disk images.
Each file is intended to be copied to the start of any type of hard
disk media (typically a CF Card or SD Card). The resulting media will
be usable on any RomWBW-based system that accepts the corresponding
media type.
NOTE: The hd512_*.img files are equivalent to the hd_*.img
@ -109,39 +109,86 @@ maximum number of CP/M directory entries from 512 to 1024.
Refer to the ReadMe.txt in the Source/Images directory
for details.
Documentation of the pre-built disk images is contained in the
Documentation of the pre-built disk images is contained in the
"RomWBW User Guide" found in the Doc directory. The contents of
the disk images is contained in the "RomWBW Disk Catalog", but it
is significantly out-of-date.
The contents of the floppy/hard disk images are created by
the BuildImages.cmd script in the Source directory. Additional
information on how to generate custom disk images is found in the
The contents of the floppy/hard disk images are created by
the BuildImages.cmd script in the Source directory. Additional
information on how to generate custom disk images is found in the
Source\Images ReadMe.txt file.
The psys.img file contains a full implementation of the UCSD p-System
for the Z80 running under RomWBW. This image file must be placed on
disk media by itself (not appended or concatenated with hd*.img files.
Refer to the Source/pSys/ReadMe.txt file for more information on the
Disk Images (hd512_combo.img, hd1k_combo.img, *_std_hd1k_combo.img)
-------------------------------------------------------------------
The hd512_combo.img and hd1k_combo.img file are the primary combo
disk image files suitable for most platforms.
The *_std_hd1k_combo.img files are platform specific combo files
typically used in romless platforms, they also contain RomWBW binary code
that is loaded at boot time into RAM
Disk Images (hd1k_prefix.dat, *_std_hd1k_prefix.dat)
----------------------------------------------------
The hd1k_prefix.dat file is part of the combo disk images and is
applied to hd1k image files as a prefix, it contains the standard
partion table.
The *_std_hd1k_prefix.dat files are platform specific prefixes
typically used in romless platforms, they also contain RomWBW binary code
that is loaded at boot time into RAM
Disk Images (psys.img)
----------------------
The psys.img file contains a full implementation of the UCSD p-System
for the Z80 running under RomWBW. This image file must be placed on
disk media by itself (not appended or concatenated with hd*.img files.
Refer to the Source/pSys/ReadMe.txt file for more information on the
p-System implementation.
Propeller ROM Images (*.eeprom)
-------------------------------
The files with and extension of ".eeprom" contain the binary images
to be programmed into the Propeller-based boards. The list below
The files with and extension of ".eeprom" contain the binary images
to be programmed into the Propeller-based boards. The list below
indicates which file targets each of the Propeller board variants:
ParPortProp ParPortProp.eeprom
PropIO V1 PropIO.eeprom
PropIO V2 PropIO2.eeprom
Refer to the board documentation of the boards for more information
Refer to the board documentation of the boards for more information
on how to program the EEPROMs on these boards.
SUB DIRECTORIES
===============
Apps Directory
--------------
The Apps subdirectory contains the executable application files that
are specific to RomWBW. The source for these applications is found
in the Source\Apps directory of the distribution.
in the Source\Apps directory of the distribution.
CPNET Directory
---------------
This directory contains the CP/NET client packages. Please refer to
the RomWBW User Guide for instructions on installing these packages,
or see the Readme.txt file in this sub-directory
CPM22 CPM3 ZSDOS ZPM3 QPM Directories
-------------------------------------
These directories contains the system files for the RomWBW adaptations
for each operating system. All of these files are already included on
the boot disk images. However if you are creating a o/s boot disk
manually, you will need copy all of these files to the boot disk.
These files should also be copied to any boot disks on your
system when you upgrade your ROM firmware. Some of these files
*must* match the version of the RomWBW firmware you are using for
proper operation of your system.

4
Binary/ZSDOS/Clean.cmd

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

7
Binary/ZSDOS/Makefile

@ -0,0 +1,7 @@
TOOLS = ../../Tools
MOREDIFF := $(shell $(TOOLS)/unix/casefn.sh *.spr)
include $(TOOLS)/Makefile.inc
clean::
@rm -f *.sys

23
Binary/ZSDOS/ReadMe.txt

@ -0,0 +1,23 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory contains the ZSDOS system files for the RomWBW ZSDOS
adaptation. All of these files are already included on the ZSDOS
boot disk images. However if you are creating a ZSDOS boot disk
manually, you should copy all of these files to the boot disk.
Note: Two file have been provided one for RomWBW HBIOS, and one for UNA
BIOS. One of these files must be installed on the system boot track.
This is usually achieved by the SYSCOPY utility e.g.
SYSCOPY a:=zsys_wbw.sys
These files should also be copied to any ZSDOS boot disks on your
system when you upgrade your ROM firmware. Some of these files
*must* match the version of the RomWBW firmware you are using for
proper operation of your system.

0
Doc/CPM Manual.pdf → Doc/CPM/CPM Manual.pdf

0
Doc/CPM3 Command Summary.pdf → Doc/CPM/CPM3 Command Summary.pdf

0
Doc/CPM3 Programmers Guide.pdf → Doc/CPM/CPM3 Programmers Guide.pdf

0
Doc/CPM3 System Guide.pdf → Doc/CPM/CPM3 System Guide.pdf

0
Doc/CPM3 Users Guide.pdf → Doc/CPM/CPM3 Users Guide.pdf

0
Doc/NZCOM Users Manual.pdf → Doc/CPM/NZCOM Users Manual.pdf

70
Doc/CPM/ReadMe.txt

@ -0,0 +1,70 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory ("Doc/CPM") is part of the RomWBW System Software
distribution archive. It contains documentation for the CP/M and
CP/M work-alike operating system components of the system.
CPM Manual ("CPM Manual.pdf")
-----------------------------
The original DRI CP/M 2.x Operating System Manual. This should be
considered the primary reference for system operation. The section
on CP/M 2 Alteration can be ignored since this work has already been
completed as part of the RomWBW distribution.
CPM3 Command Summary ("CPM3 Command Summary.pdf")
CPM3 Programmer's Guide ("CPM3 Programmers Guide.pdf")
CPM3 System Guide ("CPM3 System Guide.pdf")
CPM3 User's Guide ("CPM3 Users Guide.pdf")
------------------------------------------------------
The original DRI CP/M 3.0 Operating System Documentation Set. This
should be considered the primary reference for CP/M 3 system operation.
NZCOM, Z3PLUS, and replace ZCPR3.3 Documentation
------------------------------------------------
NZCOM operating system operation manual. ("NZCOM Users Manual.pdf")
Z3PLUS operating system operation manual. ("Z3PLUS Users Manual.pdf")
Z-System User Guide ("Z-System User Guide.pdf")
ZCPR3.3 Users Guide ("ZCPR3.3 Users Guide.pdf")
QP/M 2.7 Installation Guide and Supplements ("qpm27.pdf")
QP/M 2.7 Interface Guide ("qdos27.pdf")
QP/M 2.7 Features and Facilities ("qcp27.pdf")
--------------------------------------------
Official documentation set for QP/M 2.7 from original QP/M distribution.
ZCPR Manual ("ZCPR Manual.pdf")
-------------------------------
ZCPR is the command proccessor portion of Z-System. This is the
manual for ZCPR 1.x as included in RomWBW. The installation
instructions can be ignored since that work has already been
completed as part of the RomWBW distribution.
ZCPR D&J Manual ("ZCPR-DJ.doc")
-------------------------------
ZCPR D&J User Manual. This manual supplements the ZCPR Manual.
ZSDOS Manual ("ZSDOS Manual.pdf")
---------------------------------
ZSDOS is the DOS portion of Z-System. This is the manual for ZSDOS
1.x as included in RomWBW. The installation instructions can be
ignored since that work has already been completed as part of the
RomWBW distribution.

BIN
Doc/CPM/Z-System Users Guide.pdf

Binary file not shown.

6773
Doc/CPM/Z3PLUS Users Manual.pdf

File diff suppressed because it is too large

0
Doc/ZCPR Manual.pdf → Doc/CPM/ZCPR Manual.pdf

0
Doc/ZCPR-DJ.doc → Doc/CPM/ZCPR-DJ.doc

BIN
Doc/CPM/ZCPR3.3 User Guide.pdf

Binary file not shown.

0
Doc/ZSDOS Manual.pdf → Doc/CPM/ZSDOS Manual.pdf

0
Doc/qcp27.pdf → Doc/CPM/qcp27.pdf

0
Doc/qdos27.pdf → Doc/CPM/qdos27.pdf

0
Doc/qpm27.pdf → Doc/CPM/qpm27.pdf

36
Doc/ChangeLog.txt

@ -14,6 +14,40 @@ Version 3.5
- DDW: Added support for Duodyne Media board
- WBW: Auto restore TMS video on user reset (CP/M warm boot)
- L?B: Added support for NABU w/ RomWBW Option Board
- MAP: Reorganization of Doc directory introducing subfolders
- WBW: Upgraded BBCBASIC to v5.00
- W?S: Updated FLASH utility to v1.3.9
- WBW: Support RCBus PS/2 Keyboard (EP/Sally)
- M?R: Update Timer app to display output in decimal
- WBW: Preliminary support for S100 FPGA Z80 platform
- WBW: Added simple serial (SSER) driver
- WBW: Added preliminary support for S100 FPGA Z80 SD Cards
- M?R: Consolidated ROM Applications document into the Applications document
- M?R: Reviewed and substantially improved the Applications document
- WBW: Added support for DS1305 RTC on S100 FPGA Z80
- WBW: Added support for Les Bird's RCBus Graphics/Sound/Joystick module
- WBW: Added support for Les Bird's Dual 16C550 UART module
- WBW: Refactor UART driver for more flexible configuration
- M?R: Added hour/minute/second display to timer app
- WBW: Substantial customization of NZ-COM disk image
- WBW: Refactor build post-processing (ZRC, ZZRCC, etc.)
- MAP: Improved section Real Time Clock in User Guide document
- WBW: Support for Hitachi HD44780-based LCD display
- DRJ: Added support for Genesis STD Bus Z180 platform
- MAP: Improved section Disk Management in User Guide document
- WBW: Add CPU speed selection for HEATH platform to HBIOS
- WBW: Add Warm/Cold reboot options to CPUSPD utility
- D?N: Added support for eZ80 CPU
- MAP: Contributed COPYSL utility
- 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
- MAP: CPM3 Boot Loader, and BIOS (drive select) now use EXT_SLICE
- M?R: Added REBOOT application
- MAP: Significant improvement in Disk Catalog document
- MAP: Added Disk Image for the Z3PLUS (Z-System for CP/M-Plus) os.
- H?H: Fix XModem 12.3 WRERR to put CAN char in proper register to send.
- MAP: Initial NVRAM configuration infrastructure
Version 3.4
-----------
@ -682,4 +716,4 @@ interrupts disabled the BIOS will now start OK even if some vagrant
hardware is asserting an interrupt (DISKIO). Seems like this is better
anyway -- general idea is that we only enable interupts precisely
when desired for very specific controled purposes since there is no
concept of interrupt dispatching available.
concept of interrupt dispatching available.

BIN
Doc/Contrib/AY-3-8910 Registers.xlsx

Binary file not shown.

6
Doc/Contrib/ZSystem.txt

@ -4,7 +4,7 @@ ZSDOS Adaptation Notes for RomWBW
Wayne Warthen
wwarthen@gmail.com
This file is a log of the work done to adapt the ZSDOS distribution to the N8VEM platforms under RomWBW. I strongly recommend reviewing the zsdos.pdf file in the Doc directory.
This file is a log of the work done to adapt the ZSDOS distribution to the N8VEM platforms under RomWBW. I strongly recommend reviewing the zsdos.pdf file in the Doc/CPM directory.
The starting point was the general public release of ZSDOS that is generally available. The first line of the README file is "ZSDOS-GP. General Public Release of the ZSDOS 1.x Operating System."
@ -20,7 +20,7 @@ Beyond the construction and integration of the actual DOS itself, the majority o
The remainder of this document details the changes I made as I went along. In all cases, my goal was to keep the result as close to the original distribution as possible. I started by copying all of the files from the distribution (contained in zsdos2.zip) into Support\ZSDOS. From there I tested, modified, updated, and customized as documented below. Finally, I cherry picked files that made sense to include on the ZSystem ROM disks.
1. CLOCKS.DAT has been updated to include the RomWBW clock driver, HBCLK. I have also added the SIMHCLOK clock driver.
1. CLOCKS.DAT has been updated to include the RomWBW clock driver, WBWCLK. I have also added the SIMHCLOK clock driver.
2. STAMPS.DAT has been replaced with an updated version. The update was called STAMPS11.DAT and was found on the Walnut Creek CP/M CDROM. The original version has a bug that prevents RSX (resident system extension) mode to load properly.
@ -52,4 +52,4 @@ Usage Notes
6. After using PUTDS to initialize a directory for ZDS date stamping, I am finding that it is necessary to run RELOG before the stamping routines will actually start working.
7. Generic CP/M PIP and ZSDOS path searching do not play well together if you use PIP to copy to or from a directory in the ZSDOS search path. Best to use COPY from the ZSDOS distribution.
7. Generic CP/M PIP and ZSDOS path searching do not play well together if you use PIP to copy to or from a directory in the ZSDOS search path. Best to use COPY from the ZSDOS distribution.

BIN
Doc/Hard Disk Anatomy.pdf

Binary file not shown.

0
Doc/Aztec_C_1.06_User_Manual_Mar84.pdf → Doc/Language/Aztec_C_1.06_User_Manual_Mar84.pdf

0
Doc/Cowgol Language.pdf → Doc/Language/Cowgol Language.pdf

0
Doc/HI-TECH Z80 C Compiler Manual.txt → Doc/Language/HI-TECH Z80 C Compiler Manual.txt

0
Doc/Microsoft Basic-80 Reference Manual v5.0.pdf → Doc/Language/Microsoft Basic-80 Reference Manual v5.0.pdf

0
Doc/Microsoft_FORTRAN-80_Users_Manual_1977.pdf → Doc/Language/Microsoft_FORTRAN-80_Users_Manual_1977.pdf

62
Doc/Language/ReadMe.txt

@ -0,0 +1,62 @@
***********************************************************************
*** ***
*** R o m W B W ***
*** ***
*** Z80/Z180 System Software ***
*** ***
***********************************************************************
This directory ("Doc/Language") is part of the RomWBW System Software
distribution archive. It contains documentation for Programming
Languages provided with the system.
Aztec C Compiler User Manual (Aztec_C_1.06_User_Manual_Mar84.pdf)
-----------------------------------------------------------------
Official user manual for the Aztec C Compiler included in the aztecc disk image.
Borland TurboPascal User Manual (Turbo_Pascal_Version_3.0_Reference_Manual_1986.pdf)
------------------------------------------------------------------------------------
Official user manual Borland TurboPascal included in the pascal disk image.
Cowgol Lanaguage (Cowgol Language.pdf)
--------------------------------------
Documentation for Cowgol Language included in the cowgol disk image
HI-TECH C Compiler User Manual (HI-TECH Z80 C Compiler Manual.txt)
------------------------------------------------------------------
Official user manual for the HI-TECH C Compiler included in the
hitechc disk image.
Microsoft Basic-80 Reference Manual v5.0 (Microsoft Basic-80 Reference Manual v5.0.pdf)
---------------------------------------------------------------------------------------
Official manual for Microsoft BASIC as included in RomWBW.
Microsoft FORTRAN-80 User Manual (Microsoft_FORTRAN-80_Users_Manual_1977.pdf)
-----------------------------------------------------------------------------
Official user manual for Microsoft's FORTRAN-80 compiler included in the fortran
disk image.
Z80 Assembler User Manual (z80asm (SLR Systems).pdf)
----------------------------------------------------
Official user manual for the Z80 Macro Assembler by SLR Systems
included in the z80asm disk image.

0
Doc/Turbo_Pascal_Version_3.0_Reference_Manual_1986.pdf → Doc/Language/Turbo_Pascal_Version_3.0_Reference_Manual_1986.pdf

0
Doc/z80asm (SLR Systems).pdf → Doc/Language/z80asm (SLR Systems).pdf

107
Doc/ReadMe.txt

@ -10,6 +10,18 @@ This directory ("Doc") is part of the RomWBW System Software
distribution archive. It contains documentation for components of
the system.
CPM (Directory)
---------------
Documentation specific to CP/M, including all versions and derivatives.
Language (Directory)
--------------------
Documentation specific to programming languages, provided with the system
ChangeLog.txt
-------------
@ -31,25 +43,6 @@ and utilities are detailed in the Applications and
ROM Applications documents.
CPM Manual ("CPM Manual.pdf")
-----------------------------
The original DRI CP/M 2.x Operating System Manual. This should be
considered the primary reference for system operation. The section
on CP/M 2 Alteration can be ignored since this work has already been
completed as part of the RomWBW distribution.
CPM3 Command Summary ("CPM3 Command Summary.pdf")
CPM3 Programmer's Guide ("CPM3 Programmers Guide.pdf")
CPM3 System Guide ("CPM3 System Guide.pdf")
CPM3 User's Guide ("CPM3 Users Guide.pdf")
------------------------------------------------------
The original DRI CP/M 3.0 Operating System Documentation Set. This
should be considered the primary reference for CP/M 3 system operation.
DDTZ Manual ("DDTZ.doc")
------------------------
@ -69,47 +62,6 @@ Hard Disk Anatomy ("Hard Disk Anatomy.pdf")
Diagram of a CP/M & MS-DOS (FAT) hybrid hard disk layout.
NZCOM User's Manual ("NZCOM Users Manual.pdf")
----------------------------------------------
NZCOM operating system operation manual.
ZCPR Manual ("ZCPR Manual.pdf")
-------------------------------
ZCPR is the command proccessor portion of Z-System. This is the
manual for ZCPR 1.x as included in RomWBW. The installation
instructions can be ignored since that work has already been
completed as part of the RomWBW distribution.
ZCPR D&J Manual ("ZCPR-DJ.doc")
-------------------------------
ZCPR D&J User Manual. This manual supplements the ZCPR Manual.
ZSDOS Manual ("ZSDOS Manual.pdf")
---------------------------------
ZSDOS is the DOS portion of Z-System. This is the manual for ZSDOS
1.x as included in RomWBW. The installation instructions can be
ignored since that work has already been completed as part of the
RomWBW distribution.
Microsoft Basic-80 Reference Manual v5.0 (Microsoft Basic-80 Reference Manual v5.0.pdf)
---------------------------------------------------------------------------------------
Official manual for Microsoft BASIC as included in RomWBW.
QP/M 2.7 Installation Guide and Supplements ("qpm27.pdf")
QP/M 2.7 Interface Guide ("qdos27.pdf")
QP/M 2.7 Features and Facilities ("qcp27.pdf")
--------------------------------------------
Official documentation set for QP/M 2.7 from original QP/M distribution.
SIO+CTC Baud Rate Options (SIO+CTC Baud Rate Options.pdf)
---------------------------------------------------------
@ -132,37 +84,4 @@ UCSD p-System Users Manual ("UCSD p-System Users Manual.pdf")
Official user manual for p-System operating system included with
RomWBW.
Z80 Assembler User Manual (z80asm (SLR Systems).pdf)
----------------------------------------------------
Official user manual for the Z80 Macro Assembler by SLR Systems
included in the z80asm disk image.
HI-TECH C Compiler User Manual (HI-TECH Z80 C Compiler Manual.txt)
------------------------------------------------------------------
Official user manual for the HI-TECH C Compiler included in the
hitechc disk image.
Borland TurboPascal User Manual (Turbo_Pascal_Version_3.0_Reference_Manual_1986.pdf)
------------------------------------------------------------------------------------
Official user manual Borland TurboPascal included in the pascal disk image.
Aztec C Compiler User Manual (Aztec_C_1.06_User_Manual_Mar84.pdf)
-----------------------------------------------------------------
Official user manual for the Aztec C Compiler included in the aztecc disk image.
FORTRAN-80 User Manual (Microsoft_FORTRAN-80_Users_Manual_1977.pdf)
---------------------------------------------------------------
Official user manual for Microsoft's FORTRAN-80 compiler included in the fortran
disk image.
--WBW 5:18 PM 6/14/2023
--WBW 5:18 PM 6/14/2023

BIN
Doc/RomWBW Applications.pdf

Binary file not shown.

BIN
Doc/RomWBW Disk Catalog.pdf

Binary file not shown.

BIN
Doc/RomWBW Errata.pdf

Binary file not shown.

BIN
Doc/RomWBW ROM Applications.pdf

Binary file not shown.

BIN
Doc/RomWBW System Guide.pdf

Binary file not shown.

BIN
Doc/RomWBW User Guide.pdf

Binary file not shown.

144
Doc/Testing Notes.txt

@ -1,144 +0,0 @@
SIMH (X)
----
- Test UART driver
- Test HDSK driver
Zeta 1 (X)
------
- Test UART driver
- Test PPP detection (startup w/ and w/o PPP)
- Test boot to CRT
- Test PPPSD driver
- Test PPPCON driver (video & kbd)
- Test FD driver
- Test FDU app
Zeta 2 (X)
------
- Test UART driver
- Test PPP detection (startup w/ and w/o PPP)
- Test boot to CRT
- Test PPPSD driver
- Test PPPCON driver (video & kbd)
- Test FD driver
- Test FDU app
RCBus (X)
------
- Test SIO driver (Serial Module)
- Test ACIA driver (Dual Serial Module)
- Test IDE driver (Compact Flash Module)
- Test PPIDE driver (IDE Module)
- Test FD driver (SMC and WDC)
- Test FDU app (SMC and WDC)
N8-2312 (X)
-------
- Test ASCI driver
- Test SD driver (CSIO mode)
- Test FD driver
- Test FDU app
- Test TMS driver (video & kbd)
N8-2511 (X)
-------
- Test ASCI driver
- Test SD driver (Juha mode)
- Test FD driver
- Test FDU app
- Test TMS driver (video & kbd)
SBC (X)
---
- Test UART driver
- Test PPIDE driver
- Test PPISD driver
- Test PRP detection
- Test boot to CRT console
MK4 (X)
---
- Test ASCI driver
- Test IDE driver
- Test SD driver
- Test PRP detection
RAMF (X)
----
- Test RAMF driver
PRP (X)
---
- Test PRPSD driver
- Test PRPCON driver (video & kbd)
SCG (X)
---
- Test TMS driver (video)
VDU (X)
---
- Test CVDU driver (video & kbd)
CVDU (X)
----
- Test CVDU driver (video & kbd)
VGA (X)
---
- Test VGA driver (video & kbd)
DIO (X)
---
- Test FD driver
- Test FDU app
- Test IDE driver
DIO3 (X)
----
- Test FD driver
- Test FDU app
- Test PPIDE driver
DIDE (X)
----
- Test FD driver
- Test FDU app
- Test IDE driver
DSD (X)
---
- Test SD driver
4UART (X)
-----
- Test UART driver
UNA (X)
---
- General Startup
- Boot from disk functionality
- Image loading
- Monitor
- XM app
- ASSIGN app
- MODE app
- SYSCOPY app
- OSLDR app
- FDU app
- FDISK80 app
GENERAL (X)
-------
- Boot to ROM
- Boot to Disk
- Boot to Monitor
- XM app
- XM port auto-detect
- ASSIGN app
- MODE app
- SYSCOPY app
- FDU app
- FDISK80 app
- TUNE app

BIN
Doc/The Cowgol language.pdf

Binary file not shown.

48
Dockerfile

@ -0,0 +1,48 @@
FROM ubuntu:jammy-20240111 as basebuilder
# This docker file can be used to build a tool chain docker image for building RomWBW images.
# Tested on a ubuntu host and on Windows un WSL (with docker desktop)
# First build the docker image (will b)
# docker build --progress plain -t romwbw-chain .
# After you have built the above image (called romwbw-chain), you can use it to compile and build the RomWBW images
# as per the standard make scripts within RomWBW.
# Start a new terminal, cd to where you have clone RomWBW, and then run this command:
# docker run -v ${PWD}:/src/ --privileged=true -u $(id -u ${USER}):$(id -g ${USER}) -it romwbw-chain:latest
# you can now compile and build the required images:
# cd Tools && make
# cd Source && make # at least once to build many common units
# cd Source && make rom ROM_PLATFORM=RCEZ80 ROM_CONFIG=std
# when finish, type 'exit' to return to back to your standard terminal session
LABEL Maintainer="Dean Netherton" \
Description="spike to use clang for ez80 target"
ENV DEBIAN_FRONTEND=noninteractive
RUN dpkg --add-architecture i386
RUN sed -i 's/http:\/\/archive\.ubuntu\.com\/ubuntu/http:\/\/au.archive.ubuntu.com\/ubuntu/g' /etc/apt/sources.list
RUN apt update -y
RUN apt dist-upgrade -y
RUN apt install -y --no-install-recommends cmake lzip ca-certificates mtools build-essential dos2unix libboost-all-dev texinfo texi2html libxml2-dev subversion bison flex zlib1g-dev m4 git wget dosfstools curl
RUN mkdir work
WORKDIR /work
FROM basebuilder as main
LABEL Maintainer="Dean Netherton" \
Description="spike to build RomWBW"
RUN mkdir /src
WORKDIR /src/
RUN apt install -y --no-install-recommends build-essential libncurses-dev srecord bsdmainutils
RUN adduser --disabled-password --gecos "" builder

2
Makefile

@ -28,4 +28,4 @@ dist:
$(MAKE) --directory Source clean
distlog:
$(MAKE) dist 2>&1 | tee make.log
time -p $(MAKE) dist 2>&1 | tee make.log

24
ReadMe.md

@ -3,7 +3,7 @@
**RomWBW ReadMe** \
Version 3.5 \
Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \
03 May 2024
08 Nov 2024
# Overview
@ -112,22 +112,20 @@ functionality.
Complete instructions for installation and operation of RomWBW are found
in the [RomWBW User
Guide](https://github.com/wwarthen/RomWBW/raw/dev/Doc/RomWBW%20User%20Guide.pdf).
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/dev/Doc/RomWBW%20User%20Guide.pdf)
Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20User%20Guide.pdf)
- [RomWBW System
Guide](https://github.com/wwarthen/RomWBW/raw/dev/Doc/RomWBW%20System%20Guide.pdf)
Guide](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20System%20Guide.pdf)
- [RomWBW
Applications](https://github.com/wwarthen/RomWBW/raw/dev/Doc/RomWBW%20Applications.pdf)
- [RomWBW ROM
Applications](https://github.com/wwarthen/RomWBW/raw/dev/Doc/RomWBW%20ROM%20Applications.pdf)
Applications](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Applications.pdf)
- [RomWBW
Errata](https://github.com/wwarthen/RomWBW/raw/dev/Doc/RomWBW%20Errata.pdf)
Errata](https://github.com/wwarthen/RomWBW/raw/master/Doc/RomWBW%20Errata.pdf)
# Acknowledgments
@ -188,8 +186,8 @@ let me know if I missed you!
- Tasty Basic is a product of Dimitri Theulings.
- Dean Netherton contributed 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.
@ -198,7 +196,11 @@ let me know if I missed you!
Microsoft Fortran Compiler, and a Games compendium.
- Martin R has provided substantial help reviewing and improving the
User Guide.
User Guide and Applications documents.
- Mark Pruden has also contributed a great deal of content to the Disk
Catalog, User Guide as well as contributing the disk image for the
Z3PLUS operating system, and the COPYSL utility.
- Jacques Pelletier has contributed the DS1501 RTC driver code.

13
ReadMe.txt

@ -1,6 +1,6 @@
RomWBW ReadMe
Wayne Warthen (wwarthen@gmail.com)
03 May 2024
08 Nov 2024
@ -122,7 +122,6 @@ Documentation for RomWBW includes:
- RomWBW User Guide
- RomWBW System Guide
- RomWBW Applications
- RomWBW ROM Applications
- RomWBW Errata
@ -188,8 +187,8 @@ let me know if I missed you!
- Tasty Basic is a product of Dimitri Theulings.
- Dean Netherton contributed 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.
@ -198,7 +197,11 @@ let me know if I missed you!
BASIC Compiler, Microsoft Fortran Compiler, and a Games compendium.
- Martin R has provided substantial help reviewing and improving the
User Guide.
User Guide and Applications documents.
- Mark Pruden has also contributed a great deal of content to the Disk
Catalog, User Guide as well as contributing the disk image for the
Z3PLUS operating system, and the COPYSL utility.
- Jacques Pelletier has contributed the DS1501 RTC driver code.

23
Source/Apps/BBCBASIC/Build.cmd

@ -0,0 +1,23 @@
@echo off
setlocal
set TOOLS=..\..\..\Tools
set PATH=%TOOLS%\zxcc;%PATH%
set CPMDIR80=%TOOLS%/cpm/
zxcc z80asm -dist/FM
zxcc z80asm -main/FM
zxcc z80asm -exec/FM
zxcc z80asm -eval/FM
zxcc z80asm -asmb/FM
zxcc z80asm -cmos/FM
zxcc z80asm -math/FM
zxcc z80asm -hook/FM
zxcc z80asm -data/FM
zxcc slrnk -/v,/a:0100,dist,main,exec,eval,asmb,math,hook,cmos,/p:4B00,data,bbcbasic/n,/e
copy /Y bbcbasic.com ..\..\..\Binary\Apps\ || exit /b
copy /Y bbcbasic.txt ..\..\..\Binary\Apps\ || exit /b

9
Source/Apps/BBCBASIC/Clean.cmd

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

11
Source/Apps/BBCBASIC/Makefile

@ -0,0 +1,11 @@
OBJECTS = bbcbasic.com
DOCS = bbcbasic.txt
DEST = ../../../Binary/Apps
DOCDEST = ../../../Binary/Apps
TOOLS = ../../../Tools
OTHERS = *.rel
include $(TOOLS)/Makefile.inc
bbcbasic.com: dist.rel main.rel exec.rel eval.rel asmb.rel cmos.rel math.rel hook.rel data.rel
$(ZXCC) SLRNK -/V,/A:0100,DIST,MAIN,EXEC,EVAL,ASMB,MATH,HOOK,CMOS,/P:4B00,DATA,BBCBASIC/N,/E

1010
Source/Apps/BBCBASIC/asmb.z80

File diff suppressed because it is too large

455
Source/Apps/BBCBASIC/bbcbasic.txt

@ -0,0 +1,455 @@
This is a RomWBW HBIOS adaptation of BBCBASIC v5.00. The
cursor and screen management assumes the use of an ANSI/VT-100 terminal
which is generally correct for RomWBW. Support for a hardware system
timer is also implemented. If your system does not have a hardware
timer, the TIME function will always return 0 and the timeout
parameter of the INKEY(n) function will not be observed (will never
timeout).
What follows is some basic information on BBCBASIC from the
distribution. Note that it starts with the v3.00 information and
later on provides information on the changes in v5.00.
-- WBW 1:15 PM 5/30/2024
BBC BASIC (Z80)
Generic CP/M Version 3.00
(C) Copyright R.T.Russell 1982-1999
1. INTRODUCTION
BBC BASIC (Z80) has been designed to be as compatible as possible with
Version 4 of the 6502 BBC BASIC resident in the BBC Micro Master series.
The language syntax is not always identical to that of the 6502 version,
but in most cases the Z80 version is more tolerant.
BBC BASIC (Z80) is as machine independent as possible and, as supplied,
it will run on any CP/M 2.2 (or later) system using a Z80 processor
(checks are carried out to ensure that the processor is a Z80 and that
the version of CP/M is at least 2.2). It is minimally configured for an
ADM3a-compatible VDU.
Few CP/M systems offer colour graphics of the quality provided as
standard on the BBC Microcomputer, and no software can provide colour
high-resolution graphics from a monochrome character-orientated computer.
However, many CP/M system users are interested in the advanced program
structures available from BBC BASIC and, within the limitations of the
host computer, BBC BASIC (Z80) provides the programming structures and
the non-graphic commands and functions specified for BBC BASIC.
In order to make full use of the facilities available in BBC BASIC (Z80)
it is necessary to install a small patch to adapt it to the capabilities
of the host computer. The source code of the patch present in the
distribution version is supplied as BBCDIST.MAC.
This documentation should be read in conjunction with a standard BBC
BASIC manual. Only those features which differ from the standard Acorn
versions are documented here.
2. MEMORY UTILISATION
BBC BASIC (Z80) requires about 16 Kbytes of code space, resulting in a
value of PAGE of about &3E00. The remainder of the user memory is
available for BASIC programs, variables (heap) and stack. Depending on
the system configuration, HIMEM can have a value up to &FE00.
3. COMMANDS, STATEMENTS AND FUNCTIONS
The syntax of BASIC commands, statements and functions is in most cases
identical to that of the BBC Micro version (BASIC 4). The few
differences are documented here:
ADVAL
This function is not implemented.
CALL
CALL sets up a table in RAM containing details of the parameters; the
processor's IX register is set to the address of this parameter table.
The other processor registers are initialised as follows:
A is initialised to the least significant byte of A%
B is initialised to the least significant byte of B%
C is initialised to the least significant byte of C%
D is initialised to the least significant byte of D%
E is initialised to the least significant byte of E%
F is initialised to the least significant byte of F%
H is initialised to the least significant byte of H%
L is initialised to the least significant byte of L%
The parameter types are:
Code No. Parameter Type Example
0 Byte (8 bits) ?A%
4 Word (32 bits) !A% or A%
5 Real (40 bits) A
128 Fixed string $A%
129 Movable string A$
On entry to the subroutine the parameter table contains the following
values:
Number of parameters 1 byte (at IX)
Parameter type 1 byte (at IX+1)
Parameter address 2 bytes (at IX+2, IX+3, LSB first)
Parameter type ) repeated as often as necessary
Parameter address )
Except in the case of a movable string (normal string variable), the
parameter address given is the absolute address at which the item is
stored. In the case of movable strings (type 129) it is the address of a
4-byte parameter block containing the current length, the maximum length
and the start address of the string (LSB first) in that order.
Integer variables are stored in twos complement form with their least
significant byte first.
Fixed strings are stored as the characters of the string followed by a
carriage return (&0D).
Floating point variables are stored in binary floating point format with
their least significant byte first; the fifth byte is the exponent. The
mantissa is stored as a binary fraction in sign and magnitude format.
Bit 7 of the most significant byte is the sign bit and, for the purposes
of calculating the magnitude of the number, this bit is assumed to be set
to one. The exponent is stored as an integer in excess 127 format (to
find the exponent subtract 127 from the value in the fifth byte).
If the exponent byte of a floating point number is zero, the number is an
integer stored in integer format in the mantissa bytes. Thus an integer
can be represented in two different ways in a real variable. For example
the value +5 can be stored as:
05 00 00 00 00 Integer 5
00 00 00 20 82 (0.5 + 0.125) * 2^3
COLOUR (COLOR)
This statement is not implemented.
DRAW
This statement is not implemented.
EDIT
A command to edit or concatenate and edit the specified program line(s).
The specified lines (including their line numbers) are listed as a single
line. By changing only the line number you can use EDIT to duplicate a
line.
EDIT 230
EDIT 200,230
The following control functions are active both in the EDIT mode and in
the immediate entry mode (i.e. at the BASIC prompt):
Move the cursor one character position to the left
Move the cursor one character position to the right
Move the cursor to the start of the line
Move the cursor to the end of the line
Insert a space at the current cursor position
Delete the character at the current cursor position
Backspace and delete the character to the left of the cursor
Delete all characters to the left of the cursor
Delete all characters from the cursor to the end of the line
The choice of which keys activate these functions is made when BBC BASIC
is configured for a particular system. The distribution version uses ^H,
^I, ^K, ^J, ^A, ^E, DEL (&7F), ^L and ^X.
To exit EDIT mode and replace the edited line, type RETURN (ENTER).
To abort the edit and leave the line unchanged, type ESCape.
ENVELOPE
This statement is not implemented.
GET
This function waits for a character to be typed at the keyboard, and
returns the ASCII code.
GET can also be used to read data from a processor I/O port; full 16-bit
port addressing is available:
N% = GET(X%) : REM input from port X%
INKEY
This function waits for a specified maximum number of centiseconds for a
character to be typed at the keyboard. If no character is typed in that
time, the value -1 is returned. In the distribution version the delay is
determined by a simple software timing loop, and may be very inaccurate.
The customisation patch allows this to be adjusted to suit the system in
use.
INPUT#
The format of data files is different from that used by the BBC Micro, in
part to improve compatibility with standard CP/M files. Numeric values
are stored as five bytes in the format documented under CALL; if the
fifth byte is zero the value is an integer. Strings are stored as the
characters of the string (in the correct order!) followed by a carriage
return (&0D).
MODE
This statement is not implemented.
MOVE
This statement is not implemented.
PLOT
This statement is not implemented.
POINT
This function is not implemented.
PRINT#
The format of data files is different from that used by the BBC Micro, in
part to improve compatibility with standard CP/M files. Numeric values
are stored as five bytes in the format documented under CALL; if the
fifth byte is zero the value is an integer. Strings are stored as the
characters of the string (in the correct order!) followed by a carriage
return (&0D).
PUT
A statement to output data to a processor port. Full 16-bit addressing
is available.
PUT A%,N% : REM Output N% to port A%
SOUND
This statement is not implemented.
TIME
This pseudo-variable is not implemented in the distribution version, but
can be supported by means of the customisation patch. See BBCDIST.MAC.
USR
As with CALL, the processor's registers are initialised as follows:
A is initialised to the least significant byte of A%
B is initialised to the least significant byte of B%
C is initialised to the least significant byte of C%
D is initialised to the least significant byte of D%
E is initialised to the least significant byte of E%
F is initialised to the least significant byte of F%
H is initialised to the least significant byte of H%
L is initialised to the least significant byte of L%
USR returns a 32-bit integer result composed of the processor's H, L, H'
and L' registers, with H being the most significant.
4. RESIDENT Z80 ASSEMBLER
The in-line assembler is accessed in exactly the same way as the 6502
assembler in the BBC Micro version of BBC BASIC. That is, '[' enters
assembler mode and ']' exits assembler mode.
All standard Zilog mnemonics are accepted: ADD, ADC and SBC must be
followed by A or HL. For example, ADD A,C is accepted but ADD C is not.
However, the brackets around the port number in IN and OUT are optional.
Thus both OUT (5),A and OUT 5,A are accepted. The instruction IN F,(C)
is not accepted, but the equivalent code is produced from IN (HL),C
The pseudo-ops DEFB, DEFW and DEFM are included. DEFM works like EQUS in
the 6502 version.
5. OPERATING SYSTEM INTERFACE
The following resident Operating System ("star") commands are
implemented. They may be accessed directly (e.g. *BYE) or via the OSCLI
statement (OSCLI "BYE").
Control characters, lower-case characters, DEL and quotation marks may be
incorporated in filenames by using the 'escape' character '|'. However,
there is no equivalent to the BBC Microcomputer's '|!' to set bit 7.
*BYE
Returns control to the operating system (CP/M).
*CPM
Same as *BYE.
*. [filespec]
*DIR [filespec]
List the files which match the (optional) ambiguous filespec. If the
filespec is omitted, all .BBC files are listed:
*DIR List all .BBC files on the disk
*DIR B:*.* List all files on disk B:
*.*.* List all files on the current disk
*DRIVE d:
Select drive d as the default drive for subsequent disk operations.
*ERA filespec
Erase (delete) the specified disk file or files. The extension defaults
to .BBC if omitted.
*ESC [ON|OFF]
*ESC OFF disables the abort action of the ESCape key; after *ESC OFF the
ESCape key simply returns the ASCII code ESC (27). *ESC ON, or *ESC,
restores the normal action of the ESCape key.
*EXEC filespec
Accept console input from the specified file instead of from the
keyboard. If the extension is omitted, .BBC is assumed.
*LOAD filespec aaaa
Loads the specified file into memory at address aaaa. The load address
must be specified. If the extension is omitted, .BBC is assumed.
*OPT [n]
Select the destination for console output characters. The value n is in
the range 0 to 2, as follows:
0 Send characters to the console output
1 Send characters to the auxiliary output
2 Send characters to the printer (list) output
*REN newfile=oldfile
*RENAME newfile=oldfile
Renames 'oldfile' as 'newfile'. If the extension is omitted, .BBC is
assumed.
*RESET
Rest the disk system (CP/M function 13). This command does not close any
files nor does it perform any other housekeeping function. You should
use *RESET after you have changed a disk.
*SAVE filespec aaaa bbbb
*SAVE filespec aaaa +llll
This command saves a specified range of memory to disk. The address range
is specified either as start (aaaa) and end+1 (bbbb) or as start (aaaa)
and length (llll). If the extension is omitted, .BBC is assumed.
*SPOOL [filespec]
Copy all subsequent console output to the specified file. If the filename
is omitted, any current spool file is closed and spooling is terminated.
If the extension is omitted, .BBC is assumed.
*TYPE filespec
Type the specified file to the screen. If the extension is omitted, .BBC
is assumed.
*| comment
This is a comment line. Anything following the | is ignored.
6. ERROR MESSAGES AND CODES
Untrappable:
No room RENUMBER space
Silly LINE space
Sorry Bad program
Trappable - BASIC:
1 Out of range 24 Exp range
2 25
3 26 No such variable
4 Mistake 27 Missing )
5 Missing , 28 Bad HEX
6 Type mismatch 29 No such FN/PROC
7 No FN 30 Bad call
8 31 Arguments
9 Missing " 32 No FOR
10 Bad DIM 33 Can't match FOR
11 DIM space 34 FOR variable
12 Not LOCAL 35
13 No PROC 36 No TO
14 Array 37
15 Subscript 38 No GOSUB
16 Syntax error 39 ON syntax
17 Escape 40 ON range
18 Division by zero 41 No such line
19 String too long 42 Out of DATA
20 Too big 43 No REPEAT
21 -ve root 44
22 Log range 45 Missing #
23 Accuracy lost
Trappable - OS:
190 Directory full 214 File not found
192 Too many open files 222 Channel
196 File exists 253 Bad string
198 Disk full 254 Bad command
200 Close error 255 CP/M error
204 Bad name

New features in BBC BASIC (Z80) version 5.00, May 2024:
1. BASIC V statements
1.1 WHILE...ENDWHILE
1.2 Multi-line IF...THEN...ELSE...ENDIF
1.3 CASE...WHEN...OTHERWISE...ENDCASE
1.4 LOCAL DATA / RESTORE DATA
1.5 ON ERROR LOCAL / RESTORE ERROR
1.6 DIM var LOCAL size
1.7 ERROR err, message$
1.8 RESTORE +n
1.9 SWAP var1,var2
1.10 BPUT #file,string$[;]
1.11 QUIT
2. BASIC V functions
2.1 DIM(array()[,sub])
2.2 END (pointer to free space)
2.3 REPORT$
2.4 Binary constants
2.5 LEFT$ & RIGHT$ with last parameter omitted
2.6 MOD(array)
2.7 SUM(array)
2.8 SUMLEN(array)
2.9 GET$#file
3. BASIC V whole array operations
3.1 Pass a whole array to a FN/PROC
3.2 Pass a whole array to CALL
3.3 Whole array assignment
3.4 Whole array arithmetic *
3.5 Array dot-product operator
3.6 Array initialisation lists
3.7 Array compound assignment (+= etc.)
3.8 Make a whole array LOCAL
3.9 DIM a LOCAL array (on the stack) +
* String array expressions A$() = B$() + C$() are not currently supported.
+ LOCAL string arrays should be initialised to their maximum needed length
to eliminate the risk of a memory leak each time the PROC/FN is called:
LOCAL a$() : DIM a$(size%) : a$() = STRING$(max%, "a") : a$() = ""
4. Miscellaneous BASIC V features
4.1 Bit-shifts <<, >>, >>>
4.2 Floating-point indirection (|)
4.3 RETURNed parameters from FN/PROC
4.4 Compound assignment (+=, -=, *=, /= etc.)
4.5 Assigning to a sub-string: LEFT$()=, MID$()= , RIGHT$()=
4.6 Hooks for CIRCLE,ELLIPSE,FILL,LINE,MOUSE,ORIGIN,RECTANGLE,TINT,SYS,WAIT
4.7 Hooks for WIDTH function, TINT function, MODE function
5. Extensions to Acorn's BASIC V, compatible with BB4W, BBCSDL and BBCTTY
5.1 EXIT REPEAT / WHILE / FOR [var]
5.2 Address-of operator ^
5.3 Byte variables and arrays (& suffix)
5.4 'BY len' and 'TO term' qualifiers to GET$#file
5.5 ELSE IF <condition> THEN; (trailing semicolon)
5.6 == synonymous with = in comparisons
5.7 DIM a global array inside a FN/PROC (use RETURN)
Note: The token for PUT has changed from &CE in version 3 to &0E in version 5.
If this token is present in existing programs it will list as ENDWHILE rather
than PUT, and the programs will need to be modified to restore functionality.

1494
Source/Apps/BBCBASIC/cmos.z80

File diff suppressed because it is too large

69
Source/Apps/BBCBASIC/data.z80

@ -0,0 +1,69 @@
TITLE BBC BASIC (C) R.T.RUSSELL 1981-2024
NAME ('DATA')
;
;RAM MODULE FOR BBC BASIC INTERPRETER
;FOR USE WITH VERSION 5.0 OF BBC BASIC
;(C) COPYRIGHT R.T.RUSSELL 1981-2024
;
GLOBAL ACCS
GLOBAL BUFFER
GLOBAL ONERSP
GLOBAL LIBASE
GLOBAL PAGE
GLOBAL LOMEM
GLOBAL FREE
GLOBAL HIMEM
GLOBAL RANDOM
GLOBAL COUNT
GLOBAL WIDTH
GLOBAL ERL
GLOBAL ERR
GLOBAL ERRTRP
GLOBAL ERRTXT
GLOBAL TRACEN
GLOBAL AUTONO
GLOBAL INCREM
GLOBAL LISTON
GLOBAL DATPTR
GLOBAL FNPTR
GLOBAL PROPTR
GLOBAL STAVAR
GLOBAL OC
GLOBAL PC
GLOBAL DYNVAR
GLOBAL CURLIN
GLOBAL USER
;
;n.b. ACCS, BUFFER & STAVAR must be on page boundaries.
;
ACCS: DEFS 256 ;STRING ACCUMULATOR
BUFFER: DEFS 256 ;STRING INPUT BUFFER
STAVAR: DEFS 27*4 ;STATIC VARIABLES
OC EQU STAVAR+15*4 ;CODE ORIGIN (O%)
PC EQU STAVAR+16*4 ;PROGRAM COUNTER (P%)
DYNVAR: DEFS 54*2 ;DYN. VARIABLE POINTERS
FNPTR: DEFS 2 ;DYN. FUNCTION POINTER
PROPTR: DEFS 2 ;DYN. PROCEDURE POINTER
;
PAGE: DEFS 2 ;START OF USER PROGRAM
LOMEM: DEFS 2 ;START OF DYN. STORAGE
FREE: DEFS 2 ;FIRST FREE-SPACE BYTE
HIMEM: DEFS 2 ;FIRST BYTE ABOVE STACK
LIBASE: DEFS 2 ;START OF FIRST LIBRARY
;
TRACEN: DEFS 2 ;TRACE FLAG AND NUMBER
AUTONO: DEFS 2 ;AUTO FLAG AND NUMBER
ERRTRP: DEFS 2 ;ON ERROR STMT POINTER \
ONERSP: DEFS 2 ;ON ERROR LOCAL STKPTR /
ERRTXT: DEFS 2 ;ERROR MESSAGE POINTER
DATPTR: DEFS 2 ;DATA POINTER
ERL: DEFS 2 ;LINE NO OF LAST ERROR
CURLIN: DEFS 2 ;POINTER TO CURRENT LINE
RANDOM: DEFS 5 ;RANDOM NUMBER
COUNT: DEFS 1 ;PRINT POSITION
WIDTH: DEFS 1 ;PRINT WIDTH
ERR: DEFS 1 ;ERROR NUMBER
LISTON: DEFS 1 ;LISTO & OPT FLAG
INCREM: DEFS 1 ;AUTO INCREMENT
;
USER: END

241
Source/Apps/BBCBASIC/dist.z80

@ -0,0 +1,241 @@
TITLE BBCDIST.Z80 (C) R.T.RUSSELL 1982-2024
NAME ('DIST3')
;
;BBC BASIC (Z80) - CP/M VERSION 2.20 & 3.00
;(C) COPYRIGHT R.T.RUSSELL, 1982-2024.
;ALL RIGHTS RESERVED.
;
;THIS PROGRAM ALLOWS THE USER TO ADAPT BBC BASIC TO THE
;PARTICULAR CHARACTERISTICS OF HIS SYSTEM HARDWARE ETC.
;
;THE PROGRAM RESIDES AT 100H FOR EASE OF LOADING.
;*** IT MUST NOT EXCEED 256 BYTES IN TOTAL LENGTH ***
;
;PLEASE NOTE THAT A Z80 PROCESSOR AND CP/M VERSION 2.2
;OR LATER ARE REQUIRED.
;
;R.T.RUSSELL, 11-03-1984, 03-05-1989, 12-05-2024
;
CPM EQU 5
COLD EQU 200H
;
CR EQU 0DH
LF EQU 0AH
ESC EQU 1BH
;
GLOBAL CLRSCN
GLOBAL PUTCSR
GLOBAL GETCSR
GLOBAL PUTIME
GLOBAL GETIME
GLOBAL GETKEY
GLOBAL BYE
GLOBAL BEGIN
; GLOBAL BDOS
;
; EXTRN PRTDEC16
;
;ASEG
;ORG 100H
;
;JUMP TABLE - BASIC makes calls to hardware-dependent
;features via this table:
;
BEGIN: JP INIT
CLRSCN: JP CLS ;CLEAR SCREEN
PUTCSR: JP PCSR ;SET CURSOR POSN.
GETCSR: JP GCSR ;READ CURSOR POSN.
PUTIME: JP PTIME ;SET ELAPSED TIME
GETIME: JP GTIME ;READ ELAPSED TIME
GETKEY: JP INKEY ;READ KEY (TIME LIMIT)
BYE: JP REBOOT ;RETURN TO CP/M
;
;BDOS - Save the IX and IY registers and before performing a
; CP/M function call.
;
BDOS: PUSH IX
PUSH IY
CALL CPM
POP IY
POP IX
RET
;
;INIT - Perform hardware initialisation (if any).
;
INIT: LD HL,40H ;CPM/HBIOS MARKER LOC
LD A,'W'
CP (HL)
JR NZ,FAIL
INC HL
LD A,NOT 'W'
CP (HL)
JR NZ,FAIL
JP COLD
FAIL: LD DE,NOTHB
LD C,9
CALL BDOS
RST 0
;
NOTHB: DEFB 'CP/M w/ HBIOS required$'
;
;REBOOT - Switch off interrupts and return to CP/M
;
REBOOT: RST 0
;
;GTIME - Read elapsed-time clock.
; Outputs: DEHL = elapsed time (centiseconds)
; Destroys: A,D,E,H,L,F
;
GTIME: JR TICKS
;
;PTIME - Load elapsed-time clock.
; Inputs: DEHL = time to load (centiseconds)
; Destroys: A,D,E,H,L,F
;
PTIME:
LD BC,0F9D0H
SRL D
RR E
RR H
RR L
RST 08
RET
;
; Get OS elapsed-time clock
; Outputs: DEHL = time (centiseconds)
; Destroys: A,B,C,D,E,H,L,F
;
TICKS: LD BC,0F8D0H
RST 08
SLA L
RL H
RL E
RL D
RET
;
;INKEY - Sample keyboard with specified wait.
; Inputs: HL = Time to wait (centiseconds)
; Outputs: Carry reset indicates time-out.
; If carry set, A = character typed.
; Destroys: A,D,E,H,L,F
;
INKEY: PUSH BC
PUSH HL
CALL TICKS
POP DE
ADD HL,DE
WAIT: PUSH HL
LD C,6
LD E,0FFH
CALL BDOS
POP HL
OR A
SCF
JR NZ,INKEY1
PUSH HL
CALL TICKS
POP DE
SBC HL,DE
EX DE,HL
JR C,WAIT
INKEY1: POP BC
RET
;
;CLS - Clear screen.
; (Customise to suit your VDU)
; Destroys: A,D,E,H,L,F
;
CLS:
LD DE,CLSSTR
LD C,9
JP BDOS
;
CLSSTR: DEFB ESC,'[H',ESC,'[2J$'
;
;PCSR - Move cursor to specified position.
; Inputs: DE = horizontal position (LHS=0)
; HL = vertical position (TOP=0)
; Destroys: A,D,E,H,L,F
;
PCSR: LD B,L ; vertical = line (row)
CALL CONV ; normalized and convert to decimal
LD (LIN),HL ; and store into string
LD B,E ; horizontal = column
CALL CONV ; normalized and convert to decimal
LD (COL),HL ; and store into string
LD C,9 ; output string command
LD DE,CURS ; start of string
JP BDOS ; output string to terminal
;
; VT100 sequence for cursor positioning
CURS: DEFB 27, '['
LIN: DEFW 0 ; high byte, low byte for decimal line
DEFB ';'
COL: DEFW 0 ; high byte, low byte for decimal column
DEFB 'H$'
;
; convert binary B (0 <= B < 99, not checked) into B+1 in decimal.
; L = upper byte, H = lower byte. ready for LD (...), HL
; destroys A, B, L, H
; optimized for space over time
;
CONV: INC B ; normalize, home in VT100 is (1,1)
LD A,'0' ; A is counter for low byte of result
LD L,A ; L is counter for high byte of result
CONVLP: INC A ; now B times increment AL in decimal
CP '9'+1 ; low byte overflow?
JR NZ,CONT ; no, continue incrementing
LD A,'0' ; reset low byte
INC L ; and increment high byte
CONT: DJNZ CONVLP ; B times
LD H,A ; put low byte into right place
RET
;
;GCSR - Return cursor coordinates.
; Outputs: DE = X coordinate (POS)
; HL = Y coordinate (VPOS)
; Destroys: A,D,E,H,L,F
;
GCSR: LD DE,0
LD HL,0
RET
;
;COUT - Output a character to the console
; Inputs: A = character
; Destroys: A,F
;
COUT: PUSH BC
PUSH DE
PUSH HL
LD E,A
LD C,2
CALL BDOS
POP HL
POP DE
POP BC
RET
;
;IF $ GT 1F0H
IF $-BEGIN GT 0F0H
ERROR 'INSUFFICIENT SPACE'
ENDIF
;
;ORG 1F0H
DEFS 0F0H - ($ - BEGIN)
;
OFFLO: DEFW 0 ;TIME OFFSET LO
OFFHI: DEFW 0 ;TIME OFFSET HI
DEFB 80 ;WIDTH
DEFB 'G' AND 1FH ;CURSOR UP
DEFB 'O' AND 1FH ;CURSOR DOWN
DEFB 'F' AND 1FH ;START OF LINE
DEFB 'N' AND 1FH ;END OF LINE
DEFB 'X' AND 1FH ;DELETE TO END OF LINE
DEFB 08H ;BACKSPACE & DELETE
DEFB 'U' AND 1FH ;DEL TO START OF LINE
DEFB 'J' AND 1FH ;CURSOR LEFT
DEFB 'L' AND 1FH ;CURSOR RIGHT
DEFB 'R' AND 1FH ;DELETE CHARACTER
DEFB 'Q' AND 1FH ;INS/OVR TOGGLE
;
FIN: END

2587
Source/Apps/BBCBASIC/eval.z80

File diff suppressed because it is too large

3274
Source/Apps/BBCBASIC/exec.z80

File diff suppressed because it is too large

64
Source/Apps/BBCBASIC/hook.z80

@ -0,0 +1,64 @@
NAME ('HOOK')
;
GLOBAL CLG
GLOBAL COLOUR
GLOBAL DRAW
GLOBAL ENVEL
GLOBAL GCOL
GLOBAL MODE
GLOBAL MOVE
GLOBAL PLOT
GLOBAL SOUND
GLOBAL PUTIMS
GLOBAL CIRCLE
GLOBAL ELLIPSE
GLOBAL FILL
GLOBAL MOUSE
GLOBAL ORIGIN
GLOBAL RECTAN
GLOBAL LINE
GLOBAL TINT
GLOBAL WAIT
GLOBAL SYS
;
GLOBAL ADVAL
GLOBAL POINT
GLOBAL GETIMS
GLOBAL TINTFN
GLOBAL MODEFN
GLOBAL WIDFN
;
EXTRN EXTERR
;
CLG:
COLOUR:
DRAW:
ENVEL:
GCOL:
MODE:
MOVE:
PLOT:
SOUND:
ADVAL:
POINT:
GETIMS:
PUTIMS:
CIRCLE:
ELLIPSE:
FILL:
MOUSE:
ORIGIN:
RECTAN:
LINE:
TINT:
TINTFN:
MODEFN:
WIDFN:
WAIT:
SYS:
XOR A
CALL EXTERR
DEFM 'Sorry'
DEFB 0
;
END

2237
Source/Apps/BBCBASIC/main.z80

File diff suppressed because it is too large

2267
Source/Apps/BBCBASIC/math.z80

File diff suppressed because it is too large

62
Source/Apps/Build.cmd

@ -2,47 +2,37 @@
setlocal
set TOOLS=..\..\Tools
set APPBIN=..\..\Binary\Apps
set PATH=%TOOLS%\tasm32;%TOOLS%\zxcc;%PATH%
set TASMTABS=%TOOLS%\tasm32
set CPMDIR80=%TOOLS%/cpm/
call :asm syscopy || exit /b
call :asm assign || exit /b
call :asm format || exit /b
call :asm talk || exit /b
call :asm mode || exit /b
call :asm rtc || exit /b
call :asm timer || exit /b
call :asm rtchb || exit /b
call :build syscopy || exit /b
call :build assign || exit /b
call :build format || exit /b
call :build talk || exit /b
call :build mode || exit /b
call :build rtc || exit /b
call :build timer || exit /b
call :build sysgen || exit /b
call :build XM || exit /b
call :build FDU || exit /b
call :build Tune || exit /b
call :build FAT || exit /b
call :build Test || exit /b
call :build ZMP || exit /b
call :build ZMD || exit /b
call :build Dev || exit /b
call :build VGM || exit /b
call :build cpuspd || exit /b
call :build reboot || exit /b
call :build Survey || exit /b
call :build HTalk || exit /b
call :build BBCBASIC || exit /b
call :build copysl || exit /b
zxcc Z80ASM -SYSGEN/F || exit /b
pushd XM && call Build || exit /b & popd
pushd FDU && call Build || exit /b & popd
pushd Tune && call Build || exit /b & popd
pushd FAT && call Build || exit /b & popd
pushd Test && call Build || exit /b & popd
pushd ZMP && call Build || exit /b & popd
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 Survey && call Build || exit /b & popd
pushd HTalk && call Build || exit /b & popd
copy *.com %APPBIN%\ || exit /b
goto :eof
:asm
echo.
echo Building %1...
tasm -t80 -g3 -fFF %1.asm %1.com %1.lst || exit /b
goto :eof
:asm180
echo.
echo Building %1...
tasm -t180 -g3 -fFF %1.asm %1.com %1.lst || exit /b
:build
echo Building %1
pushd %1 && call Build || exit /b & popd
goto :eof

45
Source/Apps/Clean.cmd

@ -1,21 +1,32 @@
@echo off
setlocal
if exist *.bin del *.bin
if exist *.com del *.com
if exist *.lst del *.lst
if exist *.hex del *.hex
if exist *.prn del *.prn
call :clean syscopy || exit /b
call :clean assign || exit /b
call :clean format || exit /b
call :clean talk || exit /b
call :clean mode || exit /b
call :clean rtc || exit /b
call :clean timer || exit /b
call :clean sysgen || exit /b
call :clean XM || exit /b
call :clean FDU || exit /b
call :clean Tune || exit /b
call :clean FAT || exit /b
call :clean Test || exit /b
call :clean ZMP || exit /b
call :clean ZMD || exit /b
call :clean Dev || exit /b
call :clean VGM || exit /b
call :clean cpuspd || exit /b
call :clean reboot || exit /b
call :clean Survey || exit /b
call :clean HTalk || exit /b
call :clean BBCBASIC || exit /b
call :clean copysl || exit /b
pushd XM && call Clean || exit /b 1 & popd
pushd FDU && call Clean || exit /b 1 & popd
pushd Tune && call Clean || exit /b 1 & popd
pushd FAT && call Clean || exit /b 1 & popd
pushd Test && call Clean || exit /b 1 & popd
pushd ZMP && call Clean || exit /b 1 & popd
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 Survey && call Clean || exit /b 1 & popd
pushd HTalk && call Clean || exit /b 1 & popd
goto :eof
:clean
pushd %1 && call Clean || exit /b & popd
goto :eof

8
Source/Apps/Makefile

@ -1,9 +1,5 @@
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
DEST = ../../Binary/Apps
SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd reboot Survey BBCBASIC copysl \
sysgen syscopy assign format talk mode rtc timer
TOOLS =../../Tools
include $(TOOLS)/Makefile.inc
USETASM = 1

4
Source/Apps/Test/2piotst/Build.cmd

@ -1,10 +1,8 @@
@echo off
setlocal
set TOOLS=..\..\..\..\Tools
set TOOLS=../../../../Tools
set PATH=%TOOLS%\zxcc;%PATH%
set CPMDIR80=%TOOLS%/cpm/
zxcc M80 -=2piotst/l || exit /b

50
Source/Apps/Test/Build.cmd

@ -1,41 +1,31 @@
@echo off
setlocal
set TOOLS=../../../Tools
set APPBIN=..\..\Binary\Apps
set TOOLS=..\..\..\Tools
set PATH=%TOOLS%\tasm32;%TOOLS%\zxcc;%PATH%
set TASMTABS=%TOOLS%\tasm32
set CPMDIR80=%TOOLS%/cpm/
pushd DMAmon && call Build || exit /b & popd
pushd tstdskng && call Build || exit /b & popd
pushd inttest && call Build || exit /b & popd
pushd ppidetst && call Build || exit /b & popd
pushd ramtest && call Build || exit /b & popd
pushd I2C && call Build || exit /b & popd
pushd rzsz && call Build || exit /b & popd
pushd vdctest && call Build || exit /b & popd
pushd kbdtest && call Build || exit /b & popd
pushd ps2info && call Build || exit /b & popd
pushd 2piotst && call Build || exit /b & popd
pushd piomon && call Build || exit /b & popd
pushd banktest && call Build || exit /b & popd
pushd portscan && call Build || exit /b & popd
pushd sound && call Build || exit /b & popd
goto :eof
call :build DMAmon || exit /b
call :build tstdskng || exit /b
call :build inttest || exit /b
call :build ppidetst || exit /b
call :build ramtest || exit /b
call :build I2C || exit /b
call :build rzsz || exit /b
call :build vdctest || exit /b
call :build kbdtest || exit /b
call :build ps2info || exit /b
call :build 2piotst || exit /b
call :build piomon || exit /b
call :build banktest || exit /b
call :build portscan || exit /b
call :build sound || exit /b
call :build testh8p || exit /b
:asm
echo.
echo Building %1...
tasm -t80 -g3 -fFF %1.asm %1.com %1.lst || exit /b
goto :eof
:asm180
echo.
echo Building %1...
tasm -t180 -g3 -fFF %1.asm %1.com %1.lst || exit /b
:build
echo Building %1
pushd %1 && call Build || exit /b & popd
goto :eof

1
Source/Apps/Test/Clean.cmd

@ -22,3 +22,4 @@ pushd piomon && call Clean || exit /b 1 & popd
pushd banktest && call Clean || exit /b 1 & popd
pushd portscan && call Clean || exit /b 1 & popd
pushd sound && call Clean || exit /b 1 & popd
pushd testh8p && call Clean || exit /b 1 & popd

6
Source/Apps/Test/I2C/Build.cmd

@ -5,9 +5,9 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF i2cscan.asm i2cscan.com i2cscan.lst || exit /b
tasm -t180 -g3 -fFF rtcds7.asm rtcds7.com rtcds7.lst || exit /b
tasm -t180 -g3 -fFF i2clcd.asm i2clcd.com i2clcd.lst || exit /b
tasm -t80 -g3 -fFF i2cscan.asm i2cscan.com i2cscan.lst || exit /b
tasm -t80 -g3 -fFF rtcds7.asm rtcds7.com rtcds7.lst || exit /b
tasm -t80 -g3 -fFF i2clcd.asm i2clcd.com i2clcd.lst || exit /b
tasm -t80 -g3 -ff srom.asm srom.com srom.lst || exit /b
copy /Y i2c*.com ..\..\..\..\Binary\Apps\Test\ || exit /b

6
Source/Apps/Test/Makefile

@ -1,6 +1,6 @@
OBJECTS =
SUBDIRS = DMAmon I2C inttest ppidetst ramtest tstdskng rzsz vdctest kbdtest ps2info 2piotst piomon banktest portscan sound
DEST = ../../../Binary/Apps/Test
# OBJECTS =
SUBDIRS = DMAmon I2C inttest ppidetst ramtest tstdskng rzsz vdctest kbdtest ps2info 2piotst piomon banktest portscan sound testh8p
# DEST = ../../../Binary/Apps/Test
TOOLS =../../../Tools
include $(TOOLS)/Makefile.inc

3
Source/Apps/Test/inttest/Build.cmd

@ -5,7 +5,8 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF inttest.asm inttest.com inttest.lst || exit /b
tasm -t80 -g3 -fFF inttest.asm inttest.com inttest.lst || exit /b
copy /Y inttest.com ..\..\..\..\Binary\Apps\Test\ || exit /b
copy /Y inttest.doc ..\..\..\..\Binary\Apps\Test\ || exit /b

2
Source/Apps/Test/inttest/Makefile

@ -1,5 +1,7 @@
OBJECTS = inttest.com
DOCS = inttest.doc
DEST = ../../../../Binary/Apps/Test
DOCDEST = ../../../../Binary/Apps/Test
TOOLS =../../../../Tools
USETASM=1

6
Source/Apps/Test/inttest/inttest.asm

@ -176,6 +176,8 @@ estidx:
jr z,hkim
cp 2
jr z,hkim
cp 3
jr z,hkim
ret
;
; Setup interrupt handler
@ -545,8 +547,8 @@ stack .equ $ ; stack top
;
; Messages
;
msgban .db "INTTEST v1.2, 15-May-2019",13,10
.db "Copyright (C) 2019, Wayne Warthen, GNU GPL v3",0
msgban .db "INTTEST v1.3, 16-May-2024",13,10
.db "Copyright (C) 2024, Wayne Warthen, GNU GPL v3",0
msginfo .db "Interrupt information request...",0
msgmode .db " Active interrupt mode: ",0
msgcnt .db " Vector entries in use: ",0

44
Source/Apps/Test/inttest/inttest.doc

@ -0,0 +1,44 @@
INTTEST
=======
RomWBW includes an API allowing applications to "hook" interrupts.
The `INTTEST` utility allows you to test this functionality.
** Syntax **
`INTTEST`
** Usage **
`INTTEST` is an interactive application. At startup, it will display
a list of the interrupt vector slots in your system along with the
current vector address for each of them.
It then prompts you to enter the slot number (in hex) of a vector to
hook. After entering this, the application will watch the hooked
vector and countdown from 0xFF to 0x00 as interrupts are noted.
When the counter reaches 0x00, the interrupt is unhooked and the
application terminates. The application can also be terminated by
pressing <esc>.
** Notes **
If your system is running without interrupts active, the application
will terminate immediately.
All slots have vectors even if the corresponding interrupt is not
doing anything. In this case, the vector is pointing to the "bad
interrupt" handler.
If you hook a vector that is not receiving any interrupts, the
down-counter will not do anything.
** Etymology* *
The `INTTEST` command is an original product and the source code is
provided in the RomWBW distribution.

2
Source/Apps/Test/kbdtest/Build.cmd

@ -5,7 +5,7 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF kbdtest.asm kbdtest.com kbdtest.lst || exit /b
tasm -t80 -g3 -fFF kbdtest.asm kbdtest.com kbdtest.lst || exit /b
copy /Y kbdtest.com ..\..\..\..\Binary\Apps\Test\ || exit /b

2
Source/Apps/Test/piomon/Build.cmd

@ -5,6 +5,6 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF piomon.asm piomon.com piomon.lst || exit /b
tasm -t80 -g3 -fFF piomon.asm piomon.com piomon.lst || exit /b
copy /Y piomon.com ..\..\..\..\Binary\Apps\Test\ || exit /b

2
Source/Apps/Test/ppidetst/Build.cmd

@ -5,7 +5,7 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF ppidetst.asm ppidetst.com ppidetst.lst || exit /b
tasm -t80 -g3 -fFF ppidetst.asm ppidetst.com ppidetst.lst || exit /b
copy /Y ppidetst.com ..\..\..\..\Binary\Apps\Test\ || exit /b

2
Source/Apps/Test/ps2info/Build.cmd

@ -5,6 +5,6 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF ps2info.asm ps2info.com ps2info.lst || exit /b
tasm -t80 -g3 -fFF ps2info.asm ps2info.com ps2info.lst || exit /b
copy /Y ps2info.com ..\..\..\..\Binary\Apps\Test\ || exit /b

19
Source/Apps/Test/ps2info/ps2info.asm

@ -11,6 +11,7 @@
; WBW 2022-04-01: Add menu for test functions
; WBW 2022-04-02: Fix prtchr register saving/recovery
; WBW 2023-10-19: Add support for Duodyne
; WBW 2024-06-10: Add support for RC2014
;
;=======================================================================
;
@ -25,6 +26,10 @@ iodat_rph .equ $8C ; PS/2 controller data port address
; Duodyne:
iocmd_duo .equ $4D ; PS/2 controller command port address
iodat_duo .equ $4C ; PS/2 controller data port address
; RC2014 (EP/Sally)
iocmd_rc .equ $64 ; PS/2 controller command port address
iodat_rc .equ $60 ; PS/2 controller data port address
;
cpumhz .equ 8 ; for time delay calculations (not critical)
;
@ -87,6 +92,8 @@ setup1:
jr z,setup_rph
cp '3' ; Duodyne
jr z,setup_duo
cp '4' ; RC2014 EP/Sally
jr z,setup_rc
cp 'X'
jr z,exit
jr setup
@ -115,6 +122,14 @@ setup_duo:
ld de,str_duo
jr setup2
;
setup_rc:
ld a,iocmd_rc
ld (iocmd),a
ld a,iodat_rc
ld (iodat),a
ld de,str_rc
jr setup2
;
setup2:
call prtstr
call crlf2
@ -1437,16 +1452,18 @@ delay1:
; Constants
;=======================================================================
;
str_banner .db "PS/2 Keyboard/Mouse Information v0.8, 6-Nov-2023",0
str_banner .db "PS/2 Keyboard/Mouse Information v0.9, 10-Jun-2024",0
str_hwmenu .db "PS/2 Controller Port Options:\r\n\r\n"
.db " 1 - Nhyodyne\r\n"
.db " 2 - Rhyophyre\r\n"
.db " 3 - Duodyne\r\n"
.db " 4 - RC2014\r\n"
.db " X - Exit Application\r\n"
.db "\r\nSelection? ",0
str_mbc .db "Nhyodyne",0
str_rph .db "Rhyophyre",0
str_duo .db "Duodyne",0
str_rc .db "RC2014 (Saly)",0
str_menu .db "PS/2 Testing Options:\r\n\r\n"
.db " C - Test PS/2 Controller\r\n"
.db " K - Test PS/2 Keyboard\r\n"

2
Source/Apps/Test/ramtest/Makefile

@ -2,7 +2,7 @@ OBJECTS = ramtest.com
DEST = ../../../../Binary/Apps/Test
DOCDEST = ../../../../Doc
TOOLS = ../../../../Tools
OTHERS = loader.bin dbgmon.bin
OTHERS = *.bin
include $(TOOLS)/Makefile.inc
ramtest.com: loader.bin dbgmon.bin

10
Source/Apps/Test/testh8p/Build.cmd

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

6
Source/Apps/Test/testh8p/Clean.cmd

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

9
Source/Apps/Test/testh8p/Makefile

@ -0,0 +1,9 @@
OBJECTS = testh8p.com
# DOCS = testh8p.doc
DEST = ../../../../Binary/Apps/Test
DOCDEST = ../../../../Binary/Apps/Test
TOOLS =../../../../Tools
USETASM=1
include $(TOOLS)/Makefile.inc

238
Source/Apps/Test/testh8p/testh8p.asm

@ -0,0 +1,238 @@
;===============================================================================
; H8 Panel Test
;===============================================================================
;
; AUTHOR: WAYNE WARTHEN (wwarthen@gmail.com)
;_______________________________________________________________________________
;
;
; Trivial utility to test the register pair display functionality of the
; Heath H8 Front Panel.
;
; Program will display a set of known register values on the console,
; then go into an infinite loop. The H8 panel can then be checked to
; see if the correct values are displayed.
;
; There is no way to exit this program. You must reset your system.
;
;===============================================================================
; Definitions
;===============================================================================
;
stksiz .equ $40 ; Working stack size
;
restart .equ $0000 ; CP/M restart vector
bdos .equ $0005 ; BDOS invocation vector
;
regA .equ $11
regBC .equ $2233
regDE .equ $4455
regHL .equ $6677
;
;===============================================================================
; Code Section
;===============================================================================
;
;
.org $100
;
; setup stack (save old value)
ld (stksav),sp ; save stack
ld sp,stack ; set new stack
;
ld de,str_prefix
call prtstr
;
ld de,str_A
ld hl,regA
call prtreg
ld de,str_BC
ld hl,regBC
call prtreg
ld de,str_DE
ld hl,regDE
call prtreg
ld de,str_HL
ld hl,regHL
call prtreg
ld de,str_SP
ld hl,regSP
call prtreg
ld de,str_PC
ld hl,regPC
call prtreg
;
ld a,regA
ld bc,regBC
ld de,regDE
ld hl,regHL
regPC: jr $
;
;
;
prtreg:
call prtstr ; print label
ld a,h ; first byte
call prtoctbyte ; print it
ld a,'.' ; separator
call prtchr ; print it
ld a,l ; second byte
call prtoctbyte ; print it
ret
;
;
;
prtoctbyte:
rlca ; 2 ms bits
rlca
push af
and %00000011 ; isolate
add a,'0' ; make char
call prtchr ; show it
pop af
rlca ; next 3 bits
rlca
rlca
push af
and %00000111 ; isolate
add a,'0' ; make char
call prtchr ; show it
pop af
rlca ; next 3 bits
rlca
rlca
push af
and %00000111 ; isolate
add a,'0' ; make char
call prtchr ; show it
pop af
ret
;
; Print character in A without destroying any registers
;
prtchr:
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
ret
;
; Print a zero terminated string at (DE) without destroying any registers
;
prtstr:
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
ret
;
; Start a new line
;
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 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 hl
;
prthexword:
push af
ld a,h
call prthex
ld a,l
call prthex
pop af
ret
;
; print the hex dword value in de:hl
;
prthex32:
push bc
push de
pop bc
call prthexword
push hl
pop bc
call prthexword
pop bc
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 $0F ; low nibble only
add a,$90
daa
adc a,$40
daa
ret
;
;===============================================================================
; Storage Section
;===============================================================================
;
rtcbuf .fill 6,$FF ; RTC data buffer
;
str_prefix .db "\r\n\r\nRegisters: ",0
;
str_A .db "A=",0
str_BC .db ", BC=",0
str_DE .db ", DE=",0
str_HL .db ", HL=",0
str_SP .db ", SP=",0
str_PC .db ", PC=",0
;
stksav .dw 0 ; stack pointer saved at start
.fill stksiz,0 ; stack
stack .equ $ ; stack top
regSP:
;
.end

2
Source/Apps/Test/tstdskng/Build.cmd

@ -5,7 +5,7 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF tstdskng.asm tstdskng.com tstdskng.lst || exit /b
tasm -t80 -g3 -fFF tstdskng.asm tstdskng.com tstdskng.lst || exit /b
copy /Y tstdskng.com ..\..\..\..\Binary\Apps\Test\ || exit /b

4
Source/Apps/Test/vdctest/Build.cmd

@ -5,8 +5,8 @@ set TOOLS=../../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF vdctest.asm vdctest.com vdctest.lst || exit /b
tasm -t180 -g3 -fFF vdconly.asm vdconly.com vdconly.lst || exit /b
tasm -t80 -g3 -fFF vdctest.asm vdctest.com vdctest.lst || exit /b
tasm -t80 -g3 -fFF vdconly.asm vdconly.com vdconly.lst || exit /b
copy /Y vdctest.com ..\..\..\..\Binary\Apps\Test\ || exit /b
copy /Y vdconly.com ..\..\..\..\Binary\Apps\Test\ || exit /b

6
Source/Apps/Tune/Build.cmd

@ -5,9 +5,9 @@ set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF -dWBW tune.asm tune.com tune.lst || exit /b
tasm -t180 -g3 -fFF -dZX tune.asm tunezx.com tunezx.lst || exit /b
tasm -t180 -g3 -fFF -dMSX tune.asm tunemsx.com tunemsx.lst || exit /b
tasm -t80 -g3 -fFF -dWBW tune.asm tune.com tune.lst || exit /b
tasm -t80 -g3 -fFF -dZX tune.asm tunezx.com tunezx.lst || exit /b
tasm -t80 -g3 -fFF -dMSX tune.asm tunemsx.com tunemsx.lst || exit /b
copy /Y tune*.com ..\..\..\Binary\Apps\ || exit /b
copy /Y Tunes\*.* ..\..\..\Binary\Apps\Tunes\ || exit /b

31
Source/Apps/Tune/tune.asm

@ -49,6 +49,9 @@
; 2024-02-23 [WBW] Include ACR value in config table
; 2024-04-16 [WBW] Add support for NABU AY-3-8910
; 2024-05-10 [WBW] Hack to avoid corrupting bits 6&7 of PSG R7 for NABU!
; 2024-07-08 [WBW] Add support for Les Bird's Graphics, Sound, Joystick
; 2024-07-11 [WBW] Updated, Les Bird's module now uses same settings as EB6
; 2024-09-17 [WBW] Add support for HEATH H8 with Les Bird's MSX Card
;_______________________________________________________________________________
;
; ToDo:
@ -572,8 +575,8 @@ CFGSIZ .EQU $ - CFGTBL
.DB $07, $D8, $D0, $D8, $FF, $FF, $FF ; RCZ80 W/ RC SOUND MODULE (EB)
.DW HWSTR_RCEB
;
.DB $07, $A0, $A1, $A2, $FF, $FF, $FF ; RCZ80 W/ RC SOUND MODULE (EB Rev 6)
.DW HWSTR_RCEB6
.DB $07, $A0, $A1, $A2, $FF, $FF, $FF ; RCZ80 W/ RC SOUND MODULE (MSX)
.DW HWSTR_RCMSX
;
.DB $07, $D1, $D0, $D0, $FF, $FF, $FF ; RCZ80 W/ RC SOUND MODULE (MF)
.DW HWSTR_RCMF
@ -584,8 +587,8 @@ CFGSIZ .EQU $ - CFGTBL
.DB $08, $68, $60, $68, $C0, $FF, $FF ; RCZ180 W/ RC SOUND MODULE (EB)
.DW HWSTR_RCEB
;
.DB $08, $A0, $A1, $A2, $C0, $FF, $FF ; RCZ180 W/ RC SOUND MODULE (EB Rev 6)
.DW HWSTR_RCEB6
.DB $08, $A0, $A1, $A2, $C0, $FF, $FF ; RCZ180 W/ RC SOUND MODULE (MSX)
.DW HWSTR_RCMSX
;
.DB $08, $61, $60, $60, $C0, $FF, $FF ; RCZ180 W/ RC SOUND MODULE (MF)
.DW HWSTR_RCMF
@ -596,8 +599,8 @@ CFGSIZ .EQU $ - CFGTBL
.DB $09, $D8, $D0, $D8, $FF, $FF, $FF ; EZZ80 W/ RC SOUND MODULE (EB)
.DW HWSTR_RCEB
;
.DB $09, $A0, $A1, $A2, $FF, $FF, $FF ; EZZ80 W/ RC SOUND MODULE (EB Rev 6)
.DW HWSTR_RCEB6
.DB $09, $A0, $A1, $A2, $FF, $FF, $FF ; EZZ80 W/ RC SOUND MODULE (MSX)
.DW HWSTR_RCMSX
;
.DB $09, $D1, $D0, $D0, $FF, $FF, $FF ; EZZ80 W/ RC SOUND MODULE (MF)
.DW HWSTR_RCMF
@ -608,8 +611,8 @@ CFGSIZ .EQU $ - CFGTBL
.DB $0A, $68, $60, $68, $C0, $FF, $FF ; SCZ180 W/ RC SOUND MODULE (EB)
.DW HWSTR_RCEB
;
.DB $0A, $A0, $A1, $A2, $C0, $FF, $FF ; SCZ180 W/ RC SOUND MODULE (EB Rev 6)
.DW HWSTR_RCEB6
.DB $0A, $A0, $A1, $A2, $C0, $FF, $FF ; SCZ180 W/ RC SOUND MODULE (MS6)
.DW HWSTR_RCMSX
;
.DB $0A, $61, $60, $60, $C0, $FF, $FF ; SCZ180 W/ RC SOUND MODULE (MF)
.DW HWSTR_RCMF
@ -620,8 +623,8 @@ CFGSIZ .EQU $ - CFGTBL
.DB $0B, $D8, $D0, $D8, $FF, $FF, $FF ; RCZ280 W/ RC SOUND MODULE (EB)
.DW HWSTR_RCEB
;
.DB $0B, $A0, $A1, $A2, $FF, $FF, $FF ; RCZ280 W/ RC SOUND MODULE (EB Rev 6)
.DW HWSTR_RCEB6
.DB $0B, $A0, $A1, $A2, $FF, $FF, $FF ; RCZ280 W/ RC SOUND MODULE (MSX)
.DW HWSTR_RCMSX
;
.DB $0B, $D1, $D0, $D0, $FF, $FF, $FF ; RCZ280 W/ RC SOUND MODULE (MF)
.DW HWSTR_RCMF
@ -634,6 +637,9 @@ CFGSIZ .EQU $ - CFGTBL
;
.DB 17, $A4, $A5, $A4, $FF, $A6, $FE ; DUODYNE
.DW HWSTR_DUO
;
.DB 18, $A0, $A1, $A2, $FF, $FF, $FF ; HEATH H8
.DW HWSTR_HEATH
;
.DB 22, $41, $40, $40, $FF, $FF, $FF ; NABU
.DW HWSTR_NABU
@ -666,7 +672,7 @@ TMP .DB 0 ; work around use of undocumented Z80
HBIOSMD .DB 0 ; NON-ZERO IF USING HBIOS SOUND DRIVER, ZERO OTHERWISE
OCTAVEADJ .DB 0 ; AMOUNT TO ADJUST OCTAVE UP OR DOWN
MSGBAN .DB "Tune Player for RomWBW v3.8, 10-May-2024",0
MSGBAN .DB "Tune Player for RomWBW v3.11, 17-Sep-2024",0
MSGUSE .DB "Copyright (C) 2024, Wayne Warthen, GNU GPL v3",13,10
.DB "PTxPlayer Copyright (C) 2004-2007 S.V.Bulba",13,10
.DB "MYMPlay by Marq/Lieves!Tuore",13,10,13,10
@ -687,12 +693,13 @@ MSGERR .DB "App Error", 0
HWSTR_SCG .DB "SCG ECB Board",0
HWSTR_N8 .DB "N8 Onboard Sound",0
HWSTR_RCEB .DB "RCBus Sound Module (EB)",0
HWSTR_RCEB6 .DB "RCBus Sound Module (EBv6)",0
HWSTR_RCMSX .DB "RCBus Sound Module (MSX)",0
HWSTR_RCMF .DB "RCBus Sound Module (MF)",0
HWSTR_LINC .DB "Z50 LiNC Sound Module",0
HWSTR_MBC .DB "NHYODYNE Sound Module",0
HWSTR_DUO .DB "DUODYNE Sound Module",0
HWSTR_NABU .DB "NABU Onboard Sound",0
HWSTR_HEATH .DB "HEATH H8 MSX Module",0
MSGUNSUP .db "MYM files not supported with HBIOS yet!\r\n", 0

4
Source/Apps/VGM/Build.cmd

@ -5,8 +5,8 @@ set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
tasm -t180 -g3 -fFF -dWBW vgmplay.asm vgmplay.com vgmplay.lst || exit /b
tasm -t180 -g3 -fFF -dWBW ymfmdemo.asm ymfmdemo.com ymfmdemo.lst || exit /b
tasm -t80 -g3 -fFF -dWBW vgmplay.asm vgmplay.com vgmplay.lst || exit /b
tasm -t80 -g3 -fFF -dWBW ymfmdemo.asm ymfmdemo.com ymfmdemo.lst || exit /b
copy /Y vgmplay.com ..\..\..\Binary\Apps\ || exit /b
copy /Y Tunes\*.vgm ..\..\..\Binary\Apps\Tunes\ || exit /b

12
Source/Apps/XM/xmdm125.asm

@ -3478,7 +3478,17 @@ RSDMA: LXI D,TBUF ; Reset DMA address
RET
;
WRERR: CALL RSDMA ; Reset DMA to normal
MVI C,CAN ; Cancel
; [WBW] BEGIN: Fixed to put CAN character in A instead of C because
; SEND uses the A register. Also increased number of CAN characters
; sent to 3. Credit to HubertH for finding this and providing the fix.
; MVI C,CAN ; Cancel
; [WBW] -----
MVI A,CAN ; Cancel
CALL SEND ; Sender
MVI A,CAN ; Cancel
CALL SEND ; Sender
MVI A,CAN ; Cancel
; [WBW] END
CALL SEND ; Sender
; [WBW] BEGIN: RCVSABT does not return, so file write error
; message was never being displayed. Swapped things around

1972
Source/Apps/assign.asm

File diff suppressed because it is too large

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

Loading…
Cancel
Save