mirror of
https://github.com/wwarthen/RomWBW.git
synced 2026-02-06 22:43:15 -06:00
Compare commits
60 Commits
v3.5.0-dev
...
v3.5.0-dev
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
329a0f4d7f | ||
|
|
058a67dd40 | ||
|
|
40f2a9f35a | ||
|
|
3eea703d02 | ||
|
|
74daa4d3c5 | ||
|
|
0539b25046 | ||
|
|
a7e767d0b7 | ||
|
|
78a765147e | ||
|
|
1cb5f0b3b4 | ||
|
|
a34afaa11e | ||
|
|
e8d79bdf0a | ||
|
|
e5232c6696 | ||
|
|
70fcb2cbee | ||
|
|
dab2408166 | ||
|
|
d02c734478 | ||
|
|
c4cc800040 | ||
|
|
f82b4c9bc7 | ||
|
|
1db620d2d7 | ||
|
|
3b2c5b57ad | ||
|
|
69ab236d53 | ||
|
|
e7ed6ed27c | ||
|
|
5ea5003d01 | ||
|
|
7c41ef6fc9 | ||
|
|
7497e233d2 | ||
|
|
157af16d32 | ||
|
|
e0414bca05 | ||
|
|
2a6a3f36c2 | ||
|
|
337374c9e9 | ||
|
|
4946b313e1 | ||
|
|
a6505fbbb1 | ||
|
|
dd93a178fa | ||
|
|
a4fdebea2b | ||
|
|
3f63c92fd5 | ||
|
|
c8794d2b9c | ||
|
|
bf2d0b8196 | ||
|
|
e41cd6d8d2 | ||
|
|
47120dcf8c | ||
|
|
67d23dc540 | ||
|
|
99d5c50556 | ||
|
|
438df9a80b | ||
|
|
8c4a3d2b3d | ||
|
|
585c892a54 | ||
|
|
49025dca44 | ||
|
|
2d8c37307d | ||
|
|
d294fb6d09 | ||
|
|
1649b6093b | ||
|
|
d50593a70e | ||
|
|
874cc450ba | ||
|
|
918ed66967 | ||
|
|
7fe0312359 | ||
|
|
842a79ae5d | ||
|
|
34d25cb906 | ||
|
|
b8af62d7de | ||
|
|
b28c3b7978 | ||
|
|
bf9a8400de | ||
|
|
c3c541d150 | ||
|
|
cecd13fba9 | ||
|
|
7ce7bda43e | ||
|
|
bb5161dcb0 | ||
|
|
d8b7f88dad |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -99,6 +99,7 @@ Tools/unix/zx/zx
|
||||
!Source/ZRC512/*.bin
|
||||
!Source/Z1RCC/*.bin
|
||||
!Source/ZZRCC/*.bin
|
||||
!Source/FZ80/*.bin
|
||||
!Tools/cpm/**
|
||||
!Tools/unix/zx/*
|
||||
!Tools/zx/*
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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
|
||||
|
||||
67
Doc/CPM/ReadMe.txt
Normal file
67
Doc/CPM/ReadMe.txt
Normal file
@@ -0,0 +1,67 @@
|
||||
***********************************************************************
|
||||
*** ***
|
||||
*** 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 User's Manual ("NZCOM Users Manual.pdf")
|
||||
----------------------------------------------
|
||||
|
||||
NZCOM operating system operation manual.
|
||||
|
||||
|
||||
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.
|
||||
@@ -12,6 +12,15 @@ Version 3.5
|
||||
- WBW: Added Cowgol disk image based on the work of Ladislau Szilagyi
|
||||
- WBW: Added support for CP/NET on Duodyne Disk I/O
|
||||
- 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
|
||||
- M?P: 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
|
||||
|
||||
Version 3.4
|
||||
-----------
|
||||
|
||||
BIN
Doc/Contrib/AY-3-8910 Registers.xlsx
Normal file
BIN
Doc/Contrib/AY-3-8910 Registers.xlsx
Normal file
Binary file not shown.
@@ -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."
|
||||
|
||||
@@ -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/Language/Cowgol Language.pdf
Normal file
BIN
Doc/Language/Cowgol Language.pdf
Normal file
Binary file not shown.
62
Doc/Language/ReadMe.txt
Normal file
62
Doc/Language/ReadMe.txt
Normal file
@@ -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.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
107
Doc/ReadMe.txt
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
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
16
ReadMe.md
16
ReadMe.md
@@ -3,7 +3,7 @@
|
||||
**RomWBW ReadMe** \
|
||||
Version 3.5 \
|
||||
Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \
|
||||
28 Feb 2024
|
||||
30 Jun 2024
|
||||
|
||||
# Overview
|
||||
|
||||
@@ -112,22 +112,22 @@ 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)
|
||||
Applications](https://github.com/wwarthen/RomWBW/raw/master/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%20ROM%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
|
||||
|
||||
@@ -229,6 +229,8 @@ let me know if I missed you!
|
||||
- Ladislau Szilagyi has contributed an enhanced version of CP/M Cowgol
|
||||
that leverages RomWBW memory banking.
|
||||
|
||||
- Les Bird has contributed support for the NABU w/ Option Board
|
||||
|
||||
Contributions of all kinds to RomWBW are very welcome.
|
||||
|
||||
# Licensing
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
RomWBW ReadMe
|
||||
Wayne Warthen (wwarthen@gmail.com)
|
||||
28 Feb 2024
|
||||
30 Jun 2024
|
||||
|
||||
|
||||
|
||||
@@ -230,6 +230,8 @@ let me know if I missed you!
|
||||
- Ladislau Szilagyi has contributed an enhanced version of CP/M Cowgol
|
||||
that leverages RomWBW memory banking.
|
||||
|
||||
- Les Bird has contributed support for the NABU w/ Option Board
|
||||
|
||||
Contributions of all kinds to RomWBW are very welcome.
|
||||
|
||||
|
||||
|
||||
23
Source/Apps/BBCBASIC/Build.cmd
Normal file
23
Source/Apps/BBCBASIC/Build.cmd
Normal file
@@ -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
Normal file
9
Source/Apps/BBCBASIC/Clean.cmd
Normal file
@@ -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
Normal file
11
Source/Apps/BBCBASIC/Makefile
Normal file
@@ -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
Normal file
1010
Source/Apps/BBCBASIC/asmb.z80
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,3 +1,20 @@
|
||||
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
|
||||
@@ -366,4 +383,73 @@
|
||||
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
Normal file
1494
Source/Apps/BBCBASIC/cmos.z80
Normal file
File diff suppressed because it is too large
Load Diff
69
Source/Apps/BBCBASIC/data.z80
Normal file
69
Source/Apps/BBCBASIC/data.z80
Normal file
@@ -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
|
||||
@@ -1,7 +1,8 @@
|
||||
TITLE BBCDIST.Z80 (C) R.T.RUSSELL 1982
|
||||
TITLE BBCDIST.Z80 (C) R.T.RUSSELL 1982-2024
|
||||
NAME ('DIST3')
|
||||
;
|
||||
;BBC BASIC (Z80) - CP/M VERSION 2.30 & 3.00
|
||||
;(C) COPYRIGHT R.T.RUSSELL, 1982.
|
||||
;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
|
||||
@@ -13,11 +14,14 @@
|
||||
;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
|
||||
;ALTERNATE REGISTERS SAVED FOR BDOS CALL, 04-06-2000
|
||||
;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
|
||||
@@ -26,14 +30,18 @@ COLD EQU 200H
|
||||
GLOBAL GETIME
|
||||
GLOBAL GETKEY
|
||||
GLOBAL BYE
|
||||
GLOBAL BEGIN
|
||||
; GLOBAL BDOS
|
||||
;
|
||||
ASEG
|
||||
ORG 100H
|
||||
; EXTRN PRTDEC16
|
||||
;
|
||||
;ASEG
|
||||
;ORG 100H
|
||||
;
|
||||
;JUMP TABLE - BASIC makes calls to hardware-dependent
|
||||
;features via this table:
|
||||
;
|
||||
JP INIT
|
||||
BEGIN: JP INIT
|
||||
CLRSCN: JP CLS ;CLEAR SCREEN
|
||||
PUTCSR: JP PCSR ;SET CURSOR POSN.
|
||||
GETCSR: JP GCSR ;READ CURSOR POSN.
|
||||
@@ -42,30 +50,33 @@ GETIME: JP GTIME ;READ ELAPSED TIME
|
||||
GETKEY: JP INKEY ;READ KEY (TIME LIMIT)
|
||||
BYE: JP REBOOT ;RETURN TO CP/M
|
||||
;
|
||||
;THE CODE WHICH FOLLOWS IS A SKELETON VERSION SUITABLE
|
||||
;FOR ANY CP/M SYSTEM. IT HAS BEEN CONFIGURED FOR A VT100 TO SOME DEGREE
|
||||
;BY PETER SCHORN.
|
||||
;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
|
||||
;
|
||||
|
||||
PRSTR EQU 9
|
||||
|
||||
;INIT - Perform hardware initialisation (if any).
|
||||
;
|
||||
INIT: LD A,2
|
||||
INC A
|
||||
LD DE,NOTZ80
|
||||
JP PE,FAIL
|
||||
LD C,12
|
||||
CALL BDOS
|
||||
OR A
|
||||
LD DE,NOTV2
|
||||
JP NZ,COLD
|
||||
FAIL: LD C,PRSTR
|
||||
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
|
||||
;
|
||||
NOTZ80: DEFB 'Wrong processor$'
|
||||
NOTV2: DEFB 'Wrong CP/M version$'
|
||||
NOTHB: DEFB 'CP/M w/ HBIOS required$'
|
||||
;
|
||||
;REBOOT - Switch off interrupts and return to CP/M
|
||||
;
|
||||
@@ -75,31 +86,34 @@ REBOOT: RST 0
|
||||
; Outputs: DEHL = elapsed time (centiseconds)
|
||||
; Destroys: A,D,E,H,L,F
|
||||
;
|
||||
GTIME: LD DE,0
|
||||
LD HL,0
|
||||
RET
|
||||
GTIME: JR TICKS
|
||||
;
|
||||
;PTIME - Load elapsed-time clock.
|
||||
; Inputs: DEHL = time to load (centiseconds)
|
||||
; Destroys: A,D,E,H,L,F
|
||||
;
|
||||
PTIME: RET
|
||||
;
|
||||
;CLS - Clear screen for VT100.
|
||||
; Destroys: A,D,E,H,L,F
|
||||
;
|
||||
CLS: PUSH BC ; save BC
|
||||
LD C,PRSTR ; command for output string
|
||||
LD DE,CLSSTR ; start address of string
|
||||
CALL BDOS ; output to terminal
|
||||
POP BC ; restore BC
|
||||
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
|
||||
CLSSTR: DEFB 27,'[2J$' ; VT100 string for clear screen
|
||||
|
||||
;
|
||||
;INKEY - Sample keyboard with specified wait.
|
||||
; This version uses a simple software timing loop.
|
||||
; Modify to use hardware/interrupt timer if available.
|
||||
; Inputs: HL = Time to wait (centiseconds)
|
||||
; Outputs: Carry reset indicates time-out.
|
||||
; If carry set, A = character typed.
|
||||
@@ -107,52 +121,64 @@ CLSSTR: DEFB 27,'[2J$' ; VT100 string for clear screen
|
||||
;
|
||||
INKEY: PUSH BC
|
||||
PUSH HL
|
||||
CALL TICKS
|
||||
POP DE
|
||||
ADD HL,DE
|
||||
WAIT: PUSH HL
|
||||
LD C,6
|
||||
LD E,0FFH
|
||||
CALL BDOS ;CONSOLE INPUT
|
||||
CALL BDOS
|
||||
POP HL
|
||||
POP BC
|
||||
OR A
|
||||
SCF
|
||||
RET NZ ;KEY PRESSED
|
||||
OR H
|
||||
OR L
|
||||
RET Z ;TIME-OUT
|
||||
PUSH BC
|
||||
LD A,-1
|
||||
LD BC,1250 ;DELAY CONSTANT
|
||||
WAIT: DEC BC
|
||||
CP B
|
||||
JP NZ,WAIT ;WAIT FOR APPROX 10ms
|
||||
POP BC
|
||||
DEC HL
|
||||
JR INKEY
|
||||
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)
|
||||
; called by TAB(column, row)
|
||||
; 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,PRSTR ; output string command
|
||||
LD C,9 ; output string command
|
||||
LD DE,CURS ; start of string
|
||||
JR BDOS ; output string to terminal
|
||||
|
||||
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
|
||||
@@ -164,35 +190,7 @@ CONVLP: INC A ; now B times increment AL in decimal
|
||||
CONT: DJNZ CONVLP ; B times
|
||||
LD H,A ; put low byte into right place
|
||||
RET
|
||||
|
||||
|
||||
;BDOS - Save the IX and IY and alternate registers
|
||||
; before performing a CP/M function call.
|
||||
;
|
||||
BDOS: PUSH IX
|
||||
PUSH IY
|
||||
EXX
|
||||
PUSH BC
|
||||
PUSH DE
|
||||
PUSH HL
|
||||
EXX
|
||||
EX AF,AF'
|
||||
PUSH AF
|
||||
EX AF,AF'
|
||||
CALL CPM
|
||||
EX AF,AF'
|
||||
POP AF
|
||||
EX AF,AF'
|
||||
EXX
|
||||
POP HL
|
||||
POP DE
|
||||
POP BC
|
||||
EXX
|
||||
POP IY
|
||||
POP IX
|
||||
RET
|
||||
|
||||
|
||||
;GCSR - Return cursor coordinates.
|
||||
; Outputs: DE = X coordinate (POS)
|
||||
; HL = Y coordinate (VPOS)
|
||||
@@ -202,24 +200,42 @@ GCSR: LD DE,0
|
||||
LD HL,0
|
||||
RET
|
||||
;
|
||||
IF $ GT 1F4H
|
||||
;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 1F4H
|
||||
;ORG 1F0H
|
||||
DEFS 0F0H - ($ - BEGIN)
|
||||
;
|
||||
OFFLO: DEFW 0 ;TIME OFFSET LO
|
||||
OFFHI: DEFW 0 ;TIME OFFSET HI
|
||||
DEFB 80 ;WIDTH
|
||||
DEFB 'E' AND 1FH ;CURSOR UP
|
||||
DEFB 'X' AND 1FH ;CURSOR DOWN
|
||||
DEFB 'A' AND 1FH ;START OF LINE
|
||||
DEFB 'F' AND 1FH ;END OF LINE
|
||||
DEFB 'T' AND 1FH ;DELETE TO END OF LINE
|
||||
DEFB 'H' AND 1FH ;BACKSPACE
|
||||
DEFB 'U' AND 1FH ;CANCEL LINE
|
||||
DEFB 'S' AND 1FH ;CURSOR LEFT
|
||||
DEFB 'D' AND 1FH ;CURSOR RIGHT
|
||||
DEFB 'G' AND 1FH ;DELETE CHARACTER
|
||||
DEFB 'V' AND 1FH ;INSERT CHARACTER
|
||||
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
Normal file
2587
Source/Apps/BBCBASIC/eval.z80
Normal file
File diff suppressed because it is too large
Load Diff
3274
Source/Apps/BBCBASIC/exec.z80
Normal file
3274
Source/Apps/BBCBASIC/exec.z80
Normal file
File diff suppressed because it is too large
Load Diff
64
Source/Apps/BBCBASIC/hook.z80
Normal file
64
Source/Apps/BBCBASIC/hook.z80
Normal file
@@ -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
Normal file
2237
Source/Apps/BBCBASIC/main.z80
Normal file
File diff suppressed because it is too large
Load Diff
2267
Source/Apps/BBCBASIC/math.z80
Normal file
2267
Source/Apps/BBCBASIC/math.z80
Normal file
File diff suppressed because it is too large
Load Diff
@@ -30,6 +30,7 @@ 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
|
||||
pushd BBCBASIC && call Build || exit /b & popd
|
||||
|
||||
copy *.com %APPBIN%\ || exit /b
|
||||
|
||||
|
||||
@@ -19,3 +19,4 @@ 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
|
||||
pushd BBCBASIC && call Clean || exit /b 1 & popd
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# RomWBW HBIOS CP/M FAT Utility ("FAT.COM")
|
||||
|
||||
Author: Wayne Warthen \
|
||||
Updated: 6-Jan-2024
|
||||
Updated: 6-May-2024
|
||||
|
||||
This application allows copying files between CP/M filesystems and FAT
|
||||
filesystems (DOS, Windows, Mac, Linux, etc.). The application runs on
|
||||
@@ -72,6 +72,38 @@ creation.
|
||||
- Wildcard matching in FAT filesystems is a bit unusual as
|
||||
implemented by FatFs. See FatFs documentation.
|
||||
|
||||
- The `FAT FORMAT` command will not perform a physical format on
|
||||
floppy disks. You must use FDU to do this prior to using
|
||||
`FAT FORMAT`.
|
||||
|
||||
- Formatting (`FAT FORMAT`) of floppies does not work well. The
|
||||
underlying FatFs library uses some non-standard fields. The
|
||||
resulting floppy may or may not be useable on other systems. It is
|
||||
best to format a FAT floppy on a Windows or DOS system. You should
|
||||
have no problems copying files to/from such a floppy using `FAT`.
|
||||
|
||||
### Known Issues
|
||||
|
||||
- CP/M (and workalike) OSes have significant restrictions on filename
|
||||
characters. The FAT application will block any attempt to create a
|
||||
file on the CP/M filesystem containing any of these prohibited
|
||||
characters:
|
||||
|
||||
| `< > . , ; : ? * [ ] |/ \`
|
||||
|
||||
The operation will be aborted with "`Error: Invalid Path Name`" if such
|
||||
a filename character is encountered.
|
||||
|
||||
Since MS-DOS does allow some of these characters, you can have
|
||||
issues when copying files from MS-DOS to CP/M if the MS-DOS filenames
|
||||
use these characters. Unfortunately, FAT is not yet smart enough to
|
||||
substitute illegal characters with legal ones. So, you will need to
|
||||
clean the filenames before trying to copy them to CP/M.
|
||||
|
||||
- The FAT application does try to detect the scenario where you are
|
||||
copying a file to itself. However, this detection is not perfect and
|
||||
can corrupt a file if it occurs. Be careful to avoid this.
|
||||
|
||||
### License:
|
||||
|
||||
GNU GPLv3 (see file LICENSE.txt)
|
||||
@@ -123,3 +155,4 @@ creation.
|
||||
| 12-Oct-2023 | v0.9.9 | (beta) handle updated HBIOS Disk Device call |
|
||||
| 6-Jan-2024 | v1.0.0 | updated to latest FsFat (v0.15) |
|
||||
| | | updated to latest SDCC (v4.3) |
|
||||
| 6-May-2024 | v1.1.0 | improve floppy format boot record |
|
||||
|
||||
Binary file not shown.
@@ -1,6 +1,6 @@
|
||||
OBJECTS = sysgen.com syscopy.com assign.com format.com talk.com \
|
||||
mode.com rtc.com timer.com rtchb.com
|
||||
SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd Survey
|
||||
SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd Survey BBCBASIC
|
||||
DEST = ../../Binary/Apps
|
||||
TOOLS =../../Tools
|
||||
|
||||
|
||||
@@ -24,6 +24,7 @@ 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
|
||||
|
||||
|
||||
@@ -21,3 +21,4 @@ pushd 2piotst && call Clean || exit /b 1 & popd
|
||||
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
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
OBJECTS =
|
||||
SUBDIRS = DMAmon I2C inttest ppidetst ramtest tstdskng rzsz vdctest kbdtest ps2info 2piotst piomon banktest portscan
|
||||
SUBDIRS = DMAmon I2C inttest ppidetst ramtest tstdskng rzsz vdctest kbdtest ps2info 2piotst piomon banktest portscan sound
|
||||
DEST = ../../../Binary/Apps/Test
|
||||
TOOLS =../../../Tools
|
||||
|
||||
|
||||
@@ -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
|
||||
|
||||
@@ -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"
|
||||
|
||||
12
Source/Apps/Test/sound/Build.cmd
Normal file
12
Source/Apps/Test/sound/Build.cmd
Normal file
@@ -0,0 +1,12 @@
|
||||
@echo off
|
||||
setlocal
|
||||
|
||||
set TOOLS=../../../../Tools
|
||||
set PATH=%TOOLS%\tasm32;%PATH%
|
||||
set TASMTABS=%TOOLS%\tasm32
|
||||
|
||||
tasm -t80 -g3 -fFF sound.asm sound.com sound.lst || exit /b
|
||||
tasm -t80 -g3 -fFF ay-test.asm ay-test.com ay-test.lst || exit /b
|
||||
|
||||
copy /Y sound.com ..\..\..\..\Binary\Apps\Test\ || exit /b
|
||||
copy /Y ay-test.com ..\..\..\..\Binary\Apps\Test\ || exit /b
|
||||
6
Source/Apps/Test/sound/Clean.cmd
Normal file
6
Source/Apps/Test/sound/Clean.cmd
Normal file
@@ -0,0 +1,6 @@
|
||||
@echo off
|
||||
setlocal
|
||||
|
||||
if exist *.com del *.com
|
||||
if exist *.lst del *.lst
|
||||
if exist *.bin del *.bin
|
||||
7
Source/Apps/Test/sound/Makefile
Normal file
7
Source/Apps/Test/sound/Makefile
Normal file
@@ -0,0 +1,7 @@
|
||||
OBJECTS = ay-test.com sound.com
|
||||
DEST = ../../../../Binary/Apps/Test
|
||||
TOOLS =../../../../Tools
|
||||
|
||||
USETASM=1
|
||||
|
||||
include $(TOOLS)/Makefile.inc
|
||||
@@ -1,329 +0,0 @@
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PLAY SCALES USING HBIOS
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
FCB .EQU $5C ; Location of default FCB
|
||||
BDOS .EQU $0005
|
||||
;
|
||||
.ORG $0100
|
||||
;
|
||||
LD (OLDSTACK),SP ; save old stack pointer
|
||||
LD SP,STACK ; set new stack pointer
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; GET DEVICE # FROM COMMAND LINE
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
LD A,(FCB+1) ; GET FIRST CHAR
|
||||
SUB ' '
|
||||
JR Z,NO_ARG
|
||||
SUB '0'-' '
|
||||
JP C,EXIT
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; DISPLAY DEVICE AND NUMBER OF CHANNELS
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
NO_ARG: LD (DEVICE),A ;
|
||||
LD DE,TXT_DEV ; DEVICE:
|
||||
CALL PRTSTR
|
||||
CALL PRTDECB
|
||||
LD C,A ; GET DEVICE ID
|
||||
LD A,':'
|
||||
CALL PRTCHR
|
||||
LD B,$55
|
||||
PUSH BC
|
||||
LD E,4
|
||||
RST 08
|
||||
LD DE,TXT_NAME
|
||||
LD A,B
|
||||
RRCA \ RRCA \ RRCA \ RRCA
|
||||
CALL PRTIDXDEA ; SHOW NAME
|
||||
LD DE,TXT_CH
|
||||
CALL PRTSTR
|
||||
;
|
||||
POP BC ; GET & DISPLAY # CHANNELS
|
||||
LD E,1
|
||||
RST 08
|
||||
LD A,B
|
||||
CALL PRTDECB
|
||||
CALL CRLF ; NUMBER OF CHANNELS IS IN B
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; LOOP THROUGH EACH CHANNEL
|
||||
;------------------------------------------------------------------------------
|
||||
|
||||
CH__TONE: LD A,(DEVICE) ; C CONTAINS DEVICE
|
||||
LD C,A ; THROUGH THIS LOOP
|
||||
;
|
||||
PUSH BC
|
||||
LD B,50H ; RESET DEVICE
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
PUSH BC
|
||||
LD B,51H ; VOLUME FULL
|
||||
LD L,0FFH
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD A,B
|
||||
TST_TONE_LP: DEC A
|
||||
LD (CHANNEL),A ; SAVE CURRENT CHANNEL
|
||||
CALL TST_SCALES ; SCALES TEST
|
||||
; CALL TST_VOLUME ; VOLUME TEST
|
||||
CALL CRLF
|
||||
DJNZ TST_TONE_LP
|
||||
;
|
||||
PUSH BC
|
||||
LD B,50H ; RESET DEVICE
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; RESTORE STACK & EXIT
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
EXIT: LD SP, (OLDSTACK) ; Exit to CP/M
|
||||
RST 00H
|
||||
DI
|
||||
HALT
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PLAY SCALES FROM HIGHEST HBIOS NOTE TO LOWEST
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
TST_SCALES: PUSH BC
|
||||
PUSH AF
|
||||
;
|
||||
LD HL,380 ; START NOTE
|
||||
LD (NOTE),HL ; Top of Octave 7 is 343
|
||||
|
||||
LD B,51H ; VOLUME HIGH
|
||||
LD L,0FFH
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
NEXT0: PUSH BC
|
||||
;
|
||||
LD DE,TXT_TSTCH ; DISPLAY CHANNEL
|
||||
CALL PRTSTR
|
||||
LD A,(CHANNEL)
|
||||
CALL PRTDECB
|
||||
;
|
||||
LD DE,TXT_NOTE ; DISPLAY NOTE
|
||||
CALL PRTSTR
|
||||
LD HL,(NOTE)
|
||||
CALL PRTDECW
|
||||
POP BC
|
||||
;
|
||||
LD B,53H ; SET NOTE
|
||||
LD HL,(NOTE)
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
|
||||
OR A ; DID DRIVER FAIL
|
||||
JR Z,NEXT4 ; THIS NOTE ?
|
||||
|
||||
LD DE,TXT_BAD_N
|
||||
CALL FAILMSG
|
||||
JR SKIP
|
||||
;
|
||||
NEXT4: LD B,57H ; DURATION
|
||||
LD HL,1000
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
OR A ; DID DRIVER FAIL
|
||||
JR Z,NEXT2 ; TO PLAY ?
|
||||
|
||||
LD DE,TXT_BAD_N
|
||||
CALL FAILMSG
|
||||
JR SKIP
|
||||
;
|
||||
NEXT2: CALL DELAY
|
||||
CALL CRLF
|
||||
;
|
||||
SKIP: LD HL,(NOTE)
|
||||
DEC HL
|
||||
LD (NOTE),HL
|
||||
|
||||
INC HL
|
||||
LD A,H
|
||||
OR L
|
||||
DEC HL
|
||||
JR NZ,NEXT0
|
||||
;
|
||||
LD B,51H ; VOLUME
|
||||
LD L,00H ; OFF
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
|
||||
PUSH BC
|
||||
LD C, 6 ; check for keypress
|
||||
LD E,0FFH
|
||||
CALL BDOS
|
||||
POP BC
|
||||
OR A
|
||||
JP NZ,EXIT
|
||||
|
||||
POP AF
|
||||
POP BC
|
||||
;
|
||||
RET
|
||||
;
|
||||
FAILMSG: PUSH AF
|
||||
PUSH BC
|
||||
CALL PRTSTR
|
||||
CALL CRLF
|
||||
POP BC
|
||||
POP AF
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; CONSTANT TONE ON ALL CHANNELS, SCALE VOLUME
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
TST_VOLUME:
|
||||
LD HL,332+48 ; TONE
|
||||
LD (NOTE),HL
|
||||
;
|
||||
LD B,3
|
||||
NEXTCH1 LD A,B
|
||||
DEC A
|
||||
LD (CHANNEL),A
|
||||
PUSH BC ; ACROSS
|
||||
CALL TONE ; ALL
|
||||
|
||||
LD C, 6 ; KEYPRESS
|
||||
LD E, 0FFH
|
||||
CALL BDOS
|
||||
POP BC ; CHANNELS
|
||||
|
||||
OR A
|
||||
JP NZ,EXIT
|
||||
|
||||
DJNZ NEXTCH1
|
||||
|
||||
RET
|
||||
|
||||
TONE: LD A,(DEVICE)
|
||||
LD C,A
|
||||
|
||||
LD B,50H ; RESET
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
NEXT1: LD B,51H ; VOLUME
|
||||
LD A,(VOLUME)
|
||||
LD L,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,53H ; NOTE
|
||||
LD HL,(NOTE)
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
CALL DELAY
|
||||
;
|
||||
LD A,(VOLUME)
|
||||
DEC A
|
||||
LD (VOLUME),A
|
||||
JR NZ,NEXT1
|
||||
;
|
||||
LD B,51H ; VOLUME
|
||||
LD L,00H
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
PUSH BC
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
POP BC
|
||||
RST 08
|
||||
;
|
||||
RET
|
||||
;;
|
||||
;------------------------------------------------------------------------------
|
||||
; LONG DELAY
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
DELAY: LD HL,-1
|
||||
DELAY1: DEC HL
|
||||
LD A,H
|
||||
OR L
|
||||
JR NZ,DELAY1
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PRINT THE nTH STRING IN A LIST OF STRINGS WHERE EACH IS TERMINATED BY 0
|
||||
; A REGISTER DEFINES THE nTH STRING IN THE LIST TO PRINT AND DE POINTS
|
||||
; TO THE START OF THE STRING LIST.
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
PRTIDXDEA: LD C,A
|
||||
OR A
|
||||
PRTIDXDEA1: JR Z,PRTIDXDEA3 ; FOUND TARGET SO EXIT
|
||||
PRTIDXDEA2: LD A,(DE) ; LOOP UNIT
|
||||
INC DE ; WE REACH
|
||||
OR A ; END OF STRING
|
||||
JR NZ,PRTIDXDEA2
|
||||
DEC C ; AT STRING END. SO GO
|
||||
JR PRTIDXDEA1 ; CHECK FOR INDEX MATCH
|
||||
PRTIDXDEA3: CALL PRTSTR ; DISPLAY THE STRING
|
||||
RET
|
||||
;
|
||||
#INCLUDE "printing.inc"
|
||||
;
|
||||
TXT_CH .DB "CHANNELS: ",0
|
||||
TXT_TSTCH .DB "CHANNEL: ",0
|
||||
TXT_BAD_N .DB " BAD NOTE",0
|
||||
TXT_BAD_P .DB " PLAY ERROR",0
|
||||
TXT_NOTE .DB " NOTE: ",0
|
||||
TXT_DEV .DB "DEVICE: ",0
|
||||
TXT_NAME .DB "SN76489 ",0
|
||||
.DB "AY-3-8910 ",0
|
||||
.DB "I/O PORT ",0
|
||||
.DB "YM2612 ",0
|
||||
MODE .DB 0 ; scales mode or volume mode
|
||||
DEVICE .DB 0
|
||||
NOTE .DW 128
|
||||
VOLUME .DB 0
|
||||
CHANNEL .DB 0
|
||||
OLDSTACK .DW 0 ; original stack pointer
|
||||
.DS 40H ; space for stack
|
||||
STACK ; top of stack
|
||||
;
|
||||
.END
|
||||
177
Source/Apps/Test/sound/printing.inc
Normal file
177
Source/Apps/Test/sound/printing.inc
Normal file
@@ -0,0 +1,177 @@
|
||||
;
|
||||
; 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
|
||||
;
|
||||
PRTDOT:
|
||||
;
|
||||
; shortcut to print a dot preserving all regs
|
||||
PUSH AF ; save af
|
||||
LD A,'.' ; load dot char
|
||||
CALL PRTCHR ; print it
|
||||
POP AF ; restore af
|
||||
RET ; done
|
||||
;
|
||||
PRTCR:
|
||||
;
|
||||
; shortcut to print a carriage return preserving all regs
|
||||
PUSH AF ; save af
|
||||
LD A,13 ; load CR value
|
||||
CALL PRTCHR ; print it
|
||||
POP AF ; restore af
|
||||
RET ; done
|
||||
;
|
||||
; Print a zero terminated string at (DE) without destroying any registers
|
||||
;
|
||||
PRTSTR:
|
||||
PUSH AF
|
||||
PUSH DE
|
||||
;
|
||||
PRTSTR1:
|
||||
LD A,(DE) ; get next char
|
||||
OR A
|
||||
JR Z,PRTSTR2
|
||||
CALL PRTCHR
|
||||
INC DE
|
||||
JR PRTSTR1
|
||||
;
|
||||
PRTSTR2:
|
||||
POP DE ; restore registers
|
||||
POP AF
|
||||
RET
|
||||
;
|
||||
; Print the value in A in hex without destroying any registers
|
||||
;
|
||||
PRTHEX:
|
||||
PUSH AF ; save AF
|
||||
PUSH DE ; save DE
|
||||
CALL HEXASCII ; convert value in A to hex chars in DE
|
||||
LD A,D ; get the high order hex char
|
||||
CALL PRTCHR ; print it
|
||||
LD A,E ; get the low order hex char
|
||||
CALL PRTCHR ; print it
|
||||
POP DE ; restore DE
|
||||
POP AF ; restore AF
|
||||
RET ; done
|
||||
;
|
||||
; print the hex word value in bc
|
||||
;
|
||||
PRTHEXWORD:
|
||||
PUSH AF
|
||||
LD A,B
|
||||
CALL PRTHEX
|
||||
LD A,C
|
||||
CALL PRTHEX
|
||||
POP AF
|
||||
RET
|
||||
;
|
||||
; 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
|
||||
|
||||
;
|
||||
; Print value of A or HL in decimal with leading zero suppression
|
||||
; Use prtdecb for A or prtdecw for HL
|
||||
;
|
||||
PRTDECB:
|
||||
PUSH HL
|
||||
LD H,0
|
||||
LD L,A
|
||||
CALL PRTDECW ; print it
|
||||
POP HL
|
||||
RET
|
||||
;
|
||||
PRTDECW:
|
||||
PUSH AF
|
||||
PUSH BC
|
||||
PUSH DE
|
||||
PUSH HL
|
||||
CALL PRTDEC0
|
||||
POP HL
|
||||
POP DE
|
||||
POP BC
|
||||
POP AF
|
||||
RET
|
||||
;
|
||||
PRTDEC0:
|
||||
LD E,'0'
|
||||
LD BC,-10000
|
||||
CALL PRTDEC1
|
||||
LD BC,-1000
|
||||
CALL PRTDEC1
|
||||
LD BC,-100
|
||||
CALL PRTDEC1
|
||||
LD C,-10
|
||||
CALL PRTDEC1
|
||||
LD E,0
|
||||
LD C,-1
|
||||
PRTDEC1:
|
||||
LD A,'0' - 1
|
||||
PRTDEC2:
|
||||
INC A
|
||||
ADD HL,BC
|
||||
JR C,PRTDEC2
|
||||
SBC HL,BC
|
||||
CP E
|
||||
RET Z
|
||||
LD E,0
|
||||
CALL PRTCHR
|
||||
RET
|
||||
;
|
||||
; 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
|
||||
460
Source/Apps/Test/sound/sound.asm
Normal file
460
Source/Apps/Test/sound/sound.asm
Normal file
@@ -0,0 +1,460 @@
|
||||
;
|
||||
;=======================================================================
|
||||
; RomWBW HBIOS Sound Device Test Tool (SOUND)
|
||||
;=======================================================================
|
||||
;
|
||||
; Simple utility that can exercise a sound device in RomWBW. It can
|
||||
; play a single tone, sliding scale, or sliding volume.
|
||||
;
|
||||
; I'm not actually sure who wrote the original version of this, but I
|
||||
; suspect it was Phil Summers.
|
||||
;
|
||||
; WBW 2024-03-21: Control test function by command line
|
||||
; Add (T)one function
|
||||
;
|
||||
;=======================================================================
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PLAY SCALES USING HBIOS
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
FCB .EQU $5C ; Location of default FCB
|
||||
BDOS .EQU $0005
|
||||
;
|
||||
.ORG $0100
|
||||
;
|
||||
LD (OLDSTACK),SP ; save old stack pointer
|
||||
LD SP,STACK ; set new stack pointer
|
||||
;
|
||||
LD DE,TXT_BANNER
|
||||
CALL PRTSTR
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PARSE COMMAND LINE
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
LD HL,FCB+1 ; POINT TO FCB CHARS
|
||||
LD B,8 ; PARSE 8 CHARS
|
||||
PARSE:
|
||||
PUSH BC
|
||||
LD A,(HL) ; GET NEXT CHAR
|
||||
;
|
||||
; IF NUMBER, SET DEVICE ID
|
||||
CP '0'
|
||||
JR C,PARSE1 ; IF < 0, SKIP
|
||||
CP '9'+ 1
|
||||
JR NC,PARSE1 ; IF > 9, SKIP
|
||||
SUB '0' ; MAKE BINARY
|
||||
LD (DEVICE),A ; SAVE DEVICE NUM
|
||||
JR PARSE2 ; CONTINUE LOOP
|
||||
PARSE1:
|
||||
; IF LETTER, SET RUN OPTION
|
||||
CP 'A'
|
||||
JR C,PARSE2 ; IF < A, SKIP
|
||||
CP 'Z'+ 1
|
||||
JR NC,PARSE1 ; IF > Z, SKIP
|
||||
LD (OPTION),A ; SAVE RUN OPTION
|
||||
JR PARSE2 ; CONTINUE LOOP
|
||||
;
|
||||
PARSE2:
|
||||
INC HL ; BUMP PTR
|
||||
DJNZ PARSE
|
||||
;
|
||||
LD A,(OPTION) ; GET OPTION
|
||||
CP ' ' ; HAVE OPTION?
|
||||
JR NZ,RUN ; IF SO, RUN
|
||||
LD DE,TXT_USAGE ; ELSE GET USAGE
|
||||
CALL PRTSTR ; AND DISPLAY IT
|
||||
JP EXIT ; AND GET OUT
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; DISPLAY DEVICE AND NUMBER OF CHANNELS
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
RUN:
|
||||
LD DE,TXT_DEV ; DEVICE:
|
||||
CALL PRTSTR
|
||||
LD A,(DEVICE)
|
||||
CALL PRTDECB
|
||||
LD C,A ; GET DEVICE ID
|
||||
LD A,':'
|
||||
CALL PRTCHR
|
||||
;
|
||||
LD B,$55 ; HBIOS SND QUERY
|
||||
LD A,(DEVICE)
|
||||
LD C,A
|
||||
;
|
||||
PUSH BC ; SAVE FUNC AND ID
|
||||
LD E,4 ; HBIOS SNDQ DEV
|
||||
RST 08
|
||||
LD A,B
|
||||
;RRCA \ RRCA \ RRCA \ RRCA
|
||||
LD DE,TXT_NAME
|
||||
CALL PRTIDXDEA ; SHOW NAME
|
||||
;
|
||||
LD DE,TXT_CH
|
||||
CALL PRTSTR
|
||||
POP BC ; RESTORE FUNC AND ID
|
||||
LD E,1 ; HBIOS SNDQ_CHCNT
|
||||
RST 08
|
||||
LD A,B ; NUMBER OF CHANNELS IS IN B
|
||||
LD (CHANNELS),A ; SAVE IT
|
||||
CALL PRTDECB ; PRINT IT
|
||||
CALL CRLF
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; LOOP THROUGH EACH CHANNEL
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
LD A,(DEVICE) ; GET DEVICE
|
||||
LD C,A ; INTO C
|
||||
PUSH BC ; SAVE IT
|
||||
LD B,$50 ; RESET SND DEVICE
|
||||
RST 08 ; DO IT
|
||||
POP BC ; RECOVER DEVICE
|
||||
LD B,$51 ; SET VOLUME
|
||||
LD L,$FF ; TO MAX
|
||||
RST 08 ; DO IT
|
||||
;
|
||||
LD A,(CHANNELS)
|
||||
LD B,A ; B IS LOOP COUNTER
|
||||
LD C,0 ; C IS CHANNEL INDEX
|
||||
;
|
||||
CH_LOOP:
|
||||
PUSH BC ; SAVE LOOP CTL
|
||||
LD A,C ; CHANNEL
|
||||
LD (CHANNEL),A ; TO STORAGE
|
||||
CALL CH_RUN ; DO CHANNEL
|
||||
PUSH AF
|
||||
LD A,(DEVICE)
|
||||
LD C,A
|
||||
LD B,50H ; RESET
|
||||
RST 08
|
||||
POP AF
|
||||
POP BC ; RECOVER LOOP CTL
|
||||
JR NZ,EXIT ; HANDLE ERROR/ABORT
|
||||
INC C ; NEXT CHANNEL
|
||||
DJNZ CH_LOOP ; LOOP AS NEEDED
|
||||
;
|
||||
LD A,(DEVICE) ; GET DEVICE
|
||||
LD C,A ; TO C
|
||||
LD B,50H ; RESET DEVICE
|
||||
RST 08 ; DO IT
|
||||
JR EXIT ; DONE
|
||||
;
|
||||
CH_RUN:
|
||||
LD A,(OPTION) ; RUN OPTION
|
||||
CP 'S' ; SCALES?
|
||||
JP Z,TST_SCALES ; IF SO, DO SCALES
|
||||
CP 'V' ; VOLUME?
|
||||
JP Z,TST_VOLUME ; IF SO, DO VOLUME
|
||||
CP 'T' ; TONE
|
||||
JP Z,TST_TONE ; IF SO, DO TONE
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; RESTORE STACK & EXIT
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
EXIT: LD SP, (OLDSTACK) ; Exit to CP/M
|
||||
RST 00H
|
||||
DI
|
||||
HALT
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PLAY SCALES FROM HIGHEST HBIOS NOTE TO LOWEST
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
TST_SCALES: LD A,(DEVICE) ; SETUP DEVICE FOR BELOW
|
||||
LD C,A
|
||||
;
|
||||
LD HL,380 ; START NOTE
|
||||
LD (NOTE),HL ; Top of Octave 7 is 343
|
||||
|
||||
LD B,51H ; VOLUME HIGH
|
||||
LD L,0FFH ; MAX
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
NEXT0: PUSH BC
|
||||
;
|
||||
LD DE,TXT_TSTCH ; DISPLAY CHANNEL
|
||||
CALL PRTSTR
|
||||
LD A,(CHANNEL)
|
||||
CALL PRTDECB
|
||||
;
|
||||
LD DE,TXT_NOTE ; DISPLAY NOTE
|
||||
CALL PRTSTR
|
||||
LD HL,(NOTE)
|
||||
CALL PRTDECW
|
||||
POP BC
|
||||
;
|
||||
LD B,53H ; SET NOTE
|
||||
LD HL,(NOTE)
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
|
||||
OR A ; DID DRIVER FAIL
|
||||
JR Z,NEXT4 ; THIS NOTE ?
|
||||
|
||||
LD DE,TXT_BAD_N
|
||||
CALL FAILMSG
|
||||
JR SKIP
|
||||
;
|
||||
NEXT4: LD B,57H ; DURATION
|
||||
LD HL,1000
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
OR A ; DID DRIVER FAIL
|
||||
JR Z,NEXT2 ; TO PLAY ?
|
||||
|
||||
LD DE,TXT_BAD_N
|
||||
CALL FAILMSG
|
||||
JR SKIP
|
||||
;
|
||||
NEXT2: CALL DELAY
|
||||
CALL CRLF
|
||||
;
|
||||
SKIP:
|
||||
PUSH BC
|
||||
LD C, 6 ; CHECK FOR KEYPRESS
|
||||
LD E,0FFH
|
||||
CALL BDOS
|
||||
POP BC
|
||||
OR A ; SET RESULT
|
||||
RET NZ ; RETURN IF ABORT
|
||||
|
||||
LD HL,(NOTE)
|
||||
DEC HL
|
||||
LD (NOTE),HL
|
||||
|
||||
INC HL
|
||||
LD A,H
|
||||
OR L
|
||||
DEC HL
|
||||
JR NZ,NEXT0
|
||||
;
|
||||
LD B,51H ; VOLUME
|
||||
LD L,00H ; OFF
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
XOR A ; SET RESULT
|
||||
RET
|
||||
;
|
||||
FAILMSG: PUSH BC
|
||||
CALL PRTSTR
|
||||
CALL CRLF
|
||||
POP BC
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; CONSTANT TONE ON ALL CHANNELS, SCALE VOLUME
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
TST_VOLUME:
|
||||
; LD HL,332+48 ; TONE
|
||||
LD HL,244 ; ~1000 HZ
|
||||
LD (NOTE),HL
|
||||
;
|
||||
LD DE,TXT_TSTCH ; DISPLAY CHANNEL
|
||||
CALL PRTSTR
|
||||
LD A,(CHANNEL)
|
||||
CALL PRTDECB
|
||||
|
||||
LD A,(DEVICE)
|
||||
LD C,A
|
||||
|
||||
LD B,50H ; RESET
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
NEXT1:
|
||||
LD B,51H ; VOLUME
|
||||
LD A,(VOLUME)
|
||||
LD L,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,53H ; NOTE
|
||||
LD HL,(NOTE)
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
CALL DELAY
|
||||
|
||||
PUSH BC
|
||||
LD C, 6 ; KEYPRESS
|
||||
LD E, 0FFH
|
||||
CALL BDOS
|
||||
POP BC ; RECOVER LOOP CTRL
|
||||
OR A ; KEY PRESSED?
|
||||
RET NZ ; BAIL OUT IF SO
|
||||
;
|
||||
LD A,(VOLUME)
|
||||
DEC A
|
||||
LD (VOLUME),A
|
||||
JR NZ,NEXT1
|
||||
;
|
||||
CALL CRLF
|
||||
;
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; 1 KHZ TONE ON CHANNEL, PLAY TILL KEYPRESS
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
TST_TONE:
|
||||
LD HL,244 ; ~1000 HZ
|
||||
LD (NOTE),HL
|
||||
;
|
||||
LD DE,TXT_TSTCH ; DISPLAY CHANNEL
|
||||
CALL PRTSTR
|
||||
LD A,(CHANNEL)
|
||||
CALL PRTDECB
|
||||
;
|
||||
LD A,(DEVICE)
|
||||
LD C,A
|
||||
;
|
||||
LD B,50H ; RESET
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,51H ; VOLUME
|
||||
LD A,$FF ; MAX
|
||||
LD L,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
LD B,53H ; NOTE
|
||||
LD HL,(NOTE)
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
TST_TONE1:
|
||||
;
|
||||
LD B,54H ; PLAY
|
||||
LD A,(CHANNEL)
|
||||
LD D,A
|
||||
PUSH BC
|
||||
RST 08
|
||||
POP BC
|
||||
;
|
||||
;CALL DELAY
|
||||
;
|
||||
PUSH BC
|
||||
LD C, 6 ; KEYPRESS
|
||||
LD E, 0FFH
|
||||
CALL BDOS
|
||||
OR A ; KEY PRESSED?
|
||||
POP BC
|
||||
JR Z,TST_TONE1
|
||||
CALL CRLF
|
||||
XOR A
|
||||
RET ; RETURN ON KEYPRESS
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; LONG DELAY
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
;DELAY: LD HL,-1
|
||||
DELAY: LD HL,1000
|
||||
DELAY1: DEC HL
|
||||
LD A,H
|
||||
OR L
|
||||
JR NZ,DELAY1
|
||||
RET
|
||||
;
|
||||
;------------------------------------------------------------------------------
|
||||
; PRINT THE nTH STRING IN A LIST OF STRINGS WHERE EACH IS TERMINATED BY 0
|
||||
; A REGISTER DEFINES THE nTH STRING IN THE LIST TO PRINT AND DE POINTS
|
||||
; TO THE START OF THE STRING LIST.
|
||||
;------------------------------------------------------------------------------
|
||||
;
|
||||
PRTIDXDEA: LD C,A
|
||||
OR A
|
||||
PRTIDXDEA1: JR Z,PRTIDXDEA3 ; FOUND TARGET SO EXIT
|
||||
PRTIDXDEA2: LD A,(DE) ; LOOP UNIT
|
||||
INC DE ; WE REACH
|
||||
OR A ; END OF STRING
|
||||
JR NZ,PRTIDXDEA2
|
||||
DEC C ; AT STRING END. SO GO
|
||||
JR PRTIDXDEA1 ; CHECK FOR INDEX MATCH
|
||||
PRTIDXDEA3: CALL PRTSTR ; DISPLAY THE STRING
|
||||
RET
|
||||
;
|
||||
#INCLUDE "printing.inc"
|
||||
;
|
||||
TXT_BANNER .DB 13,10,"RomWBW HBIOS Sound Tool v1.0, 21-Mar-2024",13,10,13,10,0
|
||||
TXT_USAGE .DB "Usage:",13,10
|
||||
.DB "SOUND <d><o>",13,10
|
||||
.DB "",13,10
|
||||
.DB " <d> is number of sound device",13,10
|
||||
.DB " <o> is option to run:",13,10
|
||||
.DB " 'T': play a 1 KHz tone on each channel until keypress",13,10
|
||||
.DB " 'S': play a scale of notes on each channel",13,10
|
||||
.DB " 'V': play a 1 KHz tone at all volumes on each channel",13,10
|
||||
.DB "",13,10
|
||||
.DB "Examples:",13,10
|
||||
.DB "SOUND 1T - play a tone on all channels of sound device unit #1",13,10
|
||||
.DB "SOUND 0S - play a scale on all channels of sound device unit #0",13,10,0
|
||||
TXT_CH .DB "CHANNELS=",0
|
||||
TXT_TSTCH .DB "CHANNEL: ",0
|
||||
TXT_BAD_N .DB " BAD NOTE",0
|
||||
TXT_BAD_P .DB " PLAY ERROR",0
|
||||
TXT_NOTE .DB " NOTE: ",0
|
||||
TXT_VOL .DB " VOLUME: ",0
|
||||
TXT_DEV .DB "DEVICE: ",0
|
||||
TXT_NAME .DB "SN76489 ",0
|
||||
.DB "AY-3-8910 ",0
|
||||
.DB "I/O PORT ",0
|
||||
.DB "YM2612 ",0
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
MODE .DB 0 ; scales mode or volume mode
|
||||
DEVICE .DB 0
|
||||
OPTION .DB ' ' ; run scales
|
||||
NOTE .DW 128
|
||||
VOLUME .DB 0
|
||||
CHANNEL .DB 0
|
||||
CHANNELS .DB 0
|
||||
OLDSTACK .DW 0 ; original stack pointer
|
||||
.DS 40H ; space for stack
|
||||
STACK ; top of stack
|
||||
;
|
||||
.END
|
||||
@@ -47,6 +47,8 @@
|
||||
; 2022-03-20 [DDW] Add support for MBC PSG module
|
||||
; 2023-03-30 [WBW] Fix for quark delay adjustment being trashed
|
||||
; 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!
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
; ToDo:
|
||||
@@ -632,6 +634,9 @@ CFGSIZ .EQU $ - CFGTBL
|
||||
;
|
||||
.DB 17, $A4, $A5, $A4, $FF, $A6, $FE ; DUODYNE
|
||||
.DW HWSTR_DUO
|
||||
;
|
||||
.DB 22, $41, $40, $40, $FF, $FF, $FF ; NABU
|
||||
.DW HWSTR_NABU
|
||||
;
|
||||
.DB $FF ; END OF TABLE MARKER
|
||||
;
|
||||
@@ -661,7 +666,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.6, 23-Feb-2024",0
|
||||
MSGBAN .DB "Tune Player for RomWBW v3.8, 10-May-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,6 +692,7 @@ 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
|
||||
|
||||
MSGUNSUP .db "MYM files not supported with HBIOS yet!\r\n", 0
|
||||
|
||||
@@ -2080,8 +2086,23 @@ LOUT OUT (C),A
|
||||
LD HL, AYREGS ; START OF VALUE LIST
|
||||
LOUT OUT (C), A ; SELECT REGISTER
|
||||
LD C, D ; POINT TO DATA PORT
|
||||
OUTI ; WRITE (HL) TO DATA PORT, BUMP HL
|
||||
LD C, E ; POINT TO ADDRESS PORT
|
||||
|
||||
; UGLINESS FOR NABU! WE NEED TO KEEP BIT 7 = 0, AND BIT 6 = 1
|
||||
; FOR PSG REG 7
|
||||
CP 7 ; PSG REG 7?
|
||||
JR NZ,LOUT1 ; SKIP SPECIAL PROCESSING
|
||||
PUSH AF ; SAVE AF
|
||||
LD A,(HL) ; GET VALUE BYTE
|
||||
AND %00111111 ; FIX BITS 6 & 7
|
||||
OR %01000000 ; ... FOR NABU!
|
||||
OUT (C),A ; SEND THE FIXED VALUE
|
||||
DEC B ; SIMULATE THE RESET
|
||||
INC HL ; ... OF OUTI
|
||||
POP AF ; RESTORE AF
|
||||
JR LOUT1A ; RESUME LOOP
|
||||
|
||||
LOUT1 OUTI ; WRITE (HL) TO DATA PORT, BUMP HL
|
||||
LOUT1A LD C, E ; POINT TO ADDRESS PORT
|
||||
INC A ; NEXT REGISTER
|
||||
CP 13 ; REG 13?
|
||||
JR NZ, LOUT ; IF NOT, LOOP
|
||||
@@ -2091,6 +2112,7 @@ LOUT OUT (C), A ; SELECT REGISTER
|
||||
JP M, LOUT2 ; IF BIT 7 SET, RETURN W/O WRITING VALUE
|
||||
LD C, D ; SELECT DATA PORT
|
||||
OUT (C), A ; WRITE VALUE TO REGISTER 13
|
||||
|
||||
LOUT2 CALL NORMIO
|
||||
EI
|
||||
RET ; AND DONE
|
||||
@@ -2537,8 +2559,23 @@ upsg1: ld hl,(psource)
|
||||
psglp: ld c, e ; C := RSEL
|
||||
out (c), a ; Select register
|
||||
ld c, d ; C := RDAT
|
||||
outi ; Set register value
|
||||
inc a ; Next register
|
||||
|
||||
; ugliness for nabu! we need to keep bit 7 = 0, and bit 6 = 1
|
||||
; for psg reg 7
|
||||
cp 7 ; psg reg 7?
|
||||
jr nz,psglp1 ; if not, skip special processing
|
||||
push af ; save af
|
||||
ld a,(hl) ; get value byte
|
||||
and %00111111 ; fix bits 6 & 7
|
||||
or %01000000 ; ... for NABU!
|
||||
out (c),a ; send the fixed value
|
||||
dec b ; simulate the rest
|
||||
inc hl ; ... of outi
|
||||
pop af ; restore af
|
||||
jr psglp2 ; resume loop
|
||||
|
||||
psglp1: outi ; Set register value
|
||||
psglp2: inc a ; Next register
|
||||
|
||||
ld bc, (3 * FRAG) - 1 ; Bytes to skip before next reg-1
|
||||
add hl, bc ; Update HL
|
||||
|
||||
@@ -48,7 +48,7 @@ SHIRAKAW.VGM - SN76489+YM2612 * Jantei Monogatari: St. Shirakawa University
|
||||
ANNA.VGM - SN76489+YM2612 - Jantei Monogatari: Anna : 32K
|
||||
FIELDMAP.VGM - SN76489+YM2612 - Taikou Risshiden: Field Map: Summer : 8K
|
||||
ITSGAMOV.VGM - SN76489+YM2612 - Puyo Puyo Tsuu: It's Game Over! : 16K
|
||||
STARTDEM.VGN - 2xSN76489+AY-3-8910 * Exed Exes / Savage Bees: Start Demo ~Main BGM : 32K
|
||||
STARTDEM.VGM - 2xSN76489+AY-3-8910 * Exed Exes / Savage Bees: Start Demo ~Main BGM : 32K
|
||||
INCHINA.VGM - YM2612 * Double Dragon 3: The Rosetta Stone: In China : 44K
|
||||
SURE.VGM - YM2151 - Martial Age: Sure?? : 36K
|
||||
SABERDAN.VGM - YM2151 - Road Runner: Sabre Dance (Attract Mode - Stage 4) : 28K
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
;===============================================================================
|
||||
; TIMER - Display system timer value
|
||||
;
|
||||
; Version 1.21 30-June-2024
|
||||
;===============================================================================
|
||||
;
|
||||
; Author: Wayne Warthen (wwarthen@gmail.com)
|
||||
; Updated: MartinR (June 2024)
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
; Usage:
|
||||
@@ -14,38 +15,58 @@
|
||||
;
|
||||
; Operation:
|
||||
; Reads and displays system timer value.
|
||||
;
|
||||
; This code will only execute on a Z80 CPU (or derivitive)
|
||||
;
|
||||
; This source code assembles with TASM V3.2 under Windows-11 using the
|
||||
; following command line:
|
||||
; tasm -80 -g3 -l TIMER.ASM TIMER.COM
|
||||
; ie: Z80 CPU; output format 'binary' named .COM (rather than .OBJ)
|
||||
; and includes a symbol table as part of the listing file.
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
; Change Log:
|
||||
; 2018-01-14 [WBW] Initial release
|
||||
; 2018-01-17 [WBW] Add HBIOS check
|
||||
; 2019-11-08 [WBW] Add seconds support
|
||||
; 2024-06-30 [MR ] Display values in decimal rather than hexadecimal
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
; Includes binary-to-decimal subroutine by Alwin Henseler
|
||||
; Located at: https://www.msx.org/forum/development/msx-development/32-bit-long-ascii
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
; ToDo:
|
||||
; Display the elapsed time in HH:MM:SS
|
||||
;_______________________________________________________________________________
|
||||
;
|
||||
#include "../ver.inc"
|
||||
#include "../ver.inc" ; Used for building RomWBW
|
||||
;#include "ver.inc" ; Used for testing purposes during code development
|
||||
;
|
||||
;===============================================================================
|
||||
; Definitions
|
||||
;===============================================================================
|
||||
;
|
||||
stksiz .equ $40 ; Working stack size
|
||||
;
|
||||
restart .equ $0000 ; CP/M restart vector
|
||||
bdos .equ $0005 ; BDOS invocation vector
|
||||
;
|
||||
ident .equ $FFFE ; loc of RomWBW HBIOS ident ptr
|
||||
stksiz .equ $80 ; Working stack size (was $40)
|
||||
;
|
||||
restart .equ $0000 ; CP/M restart vector
|
||||
bdos .equ $0005 ; BDOS invocation vector
|
||||
;
|
||||
ident .equ $FFFE ; loc of RomWBW HBIOS ident ptr
|
||||
;
|
||||
bf_sysver .equ $F1 ; BIOS: VER function
|
||||
bf_sysget .equ $F8 ; HBIOS: SYSGET function
|
||||
bf_sysset .equ $F9 ; HBIOS: SYSGET function
|
||||
bf_sysset .equ $F9 ; HBIOS: SYSSET function
|
||||
bf_sysgettimer .equ $D0 ; TIMER subfunction
|
||||
bf_syssettimer .equ $D0 ; TIMER subfunction
|
||||
bf_sysgetsecs .equ $D1 ; SECONDS subfunction
|
||||
bf_syssetsecs .equ $D1 ; SECONDS subfunction
|
||||
;
|
||||
; ASCII Control Characters
|
||||
;
|
||||
lf .equ $0A ; Line Feed
|
||||
cr .equ $0D ; Carriage Return
|
||||
;
|
||||
;===============================================================================
|
||||
; Code Section
|
||||
;===============================================================================
|
||||
@@ -73,17 +94,17 @@ exit: ; clean up and return to command processor
|
||||
; Initialization
|
||||
;
|
||||
init:
|
||||
call crlf ; formatting
|
||||
ld de,msgban ; point to version message part 1
|
||||
call prtstr ; print it
|
||||
;
|
||||
call idbio ; identify active BIOS
|
||||
cp 1 ; check for HBIOS
|
||||
jp nz,errbio ; handle BIOS error
|
||||
;
|
||||
call crlf ; formatting
|
||||
ld de,msgban ; point to version message part 1
|
||||
call prtstr ; print it
|
||||
;
|
||||
call idbio ; identify active BIOS
|
||||
cp 1 ; check for HBIOS
|
||||
jp nz,errbio ; handle BIOS error
|
||||
;
|
||||
ld a,rmj << 4 | rmn ; expected HBIOS ver
|
||||
cp d ; compare with result above
|
||||
jp nz,errbio ; handle BIOS error
|
||||
cp d ; compare with result above
|
||||
jp nz,errbio ; handle BIOS error
|
||||
;
|
||||
initx
|
||||
; initialization complete
|
||||
@@ -120,9 +141,9 @@ process0:
|
||||
call crlf2 ; formatting
|
||||
;
|
||||
process1:
|
||||
ld b,bf_sysget ; HBIOS SYSGET function
|
||||
ld b,bf_sysget ; HBIOS SYSGET function
|
||||
ld c,bf_sysgettimer ; TIMER subfunction
|
||||
rst 08 ; call HBIOS, DE:HL := timer value
|
||||
rst 08 ; call HBIOS, DE:HL := timer value
|
||||
|
||||
ld a,(first)
|
||||
or a
|
||||
@@ -135,28 +156,50 @@ process1:
|
||||
cp l ; compare to current LSB
|
||||
jr z,process2 ; if equal, bypass display
|
||||
|
||||
process1a:
|
||||
;*******************************************************************************
|
||||
|
||||
; Code added/amended to print values in decimal
|
||||
; MartinR June2024
|
||||
|
||||
process1a:
|
||||
; save and print new value
|
||||
ld a,l ; new LSB value to A
|
||||
ld (last),a ; save as last value
|
||||
call prtcr ; back to start of line
|
||||
;call nz,prthex32 ; display it
|
||||
call prthex32 ; display it
|
||||
ld de,strtick ; tag
|
||||
call prtstr ; display it
|
||||
ld a,l ; new LSB value to A
|
||||
ld (last),a ; save as last value
|
||||
call prtcr ; back to start of line
|
||||
|
||||
call b2d32 ; Convert DE:HL into ASCII; Start of ASCII buffer returned in HL
|
||||
ex de,hl
|
||||
call prtstr ; Display the value
|
||||
|
||||
ld de,strtick ; "Ticks" message
|
||||
call prtstr ; Display it
|
||||
|
||||
; get and print seconds value
|
||||
ld b,bf_sysget ; HBIOS SYSGET function
|
||||
ld c,bf_sysgetsecs ; SECONDS subfunction
|
||||
rst 08 ; call HBIOS, DE:HL := seconds value
|
||||
call prthex32 ; display it
|
||||
ld a,'.' ; fraction separator
|
||||
call prtchr ; print it
|
||||
ld a,c ; get fractional component
|
||||
call prthex ; print it
|
||||
ld de,strsec ; tag
|
||||
call prtstr ; display it
|
||||
;
|
||||
ld b,bf_sysget ; HBIOS SYSGET function
|
||||
ld c,bf_sysgetsecs ; SECONDS subfunction
|
||||
rst 08 ; Call HBIOS; DE:HL := seconds value; C := fractional part
|
||||
push bc ; Preserve the fractional part on the stack
|
||||
|
||||
call b2d32 ; Convert DE:HL into ASCII; Start of ASCII buffer returned in HL
|
||||
ex de,hl
|
||||
call prtstr ; Display the value
|
||||
|
||||
ld a,'.' ; Fraction separator, ie decimal point
|
||||
call prtchr ; Print it
|
||||
|
||||
pop bc ; Retrieve fractional part into A
|
||||
ld a,c
|
||||
sla a ; Double the 50Hz 'ticks' value to give 1/100s of a second
|
||||
|
||||
call b2d8 ; Convert into ASCII - up to 3 digits
|
||||
ex de,hl ; Start of ASCII buffer returned in HL
|
||||
call prtstr ; Display fractional part of the value
|
||||
|
||||
ld de,strsec ; "Seconds" message
|
||||
call prtstr ; Display it
|
||||
|
||||
;*******************************************************************************
|
||||
|
||||
process2:
|
||||
ld a,(cont) ; continuous display?
|
||||
or a ; test for true/false
|
||||
@@ -269,9 +312,9 @@ prtdot:
|
||||
;
|
||||
prtcr:
|
||||
;
|
||||
; shortcut to print a dot preserving all regs
|
||||
; shortcut to print carriage return preserving all regs
|
||||
push af ; save af
|
||||
ld a,13 ; load CR value
|
||||
ld a,cr ; load CR value
|
||||
call prtchr ; print it
|
||||
pop af ; restore af
|
||||
ret ; done
|
||||
@@ -477,6 +520,124 @@ err2: ; without the string
|
||||
or $FF ; signal error
|
||||
ret ; done
|
||||
;
|
||||
;
|
||||
;===============================================================================
|
||||
; Subroutine to print decimal numbers
|
||||
;===============================================================================
|
||||
;
|
||||
; Combined routine for conversion of different sized binary numbers into
|
||||
; directly printable ASCII(Z)-string
|
||||
; Input value in registers, number size and -related to that- registers to fill
|
||||
; is selected by calling the correct entry:
|
||||
;
|
||||
; entry input decimal value 0 to:
|
||||
; b2d8 A 255 (3 digits)
|
||||
; b2d16 HL 65535 5 "
|
||||
; b2d24 E:HL 16777215 8 "
|
||||
; b2d32 DE:HL 4294967295 10 "
|
||||
; b2d48 BC:DE:HL 281474976710655 15 "
|
||||
; b2d64 IX:BC:DE:HL 18446744073709551615 20 "
|
||||
;
|
||||
; The resulting string is placed into a small buffer attached to this routine,
|
||||
; this buffer needs no initialization and can be modified as desired.
|
||||
; The number is aligned to the right, and leading 0's are replaced with spaces.
|
||||
; On exit HL points to the first digit, (B)C = number of decimals
|
||||
; This way any re-alignment / postprocessing is made easy.
|
||||
; Changes: AF,BC,DE,HL,IX
|
||||
;
|
||||
; by Alwin Henseler
|
||||
; https://msx.org/forum/topic/who-who/dutch-hardware-guy-pops-back-sort
|
||||
;
|
||||
; Found at:
|
||||
; https://www.msx.org/forum/development/msx-development/32-bit-long-ascii
|
||||
;
|
||||
; Tweaked to assemble using TASM 3.2 by MartinR 23June2024
|
||||
;
|
||||
b2d8: ld h,0
|
||||
ld l,a
|
||||
b2d16: ld e,0
|
||||
b2d24: ld d,0
|
||||
b2d32: ld bc,0
|
||||
b2d48: ld ix,0 ; zero all non-used bits
|
||||
b2d64: ld (b2dinv),hl
|
||||
ld (b2dinv+2),de
|
||||
ld (b2dinv+4),bc
|
||||
ld (b2dinv+6),ix ; place full 64-bit input value in buffer
|
||||
ld hl,b2dbuf
|
||||
ld de,b2dbuf+1
|
||||
ld (hl),' '
|
||||
b2dfilc:.equ $-1 ; address of fill-character
|
||||
ld bc,18
|
||||
ldir ; fill 1st 19 bytes of buffer with spaces
|
||||
ld (b2dend-1),bc ; set BCD value to "0" & place terminating 0
|
||||
ld e,1 ; no. of bytes in BCD value
|
||||
ld hl,b2dinv+8 ; (address MSB input)+1
|
||||
ld bc,$0909
|
||||
xor a
|
||||
b2dskp0:dec b
|
||||
jr z,b2dsiz ; all 0: continue with postprocessing
|
||||
dec hl
|
||||
or (hl) ; find first byte <> 0
|
||||
jr z,b2dskp0
|
||||
b2dfnd1:dec c
|
||||
rla
|
||||
jr nc,b2dfnd1 ; determine no. of most significant 1-bit
|
||||
rra
|
||||
ld d,a ; byte from binary input value
|
||||
b2dlus2:push hl
|
||||
push bc
|
||||
b2dlus1:ld hl,b2dend-1 ; address LSB of bcd value
|
||||
ld b,e ; current length of BCD value in bytes
|
||||
rl d ; highest bit from input value -> carry
|
||||
b2dlus0:ld a,(hl)
|
||||
adc a,a
|
||||
daa
|
||||
ld (hl),a ; double 1 BCD byte from intermediate result
|
||||
dec hl
|
||||
djnz b2dlus0 ; and go on to double entire BCD value (+carry!)
|
||||
jr nc,b2dnxt
|
||||
inc e ; carry at MSB -> BCD value grew 1 byte larger
|
||||
ld (hl),1 ; initialize new MSB of BCD value
|
||||
b2dnxt: dec c
|
||||
jr nz,b2dlus1 ; repeat for remaining bits from 1 input byte
|
||||
pop bc ; no. of remaining bytes in input value
|
||||
ld c,8 ; reset bit-counter
|
||||
pop hl ; pointer to byte from input value
|
||||
dec hl
|
||||
ld d,(hl) ; get next group of 8 bits
|
||||
djnz b2dlus2 ; and repeat until last byte from input value
|
||||
b2dsiz: ld hl,b2dend ; address of terminating 0
|
||||
ld c,e ; size of bcd value in bytes
|
||||
or a
|
||||
sbc hl,bc ; calculate address of MSB BCD
|
||||
ld d,h
|
||||
ld e,l
|
||||
sbc hl,bc
|
||||
ex de,hl ; HL=address BCD value, de=start of decimal value
|
||||
ld b,c ; no. of bytes BCD
|
||||
sla c ; no. of bytes decimal (possibly 1 too high)
|
||||
ld a,'0'
|
||||
rld ; shift bits 4-7 of (HL) into bit 0-3 of A
|
||||
cp '0' ; (HL) was > 9h?
|
||||
jr nz,b2dexph ; if yes, start with recording high digit
|
||||
dec c ; correct number of decimals
|
||||
inc de ; correct start address
|
||||
jr b2dexpl ; continue with converting low digit
|
||||
b2dexp: rld ; shift high digit (HL) into low digit of a
|
||||
b2dexph:ld (de),a ; record resulting ascii-code
|
||||
inc de
|
||||
b2dexpl:rld
|
||||
ld (de),a
|
||||
inc de
|
||||
inc hl ; next BCD-byte
|
||||
djnz b2dexp ; and go on to convert each BCD-byte into 2 ASCII
|
||||
sbc hl,bc ; return with HL pointing to 1st decimal
|
||||
ret
|
||||
|
||||
b2dinv .fill 8 ; space for 64-bit input value (LSB first)
|
||||
b2dbuf .fill 20 ; space for 20 decimal digits
|
||||
b2dend .db 0 ; space for terminating character
|
||||
;
|
||||
;===============================================================================
|
||||
; Storage Section
|
||||
;===============================================================================
|
||||
@@ -487,20 +648,21 @@ first .db $FF ; first pass flag (true at start)
|
||||
;
|
||||
stksav .dw 0 ; stack pointer saved at start
|
||||
.fill stksiz,0 ; stack
|
||||
stack .equ $ ; stack top
|
||||
stack .equ $ ; new stack top
|
||||
;
|
||||
; Messages
|
||||
;
|
||||
msgban .db "TIMER v1.1, 10-Nov-2019",13,10
|
||||
.db "Copyright (C) 2019, Wayne Warthen, GNU GPL v3",0
|
||||
msguse .db "Usage: TIMER [/C] [/?]",13,10
|
||||
.db " ex. TIMER (display current timer value)",13,10
|
||||
.db " TIMER /? (display version and usage)",13,10
|
||||
msgban .db "TIMER v1.21, 30-Jun-2024",cr,lf
|
||||
.db "Copyright (C) 2019, Wayne Warthen, GNU GPL v3",cr,lf
|
||||
.db "Updated by MartinR 2024",0
|
||||
msguse .db "Usage: TIMER [/C] [/?]",cr,lf
|
||||
.db " ex. TIMER (display current timer value)",cr,lf
|
||||
.db " TIMER /? (display version and usage)",cr,lf
|
||||
.db " TIMER /C (display timer value continuously)",0
|
||||
msgprm .db "Parameter error (TIMER /? for usage)",0
|
||||
msgbio .db "Incompatible BIOS or version, "
|
||||
.db "HBIOS v", '0' + rmj, ".", '0' + rmn, " required",0
|
||||
strtick .db " Ticks, ",0
|
||||
strsec .db " Seconds",0
|
||||
strtick .db " Ticks ",0
|
||||
strsec .db " Seconds ",0
|
||||
;
|
||||
.end
|
||||
.end
|
||||
|
||||
@@ -11,6 +11,7 @@ call BuildZRC || exit /b
|
||||
call BuildZ1RCC || exit /b
|
||||
call BuildZZRCC || exit /b
|
||||
call BuildZRC512 || exit /b
|
||||
call BuildFZ80 || exit /b
|
||||
|
||||
if "%1" == "dist" (
|
||||
call Clean || exit /b
|
||||
|
||||
4
Source/BuildFZ80.cmd
Normal file
4
Source/BuildFZ80.cmd
Normal file
@@ -0,0 +1,4 @@
|
||||
@echo off
|
||||
setlocal
|
||||
|
||||
pushd FZ80 && call Build || exit /b & popd
|
||||
@@ -2266,13 +2266,7 @@ INIT:
|
||||
RST 08 ; DO IT, DE=MAJ/MIN/UP/PAT
|
||||
LD A,D ; A := MAJ/MIN
|
||||
CP ((RMJ << 4) | RMN) ; MATCH?
|
||||
JR NZ,INIT1 ; HANDLE VER MISMATCH
|
||||
LD A,E ; A := OS UP/PAT
|
||||
AND $F0 ; PAT NOT INCLUDED IN MATCH
|
||||
CP (RUP << 4) ; MATCH?
|
||||
JR NZ,INIT1 ; HANDLE VER MISMATCH
|
||||
JR INIT2 ; ALL GOOD, CONTINUE
|
||||
INIT1:
|
||||
JR Z,INIT2 ; ALL GOOD, CONTINUE
|
||||
; DISPLAY VERSION MISMATCH
|
||||
CALL NEWLINE2 ; FORMATTING
|
||||
LD DE,STR_VERMIS ; VERSION MISMATCH
|
||||
@@ -2753,10 +2747,12 @@ CLRRAM2:
|
||||
#ENDIF
|
||||
LD A,(BNKUSER) ; SWITCH BACK TO USER BANK
|
||||
CALL HB_BNKSEL ; SELECT BANK
|
||||
EI ; INTERRUPTS OK AGAIN
|
||||
CALL NEWLINE2 ; FORMATTING
|
||||
LD DE,STR_INITRAMDISK ; RAM DISK INIT MESSAGE
|
||||
CALL WRITESTR ; DISPLAY IT
|
||||
LD A,(BNKRAMD) ; SWITCH BACK TO FIRST BANK
|
||||
DI ; DISABLE INTERRUPTS AGAIN
|
||||
LD A,(BNKRAMD) ; SWITCH BACK TO FIRST RAM BANK
|
||||
CALL HB_BNKSEL ; SELECT BANK
|
||||
LD HL,0 ; SOURCE ADR FOR FILL
|
||||
LD BC,$2000 ; LENGTH OF FILL IS 8K
|
||||
|
||||
@@ -96,13 +96,7 @@ init$2:
|
||||
rst 08 ; do it, de=maj/min/up/pat
|
||||
ld a,d ; a := maj/min
|
||||
cp ((rmj << 4) | rmn) ; match?
|
||||
jr nz,init$3 ; handle ver mismatch
|
||||
ld a,e ; a := os up/pat
|
||||
and 0F0h ; pat not included in match
|
||||
cp (rup << 4) ; match?
|
||||
jr nz,init$3 ; handle ver mismatch
|
||||
jr init$4 ; all good, continue
|
||||
init$3:
|
||||
jr z,init$4 ; all good, continue
|
||||
; display version mismatch
|
||||
ld hl,vermis$msg ; version mismatch
|
||||
call ?pmsg ; display it
|
||||
|
||||
@@ -48,8 +48,9 @@ found:
|
||||
| RTC | Yes | Yes | Yes |
|
||||
| TIMER | Yes | Yes | Yes |
|
||||
| CPUSPD | Yes | Yes | Yes |
|
||||
| FAT | Yes | Yes | Yes |
|
||||
| CLRDIR | Yes | Yes | Yes |
|
||||
| INTTEST | No | Yes | Yes |
|
||||
| FAT | No | Yes | Yes |
|
||||
| TUNE | No | Yes | Yes |
|
||||
| WDATE | No | Yes | Yes |
|
||||
| HTALK | No | Yes | Yes |
|
||||
@@ -545,7 +546,7 @@ distribution in the Doc/Contrib directory.
|
||||
The application supports a significant number of EEPROM parts. It
|
||||
should automatically detect your part. If it does not recognize your
|
||||
chip, make sure that you do not have a write protect jumper set --
|
||||
this jumper can prevent the ROM chip from being recognized.
|
||||
this jumper will prevent the ROM chip from being recognized.
|
||||
|
||||
Reprogramming a ROM chip in-place is inherently dangerous. If anything
|
||||
goes wrong, you will be left with a non-functional system and no
|
||||
@@ -921,6 +922,15 @@ Files written are not verified.
|
||||
Wildcard matching in FAT filesystems is a bit unusual as implemented by
|
||||
FatFs. See FatFs documentation.
|
||||
|
||||
The `FAT FORMAT` command will not perform a physical format on floppy
|
||||
disks. You must use FDU to do this prior to using `FAT FORMAT`.
|
||||
|
||||
Formatting (`FAT FORMAT`) of floppies does not work well. The
|
||||
underlying FatFs library uses some non-standard fields. The resulting
|
||||
floppy may or may not be useable on other systems. It is best to format
|
||||
a FAT floppy on a Windows or DOS system. You should have no problems
|
||||
copying files to/from such a floppy using `FAT`.
|
||||
|
||||
## Etymology
|
||||
|
||||
The `FAT` application is an original RomWBW work, but utilizes the
|
||||
@@ -953,6 +963,60 @@ can corrupt a file if it occurs. Be careful to avoid this.
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
# CLRDIR
|
||||
|
||||
`CLRDIR` is used to initialize a CP/M filesystem. This is frequently
|
||||
used to prepare RomWBW disk slices for use. If there is any data
|
||||
on the filesystem, it will be destroyed. `CLRDIR` works on CP/M
|
||||
drive letters. To initialize a RomWBW slice, the slice must first be
|
||||
assigned to a CP/M drive letter.
|
||||
|
||||
|
||||
This application is provided by Max Scane.
|
||||
|
||||
## Syntax
|
||||
|
||||
| `CLRDIR `*`<drive>`*` [options]`
|
||||
|
||||
*`<drive>`* is the CP/M drive letter to be cleared (e.g., "A:")
|
||||
|
||||
|
||||
Options:
|
||||
|
||||
| `-D`: Enable debug output
|
||||
| `-Y`: Do not ask for confirmation
|
||||
|
||||
## Usage
|
||||
|
||||
This application has a command line interface only. Type an
|
||||
appropriately formatted command at the command prompt at any of the
|
||||
RomWBW CP/M operatings systems (CP/M 2.2, ZSDOS, CP/M 3, etc.).
|
||||
|
||||
You will be prompted for confirmation to continue. You must type a
|
||||
**capital** 'Y' to proceed. The application will confirm that the
|
||||
drive has been cleared.
|
||||
|
||||
If used under ZSDOS, you should issue a `RELOG` command after using
|
||||
`CLRDIR` to ensure that CP/M relogs the cleared drive.
|
||||
|
||||
## Notes
|
||||
|
||||
This command is inherently dangerous. It will completely destroy the
|
||||
directory area of the target drive. Be very careful to ensure you do
|
||||
not target a drive that contains useful data.
|
||||
|
||||
`CLRDIR` understands the directory formats of all of the RomWBW
|
||||
CPM-like operating systems and devices including floppy disks, CF/SD
|
||||
Cards, etc.
|
||||
|
||||
## Etymology
|
||||
|
||||
This application was written and provided by Max Scane. He
|
||||
provides it in binary format and is included in the RomWBW
|
||||
distribution as a binary file.
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
# TUNE
|
||||
|
||||
If your RomWBW system has a sound card based on either an AY-3-8190 or
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
$define{doc_ver}{Version 3.5}$
|
||||
$define{doc_product}{RomWBW}$
|
||||
$define{doc_root}{https://github.com/wwarthen/RomWBW/raw/dev/Doc}$
|
||||
$define{file_root}{https://github.com/wwarthen/RomWBW/raw/master}$
|
||||
$define{doc_root}{$file_root$/Doc}$
|
||||
$ifndef{doc_title}$ $define{doc_title}{Document Title}$ $endif$
|
||||
$ifndef{doc_author}$ $define{doc_author}{Wayne Warthen}$ $endif$
|
||||
$define{doc_date}{$date{%d %b %Y}$}$
|
||||
|
||||
@@ -10,7 +10,7 @@ programming languages.
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
# ROMWBW Monitor
|
||||
# RomWBW Monitor
|
||||
|
||||
The Monitor program is a low level utility that can be used
|
||||
for testing and programming. It allows programs to be entered,
|
||||
@@ -339,8 +339,8 @@ A comprehensive instruction manual is available in the Doc\\Contrib directory.
|
||||
|
||||
## ROMWBW unsupported features
|
||||
|
||||
- Cassette loading
|
||||
- Cassette saving
|
||||
- This ROM-hosted implementation does not support cassette or disk
|
||||
access for loading and saving programs.
|
||||
|
||||
# TastyBASIC
|
||||
|
||||
@@ -350,10 +350,12 @@ original source can be found here [https://github.com/dimitrit/tastybasic](https
|
||||
|
||||
## Features / Limitations
|
||||
|
||||
Integer arithmetic, numbers -32767 to 32767
|
||||
Singles letter variables A-Z
|
||||
1-dimensional array support
|
||||
Strings are not supported
|
||||
- This ROM-hosted implementation does not support disk access for
|
||||
loading and saving programs.
|
||||
- Integer arithmetic, numbers -32767 to 32767
|
||||
- Singles letter variables A-Z
|
||||
- 1-dimensional array support
|
||||
- Strings are not supported
|
||||
|
||||
## Direct Commands
|
||||
|
||||
@@ -494,7 +496,8 @@ Due to different platform processor speeds, serials speeds and flow control cap
|
||||
|
||||
See the ROMWBW Applications guide for additional information on performing upgrades.
|
||||
|
||||
## Console Options
|
||||
## Console Options
|
||||
|
||||
Option ( C ) - Set Console Device
|
||||
|
||||
Option ( S ) - Set Serial Device
|
||||
@@ -576,7 +579,7 @@ Can be used to verify if a ROM image has been transferred and flashed correctly.
|
||||
|
||||
In Windows, right clicking on a file should also give you a context menu option CRC SHA which will allow you to select a CRC32 calculation to be done on the selected file.
|
||||
|
||||
## Teraterm macro configuration
|
||||
## Tera Term macro configuration
|
||||
|
||||
Macros are a useful tool for automatic common tasks. There are a number of instances where using macros to facilitate the update process could be worthwhile if you are:
|
||||
|
||||
@@ -595,20 +598,21 @@ crc32file crc '\\desktop\users\phillip\documents\github\romwbw\binary\sbc_std_cu
|
||||
sprintf '0x%08x' crc
|
||||
messagebox inputstr 'crc32'
|
||||
```
|
||||
|
||||
## Serial speed guidelines
|
||||
|
||||
As identified in the introduction, there are limitations on serial speed depending on processor speed and flow control settings. Listed below are some of the results identified during testing.
|
||||
|
||||
Platform / Configuration | Processor Speed | Maximum Serial Speed
|
||||
-------------------------------|-----------------|---------------------
|
||||
Sbc-v2 uart no flow control | 2mhz | 9600
|
||||
sbc-v2 uart no flow control | 4mhz | 19200
|
||||
sbc-v2 uart no flow control | 5mhz | 19200
|
||||
sbc-v2 uart no flow control | 8mhz | 38400
|
||||
sbc-v2 uart no flow control | 10mhz | 38400
|
||||
sbc-v2 usb-fifo 2mhz+ | | n/a
|
||||
sbc-mk4 asci no flow control | 18.432mhz | 9600
|
||||
sbc-mk4 asci with flow control | 18.432mhz | 38400
|
||||
SBC-V2 UART no flow control | 2mhz | 9600
|
||||
SBC-V2 UART no flow control | 4mhz | 19200
|
||||
SBC-V2 UART no flow control | 5mhz | 19200
|
||||
SBC-V2 UART no flow control | 8mhz | 38400
|
||||
SBC-V2 UART no flow control | 10mhz | 38400
|
||||
SBC-V2 USB-FIFO 2mhz+ | | n/a
|
||||
SBC-MK4 ASCI no flow control | 18.432mhz | 9600
|
||||
SBC-MK4 ASCI with flow control | 18.432mhz | 38400
|
||||
|
||||
The **Set Recommend Baud Rate** option in the Updater menu follows the following guidelines.
|
||||
|
||||
@@ -623,9 +627,9 @@ These can be customized in the updater.asm source code in the CLKTBL table if d
|
||||
Feedback to the ROMWBW developers on these guidelines would be appreciated.
|
||||
|
||||
## Notes:
|
||||
All testing was done with Teraterm x-modem, Forcing checksum mode using macros was found to give the most reliable transfer.
|
||||
Partial writes can be completed with 39SF040 chips. Other chips require entire flash to be erased before being written.
|
||||
An SBC V2-005 MegaFlash or Z80 MBC required for 1mb flash support. The Updater assumes both chips are same type
|
||||
Failure handling has not been tested.
|
||||
Timing broadly calibrated on a Z80 SBC-v2
|
||||
Unabios not supported
|
||||
- All testing was done with Teraterm x-modem, Forcing checksum mode using macros was found to give the most reliable transfer.
|
||||
- Partial writes can be completed with 39SF040 chips. Other chips require entire flash to be erased before being written.
|
||||
- An SBC V2-005 MegaFlash or Z80 MBC required for 1mb flash support. The Updater assumes both chips are same type
|
||||
- Failure handling has not been tested.
|
||||
- Timing broadly calibrated on a Z80 SBC-v2
|
||||
- UNA BIOS not supported
|
||||
|
||||
@@ -220,6 +220,8 @@ please let me know if I missed you!
|
||||
* Ladislau Szilagyi has contributed an enhanced version of
|
||||
CP/M Cowgol that leverages RomWBW memory banking.
|
||||
|
||||
* Les Bird has contributed support for the NABU w/ Option Board
|
||||
|
||||
Contributions of all kinds to RomWBW are very welcome.
|
||||
|
||||
# Licensing
|
||||
|
||||
@@ -126,6 +126,142 @@ execution.
|
||||
|
||||
{ width=100% }
|
||||
|
||||
## Bank Id
|
||||
|
||||
RomWBW utilizes a specific assignment of memory banks for dedicated
|
||||
purposes. A numeric Bank Id is used to refer to the memory banks. The
|
||||
Bank Id is a single byte. In general, the Bank Id simply refers to each
|
||||
of the 32K banks in sequential order. In other words, Bank Id 0 is the
|
||||
first physical 32K, Bank Id 1 is the second, etc. However, the high
|
||||
order bit of the Bank Id has a special meaning. If it is 0, it indicates
|
||||
a ROM bank is being referred to. If it is 1, it indicates a RAM bank
|
||||
is being referred to.
|
||||
|
||||
For example, let's say we have a typical system with 512KB of ROM and
|
||||
512KB of RAM. The Bank Ids would look like this:
|
||||
|
||||
| Physical Memory | Type | Physical Bank | Bank Id |
|
||||
|-------------------|------|---------------|-----------|
|
||||
| 0x000000-0x007FFF | ROM | 0 | 0x00 |
|
||||
| 0x008000-0x00FFFF | ROM | 1 | 0x01 |
|
||||
| 0x010000-0x07FFFF | ROM | 2-15 | 0x02-0x0F |
|
||||
| 0x080000-0x087FFF | RAM | 16 | 0x80 |
|
||||
| 0x088000-0x08FFFF | RAM | 17 | 0x81 |
|
||||
| 0x090000-0x0FFFFF | RAM | 18-31 | 0x82-0x8F |
|
||||
|
||||
Note that Bank Id 0x00 is **always** the first bank of ROM and 0x80 is
|
||||
**always** the first bank of RAM. If there were more banks of physical ROM,
|
||||
they would be assigned Bank Ids starting with 0x10. Likewise, additional
|
||||
bank of physical RAM would be assigned Bank Ids starting with 0x90.
|
||||
|
||||
The Bank Id is used in all RomWBW API functions when referring to
|
||||
the mapping of banks to the lower 32K bank area of the processor. In
|
||||
this way, all RomWBW functions can refer to a generic Bank Id without
|
||||
needing to understand how a specific hardware platform accesses the
|
||||
physical memory areas. A single routine within the HBIOS is implemented
|
||||
for each memory manager that maps Bank Ids to physical memory.
|
||||
|
||||
## Bank Assignments
|
||||
|
||||
RomWBW requires dedicated banks of memory for specific purposes. It
|
||||
uses Bank Ids via an algorithm to make these assignments. The following
|
||||
table describes the way the banks are assigned. The Typical column
|
||||
shows the specific values that would be assigned for a common system
|
||||
with 512KB of ROM and 512KB of RAM (nROM=16, nRAM=16).
|
||||
|
||||
| Bank Id | Identity | Typical | Purpose |
|
||||
|-------------------|-----------|---------|------------------------------------------|
|
||||
| 0x00 |BID_BOOT | 0x00 | Boot Bank (HBIOS image) |
|
||||
| 0x01 |BID_IMG0 | 0x01 | Boot Loader, Monitor, ROM OSes, ROM Apps |
|
||||
| 0x02 |BID_IMG1 | 0x02 | ROM Apps |
|
||||
| 0x03 |BID_IMG2 | 0x03 | \<Reserved\> |
|
||||
| 0x04 |BID_ROMD0 | 0x04 | First ROM Disk Bank |
|
||||
| nROM - 1 | | 0x0F | Last ROM Disk Bank |
|
||||
| 0x80 |BID_BIOS | 0x80 | HBIOS (working copy) |
|
||||
| 0x81 |BID_RAMD0 | 0x81 | First RAM Disk Bank |
|
||||
| 0x80 + nRAM - 8 | | 0x88 | Last RAM Disk Bank |
|
||||
| 0x80 + nRAM - 7 |BID_APP0 | 0x89 | First Application Bank |
|
||||
| 0x80 + nRAM - 5 | | 0x8B | Last Application Bank |
|
||||
| 0x80 + nRAM - 4 |BID_BUF | 0x8C | OS Disk Buffers |
|
||||
| 0x80 + nRAM - 3 |BID_AUX | 0x8D | OS Code Bank |
|
||||
| 0x80 + nRAM - 2 |BID_USR | 0x8E | User Bank (CP/M TPA) |
|
||||
| 0x80 + nRAM - 1 |BID_COM | 0x8F | Common Bank |
|
||||
|
||||
In this table, nROM and nRAM refer to the number of corresponding
|
||||
ROM and RAM banks in the the system.
|
||||
|
||||
The contents of the banks referred to above are described in more detail
|
||||
below:
|
||||
|
||||
Boot Bank:
|
||||
|
||||
: The Boot Bank receives control when a system is first powered
|
||||
on. It contains a ROM (read-only) copy of the HBIOS. At boot, it does
|
||||
minimal hardware initialization, then copies itself to the HBIOS bank
|
||||
in RAM, then resumes execution from the RAM bank.
|
||||
|
||||
Boot Loader:
|
||||
|
||||
: The application that handles loading of ROM or Disk based applications
|
||||
including operating systems. It copies itself to a RAM bank at the
|
||||
start of it's execution.
|
||||
|
||||
Monitor:
|
||||
|
||||
: The application that implements the basic system monitor functions.
|
||||
It copies itself to a RAM bank at the start of it's execution.
|
||||
|
||||
ROM OSes:
|
||||
|
||||
: Code images of CP/M 2.2 and Z-System which are copied to RAM and
|
||||
executed when a ROM-based operating system is selected in the Boot
|
||||
Loader.
|
||||
|
||||
ROM Applications:
|
||||
|
||||
: Various ROM-based application images such as BASIC, FORTH, etc. They
|
||||
can be selected in the Boot Loader. The Boot Loader will copy the
|
||||
application image to a RAM bank, then transfer control to it.
|
||||
|
||||
ROM Disk:
|
||||
|
||||
: A sequential series of banks assigned to provide the system ROM Disk
|
||||
contents.
|
||||
|
||||
HBIOS:
|
||||
|
||||
: This bank hosts the running copy of the RomWBW HBIOS.
|
||||
|
||||
RAM Disk:
|
||||
|
||||
: A sequential series of banks assigned to provide the system RAM Disk.
|
||||
|
||||
Application Bank:
|
||||
|
||||
: A sequential series of banks that are available for use by applications
|
||||
that wish to utilize banked memory.
|
||||
|
||||
OS Disk Buffers:
|
||||
|
||||
: This bank is used by CP/M 3 and ZPM3 for disk buffer storage.
|
||||
|
||||
OS Code Bank:
|
||||
|
||||
: This bank is used by CP/M 3 and ZPM3 as an alternate bank for code.
|
||||
This allows these operating systems to make additional TPA space
|
||||
available for applications.
|
||||
|
||||
User Bank:
|
||||
|
||||
: This is the default bank for applications to use. This includes the
|
||||
traditional TPA space for CP/M.
|
||||
|
||||
Common Bank:
|
||||
|
||||
: This bank is mapped to the upper 32K of the processors memory space.
|
||||
It is a fixed mapping that is never changed in normal RomWBW operation
|
||||
hence the name "Common".
|
||||
|
||||
# System Boot Process
|
||||
|
||||
A multi-phase boot strategy is employed. This is necessary because at
|
||||
@@ -1327,7 +1463,7 @@ specified (set to 0 for default/not specified). Video Mode (E) values
|
||||
are specific to each VDA. The returned Status (A) is a standard HBIOS
|
||||
result code.
|
||||
|
||||
If the hardware and driver support it, you can specify a Font Bitmap
|
||||
If the hardware and driver supports it, you can specify a Font Bitmap
|
||||
(HL) buffer address containing the character bitmap data to be loaded
|
||||
into the video processor. The buffer **must** be located entirely in the
|
||||
top 32K of the CPU memory space. HL must be set to zero if no character
|
||||
@@ -1372,10 +1508,10 @@ data, then Font Bitmap (HL) will be set to zero on return.
|
||||
| B: 0x42 | A: Status |
|
||||
| C: Video Unit | |
|
||||
|
||||
Performs a soft reset of the specified Video Unit (C). Will clear the
|
||||
screen, home the cursor, and restore active attribute/color to defaults.
|
||||
Keyboard will be flushed. The current video mode will not be changed.
|
||||
The returned Status (A) is a standard HBIOS result code.
|
||||
Performs a non-destructive reset of the specified Video Unit (C).
|
||||
Should re-initialize the video hardware without destroying the screen
|
||||
contents or cursor position. The current video mode will not be
|
||||
changed. The returned Status (A) is a standard HBIOS result code.
|
||||
|
||||
### Function 0x43 -- Video Device (VDADEV)
|
||||
|
||||
@@ -2272,14 +2408,19 @@ to see if it is incrementing.
|
||||
|----------------------------------------|----------------------------------------|
|
||||
| B: 0xF8 | A: Status |
|
||||
| C: 0xD1 | DEHL: Seconds Count |
|
||||
| | C: Ticks per Second |
|
||||
| | C: Remainder Ticks |
|
||||
|
||||
Return the a Seconds Count (DEHL) with the number of seconds that have
|
||||
Return the Seconds Count (DEHL) with the number of seconds that have
|
||||
elapsed since the system was started. This is a double-word binary
|
||||
value. Additionally, the number of Ticks per Second (C) is returned.
|
||||
The returned Status (A) is a standard HBIOS result code.
|
||||
value. Additionally, Remainder Ticks (C) is returned and contains the number
|
||||
of ticks that have elapsed within the current second.
|
||||
|
||||
This availability of the Seconds Count (DEHL) is dependent on having a
|
||||
Note that Remainder Ticks (C) will have a value from 0 to 49 since there are
|
||||
50 ticks per second. So, Remainder Ticks does not represent a fraction of the
|
||||
current second. Remainder Ticks (C) can be doubled to derive the hundredths of
|
||||
milliseconds elapsed within the current second.
|
||||
|
||||
The availability of the Seconds Count (DEHL) is dependent on having a
|
||||
system timer active. If the hardware configuration has no system timer,
|
||||
then Seconds Count (DEHL) will not increment.
|
||||
|
||||
|
||||
@@ -263,6 +263,8 @@ is discussed in [Customizing RomWBW].
|
||||
| [Duodyne Z80 System]^1^ | Duo | DUO_std.rom | 38400 |
|
||||
| [Heath H8 Z80 System]^10^ | H8 | HEATH_std.rom | 115200 |
|
||||
| [EP Mini-ITX Z180]^11^ | RCBus? | EPITX_std.rom | 115200 |
|
||||
| [NABU w/ RomWBW Option Board]^10^ | NABU | NABU_std.rom | 115200 |
|
||||
| [S100 FPGA Z80]^9^ | S100 | FZ80_std.rom | 9600 |
|
||||
|
||||
| ^1^Designed by Andrew Lynch
|
||||
| ^2^Designed by Sergey Kiselev
|
||||
@@ -630,6 +632,7 @@ prompt:
|
||||
| CP/M 2.2 | Digital Research CP/M 2.2 OS |
|
||||
| Z-System | ZSDOS 1.1 w/ ZCPR 1 (Enhanced CP/M compatible OS) |
|
||||
| Forth | Brad Rodriguez's ANSI compatible Forth language |
|
||||
| BASIC | Microsoft ROM BASIC |
|
||||
| Tasty BASIC | Dimitri Theuling's Tiny BASIC implementation |
|
||||
| Play | A simple video game (requires ANSI terminal emulation) |
|
||||
| Network Boot | Boot system via Wiznet MT011 device |
|
||||
@@ -649,9 +652,17 @@ in the ROM (CP/M 2.2 & Z-System) are described in the Operating Systems
|
||||
chapter of this document.
|
||||
|
||||
In general, the command to exit any of these applications and restart
|
||||
the system is `BYE`. The exceptions are the Monitor which uses `B` and
|
||||
the system is `BYE`. The exceptions are the Monitor which uses `X` and
|
||||
Play which uses `Q`.
|
||||
|
||||
**NOTE:** Of the ROM Applications, only the operating systems (CP/M and
|
||||
Z-System) have the ability to interact with disk drives. So, other than
|
||||
these 2 OSes, the ROM Applications do **not** have any way to save or
|
||||
load data from peristent/disk storage. For example, if you launch BASIC
|
||||
from the Boot Loader, you will not be able to save or load your
|
||||
programs. You will need to start an operating system first and then run
|
||||
BASIC in order to save or load programs.
|
||||
|
||||
Two of the ROM Applications are, in fact, complete operating systems.
|
||||
Specifically, "CP/M 2.2" and "Z-System" are provided so that you can
|
||||
actually start either operating system directly from your ROM. This
|
||||
@@ -1108,11 +1119,11 @@ system.
|
||||
|
||||
The drive letter assignments **do not** change during an OS session
|
||||
unless you use the `ASSIGN` command yourself to do it. Additionally, the
|
||||
assignments at boot will stay the same on each boot as long as you do
|
||||
assignments at boot will stay the same on each boot as long as you do
|
||||
not make changes to your hardware configuration. Note that the
|
||||
assignments **are** dependent on the media currently inserted in hard
|
||||
disk drives when the operating system is started. So, notice that if you
|
||||
insert or remove an SD Card, CF Card or USB Drive, the drive
|
||||
insert or remove an SD Card, CF Card or USB Drive, the drive
|
||||
assignments will change. Since drive letter assignments can change, you
|
||||
must be careful when doing destructive things like using `CLRDIR` to
|
||||
make sure the drive letter you use is referring to the desired media.
|
||||
@@ -1394,15 +1405,24 @@ filesystem format used is 8MB. This ensures any filesystem will be
|
||||
accessible to any of the operating systems.
|
||||
|
||||
Since storage devices today are quite large, RomWBW implements a
|
||||
mechanism called slicing to allow up to 256 8MB filesystems on a
|
||||
single large storage device. This allows up to 2GB of usable space on
|
||||
mechanism called slicing to allow up to 256 8MB CP/M filesystems on a
|
||||
single large storage device. To say it another way, the media is
|
||||
"sliced up" into many 8MB CP/M filesystems. Each slice is a complete
|
||||
CP/M filesystem. This allows up to 2GB of usable space on
|
||||
one media. You can think of slices as a way to refer to any of
|
||||
the first 256 8MB chunks of space on a single media.
|
||||
the first 256 8MB chunks of space on a single media. Each chunk
|
||||
is a CP/M filesystem.
|
||||
|
||||
Note that although you can use up to 256 slices per physical disk, this
|
||||
large number of slices is rarely used. The recommended RomWBW disk
|
||||
layout provides for 64 slices which is more than enough for most
|
||||
use cases.
|
||||
Note that slices are **not** the same thing as a hard disk partition.
|
||||
In fact, these slices all live inside of a single hard disk partition.
|
||||
Normally, a RomWBW hard disk will have one partition (called the
|
||||
RomWBW partition) containing 64 slices. Optionally, there may be
|
||||
a second partition which contains a FAT filesystem. For now, we
|
||||
are just talking about the slices within the single RomWBW partition.
|
||||
|
||||
Although you can use up to 256 slices per physical disk, this large
|
||||
number of slices is rarely used. The recommended RomWBW disk layout
|
||||
provides for 64 slices which is more than enough for most use cases.
|
||||
|
||||
Of course, the problem is that CP/M-like operating systems have only
|
||||
16 drive letters (A:-P:) available. Under the covers, RomWBW allows
|
||||
@@ -1438,22 +1458,28 @@ the same device/slice at the same time. Second, there must always be a
|
||||
drive assigned to A:. Any attempt to violate these rules will be blocked
|
||||
by the `ASSIGN` command.
|
||||
|
||||
As you see, the name of a slice does not reference the hard disk
|
||||
partition containing the slices. Since there can only be a single
|
||||
RomWBW partition containing slices on any disk, the partition is
|
||||
determined automatically.
|
||||
|
||||
In case this wasn't already clear, you **cannot** refer directly
|
||||
to slices using CP/M. CP/M only understands drive letters, so
|
||||
to access a given slice, you must assign a drive letter to it first.
|
||||
|
||||
While it may be obvious, you cannot use slices on any media less
|
||||
than 8MB in size. Specifically, you cannot slice RAM disks, ROM
|
||||
disks, floppy disks, etc. All of these are considered to have a single
|
||||
slice and any attempt to ASSIGN a drive letter to a slice beyond that
|
||||
will result in an error message.
|
||||
While it may be obvious, you cannot use slices on any media less than
|
||||
8MB in size. Specifically, you cannot slice RAM disks, ROM disks, floppy
|
||||
disks, etc. All of these are considered to have a single slice (slice
|
||||
0) and any attempt to ASSIGN a drive letter to a slice beyond that will
|
||||
fail and produce an error message.
|
||||
|
||||
It is very important to understand that RomWBW slices are not
|
||||
individually created or allocated on your hard disk. RomWBW uses a
|
||||
single, large chunk of space on your hard disk to contain the slices.
|
||||
You should think of slices as just an index into a sequential set of 8MB
|
||||
areas that exist in this large chunk of space. The next section will
|
||||
go into more detail on how slices are located on your hard disk.
|
||||
single, large chunk of space (partition) on your hard disk to contain
|
||||
the slices. You should think of slices as just an index into a
|
||||
sequential set of 8MB areas that exist in this large chunk of space.
|
||||
The next section will go into more detail on how slices are located on
|
||||
your hard disk.
|
||||
|
||||
Although you do not need to allocate slices individually, you do need to
|
||||
initialize each slice for CP/M to use it. This is somewhat analogous
|
||||
@@ -1465,10 +1491,10 @@ absolutely sure you know what media and slice are assigned to that
|
||||
drive letter before using `CLRDIR` because CLRDIR will wipe out any
|
||||
pre-existing contents of the slice.
|
||||
|
||||
**WARNING**: The `CLRDIR` application does not appear to check for
|
||||
disk errors when it runs. If you attempt to run `CLRDIR` on a drive
|
||||
that is mapped to a slice that does not actually fit on the physical
|
||||
disk, it may behave erratically.
|
||||
**WARNING**: Earlier versions of the `CLRDIR` application does not
|
||||
appear to check for disk errors when it runs. If you attempt to run
|
||||
`CLRDIR` on a drive that is mapped to a slice that does not actually fit
|
||||
on the physical disk, it may behave erratically.
|
||||
|
||||
Here is an example of using `CLRDIR`. In this example, the `ASSIGN`
|
||||
command is used to show the current drive letter assignments. Then
|
||||
@@ -1488,10 +1514,10 @@ B>assign
|
||||
H:=IDE0:3
|
||||
|
||||
B>clrdir G:
|
||||
CLRDIR Version 1.2 April 2020 by Max Scane
|
||||
CLRDIR Version 1.2B May 2024 by Max Scane
|
||||
|
||||
Warning - this utility will overwrite the directory sectors of Drive: G
|
||||
Type Y to proceed, any key other key to exit. Y
|
||||
Type CAPITAL Y to proceed, any key other key to exit. Y
|
||||
Directory cleared.
|
||||
B>
|
||||
```
|
||||
@@ -1695,9 +1721,9 @@ transferring your files over individually. You use your modern
|
||||
computer (Windows, Linux, MacOS) to write the disk image onto the
|
||||
disk media, then just move the media over to your system.
|
||||
|
||||
The disk image files are found in the Binary directory of the
|
||||
distribution. Floppy disk images are prefixed with "fd_" and hard
|
||||
disk images are prefixed with either "hd512_" or "hd1k_" depending on the
|
||||
The disk image files are found in the Binary directory of the
|
||||
distribution. Floppy disk images are prefixed with "fd_" and hard disk
|
||||
images are prefixed with either "hd512_" or "hd1k_" depending on the
|
||||
hard disk layout they are for.
|
||||
|
||||
Each disk image has the complete set of normal applications and tools
|
||||
@@ -1968,10 +1994,12 @@ custom hard disk image file, it will need to be written to the media
|
||||
using your modern computer. Note that you **do not** run `CLRDIR` or
|
||||
`SYSCOPY` on the slices that contain the data. When using this method,
|
||||
the disk will be partitioned and setup with 1 or more slices containing
|
||||
ready-to-run bootable operating systems.
|
||||
ready-to-run bootable operating systems. You **do** need to run
|
||||
`CLRDIR` and optionally `SYSCOPY` on slices that are not part of the
|
||||
image (slices beyond the ones included with the image).
|
||||
|
||||
To write a hard disk image file onto your actual media (actual hard disk
|
||||
or CF/SD/USB Media), you need to use an image writing utility on your
|
||||
or CF/SD/USB Media), you need to use an image writing utility on your
|
||||
modern computer. Your modern computer will need to have an appropriate
|
||||
interface or slot that accepts the media. To actually copy the image,
|
||||
you can use the `dd` command on Linux or MacOS. On Windows, in the
|
||||
@@ -2214,7 +2242,7 @@ less likely to encounter compatibility issues.
|
||||
|
||||
#### Documentation
|
||||
|
||||
* [CPM Manual]($doc_root$/CPM Manual.pdf)
|
||||
* [CPM Manual]($doc_root$/CPM/CPM Manual.pdf)
|
||||
|
||||
#### Boot Disk
|
||||
|
||||
@@ -2254,15 +2282,15 @@ significant improvements such as date/time stamping of files.
|
||||
|
||||
Z-System is a somewhat ambiguous term because there are multiple
|
||||
generations of this software. RomWBW Z-System is a combination of both
|
||||
ZCPR-DJ (the CCP) and ZSDOS 1.1 (the BDOS) when referring to Z-System.
|
||||
ZCPR-DJ (the CCP) and ZSDOS 1.1 (the BDOS) when referring to Z-System.
|
||||
The latest version of Z-System (ZCPR 3.4) is also provided with RomWBW
|
||||
via the NZ-COM adaptation (see below).
|
||||
|
||||
#### Documentation
|
||||
|
||||
* [ZCPR Manual]($doc_root$/ZCPR Manual.pdf)
|
||||
* [ZCPR-DJ]($doc_root$/ZCPR-DJ.doc)
|
||||
* [ZSDOS Manual]($doc_root$/ZSDOS Manual.pdf)
|
||||
* [ZCPR Manual]($doc_root$/CPM/ZCPR Manual.pdf)
|
||||
* [ZCPR-DJ]($doc_root$/CPM/ZCPR-DJ.doc)
|
||||
* [ZSDOS Manual]($doc_root$/CPM/ZSDOS Manual.pdf)
|
||||
|
||||
#### Boot Disk
|
||||
|
||||
@@ -2349,7 +2377,7 @@ Manual.pdf" document in order to use this operating system effectively.
|
||||
|
||||
#### Documentation
|
||||
|
||||
* [NZCOM Users Manual]($doc_root$/NZCOM Users Manual.pdf)
|
||||
* [NZCOM Users Manual]($doc_root$/CPM/NZCOM Users Manual.pdf)
|
||||
|
||||
#### Boot Disk
|
||||
|
||||
@@ -2374,10 +2402,10 @@ has a new suite of support tools and help system.
|
||||
|
||||
#### Documentation
|
||||
|
||||
* [CPM3 Users Guide]($doc_root$/CPM3 Users Guide.pdf)
|
||||
* [CPM3 Command Summary]($doc_root$/CPM3 Command Summary.pdf)
|
||||
* [CPM3 Programmers Guide]($doc_root$/CPM3 Programmers Guide.pdf)
|
||||
* [CPM3 System Guide]($doc_root$/CPM3 System Guide.pdf)
|
||||
* [CPM3 Users Guide]($doc_root$/CPM/CPM3 Users Guide.pdf)
|
||||
* [CPM3 Command Summary]($doc_root$/CPM/CPM3 Command Summary.pdf)
|
||||
* [CPM3 Programmers Guide]($doc_root$/CPM/CPM3 Programmers Guide.pdf)
|
||||
* [CPM3 System Guide]($doc_root$/CPM/CPM3 System Guide.pdf)
|
||||
|
||||
#### Boot Disk
|
||||
|
||||
@@ -2469,7 +2497,7 @@ CP/M 3 and ZCPR 3.
|
||||
To create (or update) a ZPM3 boot drive, you must place `ZPMLDR.SYS` on
|
||||
the system track of the disk. You must also place `CPM3.SYS`,
|
||||
`ZCCP.COM`, `ZINSTAL.ZPM`, and `STARTZPM.COM` on the target drive as
|
||||
regular files. Do **not** place CPM3.SYS on the boot track.
|
||||
regular files. Do **not** place CPM3.SYS on the boot track.
|
||||
`ZPMLDR.SYS` chain loads `CPM3.SYS` which must exist as a regular file
|
||||
on the disk. Subsequently, `CPM3.SYS` loads `CCP.COM`.
|
||||
|
||||
@@ -2526,9 +2554,9 @@ regarding the RomWBW adaptation and customizations.
|
||||
|
||||
#### Documentation
|
||||
|
||||
* [QP/M 2.7 Installation Guide and Supplements]($doc_root$/qpm27.pdf)
|
||||
* [QP/M 2.7 Interface Guide]($doc_root$/qdos27.pdf)
|
||||
* [QP/M 2.7 Features and Facilities]($doc_root$/qcp27.pdf)
|
||||
* [QP/M 2.7 Installation Guide and Supplements]($doc_root$/CPM/qpm27.pdf)
|
||||
* [QP/M 2.7 Interface Guide]($doc_root$/CPM/qdos27.pdf)
|
||||
* [QP/M 2.7 Features and Facilities]($doc_root$/CPM/qcp27.pdf)
|
||||
|
||||
#### Boot Disk
|
||||
|
||||
@@ -2548,9 +2576,9 @@ the QP/M components. To do this, you can perform the following steps:
|
||||
|
||||
1. Use RomWBW `SYSCOPY` to place the stock RomWBW CP/M OS image
|
||||
onto the system tracks of the QP/M boot disk:
|
||||
|
||||
|
||||
`SYSCOPY A:=x:CPM.SYS`
|
||||
|
||||
|
||||
where x is the drive letter of your ROM Disk.
|
||||
|
||||
1. Run `QINSTALL` to overlay the QP/M OS components on your
|
||||
@@ -2601,7 +2629,19 @@ selecting slice 0 of the corresponding hard disk unit at
|
||||
the RomWBW Boot Loader prompt. Do not attempt to use
|
||||
CP/M slices on the same disk.
|
||||
|
||||
Refer to the ReadMe.txt file in Source/pSys for more details.
|
||||
Due to limitations in the p-System configuration mechanism, it does
|
||||
not recognize the arrow keys of an ANSI Terminal. To work around
|
||||
this, the following control keys have been defined:
|
||||
|
||||
| Function | Key |
|
||||
|------------|------------|
|
||||
| Up | ctrl+E |
|
||||
| Down | ctrl+X |
|
||||
| Left | ctrl+S |
|
||||
| Right | ctrl+D |
|
||||
|
||||
Refer to [Source/pSys/ReadMe.txt]($file_root$/Source/pSys/ReadMe.txt)
|
||||
for more details about the p-System adaptation.
|
||||
|
||||
#### Documentation
|
||||
|
||||
@@ -2708,11 +2748,11 @@ To boot into Fuzix:
|
||||
```
|
||||
RCBus [RCZ180_nat_wbw] Boot Loader
|
||||
FP Switches = 0x00
|
||||
|
||||
|
||||
Boot [H=Help]: 2
|
||||
|
||||
|
||||
Booting Disk Unit 2, Slice 0, Sector 0x00000000...
|
||||
|
||||
|
||||
Volume "Fuzix 126 Loader" [0xF200-0xF400, entry @ 0xF200]...
|
||||
FUZIX version 0.4
|
||||
Copyright (c) 1988-2002 by H.F.Bower, D.Braun, S.Nitschke, H.Peraza
|
||||
@@ -2741,13 +2781,13 @@ To boot into Fuzix:
|
||||
Enter new date:
|
||||
Current time is 13:30:24
|
||||
Enter new time:
|
||||
|
||||
|
||||
^ ^
|
||||
n n Fuzix 0.4
|
||||
>@<
|
||||
Welcome to Fuzix
|
||||
m m
|
||||
|
||||
|
||||
login:
|
||||
```
|
||||
|
||||
@@ -2756,7 +2796,7 @@ To boot into Fuzix:
|
||||
|
||||
```
|
||||
login: root
|
||||
|
||||
|
||||
Welcome to FUZIX.
|
||||
#
|
||||
```
|
||||
@@ -2840,7 +2880,7 @@ This application understands both FAT filesystems as well as CP/M filesystems.
|
||||
characters are **not permitted** in a CP/M filename:
|
||||
|
||||
`< > . , ; : = ? * [ ] _ % | ( ) / \`
|
||||
|
||||
|
||||
The FAT application does not auto-rename files when it encounters
|
||||
invalid filenames. It will just issue an error and quit.
|
||||
Additionally, the error message is not very clear about the problem.
|
||||
@@ -2915,8 +2955,8 @@ computer and access it using `FAT` based on its RomWBW unit number.
|
||||
**WARNING**: Microsoft Windows will sometimes suggest reformatting
|
||||
partitions that it does not recognize. If you are prompted to format a
|
||||
partition of your SD/CF/USB Media when inserting the card into a Windows
|
||||
computer, you probably want to select Cancel.
|
||||
|
||||
computer, you probably want to select Cancel.
|
||||
|
||||
## FAT Application Usage
|
||||
|
||||
Complete instructions for the `FAT` application are found in $doc_apps$.
|
||||
@@ -3392,7 +3432,7 @@ The document is called "dri-cpnet.pdf".
|
||||
Under CP/M 2.2, you will start the networking client using the command
|
||||
`CPNETLDR`. Under CP/M 3, you use the command `NDOS3`. If that works,
|
||||
you can map network drives as local drives using the `NETWORK` command.
|
||||
The `CPNETSTS` command is useful for displaying the current status.
|
||||
The `CPNETSTS` command is useful for displaying the current status.
|
||||
Here is a sample session from CP/M 2.2:
|
||||
|
||||
```
|
||||
@@ -4183,6 +4223,8 @@ please let me know if I missed you!
|
||||
* Ladislau Szilagyi has contributed an enhanced version of
|
||||
CP/M Cowgol that leverages RomWBW memory banking.
|
||||
|
||||
* Les Bird has contributed support for the NABU w/ Option Board
|
||||
|
||||
Contributions of all kinds to RomWBW are very welcome.
|
||||
|
||||
# Licensing
|
||||
@@ -5680,6 +5722,16 @@ S- MD: TYPE=RAM
|
||||
|
||||
##### Notes:
|
||||
|
||||
- Z180 SBC SW2 (IOBYTE) Dip Switches:
|
||||
|
||||
| Bit | Setting | Function |
|
||||
|-----|---------|-------------------------------------|
|
||||
| 0 | Off | Use Z180 ASCI Channel A for console |
|
||||
| | On | Use Propeller Console |
|
||||
| | | |
|
||||
| 1 | Off | Boot to RomWBW Boot Loader |
|
||||
| | On | Boot to S100 Monitor |
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
### Duodyne Z80 System
|
||||
@@ -5810,6 +5862,63 @@ S- MD: TYPE=RAM
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
### NABU w/ RomWBW Option Board
|
||||
|
||||
#### ROM Image File: NABU_std.rom
|
||||
|
||||
| | |
|
||||
|-------------------|---------------|
|
||||
| Default CPU Speed | 3.580 MHz |
|
||||
| Interrupts | Mode 1 |
|
||||
| System Timer | None |
|
||||
| Serial Default | 115200 Baud |
|
||||
| Memory Manager | Z2 |
|
||||
| ROM Size | 512 KB |
|
||||
| RAM Size | 512 KB |
|
||||
|
||||
##### Supported Hardware (see [Appendix B - Device Summary]):
|
||||
|
||||
- UART: MODE=NABU, IO=72
|
||||
- TMS: MODE=NABU, IO=160
|
||||
- MD: TYPE=RAM
|
||||
- MD: TYPE=ROM
|
||||
- PPIDE: IO=96, MASTER
|
||||
- PPIDE: IO=96, SLAVE
|
||||
- AY38910: MODE=NABU, IO=65, CLOCK=1789772 HZ
|
||||
|
||||
##### Notes:
|
||||
|
||||
- TMS video assumes F18A replacement for TMS9918
|
||||
|
||||
`\clearpage`{=latex}
|
||||
|
||||
### S100 FPGA Z80
|
||||
|
||||
#### ROM Image File: FZ80_std.rom
|
||||
|
||||
| | |
|
||||
|-------------------|---------------|
|
||||
| Default CPU Speed | 8.000 MHz |
|
||||
| Interrupts | None |
|
||||
| System Timer | None |
|
||||
| Serial Default | 9600 Baud |
|
||||
| Memory Manager | Z2 |
|
||||
| ROM Size | 0 KB |
|
||||
| RAM Size | 512 KB |
|
||||
|
||||
##### Supported Hardware (see [Appendix B - Device Summary]):
|
||||
|
||||
FP: LEDIO=255
|
||||
SSER: IO=52
|
||||
SCON: IO=0
|
||||
MD: TYPE=RAM
|
||||
PPIDE: IO=48, MASTER
|
||||
PPIDE: IO=48, SLAVE
|
||||
|
||||
##### Notes:
|
||||
|
||||
- Requires matching FPGA code
|
||||
|
||||
## Appendix B - Device Summary
|
||||
|
||||
The table below briefly describes each of the possible devices that
|
||||
|
||||
18
Source/FZ80/Bank Layout.txt
Normal file
18
Source/FZ80/Bank Layout.txt
Normal file
@@ -0,0 +1,18 @@
|
||||
FPGA Z80 has no real ROM. It has a single 512K RAM chip.
|
||||
|
||||
The ROMless startup mode treats the entire 512KB as RAM. 384KB of RAM
|
||||
must be preloaded by the FPGA Monitor CF Loader. There will be no ROM
|
||||
disk available under RomWBW. There will be a RAM Disk and it's initial
|
||||
contents will be seeded by the image loaded by the CF Loader.
|
||||
|
||||
Bank Contents Description
|
||||
-------- -------- -----------
|
||||
0x0 BIOS HBIOS Bank (operating)
|
||||
0x1 IMG0 ROM Loader, Monitor, ROM OSes
|
||||
0x2 IMG1 ROM Applications
|
||||
0x3 IMG2 Reserved
|
||||
0x4-0xB RAMD RAM Disk Banks
|
||||
0xC BUF OS Buffers (CP/M3)
|
||||
0xD AUX Aux Bank (CP/M 3, BPBIOS, etc.)
|
||||
0xE USR User Bank (CP/M TPA, etc.)
|
||||
0xF COM Common Bank, Upper 32KB
|
||||
21
Source/FZ80/Build.cmd
Normal file
21
Source/FZ80/Build.cmd
Normal file
@@ -0,0 +1,21 @@
|
||||
@echo off
|
||||
setlocal
|
||||
|
||||
set TOOLS=../../Tools
|
||||
|
||||
set PATH=%TOOLS%\srecord;%PATH%
|
||||
|
||||
if exist ..\..\Binary\FZ80_std.rom call :build_fz80
|
||||
|
||||
goto :eof
|
||||
|
||||
:build_fz80
|
||||
|
||||
srec_cat -generate 0x0 0x100000 --constant 0x00 -o temp.dat -binary
|
||||
srec_cat temp.dat -binary -exclude 0x1B8 0x200 fz80_ptbl.bin -binary -offset 0x1B8 -o temp.dat -binary
|
||||
srec_cat temp.dat -binary -exclude 0x80000 0xE0000 ..\..\Binary\FZ80_std.rom -binary -offset 0x80000 -o temp.dat -binary
|
||||
move temp.dat ..\..\Binary\hd1k_fz80_prefix.dat
|
||||
|
||||
copy /b ..\..\Binary\hd1k_fz80_prefix.dat + ..\..\Binary\hd1k_cpm22.img + ..\..\Binary\hd1k_zsdos.img + ..\..\Binary\hd1k_nzcom.img + ..\..\Binary\hd1k_cpm3.img + ..\..\Binary\hd1k_zpm3.img + ..\..\Binary\hd1k_ws4.img ..\..\Binary\hd1k_fz80_combo.img || exit /b
|
||||
|
||||
goto :eof
|
||||
3
Source/FZ80/Clean.cmd
Normal file
3
Source/FZ80/Clean.cmd
Normal file
@@ -0,0 +1,3 @@
|
||||
@echo off
|
||||
setlocal
|
||||
|
||||
19
Source/FZ80/FZ80 Disk Layout.txt
Normal file
19
Source/FZ80/FZ80 Disk Layout.txt
Normal file
@@ -0,0 +1,19 @@
|
||||
FZ80 Disk Prefix Layout
|
||||
=======================
|
||||
|
||||
---- Bytes ---- --- Sectors ---
|
||||
Start Length Start Length Description
|
||||
------- ------- ------- ------- ---------------------------
|
||||
0x00000 0x001BE 0 1 Unused
|
||||
0x001B8 0x00048 RomWBW Partition Table
|
||||
0x00200 0x1EE00 1 7FE00 Unused
|
||||
0x80000 0x60000 1024 768 RomWBW
|
||||
0x100000 2048 Start of slices (partition 0x1E)
|
||||
|
||||
Notes
|
||||
-----
|
||||
|
||||
- FPGA Z80 Monitor reads 384KB (RomWBW) from sectors 1024-1791 of CF into first 384KB of physical RAM
|
||||
- FPGA Z80 ZRC Monitor maps first 32KB of physical RAM to first 32KB of CPU RAM and starts execution at 0x0000
|
||||
|
||||
-- WBW 3:18 PM 6/30/2024
|
||||
24
Source/FZ80/Makefile
Normal file
24
Source/FZ80/Makefile
Normal file
@@ -0,0 +1,24 @@
|
||||
HD1KFZ80PREFIX = hd1k_fz80_prefix.dat
|
||||
HD1KFZ80COMBOIMG = hd1k_fz80_combo.img
|
||||
FZ80ROM = ../../Binary/FZ80_std.rom
|
||||
HD1KIMGS = ../../Binary/hd1k_cpm22.img ../../Binary/hd1k_zsdos.img ../../Binary/hd1k_nzcom.img \
|
||||
../../Binary/hd1k_cpm3.img ../../Binary/hd1k_zpm3.img ../../Binary/hd1k_ws4.img
|
||||
|
||||
OBJECTS := $(HD1KFZ80PREFIX) $(HD1KFZ80COMBOIMG)
|
||||
|
||||
DEST=../../Binary
|
||||
|
||||
TOOLS = ../../Tools
|
||||
|
||||
include $(TOOLS)/Makefile.inc
|
||||
|
||||
DIFFPATH = $(DIFFTO)/Binary
|
||||
|
||||
$(HD1KFZ80PREFIX):
|
||||
srec_cat -generate 0x0 0x100000 --constant 0x00 -o temp.dat -binary
|
||||
srec_cat temp.dat -binary -exclude 0x1B8 0x200 fz80_ptbl.bin -binary -offset 0x1B8 -o temp.dat -binary
|
||||
srec_cat temp.dat -binary -exclude 0x80000 0xE0000 $(FZ80ROM) -binary -offset 0x80000 -o temp.dat -binary
|
||||
mv temp.dat $@
|
||||
|
||||
$(HD1KFZ80COMBOIMG): $(HD1KFZ80PREFIX) $(HD1KIMGS)
|
||||
cat $^ > $@
|
||||
BIN
Source/FZ80/fz80_ptbl.bin
Normal file
BIN
Source/FZ80/fz80_ptbl.bin
Normal file
Binary file not shown.
@@ -27,7 +27,7 @@ Bank ID Module Start Size
|
||||
0x04 - N ROM Disk Data
|
||||
|
||||
|
||||
Typical ROM Bank Layout
|
||||
Typical ROM Bank Layout (512K)
|
||||
|
||||
Bank ID Usage
|
||||
------- ------
|
||||
@@ -35,22 +35,43 @@ Bank ID Usage
|
||||
0x01 ROM Loader, Monitor, ROM OSes
|
||||
0x02 ROM Applications
|
||||
0x03 Reserved
|
||||
0x04-0x0F ROM Disk Banks
|
||||
0x04-0x0F ROM Disk Banks (12)
|
||||
|
||||
|
||||
Typical RAM Bank Layout
|
||||
Standard RAM Bank Layout (512K)
|
||||
|
||||
Bank ID Usage
|
||||
------- ------
|
||||
0x80 RomWBW HBIOS
|
||||
0x81-0x8B RAM Disk Data
|
||||
0x81-0x88 RAM Disk Data (3)
|
||||
0x89-0x8B App Banks (8)
|
||||
0x8C CP/M 3 Buffers
|
||||
0x8D CP/M 3 OS
|
||||
0x8E User TPA
|
||||
0x8F Common
|
||||
|
||||
Large RAM Bank Layout (2048K)
|
||||
|
||||
Typical ROMless Bank Layout
|
||||
Bank ID Usage
|
||||
------- ------
|
||||
0x80 RomWBW HBIOS
|
||||
0x81-0xB0 RAM Disk Data (30)
|
||||
0xB1-0xBB App Banks (11)
|
||||
0xBC CP/M 3 Buffers
|
||||
0x8D CP/M 3 OS
|
||||
0x8E User TPA
|
||||
0x8F Common
|
||||
|
||||
Tiny RAM Bank Layout (128K)
|
||||
|
||||
Bank ID Usage
|
||||
------- ------
|
||||
0x80 RomWBW HBIOS
|
||||
0x81 CP/M 3 OS
|
||||
0x82 User TPA
|
||||
0x83 Common
|
||||
|
||||
ROMless Standard Bank Layout (512K)
|
||||
|
||||
Bank ID Usage
|
||||
------- ------
|
||||
@@ -58,7 +79,7 @@ Bank ID Usage
|
||||
0x81 Loader, DbgMon, CP/M 2.2, ZSDOS
|
||||
0x82 ROM Apps
|
||||
0x83 More ROM Apps
|
||||
0x84-0x8B RAM Disk Data
|
||||
0x84-0x8B RAM Disk Data (8)
|
||||
0x8C CP/M 3 Buffers
|
||||
0x8D CP/M 3 OS
|
||||
0x8E User TPA
|
||||
|
||||
@@ -50,6 +50,7 @@ echo.
|
||||
::
|
||||
|
||||
tasm -t80 -g3 -dCMD hbios_env.asm hbios_env.com hbios_env.lst || exit /b
|
||||
zxcc hbios_env
|
||||
zxcc hbios_env >hbios_env.cmd
|
||||
call hbios_env.cmd
|
||||
|
||||
@@ -71,7 +72,7 @@ copy ..\Fonts\font*.asm . || exit /b
|
||||
|
||||
tasm -t%CPUType% -g3 -dROMBOOT hbios.asm hbios_rom.bin hbios_rom.lst || exit /b
|
||||
tasm -t%CPUType% -g3 -dAPPBOOT hbios.asm hbios_app.bin hbios_app.lst || exit /b
|
||||
tasm -t%CPUType% -g3 -dIMGBOOT hbios.asm hbios_img.bin hbios_img.lst || exit /b
|
||||
::tasm -t%CPUType% -g3 -dIMGBOOT hbios.asm hbios_img.bin hbios_img.lst || exit /b
|
||||
|
||||
::
|
||||
:: Build ROM Components
|
||||
@@ -242,5 +243,7 @@ call Build DUO std || exit /b
|
||||
call Build HEATH std || exit /b
|
||||
call Build EPITX std || exit /b
|
||||
:: call Build MON std || exit /b
|
||||
call Build NABU std || exit /b
|
||||
call Build FZ80 std || exit /b
|
||||
|
||||
goto :eof
|
||||
|
||||
@@ -27,7 +27,7 @@ $ErrorAction = 'Stop'
|
||||
# UNA BIOS is simply imbedded, it is not built here.
|
||||
#
|
||||
|
||||
$PlatformListZ80 = "SBC", "MBC", "ZETA", "ZETA2", "RCZ80", "Z80RETRO", "DUO", "UNA", "HEATH", "MON"
|
||||
$PlatformListZ80 = "SBC", "MBC", "ZETA", "ZETA2", "RCZ80", "Z80RETRO", "DUO", "UNA", "HEATH", "MON", "NABU", "FZ80"
|
||||
$PlatformListZ180 = "N8", "MK4", "RCZ180", "SCZ180", "DYNO", "RPH", "S100", "EPITX"
|
||||
$PlatformListZ280 = "RCZ280"
|
||||
|
||||
|
||||
@@ -51,6 +51,8 @@ if [ "${ROM_PLATFORM}" == "dist" ] ; then
|
||||
ROM_PLATFORM="HEATH"; ROM_CONFIG="std"; bash Build.sh
|
||||
ROM_PLATFORM="EPITX"; ROM_CONFIG="std"; bash Build.sh
|
||||
# ROM_PLATFORM="MON"; ROM_CONFIG="std"; bash Build.sh
|
||||
ROM_PLATFORM="NABU"; ROM_CONFIG="std"; bash Build.sh
|
||||
ROM_PLATFORM="FZ80"; ROM_CONFIG="std"; bash Build.sh
|
||||
exit
|
||||
fi
|
||||
|
||||
|
||||
@@ -31,7 +31,7 @@ CRTACT .SET FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
|
||||
;
|
||||
INTMODE .SET 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
|
||||
;
|
||||
;;;DMAENABLE .SET TRUE ; DMA: ENABLE DMA DRIVER (DMA.ASM)
|
||||
DMAENABLE .SET TRUE ; DMA: ENABLE DMA DRIVER (DMA.ASM)
|
||||
;
|
||||
BATCOND .SET TRUE ; ENABLE LOW BATTERY WARNING MESSAGE
|
||||
;
|
||||
@@ -44,4 +44,8 @@ MDFFENABLE .SET FALSE ; MD: ENABLE FLASH FILE SYSTEM
|
||||
;
|
||||
UARTINTS .SET FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
|
||||
;
|
||||
ESPENABLE .SET TRUE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)
|
||||
SN76489ENABLE .SET FALSE ; SN: ENABLE SN76489 SOUND DRIVER
|
||||
;
|
||||
CHENABLE .SET TRUE ; CH: ENABLE CH375/376 USB SUPPORT
|
||||
;
|
||||
ESPENABLE .SET FALSE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)
|
||||
|
||||
27
Source/HBIOS/Config/FZ80_std.asm
Normal file
27
Source/HBIOS/Config/FZ80_std.asm
Normal file
@@ -0,0 +1,27 @@
|
||||
;
|
||||
;==================================================================================================
|
||||
; S100 FPGZ Z80 STANDARD CONFIGURATION
|
||||
;==================================================================================================
|
||||
;
|
||||
; THE COMPLETE SET OF DEFAULT CONFIGURATION SETTINGS FOR THIS PLATFORM ARE FOUND IN THE
|
||||
; CFG_<PLT>.ASM INCLUDED FILE WHICH IS FOUND IN THE PARENT DIRECTORY. THIS FILE CONTAINS
|
||||
; COMMON CONFIGURATION SETTINGS THAT OVERRIDE THE DEFAULTS. IT IS INTENDED THAT YOU MAKE
|
||||
; YOUR CUSTOMIZATIONS IN THIS FILE AND JUST INHERIT ALL OTHER SETTINGS FROM THE DEFAULTS.
|
||||
; EVEN BETTER, YOU CAN MAKE A COPY OF THIS FILE WITH A NAME LIKE <PLT>_XXX.ASM AND SPECIFY
|
||||
; YOUR FILE IN THE BUILD PROCESS.
|
||||
;
|
||||
; THE SETTINGS BELOW ARE THE SETTINGS THAT ARE MOST COMMONLY MODIFIED FOR THIS PLATFORM.
|
||||
; MANY OF THEM ARE EQUAL TO THE SETTINGS IN THE INCLUDED FILE, SO THEY DON'T REALLY DO
|
||||
; ANYTHING AS IS. THEY ARE LISTED HERE TO MAKE IT EASY FOR YOU TO ADJUST THE MOST COMMON
|
||||
; SETTINGS.
|
||||
;
|
||||
; N.B., SINCE THE SETTINGS BELOW ARE REDEFINING VALUES ALREADY SET IN THE INCLUDED FILE,
|
||||
; TASM INSISTS THAT YOU USE THE .SET OPERATOR AND NOT THE .EQU OPERATOR BELOW. ATTEMPTING
|
||||
; TO REDEFINE A VALUE WITH .EQU BELOW WILL CAUSE TASM ERRORS!
|
||||
;
|
||||
; PLEASE REFER TO THE CUSTOM BUILD INSTRUCTIONS (README.TXT) IN THE SOURCE DIRECTORY (TWO
|
||||
; DIRECTORIES ABOVE THIS ONE).
|
||||
;
|
||||
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
|
||||
;
|
||||
#include "cfg_fz80.asm"
|
||||
32
Source/HBIOS/Config/NABU_std.asm
Normal file
32
Source/HBIOS/Config/NABU_std.asm
Normal file
@@ -0,0 +1,32 @@
|
||||
;
|
||||
;==================================================================================================
|
||||
; NABU Z80 STANDARD CONFIGURATION
|
||||
;==================================================================================================
|
||||
;
|
||||
; THE COMPLETE SET OF DEFAULT CONFIGURATION SETTINGS FOR THIS PLATFORM ARE FOUND IN THE
|
||||
; CFG_<PLT>.ASM INCLUDED FILE WHICH IS FOUND IN THE PARENT DIRECTORY. THIS FILE CONTAINS
|
||||
; COMMON CONFIGURATION SETTINGS THAT OVERRIDE THE DEFAULTS. IT IS INTENDED THAT YOU MAKE
|
||||
; YOUR CUSTOMIZATIONS IN THIS FILE AND JUST INHERIT ALL OTHER SETTINGS FROM THE DEFAULTS.
|
||||
; EVEN BETTER, YOU CAN MAKE A COPY OF THIS FILE WITH A NAME LIKE <PLT>_XXX.ASM AND SPECIFY
|
||||
; YOUR FILE IN THE BUILD PROCESS.
|
||||
;
|
||||
; THE SETTINGS BELOW ARE THE SETTINGS THAT ARE MOST COMMONLY MODIFIED FOR THIS PLATFORM.
|
||||
; MANY OF THEM ARE EQUAL TO THE SETTINGS IN THE INCLUDED FILE, SO THEY DON'T REALLY DO
|
||||
; ANYTHING AS IS. THEY ARE LISTED HERE TO MAKE IT EASY FOR YOU TO ADJUST THE MOST COMMON
|
||||
; SETTINGS.
|
||||
;
|
||||
; N.B., SINCE THE SETTINGS BELOW ARE REDEFINING VALUES ALREADY SET IN THE INCLUDED FILE,
|
||||
; TASM INSISTS THAT YOU USE THE .SET OPERATOR AND NOT THE .EQU OPERATOR BELOW. ATTEMPTING
|
||||
; TO REDEFINE A VALUE WITH .EQU BELOW WILL CAUSE TASM ERRORS!
|
||||
;
|
||||
; PLEASE REFER TO THE CUSTOM BUILD INSTRUCTIONS (README.TXT) IN THE SOURCE DIRECTORY (TWO
|
||||
; DIRECTORIES ABOVE THIS ONE).
|
||||
;
|
||||
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
|
||||
;
|
||||
#include "cfg_nabu.asm"
|
||||
;
|
||||
CRTACT .SET TRUE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
|
||||
;
|
||||
TMSMODE .SET TMSMODE_NABU80 ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO|NABU40|NABU80]
|
||||
|
||||
@@ -36,6 +36,7 @@ Z180_MEMWAIT .SET 0 ; Z180: MEMORY WAIT STATES (0-3)
|
||||
Z180_IOWAIT .SET 1 ; Z180: I/O WAIT STATES TO ADD ABOVE 1 W/S BUILT-IN (0-3)
|
||||
;
|
||||
LEDENABLE .SET TRUE ; ENABLE STATUS LED (SINGLE LED)
|
||||
LEDMODE .SET LEDMODE_STD ; LEDMODE_[STD|SC|RTC|NABU]
|
||||
LEDPORT .SET $0E ; STATUS LED PORT ADDRESS
|
||||
;
|
||||
FPLED_ENABLE .SET TRUE ; FP: ENABLES FRONT PANEL LEDS
|
||||
|
||||
@@ -705,12 +705,12 @@ ACIA0_CFG:
|
||||
.DW (ACIA0CLK / ACIA0DIV) & $FFFF ; CLOCK FREQ AS
|
||||
.DW (ACIA0CLK / ACIA0DIV) >> 16 ; ... DWORD VALUE
|
||||
;
|
||||
.ECHO "ACIA: IO="
|
||||
.ECHO ACIA0BASE
|
||||
DEVECHO "ACIA: IO="
|
||||
DEVECHO ACIA0BASE
|
||||
#IF (INTMODE == 1)
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
ACIA_CFGSIZ .EQU $ - ACIA_CFG ; SIZE OF ONE CFG TABLE ENTRY
|
||||
;
|
||||
@@ -728,12 +728,12 @@ ACIA1_CFG:
|
||||
.DW (ACIA1CLK / ACIA1DIV) & $FFFF ; CLOCK FREQ AS
|
||||
.DW (ACIA1CLK / ACIA1DIV) >> 16 ; ... DWORD VALUE
|
||||
;
|
||||
.ECHO "ACIA: IO="
|
||||
.ECHO ACIA1BASE
|
||||
DEVECHO "ACIA: IO="
|
||||
DEVECHO ACIA1BASE
|
||||
#IF (INTMODE == 1)
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
#ENDIF
|
||||
;
|
||||
|
||||
@@ -149,8 +149,20 @@ ANSI_IN1: ; PERFORM ACTUAL KEYBOARD INPUT
|
||||
LD B,BF_VDAKRD ; SET FUNCTION TO KEYBOARD READ
|
||||
CALL ANSI_VDADISP ; CALL VDA DISPATCHER
|
||||
LD A,E ; CHARACTER READ INTO A
|
||||
;
|
||||
; THE NABU USES KEYBOARD CODES TO REPORT JOYSTICK ACTIVITY USING
|
||||
; VALUES $A0-$BF. NORMALLY, WE WOULD PROCESS ANYTHING OVER $80 AS
|
||||
; A SPECIAL CHAR AND WIND UP IGNORING $80-$DF. FOR NABU, WE ALLOW
|
||||
; ANYTHING LESS THAN $E0 TO BE RETURNED TO THE APPLICATION FOR
|
||||
; JOYSTICK PROCESSING.
|
||||
;
|
||||
#IF (PLATFORM == PLT_NABU)
|
||||
CP $E0 ; >= $E0 IS SPECIAL KEY
|
||||
JR NC,ANSI_IN2 ; HANDLE SPECIAL KEY
|
||||
#ELSE
|
||||
BIT 7,A ; TEST HIGH BIT
|
||||
JR NZ,ANSI_IN2 ; HANDLE $80 OR HIGHER AS SPECIAL CHAR
|
||||
#ENDIF
|
||||
XOR A ; OTHERWISE, SIGNAL SUCCESS
|
||||
RET ; AND RETURN THE KEY
|
||||
;
|
||||
|
||||
@@ -618,7 +618,7 @@ ASCI_DETECT:
|
||||
; Z180 DIVISOR IS ALWAYS A FACTOR OF 160
|
||||
;
|
||||
; CNTLB= XXPXDSSS
|
||||
; FAILSAVE = 00100000
|
||||
; FAILSAFE = 00100000
|
||||
;
|
||||
; PS (PRESCALE): 0=/10, 1=/30
|
||||
; DR (DIVIDE RATIO): 0=/16, 1=/64
|
||||
@@ -837,12 +837,12 @@ ASCI1_CFG:
|
||||
.DW ASCI1CFG ; LINE CONFIGURATION
|
||||
.DW ASCI1_RCVBUF ; POINTER TO RCV BUFFER STRUCT
|
||||
;
|
||||
.ECHO "ASCI: IO="
|
||||
.ECHO ASCI1_BASE
|
||||
DEVECHO "ASCI: IO="
|
||||
DEVECHO ASCI1_BASE
|
||||
#IF ((ASCIINTS) & (INTMODE >0))
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
ASCI_CFGSIZ .EQU $ - ASCI_CFG ; SIZE OF ONE CFG TABLE ENTRY
|
||||
;
|
||||
@@ -855,12 +855,12 @@ ASCI0_CFG:
|
||||
.DW ASCI0CFG ; LINE CONFIGURATION
|
||||
.DW ASCI0_RCVBUF ; POINTER TO RCV BUFFER STRUCT
|
||||
;
|
||||
.ECHO "ASCI: IO="
|
||||
.ECHO ASCI0_BASE
|
||||
DEVECHO "ASCI: IO="
|
||||
DEVECHO ASCI0_BASE
|
||||
#IF ((ASCIINTS) & (INTMODE >0))
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
#ELSE
|
||||
;
|
||||
@@ -873,12 +873,12 @@ ASCI0_CFG:
|
||||
.DW ASCI0CFG ; LINE CONFIGURATION
|
||||
.DW ASCI0_RCVBUF ; POINTER TO RCV BUFFER STRUCT
|
||||
;
|
||||
.ECHO "ASCI: IO="
|
||||
.ECHO ASCI0_BASE
|
||||
DEVECHO "ASCI: IO="
|
||||
DEVECHO ASCI0_BASE
|
||||
#IF ((ASCIINTS) & (INTMODE >0))
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
ASCI_CFGSIZ .EQU $ - ASCI_CFG ; SIZE OF ONE CFG TABLE ENTRY
|
||||
;
|
||||
@@ -891,12 +891,12 @@ ASCI1_CFG:
|
||||
.DW ASCI1CFG ; LINE CONFIGURATION
|
||||
.DW ASCI1_RCVBUF ; POINTER TO RCV BUFFER STRUCT
|
||||
;
|
||||
.ECHO "ASCI: IO="
|
||||
.ECHO ASCI1_BASE
|
||||
DEVECHO "ASCI: IO="
|
||||
DEVECHO ASCI1_BASE
|
||||
#IF ((ASCIINTS) & (INTMODE > 0))
|
||||
.ECHO ", INTERRUPTS ENABLED"
|
||||
DEVECHO ", INTERRUPTS ENABLED"
|
||||
#ENDIF
|
||||
.ECHO "\n"
|
||||
DEVECHO "\n"
|
||||
;
|
||||
#ENDIF
|
||||
;
|
||||
|
||||
@@ -19,16 +19,25 @@
|
||||
; UNUSED BITS CAN BE READ BACK AND WRITTEN ON YM.
|
||||
; VOLTAGE LEVEL OUTPUT ON A AY-3-8910 IS LOW AND AROUND 2V ON YM2149.
|
||||
;
|
||||
; THERE ARE TWO VARIANTS OF AY-3-8910 SOUND CARDS THAT HAVE BEEN
|
||||
; PRODUCED FOR THE RCBUS. THE ONE PRODUCED BY ED BRINDLEY (EB) USES
|
||||
; THE SAME PORT FOR REGISTER SELECT (RSEL) AND REGISTER IN (RIN).
|
||||
; THE ONE PRODUCED BY MARTEN FELDTMANN (MF) USES THE PORT FOLLOWING
|
||||
; REGISTER SELECT (RSEL) FOR THE REGISTER IN (RIN) PORT. THE FOLLOWING
|
||||
; EQUATE MUST BE SET CORRECTLY FOR THE HARDWARE BEING USED. THIS
|
||||
; HAS NOT BEEN MOVED TO A CONFIG VARIABLE BECAUSE THE MF MODULE IS
|
||||
; RARELY ENCOUNTERED IN THE WILD.
|
||||
;
|
||||
AY_RCSND .EQU 0 ; 0 = EB MODULE, 1=MF MODULE
|
||||
;
|
||||
.ECHO "AY38910: MODE="
|
||||
DEVECHO "AY38910: MODE="
|
||||
;
|
||||
#IF (AYMODE == AYMODE_SCG)
|
||||
AY_RSEL .EQU $9A
|
||||
AY_RDAT .EQU $9B
|
||||
AY_RIN .EQU AY_RSEL
|
||||
AY_ACR .EQU $9C
|
||||
.ECHO "SCG"
|
||||
DEVECHO "SCG"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_N8)
|
||||
@@ -36,35 +45,35 @@ AY_RSEL .EQU $9C
|
||||
AY_RDAT .EQU $9D
|
||||
AY_RIN .EQU AY_RSEL
|
||||
AY_ACR .EQU N8_ACR
|
||||
.ECHO "N8"
|
||||
DEVECHO "N8"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_RCZ80)
|
||||
AY_RSEL .EQU $D8
|
||||
AY_RDAT .EQU $D0
|
||||
AY_RIN .EQU AY_RSEL+AY_RCSND
|
||||
.ECHO "RCZ80"
|
||||
DEVECHO "RCZ80"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_RCZ180)
|
||||
AY_RSEL .EQU $68
|
||||
AY_RDAT .EQU $60
|
||||
AY_RIN .EQU AY_RSEL+AY_RCSND
|
||||
.ECHO "RCZ180"
|
||||
DEVECHO "RCZ180"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_MSX)
|
||||
AY_RSEL .EQU $A0
|
||||
AY_RDAT .EQU $A1
|
||||
AY_RIN .EQU $A2
|
||||
.ECHO "MSX"
|
||||
DEVECHO "MSX"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_LINC)
|
||||
AY_RSEL .EQU $33
|
||||
AY_RDAT .EQU $32
|
||||
AY_RIN .EQU $32
|
||||
.ECHO "LINC"
|
||||
DEVECHO "LINC"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_MBC)
|
||||
@@ -72,7 +81,7 @@ AY_RSEL .EQU $A0
|
||||
AY_RDAT .EQU $A1
|
||||
AY_RIN .EQU AY_RSEL
|
||||
AY_ACR .EQU $A2
|
||||
.ECHO "MBC"
|
||||
DEVECHO "MBC"
|
||||
#ENDIF
|
||||
;
|
||||
#IF (AYMODE == AYMODE_DUO)
|
||||
@@ -80,14 +89,21 @@ AY_RSEL .EQU $A4
|
||||
AY_RDAT .EQU $A5
|
||||
AY_RIN .EQU AY_RSEL
|
||||
AY_ACR .EQU $A6
|
||||
.ECHO "DUO"
|
||||
DEVECHO "DUO"
|
||||
#ENDIF
|
||||
;
|
||||
.ECHO ", IO="
|
||||
.ECHO AY_RSEL
|
||||
.ECHO ", CLOCK="
|
||||
.ECHO AY_CLK
|
||||
.ECHO " HZ\n"
|
||||
#IF (AYMODE == AYMODE_NABU)
|
||||
AY_RSEL .EQU $41
|
||||
AY_RDAT .EQU $40
|
||||
AY_RIN .EQU $40
|
||||
DEVECHO "NABU"
|
||||
#ENDIF
|
||||
;
|
||||
DEVECHO ", IO="
|
||||
DEVECHO AY_RSEL
|
||||
DEVECHO ", CLOCK="
|
||||
DEVECHO AY_CLK
|
||||
DEVECHO " HZ\n"
|
||||
;
|
||||
;======================================================================
|
||||
;
|
||||
@@ -212,7 +228,7 @@ AY_FND: LD IY, AY_IDAT ; SETUP FUNCTION TABLE
|
||||
;
|
||||
CALL AY_INIT ; SET DEFAULT CHIP CONFIGURATION
|
||||
;
|
||||
LD E,$07 ; SET VOLUME TO 50%
|
||||
LD E,$08 ; SET VOLUME TO 50%
|
||||
CALL AY_SETV ; ON ALL CHANNELS
|
||||
;
|
||||
; LD DE,(AY_R2CHBP*256)+$55 ; BEEP ON CHANNEL B (CENTER)
|
||||
@@ -220,14 +236,19 @@ AY_FND: LD IY, AY_IDAT ; SETUP FUNCTION TABLE
|
||||
LD DE,(AY_R3CHBP*256)+$00
|
||||
CALL AY_WRTPSG ; R03 = $00 = XXXX0000
|
||||
;
|
||||
#IF ((SYSTIM != TM_NONE) & (AYMODE != AYMODE_DUO))
|
||||
#IF (SYSTIM != TM_NONE)
|
||||
LD A, TICKFREQ / 3 ; SCHEDULE IN 1/3 SECOND TO TURN OFF SOUND
|
||||
LD (AY_TIMTIK), A
|
||||
;
|
||||
LD HL, (VEC_TICK + 1) ; GET CUR TICKS VECTOR
|
||||
LD (AY_TIMHOOK), HL ; SAVE IT INTERNALLY
|
||||
LD HL, AY_TIMER ; INSTALL TIMER HOOK HANDLER
|
||||
LD (VEC_TICK + 1), HL
|
||||
; RESET THE AY_TIMER BYPASS
|
||||
LD HL,AY_TIMER1
|
||||
LD (AY_TIMER + 1),HL
|
||||
;
|
||||
; HOOK THE TICK VECTOR
|
||||
LD HL,(VEC_TICK + 1) ; GET CUR TICKS VECTOR
|
||||
LD (AY_TIMHOOK + 1),HL ; SAVE IT INTERNALLY
|
||||
LD HL,AY_TIMER ; INSTALL TIMER HOOK HANDLER
|
||||
LD (VEC_TICK + 1),HL
|
||||
;
|
||||
LD A, $02 ; NOT READY & IN INTERUPT HANDLER
|
||||
LD (AY_READY), A
|
||||
@@ -242,27 +263,27 @@ AY_FND: LD IY, AY_IDAT ; SETUP FUNCTION TABLE
|
||||
XOR A ; SUCCESSFULL INIT
|
||||
RET
|
||||
;
|
||||
#IF ((SYSTIM != TM_NONE) & (AYMODE != AYMODE_DUO))
|
||||
#IF (SYSTIM != TM_NONE)
|
||||
AY_TIMER:
|
||||
LD A, (AY_TIMTIK)
|
||||
JP AY_TIMER1 ; SELF MODIFIED TO BYPASS HANDLER
|
||||
AY_TIMER1:
|
||||
LD A,(AY_TIMTIK)
|
||||
DEC A
|
||||
LD (AY_TIMTIK), A
|
||||
JR NZ, AY_TIMER1
|
||||
JR NZ,AY_TIMHOOK
|
||||
;
|
||||
LD E,$00 ; SET VOLUME OFF
|
||||
CALL AY_SETV ; ON ALL CHANNELS
|
||||
LD A, $01 ; READY & NOT IN INTERUPT HANDLER
|
||||
LD (AY_READY), A
|
||||
;
|
||||
LD DE, AY_TIMER ; MAKE AY_TIMER A NO_OP HANDLER
|
||||
LD HL, AY_TIMER1
|
||||
LD BC, 3
|
||||
LDIR
|
||||
; MAKE AY_TIMER A NO-OP HANDLER
|
||||
LD HL,(AY_TIMHOOK + 1)
|
||||
LD (AY_TIMER + 1),HL
|
||||
;
|
||||
AY_TIMER1:
|
||||
AY_TIMHOOK:
|
||||
JP 0 ; OVERWRITTEN WITH NEXT HANDLER
|
||||
AY_TIMHOOK: .EQU $ - 2
|
||||
|
||||
;
|
||||
AY_TIMTIK .DB 0 ; COUNT DOWN TO FINISH BOOT BEEP
|
||||
#ENDIF
|
||||
;
|
||||
@@ -271,8 +292,14 @@ AY_TIMTIK .DB 0 ; COUNT DOWN TO FINISH BOOT BEEP
|
||||
;======================================================================
|
||||
;
|
||||
AY_INIT:
|
||||
#IF (AYMODE == AYMODE_NABU)
|
||||
; I/O B=INPUT, I/O A=OUTPUT, NOISE CHANNEL C, B, A DISABLE, TONE CHANNEL C, B, A ENABLE
|
||||
LD DE,(AY_R7ENAB*256)+$78 ; SET MIXER CONTROL / IO ENABLE. $78 - 01 111 000
|
||||
#ELSE
|
||||
; I/O PORTS = OUTPUT, NOISE CHANNEL C, B, A DISABLE, TONE CHANNEL C, B, A ENABLE
|
||||
LD DE,(AY_R7ENAB*256)+$F8 ; SET MIXER CONTROL / IO ENABLE. $F8 - 11 111 000
|
||||
JP AY_WRTPSG ; I/O PORTS = OUTPUT, NOISE CHANNEL C, B, A DISABLE, TONE CHANNEL C, B, A ENABLE
|
||||
#ENDIF
|
||||
JP AY_WRTPSG
|
||||
;
|
||||
AY_CHKREDY:
|
||||
LD A, (AY_READY)
|
||||
|
||||
@@ -91,9 +91,9 @@ BQRTC_UTI .EQU %00001000
|
||||
|
||||
BQRTC_BUFSIZE .EQU 6 ; 6 BYTE BUFFER (YYMMDDHHMMSS)
|
||||
|
||||
.ECHO "BQRTC: IO="
|
||||
.ECHO BQRTC_BASE
|
||||
.ECHO "\n"
|
||||
DEVECHO "BQRTC: IO="
|
||||
DEVECHO BQRTC_BASE
|
||||
DEVECHO "\n"
|
||||
|
||||
; RTC Device Initialization Entry
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
;
|
||||
#INCLUDE "hbios.inc"
|
||||
;
|
||||
PLATFORM .EQU PLT_DUO ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|MON]
|
||||
PLATFORM .EQU PLT_DUO ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
|
||||
CPUFAM .EQU CPU_Z80 ; CPU FAMILY: CPU_[Z80|Z180|Z280]
|
||||
BIOS .EQU BIOS_WBW ; HARDWARE BIOS: BIOS_[WBW|UNA]
|
||||
BATCOND .EQU FALSE ; ENABLE LOW BATTERY WARNING MESSAGE
|
||||
@@ -78,7 +78,7 @@ FPSW_INV .EQU FALSE ; FP: SWITCH BITS ARE INVERTED
|
||||
DIAGLVL .EQU DL_CRITICAL ; ERROR LEVEL REPORTING
|
||||
;
|
||||
LEDENABLE .EQU TRUE ; ENABLES STATUS LED
|
||||
LEDMODE .EQU LEDMODE_RTC ; LEDMODE_[STD|RTC]
|
||||
LEDMODE .EQU LEDMODE_RTC ; LEDMODE_[STD|SC|RTC|NABU]
|
||||
LEDPORT .EQU RTCIO ; STATUS LED PORT ADDRESS
|
||||
LEDDISKIO .EQU TRUE ; ENABLES DISK I/O ACTIVITY ON STATUS LED
|
||||
;
|
||||
@@ -105,7 +105,7 @@ MKYENABLE .EQU FALSE ; MSX 5255 PPI KEYBOARD COMPATIBLE DRIVER (REQUIRES TMS VD
|
||||
MKYKBLOUT .EQU KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
|
||||
;
|
||||
DSRTCENABLE .EQU TRUE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC]
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC|K80W]
|
||||
DSRTCCHG .EQU FALSE ; DSRTC: FORCE BATTERY CHARGE ON (USE WITH CAUTION!!!)
|
||||
;
|
||||
DS1501RTCENABLE .EQU FALSE ; DS1501RTC: ENABLE DS-1501 CLOCK DRIVER (DS1501RTC.ASM)
|
||||
@@ -124,6 +124,15 @@ SIMRTCENABLE .EQU FALSE ; ENABLE SIMH CLOCK DRIVER (SIMRTC.ASM)
|
||||
DS7RTCENABLE .EQU FALSE ; DS7RTC: ENABLE DS-1307 I2C CLOCK DRIVER (DS7RTC.ASM)
|
||||
DS7RTCMODE .EQU DS7RTCMODE_PCF ; DS7RTC: OPERATING MODE: DS7RTC_[PCF]
|
||||
;
|
||||
SSERENABLE .EQU FALSE ; SSER: ENABLE SIMPLE SERIAL DRIVER (SSER.ASM)
|
||||
SSERCFG .EQU SER_9600_8N1 ; SSER: SERIAL LINE CONFIG
|
||||
SSERSTATUS .EQU $FF ; SSER: STATUS PORT
|
||||
SSERDATA .EQU $FF ; SSER: DATA PORT
|
||||
SSERIRDY .EQU %00000001 ; SSER: INPUT READY BIT MASK
|
||||
SSERIINV .EQU FALSE ; SSER: INPUT READY BIT INVERTED
|
||||
SSERORDY .EQU %00000010 ; SSER: OUTPUT READY BIT MASK
|
||||
SSEROINV .EQU FALSE ; SSER: OUTPUT READY BIT INVERTED
|
||||
;
|
||||
DUARTENABLE .EQU FALSE ; DUART: ENABLE 2681/2692 SERIAL DRIVER (DUART.ASM)
|
||||
;
|
||||
UARTENABLE .EQU TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
|
||||
@@ -131,7 +140,7 @@ UARTOSC .EQU 7372800 ; UART: OSC FREQUENCY IN MHZ
|
||||
UARTINTS .EQU FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
|
||||
UARTCFG .EQU DEFSERCFG ; UART: LINE CONFIG FOR UART PORTS
|
||||
UARTCASSPD .EQU SER_300_8N1 ; UART: ECB CASSETTE UART DEFAULT SPEED
|
||||
UARTSBC .EQU TRUE ; UART: AUTO-DETECT SBC/ZETA/DUO ONBOARD UART
|
||||
UARTSBC .EQU TRUE ; UART: AUTO-DETECT SBC/ZETA/DUO/NABU ONBOARD UART
|
||||
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
|
||||
UARTAUX .EQU TRUE ; UART: AUTO-DETECT AUX UART
|
||||
UARTCAS .EQU FALSE ; UART: AUTO-DETECT ECB CASSETTE UART
|
||||
@@ -168,7 +177,7 @@ CVDUMODE .EQU CVDUMODE_MBC ; CVDU: CVDU MODE: CVDUMODE_[NONE|ECB|MBC]
|
||||
CVDUMON .EQU CVDUMON_CGA ; CVDU: CVDU MONITOR SETUP: CVDUMON_[NONE|CGA|EGA]
|
||||
GDCENABLE .EQU FALSE ; GDC: ENABLE 7220 GDC VIDEO/KBD DRIVER (GDC.ASM)
|
||||
TMSENABLE .EQU TRUE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
|
||||
TMSMODE .EQU TMSMODE_DUO ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO]
|
||||
TMSMODE .EQU TMSMODE_DUO ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO|NABU40|NABU80]
|
||||
TMSTIMENABLE .EQU FALSE ; TMS: ENABLE TIMER INTERRUPTS (REQUIRES IM1)
|
||||
VGAENABLE .EQU FALSE ; VGA: ENABLE VGA VIDEO/KBD DRIVER (VGA.ASM)
|
||||
VGASIZ .EQU V80X25 ; VGA: DISPLAY FORMAT [V80X25|V80X30|V80X43]
|
||||
@@ -237,7 +246,7 @@ SDTRACE .EQU 1 ; SD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
|
||||
SDCSIOFAST .EQU FALSE ; SD: ENABLE TABLE-DRIVEN BIT INVERTER IN CSIO MODE
|
||||
SDMTSWAP .EQU TRUE ; SD: SWAP THE LOGICAL ORDER OF THE SPI PORTS OF THE MT011
|
||||
;
|
||||
CHENABLE .EQU TRUE ; CH: ENABLE CH375/376 USB SUPPORT
|
||||
CHENABLE .EQU FALSE ; CH: ENABLE CH375/376 USB SUPPORT
|
||||
CHTRACE .EQU 1 ; CH: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
|
||||
CHUSBTRACE .EQU 1 ; CHUSB: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
|
||||
CHSDTRACE .EQU 1 ; CHSD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
|
||||
@@ -308,11 +317,11 @@ UFBASE .EQU $0C ; UF: REGISTERS BASE ADR
|
||||
SN76489ENABLE .EQU FALSE ; SN: ENABLE SN76489 SOUND DRIVER
|
||||
AUDIOTRACE .EQU FALSE ; ENABLE TRACING TO CONSOLE OF SOUND DRIVER
|
||||
SN7CLK .EQU 3579545 ; SN: PSG CLOCK FREQ, ASSUME MSX STD
|
||||
SNMODE .EQU SNMODE_NONE ; SN: DRIVER MODE: SNMODE_[NONE|RC|VGM]
|
||||
SNMODE .EQU SNMODE_DUO ; SN: DRIVER MODE: SNMODE_[NONE|RC|VGM|DUO]
|
||||
;
|
||||
AY38910ENABLE .EQU TRUE ; AY: ENABLE AY-3-8910 / YM2149 SOUND DRIVER
|
||||
AY_CLK .EQU 1789772 ; AY: PSG CLOCK FREQ, ASSUME MSX STD
|
||||
AYMODE .EQU AYMODE_DUO ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO]
|
||||
AYMODE .EQU AYMODE_DUO ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO|NABU]
|
||||
;
|
||||
SPKENABLE .EQU TRUE ; SPK: ENABLE RTC LATCH IOBIT SOUND DRIVER (SPK.ASM)
|
||||
;
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
;
|
||||
#INCLUDE "hbios.inc"
|
||||
;
|
||||
PLATFORM .EQU PLT_DYNO ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|MON]
|
||||
PLATFORM .EQU PLT_DYNO ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
|
||||
CPUFAM .EQU CPU_Z180 ; CPU FAMILY: CPU_[Z80|Z180|Z280]
|
||||
BIOS .EQU BIOS_WBW ; HARDWARE BIOS: BIOS_[WBW|UNA]
|
||||
BATCOND .EQU FALSE ; ENABLE LOW BATTERY WARNING MESSAGE
|
||||
@@ -80,7 +80,7 @@ FPSW_INV .EQU FALSE ; FP: SWITCH BITS ARE INVERTED
|
||||
DIAGLVL .EQU DL_CRITICAL ; ERROR LEVEL REPORTING
|
||||
;
|
||||
LEDENABLE .EQU FALSE ; ENABLES STATUS LED (SINGLE LED)
|
||||
LEDMODE .EQU LEDMODE_STD ; LEDMODE_[STD|RTC]
|
||||
LEDMODE .EQU LEDMODE_STD ; LEDMODE_[STD|SC|RTC|NABU]
|
||||
LEDPORT .EQU $0E ; STATUS LED PORT ADDRESS
|
||||
LEDDISKIO .EQU TRUE ; ENABLES DISK I/O ACTIVITY ON STATUS LED
|
||||
;
|
||||
@@ -107,7 +107,7 @@ MKYENABLE .EQU FALSE ; MSX 5255 PPI KEYBOARD COMPATIBLE DRIVER (REQUIRES TMS VD
|
||||
MKYKBLOUT .EQU KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
|
||||
;
|
||||
DSRTCENABLE .EQU FALSE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC]
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC|K80W]
|
||||
DSRTCCHG .EQU FALSE ; DSRTC: FORCE BATTERY CHARGE ON (USE WITH CAUTION!!!)
|
||||
;
|
||||
DS1501RTCENABLE .EQU FALSE ; DS1501RTC: ENABLE DS-1501 CLOCK DRIVER (DS1501RTC.ASM)
|
||||
@@ -126,6 +126,15 @@ SIMRTCENABLE .EQU FALSE ; ENABLE SIMH CLOCK DRIVER (SIMRTC.ASM)
|
||||
DS7RTCENABLE .EQU FALSE ; DS7RTC: ENABLE DS-1307 I2C CLOCK DRIVER (DS7RTC.ASM)
|
||||
DS7RTCMODE .EQU DS7RTCMODE_PCF ; DS7RTC: OPERATING MODE: DS7RTC_[PCF]
|
||||
;
|
||||
SSERENABLE .EQU FALSE ; SSER: ENABLE SIMPLE SERIAL DRIVER (SSER.ASM)
|
||||
SSERCFG .EQU SER_9600_8N1 ; SSER: SERIAL LINE CONFIG
|
||||
SSERSTATUS .EQU $FF ; SSER: STATUS PORT
|
||||
SSERDATA .EQU $FF ; SSER: DATA PORT
|
||||
SSERIRDY .EQU %00000001 ; SSER: INPUT READY BIT MASK
|
||||
SSERIINV .EQU FALSE ; SSER: INPUT READY BIT INVERTED
|
||||
SSERORDY .EQU %00000010 ; SSER: OUTPUT READY BIT MASK
|
||||
SSEROINV .EQU FALSE ; SSER: OUTPUT READY BIT INVERTED
|
||||
;
|
||||
DUARTENABLE .EQU FALSE ; DUART: ENABLE 2681/2692 SERIAL DRIVER (DUART.ASM)
|
||||
DUARTCNT .EQU 1 ; DUART: NUMBER OF CHIPS TO DETECT (1-2)
|
||||
DUART0BASE .EQU $A0 ; DUART 0: BASE ADDRESS OF CHIP
|
||||
@@ -139,7 +148,7 @@ UARTENABLE .EQU FALSE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
|
||||
UARTOSC .EQU 1843200 ; UART: OSC FREQUENCY IN MHZ
|
||||
UARTINTS .EQU FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
|
||||
UARTCFG .EQU DEFSERCFG | SER_RTS ; UART: LINE CONFIG FOR UART PORTS
|
||||
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO ONBOARD UART
|
||||
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO/NABU ONBOARD UART
|
||||
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
|
||||
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
|
||||
UARTCAS .EQU FALSE ; UART: AUTO-DETECT ECB CASSETTE UART
|
||||
@@ -186,7 +195,7 @@ VDUENABLE .EQU FALSE ; VDU: ENABLE VDU VIDEO/KBD DRIVER (VDU.ASM)
|
||||
CVDUENABLE .EQU FALSE ; CVDU: ENABLE CVDU VIDEO/KBD DRIVER (CVDU.ASM)
|
||||
GDCENABLE .EQU FALSE ; GDC: ENABLE 7220 GDC VIDEO/KBD DRIVER (GDC.ASM)
|
||||
TMSENABLE .EQU FALSE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
|
||||
TMSMODE .EQU TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO]
|
||||
TMSMODE .EQU TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO|NABU40|NABU80]
|
||||
TMSTIMENABLE .EQU FALSE ; TMS: ENABLE TIMER INTERRUPTS (REQUIRES IM1)
|
||||
VGAENABLE .EQU FALSE ; VGA: ENABLE VGA VIDEO/KBD DRIVER (VGA.ASM)
|
||||
VRCENABLE .EQU FALSE ; VRC: ENABLE VGARC VIDEO/KBD DRIVER (VRC.ASM)
|
||||
@@ -291,7 +300,7 @@ SNMODE .EQU SNMODE_NONE ; SN: DRIVER MODE: SNMODE_[NONE|RC|VGM]
|
||||
;
|
||||
AY38910ENABLE .EQU FALSE ; AY: ENABLE AY-3-8910 / YM2149 SOUND DRIVER
|
||||
AY_CLK .EQU 1789772 ; AY: PSG CLOCK FREQ, ASSUME MSX STD
|
||||
AYMODE .EQU AYMODE_NONE ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO]
|
||||
AYMODE .EQU AYMODE_NONE ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO|NABU]
|
||||
;
|
||||
SPKENABLE .EQU FALSE ; SPK: ENABLE RTC LATCH IOBIT SOUND DRIVER (SPK.ASM)
|
||||
;
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
;
|
||||
#INCLUDE "hbios.inc"
|
||||
;
|
||||
PLATFORM .EQU PLT_EPITX ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|MON]
|
||||
PLATFORM .EQU PLT_EPITX ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|RPH|Z80RETRO|S100|DUO|HEATH|EPITX|MON|STDZ180|NABU|FZ80]
|
||||
CPUFAM .EQU CPU_Z180 ; CPU FAMILY: CPU_[Z80|Z180|Z280]
|
||||
BIOS .EQU BIOS_WBW ; HARDWARE BIOS: BIOS_[WBW|UNA]
|
||||
BATCOND .EQU FALSE ; ENABLE LOW BATTERY WARNING MESSAGE
|
||||
@@ -81,7 +81,7 @@ FPSW_INV .EQU FALSE ; FP: SWITCH BITS ARE INVERTED
|
||||
DIAGLVL .EQU DL_CRITICAL ; ERROR LEVEL REPORTING
|
||||
;
|
||||
LEDENABLE .EQU FALSE ; ENABLES STATUS LED (SINGLE LED)
|
||||
LEDMODE .EQU LEDMODE_STD ; LEDMODE_[STD|RTC]
|
||||
LEDMODE .EQU LEDMODE_STD ; LEDMODE_[STD|SC|RTC|NABU]
|
||||
LEDPORT .EQU $0E ; STATUS LED PORT ADDRESS
|
||||
LEDDISKIO .EQU TRUE ; ENABLES DISK I/O ACTIVITY ON STATUS LED
|
||||
;
|
||||
@@ -109,7 +109,7 @@ MKYENABLE .EQU FALSE ; MSX 5255 PPI KEYBOARD COMPATIBLE DRIVER (REQUIRES TMS VD
|
||||
MKYKBLOUT .EQU KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
|
||||
;
|
||||
DSRTCENABLE .EQU FALSE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC]
|
||||
DSRTCMODE .EQU DSRTCMODE_STD ; DSRTC: OPERATING MODE: DSRTC_[STD|MFPIC|K80W]
|
||||
DSRTCCHG .EQU FALSE ; DSRTC: FORCE BATTERY CHARGE ON (USE WITH CAUTION!!!)
|
||||
;
|
||||
DS1501RTCENABLE .EQU FALSE ; DS1501RTC: ENABLE DS-1501 CLOCK DRIVER (DS1501RTC.ASM)
|
||||
@@ -128,6 +128,15 @@ SIMRTCENABLE .EQU FALSE ; ENABLE SIMH CLOCK DRIVER (SIMRTC.ASM)
|
||||
DS7RTCENABLE .EQU FALSE ; DS7RTC: ENABLE DS-1307 I2C CLOCK DRIVER (DS7RTC.ASM)
|
||||
DS7RTCMODE .EQU DS7RTCMODE_PCF ; DS7RTC: OPERATING MODE: DS7RTC_[PCF]
|
||||
;
|
||||
SSERENABLE .EQU FALSE ; SSER: ENABLE SIMPLE SERIAL DRIVER (SSER.ASM)
|
||||
SSERCFG .EQU SER_9600_8N1 ; SSER: SERIAL LINE CONFIG
|
||||
SSERSTATUS .EQU $FF ; SSER: STATUS PORT
|
||||
SSERDATA .EQU $FF ; SSER: DATA PORT
|
||||
SSERIRDY .EQU %00000001 ; SSER: INPUT READY BIT MASK
|
||||
SSERIINV .EQU FALSE ; SSER: INPUT READY BIT INVERTED
|
||||
SSERORDY .EQU %00000010 ; SSER: OUTPUT READY BIT MASK
|
||||
SSEROINV .EQU FALSE ; SSER: OUTPUT READY BIT INVERTED
|
||||
;
|
||||
DUARTENABLE .EQU FALSE ; DUART: ENABLE 2681/2692 SERIAL DRIVER (DUART.ASM)
|
||||
DUARTCNT .EQU 2 ; DUART: NUMBER OF CHIPS TO DETECT (1-2)
|
||||
DUART0BASE .EQU $A0 ; DUART 0: BASE ADDRESS OF CHIP
|
||||
@@ -141,7 +150,7 @@ UARTENABLE .EQU TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
|
||||
UARTOSC .EQU 1843200 ; UART: OSC FREQUENCY IN MHZ
|
||||
UARTINTS .EQU FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
|
||||
UARTCFG .EQU DEFSERCFG | SER_RTS ; UART: LINE CONFIG FOR UART PORTS
|
||||
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO ONBOARD UART
|
||||
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO/NABU ONBOARD UART
|
||||
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
|
||||
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
|
||||
UARTCAS .EQU FALSE ; UART: AUTO-DETECT ECB CASSETTE UART
|
||||
@@ -188,7 +197,7 @@ VDUENABLE .EQU FALSE ; VDU: ENABLE VDU VIDEO/KBD DRIVER (VDU.ASM)
|
||||
CVDUENABLE .EQU FALSE ; CVDU: ENABLE CVDU VIDEO/KBD DRIVER (CVDU.ASM)
|
||||
GDCENABLE .EQU FALSE ; GDC: ENABLE 7220 GDC VIDEO/KBD DRIVER (GDC.ASM)
|
||||
TMSENABLE .EQU FALSE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
|
||||
TMSMODE .EQU TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO]
|
||||
TMSMODE .EQU TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO|DUO|NABU40|NABU80]
|
||||
TMSTIMENABLE .EQU FALSE ; TMS: ENABLE TIMER INTERRUPTS (REQUIRES IM1)
|
||||
VGAENABLE .EQU FALSE ; VGA: ENABLE VGA VIDEO/KBD DRIVER (VGA.ASM)
|
||||
VRCENABLE .EQU FALSE ; VRC: ENABLE VGARC VIDEO/KBD DRIVER (VRC.ASM)
|
||||
@@ -323,7 +332,7 @@ SNMODE .EQU SNMODE_RC ; SN: DRIVER MODE: SNMODE_[NONE|RC|VGM]
|
||||
;
|
||||
AY38910ENABLE .EQU FALSE ; AY: ENABLE AY-3-8910 / YM2149 SOUND DRIVER
|
||||
AY_CLK .EQU 1789772 ; AY: PSG CLOCK FREQ, ASSUME MSX STD
|
||||
AYMODE .EQU AYMODE_RCZ180 ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO]
|
||||
AYMODE .EQU AYMODE_RCZ180 ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC|MBC|DUO|NABU]
|
||||
;
|
||||
SPKENABLE .EQU FALSE ; SPK: ENABLE RTC LATCH IOBIT SOUND DRIVER (SPK.ASM)
|
||||
;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user