Compare commits

...

42 Commits

Author SHA1 Message Date
Wayne Warthen
df42cf544e Support Mini-ITX Z180 Platform by Alan Cox
Support for Mini-ITX contributed by Alan Cox.
2023-11-24 18:03:19 -08:00
Wayne Warthen
55a41ec0a3 TMS Driver Enhancement by Jose Collado
- The 40 column mode of the TMS driver now conforms to the memory map from the TMS9918 documentation and is also now consistent with the existing TMS9918 video programs from the RC2014 forum.
2023-11-24 17:15:29 -08:00
Wayne Warthen
4417f871e5 Update AddRom.cmd
- Minor improvements
2023-11-21 14:55:14 -08:00
Wayne Warthen
1c10f734bd Create AddRom.cmd
Experimental command line script (Windows only) to add a ROM image to user area 0 of hd1k_combo.img.  Intended to make it easier to get a ROM image to a system for subsequent FLASHing.
2023-11-21 14:36:56 -08:00
Wayne Warthen
214182b514 Fix RTC Initialization
When using the Z2 memory manager, if the HBIOS exceeds 16K, RTCDEFVAL will not be accessible prior to programming the Z2 memory bank registers.  In this corner case the RTC latch could be mis-programmed.  This commit introduces a workaround.
2023-11-21 11:59:31 -08:00
Wayne Warthen
08942fb944 Support Duodyne SelfHost UART 2023-11-20 17:01:53 -08:00
Wayne Warthen
5dc724785b Completed CH37x Driver
The ch.asm driver now supports SD Card operations (only possible for CH376).
2023-11-19 14:48:41 -08:00
Wayne Warthen
ce17be9ba6 CP/M 3 RAM Check
- Check to ensure that we have enough RAM banks for banked CP/M 3 startup.  If not, message and return to boot loader.
2023-11-18 16:58:23 -08:00
Wayne Warthen
badca621ba Merge pull request #372 from dylanhall/dev
Allow override of secondary console front panel switch selection
2023-11-18 16:54:50 -08:00
Dylan Hall
291cdd2c03 Use SECCON to override default secondary console selection 2023-11-17 17:47:01 +13:00
Wayne Warthen
888d9879c9 Preliminary Support for CH37x SD Cards
- Currently operates as a read only disk device.
2023-11-16 19:39:09 -08:00
Dylan Hall
39446d5e4f Add SECCON to config files 2023-11-17 16:36:29 +13:00
Wayne Warthen
af8385fba8 Fix IM1 Handling for Z180 - Credit to Dylan Hall
- Z180 code failed to initialize interrupt vector registers for IM1 startup
- Updated bad interrupt messaging to avoid interrupt stack overflow
2023-11-15 12:48:55 -08:00
Wayne Warthen
10ff97b6c6 ACIA Interrupt Fix & ROMless APPBOOT Fix
- ACIA driver was not properly returning ZF to indicate if it handled an interrupt.
- APPBOOT was failing on ROMless systems because it was copying the HBIOS code overtop of itself.
2023-11-09 14:37:46 -08:00
Wayne Warthen
7e9191f3ef Update ps2info.asm
- Updated PS2INFO to handle extraneous 0x00 byte after reset command.
2023-11-07 18:30:17 -08:00
Wayne Warthen
a67b1ecd0a Fix RTC Init on ROMless Restart
- On ROMless restart, the RTC was not being included in the boot messages.
2023-10-31 14:54:07 -07:00
Wayne Warthen
4012ee7775 Update User Guide
Based on input from Issue #364, I have attempted to clarify a few areas on the User Guide:
- Recommendation to only use ROM OSes only for limited purposes
- Added a more detailed description of the automatic drive assignment algorithm
- Added more detail on batch file auto-submission
2023-10-31 13:03:09 -07:00
Wayne Warthen
150ca6b50c Fix .gitignore 2023-10-30 15:03:59 -07:00
Wayne Warthen
6af84e9ad8 Update Makefile
- Fix Makefile
2023-10-30 14:29:02 -07:00
Wayne Warthen
6bcad122cd Add Z1RCC Support
- Added build support for Bill Chen's Z1RCC.
- Thanks and credit to Bill for supplying the bulk of the build changes.
2023-10-30 14:14:11 -07:00
Wayne Warthen
003481410f Update UNARC to Universal UNARC from Lars Nelson
- Credit and thanks to Lars Nelson for providing an enhanced version of UNARC.
2023-10-30 12:07:26 -07:00
Wayne Warthen
9a1c3f7929 Minor Fix in SPK Driver and Tick Counter Space Reservation
- Fix ensures that the speaker control bit is set the same as it was initially after playing a tone.
- Reserve 2 bytes in the proxy for a platform dependent tick counter value.  Currently for HEATH platform.
2023-10-30 11:41:31 -07:00
Wayne Warthen
ef536750ea Makefile Improvements
These changes improve the chances of a make operation actually failing when a nested error occurs.
2023-10-24 13:25:32 -07:00
Wayne Warthen
347a15a3b6 Build Script Updates
- Minor update to GitHub build scripts
2023-10-23 18:30:40 -07:00
Wayne Warthen
1e5b38c251 PS2INFO Update & OpenSpin Conversion
- Added support for Duodyne to PS2INFO application.
- Switched all build paths to consistently use OpenSpin since it appears to be compatible with all build environments supported by RomWBW.
2023-10-23 18:07:42 -07:00
Wayne Warthen
29f93fb153 Enable CH and LPT Drivers for Duodyne 2023-10-19 17:23:08 -07:00
Wayne Warthen
b0975745df Bump Version 2023-10-19 15:47:45 -07:00
Wayne Warthen
163460856a Add Real Time Clock Section to User Guide, Issue #368 2023-10-19 15:03:49 -07:00
Wayne Warthen
3ce9246904 Update FLASH to v1.3.7
Thanks and credit to Will Sowerbutts for contributing and maintaining this critical utility!
2023-10-19 14:09:45 -07:00
Wayne Warthen
1a021e02b9 Enable PIO Support for Duodyne 2023-10-16 15:51:14 -07:00
Wayne Warthen
f2d304ef0d Update cfg_duo.asm 2023-10-15 18:03:01 -07:00
Wayne Warthen
cbfbca8d92 Support New Duodyne Boards
- Added support for Duodyne Multi-IO board
- Added support for Duodyne Zilog-IO board
- Added SUPCTS equate in hbios.asm to allow selectively adding code to suppress use of CTS during HBIOS boot
- Added reference in User Guide to Bruce Hall's Assembly Language Programming document
2023-10-15 17:53:35 -07:00
Wayne Warthen
b175808a92 Fix for CP/M 3 Floppy Boot
- CP/M 3 ldrbios had not been properly updated for device type id change.
- ASSIGN command was not handling DPB's correctly due to device type id change.
2023-10-13 10:29:43 -07:00
Wayne Warthen
3e86e79133 Fix Makefiles 2023-10-12 17:45:00 -07:00
Wayne Warthen
3247e67ed4 ZRC and ZZRCC Image Creation Updates
- Modified ZRC and ZZRCC image creation scripts to allow up to 0x1B8 of boot code.
2023-10-12 17:25:40 -07:00
Wayne Warthen
bbc84f0c2d Fix FAT Application API Call
FAT application had not been updated to reflect a change in the HBIOS Disk Device API call return data.  This is corrected in this check-in.  Related discussion in #368.
2023-10-12 12:49:05 -07:00
Wayne Warthen
872d51e9b6 Detect CTS Stall
- Detect CTS at startup to ensure it is asserted.  If not, disable hardware flow control to avoid stalling the console at boot.  Only for UART driver because this is the only place it is currently relevant.
2023-10-10 14:09:21 -07:00
Wayne Warthen
b41f189a4c Miscellaneous
- Add minimal Fuzix instructions to User Guide
- Enable CTC auto-detect by default for RCBus.  It causes no problems to auto-detect it and it will stop a CTC from generating unexpected interrupts after a soft restart.
- Upgrade `SUPERSUB` to v1.3 (previously v1.1)
2023-10-09 16:50:18 -07:00
Wayne Warthen
25fb2bd59e Rename ZZRC -> ZZRCC, Update to CLRDIR
- The naming of ZZRCC was incorrectly ZZRC.  Corrected.
- Max Scane has provided a small bug fix for CLRDIR.
- Minor build updates for new HTalk utility.
2023-10-08 17:57:58 -07:00
Wayne Warthen
76867b8351 Merge pull request #367 from TomPlano/dev
Uploading HTalk program to supplement talk.com program
2023-10-08 17:12:49 -07:00
Tom Plano
43745f8c90 Uploading HTalk program to supliment talk.com program. Similar functionality, but uses HBIOS calls and Char IDs, as opposed to CP/M calls and IDs 2023-10-08 18:22:09 -05:00
Wayne Warthen
ed4daf06a4 CP/M 3 Memory Configuration Regression
Put CP/M 3 disk buffers back in alternate banks.
2023-10-08 07:32:01 -07:00
204 changed files with 19370 additions and 1247 deletions

View File

@@ -26,7 +26,7 @@ jobs:
run: |
export TZ='America/Los_Angeles'
sudo apt-get install srecord
make dist
make distlog
rm -rf .git*
- name: List Output
@@ -58,7 +58,7 @@ jobs:
run: |
export TZ='America/Los_Angeles'
brew install srecord
make dist
make distlog
rm -rf .git*
- name: List Output

View File

@@ -19,7 +19,7 @@ jobs:
export TZ='America/Los_Angeles'
sudo apt-get install libncurses-dev
sudo apt-get install srecord
make dist
make distlog
rm -rf .git*
- name: Create Package Archive

4
.gitignore vendored
View File

@@ -95,8 +95,8 @@ Tools/unix/zx/zx
!Source/ZPM3/*.[Cc][Oo][Mm]
!Source/ZSDOS/*.[Cc][Oo][Mm]
!Source/ZRC/*.bin
!Source/ZZRC/*.bin
!Source/ZZRC/*.hex
!Source/Z1RCC/*.bin
!Source/ZZRCC/*.bin
!Tools/cpm/**
!Tools/unix/zx/*
!Tools/zx/*

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -1,5 +1,8 @@
.PHONY: tools source clean clobber diff dist
.ONESHELL:
.SHELLFLAGS = -cex
all: tools source
tools:
@@ -20,6 +23,9 @@ diff:
$(MAKE) --directory Source diff
dist:
$(MAKE) ROM_PLATFORM=dist 2>&1 | tee make.log
$(MAKE) --directory Source clean
$(MAKE) ROM_PLATFORM=dist
$(MAKE) --directory Tools clean
$(MAKE) --directory Source clean
distlog:
$(MAKE) dist 2>&1 | tee make.log

View File

@@ -3,7 +3,7 @@
**RomWBW ReadMe** \
Version 3.4 \
Wayne Warthen ([wwarthen@gmail.com](mailto:wwarthen@gmail.com)) \
07 Oct 2023
31 Oct 2023
# Overview

View File

@@ -1,6 +1,6 @@
RomWBW ReadMe
Wayne Warthen (wwarthen@gmail.com)
07 Oct 2023
31 Oct 2023

View File

@@ -32,6 +32,7 @@ pushd Dev && call Build || exit /b & popd
pushd VGM && call Build || exit /b & popd
pushd cpuspd && call Build || exit /b & popd
pushd Survey && call Build || exit /b & popd
pushd HTalk && call Build || exit /b & popd
copy *.com %APPBIN%\ || exit /b

View File

@@ -18,3 +18,4 @@ pushd Dev && call Clean || exit /b 1 & popd
pushd VGM && call Clean || exit /b 1 & popd
pushd cpuspd && call Clean || exit /b 1 & popd
pushd Survey && call Clean || exit /b 1 & popd
pushd HTalk && call Clean || exit /b 1 & popd

View File

@@ -1,7 +1,7 @@
RomWBW HBIOS CP/M FAT Utility ("FAT.COM")
Author: Wayne Warthen
Updated: 12-Apr-2021
Updated: 12-Oct-2023
Application to manipulate and exchange files with a FAT (DOS)
filesystem. Runs on any HBIOS hosted CP/M implementation.
@@ -101,4 +101,5 @@ HISTORY:
11-Oct-2019: v0.9.7 (beta) fix FORMAT to use existing partition table entries
add attributes to directory listing
12-Apr-2021: v0.9.8 (beta) support CP/NET drives
12-Oct-2023: v0.9.9 (beta) handle updated HBIOS Disk Device call

Binary file not shown.

View File

@@ -0,0 +1,14 @@
@echo off
setlocal
set TOOLS=../../../Tools
set PATH=%TOOLS%\tasm32;%PATH%
set TASMTABS=%TOOLS%\tasm32
echo Building HTalk...
tasm -t80 -g3 -fFF htalk.asm htalk.com %htalk.lst || exit /b
copy /Y htalk.com ..\..\..\Binary\Apps\ || exit /b
rem copy /Y *.ovr ..\..\..\Binary\Apps\ || exit /b
rem copy /Y *.hlp ..\..\..\Binary\Apps\ || exit /b
rem copy /Y *.doc ..\..\..\Binary\Apps\ || exit /b

View File

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

View File

@@ -0,0 +1,10 @@
OBJECTS = htalk.com
#DOCS = htalk.txt
DEST = ../../../Binary/Apps
DOCDEST = ../../../Binary/Apps
TOOLS = ../../../Tools
include $(TOOLS)/Makefile.inc
%.com: USETASM=1

725
Source/Apps/HTalk/htalk.asm Normal file
View File

@@ -0,0 +1,725 @@
;===============================================================================
;HTALK - BARE MINIMUM TERMINAL INTERFACE
;
; CONSOLE TALKS TO ARBITRARY CHARACTER DEVICE.
;===============================================================================
;
; AUTHOR: TOM PLANO (TOMPLANO@PROTON.ME)
;
; USAGE:
; HTALK $<CHAR_DEVICE_NUM>
;
;_______________________________________________________________________________
;
; CHANGE LOG:
; I'VE NOTATED SECTIONS OF CODE THAT ARNT REQUIRED IF THIS APP IS
; INCORPORATED INTO DBGMOD WITH A <OPT> TAG
;
;_______________________________________________________________________________
;
; TODO:
; SEE ENUM_DEV1 TODO
;
;
;_______________________________________________________________________________
;
;===============================================================================
; DEFINITIONS
;===============================================================================
;
STKSIZ .EQU $FF
;
; HBIOS SYSTEM CALLS AND ID STRING ADDRESS
;
ROMWBW_ID .EQU $FFFE ; ROMWBW ID STRING ADDRESS
HBIOS_SYS .EQU $FFF0 ; HBIOS SYSCALL ADDRESS
H_SYSGET .EQU $F8 ; GET SYSTEM INFO
H_CIOCNT .EQU $00 ; GET CHAR DEV COUNT SUBFUNCTION
BF_CIOIN .EQU $00 ; HBIOS CHAR INPUT
BF_CIOOUT .EQU $01 ; HBIOS CHAR OUTPUT
BF_CIOIST .EQU $02 ; HBIOS CHAR INPUT STATUS
BF_CIOOST .EQU $03 ; HBIOS CHAR OUTPUT STATUS
BF_CIOINIT .EQU $04 ; HBIOS CHAR I/O INIT
BF_CIOQUERY .EQU $05 ; HBIOS CHAR I/O QUERY
BF_CIODEVICE .EQU $06 ; HBIOS CHAR I/O DEVICE
;
; SUPPORTED HBIOS CIO DEVICE TYPES
;
CIODEV_UART .EQU $00 ; 16C550 FAMILY SERIAL INTERFACE UART.ASM
CIODEV_ASCI .EQU $10 ; Z180 BUILT-IN SERIAL PORTS ASCI.ASM
CIODEV_TERM .EQU $20 ; TERMINAL ANSI.ASM
CIODEV_PRPCON .EQU $30 ; PROPIO SERIAL CONSOLE INTERFACE PRP.ASM
CIODEV_PPPCON .EQU $40 ; PARPORTPROP SERIAL CONSOLE INTERFACE PPP.ASM
CIODEV_SIO .EQU $50 ; ZILOG SERIAL PORT INTERFACE SIO.ASM
CIODEV_ACIA .EQU $60 ; MC68B50 ASYNCHRONOUS INTERFACE ACIA.ASM
CIODEV_PIO .EQU $70 ; ZILOG PARALLEL INTERFACE CONTROLLER PIO.ASM
CIODEV_UF .EQU $80 ; FT232H-BASED ECB USB FIFO UF.ASM
CIODEV_DUART .EQU $90 ; SCC2681 FAMILY DUAL UART DUART.ASM
CIODEV_Z2U .EQU $A0 ; ZILOG Z280 BUILT-IN SERIAL PORTS Z2U.ASM
CIODEV_LPT .EQU $B0 ; PARALLEL I/O CONTROLLER LPT.ASM
; HBIOS CURRENT CONSOLE NUMBER
CIO_CONSOLE .EQU $80
; SPECIAL CHARS
CTRLC .EQU $03
CHR_BEL .EQU $07
CHR_CR .EQU $0D
CHR_LF .EQU $0A
CHR_BS .EQU $08
CHR_ESC .EQU $1B
CHR_DEL .EQU $7F
;
;===============================================================================
; BEGIN MAIN PROGRAM
;===============================================================================
;
.ORG $0100
;
; SETUP STACK (SAVE OLD VALUE)
; <OPT> HANDLED BY DBGMON
LD (STKSAV),SP
LD SP,STACK
;
; INITIALIZATION + STARTUP MESSAGE + HBIOS DETECT
; <OPT> HANDLED BY DBGMON
CALL INIT_PROG
JP NZ,EXIT
;
; LIST HBIOS DEV OPTIONS FOR REFERENCE
; ALSO GETS MAX CONN
;
; <OPT> THIS IS OPTIONAL BECAUSE IF A CHAR DEVICE DOESNT EXIST, WE NEVER READ OR
; WRITE TO IT, WE SIMPLY CALL CIOIST AND CIOOST OVER AND OVER ON IT, WITHOUT
; EVER PUSHING DATA TO IT
CALL ENUM_DEV
JP NZ,EXIT
;
; PARSE COMMAND LINE
;
CALL PARSE
JP NZ,EXIT
;
; RUN CONVERSTION WITH CHAR DEVICE
;
CALL TALK
;
; DONE
JP EXIT
;
; CLEAN UP AND RETURN TO CALLING PROCESS
;
EXIT:
CALL NEWLINE ; ...
LD HL,STR_EXITMSG ; LOAD EXIT STRING
CALL PRTSTR ; PRINT IT
CALL NEWLINE ; ...
LD SP,(STKSAV) ; RESET STACK
RET ; RETURN TO CALLER
;
;===============================================================================
; END MAIN PROGRAM
;===============================================================================
;
;
;===============================================================================
; BEGIN MAIN PROGRAM SUBROUTINES
;===============================================================================
;
INIT_PROG:
LD HL, STR_BANNER ; LOAD WELCOME BANNER
CALL PRTSTR ; PRINT IT
CALL NEWLINE ; ...
LD HL,(ROMWBW_ID) ; GET FIRST BYTE OF ROMWBW MARKER
LD A,(HL) ; ... THROUGH HL
CP 'W' ; MATCH?
JP NZ,NOTHBIOS ; ABORT WITH INVALID CONFIG BLOCK
INC HL ; NEXT BYTE (MARKER BYTE 2)
LD A,(HL) ; LOAD IT
CP ~'W' ; MATCH?
JP NZ,NOTHBIOS ; ABORT WITH INVALID CONFIG BLOCK
LD HL,STR_HBIOS ; POINT TO HBIOS STR
CALL PRTSTR ; PRINT IT
CALL NEWLINE ; ...
RET
;
; HBOIS NOT DETECTED, BAIL OUT W/ ERROR
;
NOTHBIOS:
LD HL,STR_BIOERR ; LOAD HBIOS NOT FOUND STR
CALL PRTSTR ; PRINT IT
CALL NEWLINE ; ...
AND $FF ; SET FLAGS
RET
ENUM_DEV:
;
; CHAR COUNT HEADER
;
LD HL,STR_DEVS_FOUND
CALL PRTSTR
;
;GET COUNT OF CHAR UNITS
;
LD B,H_SYSGET ; LOAD SYSGET HBIOS FUNCTION
LD C,H_CIOCNT ; LOAD SYSGET CHAR DEV COUNT SUBFUNCTION
CALL HBIOS_SYS ; JUMP TO HBIOS
OR A ; SET FLAGS
JP NZ, EXIT ; JUMP TO EXIT ON FAILED
LD A,E ; NUM CHAR DEVICES NOW IN A
DEC A ; DEC NUM DEVICES TO BE 0 INDEXED
LD (CIODEV_CNT), A ; STORE BEFORE PRINT
LD (CIODEV_MAX), A ; STORE BEFORE PRINT
INC A ; RESTORE NUM DEVICES VALUE
CALL PRTHEX ; PRINT NUMBER OF UNITS FOUND
CALL NEWLINE ; ...
ENUM_DEV1:
LD IX, TGT_DEV
; TODO: H AND L DONT ALWAYS GET SET BY THE DRIVERS. FIND SOME WAY TO MASK
; THEM OUT IF THEY ARE THE SAME BEFORE AND AFTER THE CALL?
LD B, BF_CIODEVICE ; LOAD HBIOS FUNCTION TO QUERRY DEVICE INFO
LD HL, CIODEV_CNT ; REQUEST A CHAR DEVICE
LD C, (HL) ; ...
LD (IX), C ; REMEMBER WHAT DEVICE WE ASKED FOR BEFORE BE
CALL HBIOS_SYS ; EXECUTE HBIOS SUBROUTINE
OR A ; SET FLAGS
RET NZ ; RETURN FAILED
;
; STORE RESULTS OF HBOIS DEVICE QUERRY
;
LD A,C ; MOVE C TO A
LD (IX+1), A ; STORE A DEVICE ATTRIBUTES, SKIP FIRST ENTRY
LD A,D
LD (IX+2), A
LD A,E
LD (IX+3), A
LD A,H
LD (IX+4), A
LD A,L
LD (IX+5), A
;
; PRINT FORMATED DATA LOOP
;
LD B, $06 ; PRINT THE 5 ELEMENTS OF DEV_STR_TBL
LD HL,DEV_STR_TBL ; TABLE BASE PTR
PLOOP_BASE:
CALL PRTSTR ; PTRSTR INCREMENTS HL FOR US
LD A, (IX)
CALL PRTHEX
LD A, '|'
CALL COUT
INC IX
DJNZ PLOOP_BASE
CALL NEWLINE
LD A, (CIODEV_CNT)
DEC A
LD (CIODEV_CNT), A
JP P, ENUM_DEV1 ; JUMP WHILE CIODEV_CNT >=0
AND $00
RET
;
; RUN CONVERSTION WITH CHAR DEVICE
;
TALK:
;
; INIT PING PONG DEVICE POINTERS
;
LD IX, USER_CON ; LOAD VALUE AT ADDR USER_CON
LD A, (IX) ; LOAD VALUE AT ADDR USER_CON
LD (RF_DEV), A ; STORE TO ADDR RF_DEV
LD A, (IX+1) ; LOAD VALUE AT ADDR TARGET_CON
LD (WT_DEV), A ; STORE TO ADDR WT_DEV
;
; READ FROM RF_DEV -> WRITE TO WT_DEV
;
TALK_LOOP:
;
; CHECK FOR DATA ON RF_DEV
;
LD B,BF_CIOIST ; SET HBIOS FUNCTION TO RUN
LD HL, RF_DEV
LD C,(HL)
CALL HBIOS_SYS ; CHECK FOR CHAR PENDING ON INPUT BUFFER USING HBIOS
OR A ; SET FLAGS
JP Z,TALK_NEXT ; JUMP NO CHARACTERS READY
JP M,TALK_NEXT ; JUMP ERROR ON READ
;
; EXEC READ FROM RF_DEV
;
LD B,BF_CIOIN ; SET FUNCTION TO RUN
LD HL, RF_DEV
LD C,(HL) ; RETRIEVE CON_DEV_NUM TO READ/WRITE FROM ACTIVE CONSOLE
CALL HBIOS_SYS ; CHECK FOR CHAR PENDING USING HBIOS
LD A,E ; MOVE RESULT TO A
CP CTRLC ; CHECK FOR EXIT REQUEST (CTRL+C)
RET Z ; IF SO, BAIL OUT
PUSH AF ; SAVE THE CHAR WE READ
;
; CHECK FOR SPACE ON WT_DEV
;
LD B,BF_CIOOST ; SET HBIOS FUNCTION TO RUN
LD HL, WT_DEV
LD C,(HL)
CALL HBIOS_SYS ; CHECK FOR SPACE IN OUTPUT BUFFER USING HBIOS
OR A ; 0 OR 1 IS A VALID RETURN
JP Z,TALK_NEXT ; JUMP NO SPACE
JP M,TALK_NEXT ; JUMP ERROR ON WRITE
;
; EXEC WRITE TO WT_DEV
;
LD B,BF_CIOOUT ; SET HBIOS FUNCTION TO RUN
LD HL, WT_DEV
LD C,(HL) ; RETRIEVE TGT_DEV_NUM TO READ/WRITE FROM TARGET CHAR DEVICE
;
POP AF ; RECOVER THE CHARACTER
LD E,A ; MOVE CHARACTER TO E
CALL HBIOS_SYS ; WRITE CHAR USING HBIOS
TALK_NEXT:
;
; SWAP RF_DEV AND WT_DEV
;
LD IX, RF_DEV ; LOAD VALUE AT ADDR USER_CON
LD A, (IX) ; LOAD VALUE AT ADDR RF_DEV
LD B, (IX+1) ; LOAD VALUE AT ADDR WT_DEV
LD (IX+1), A ; STORE TO OLD RF_DEV TO ADDR WT_DEV
LD A, B ; MOVE OLD WT_DEV TO A
LD (IX), A ; STORE TO OLD WT_DEF TO ADDR RF_DEV
JP TALK_LOOP ; LOOP
;
;===============================================================================
; END MAIN PROGRAM SUBROUTINES
;===============================================================================
;
;
;===============================================================================
; BEGIN ROUTINES THAT ARE NOT COMPATIBLE WITH DBGMON
;===============================================================================
;
PARSE:
;
LD HL,$81 ; POINT TO START OF COMMAND TAIL (AFTER LENGTH BYTE)
CALL NONBLANK ; SKIP LEADING BLANKS,
CALL HEXBYTE
JP C,ERRHEXRD ; IF NOT, ERR
LD (TARGET_CON),A ; REQUESTED TARGET CONN
LD B,A ; MOVE TO B
LD HL,CIODEV_MAX ; GRAB MAX VALUE OF TARGETCON
LD A,(HL)
CP B ; CHECK IF B<=A
JP M, ERROOR ; IF B>A, and both are less then 80 then S SET, ERR
JP C, ERROOR ; IF B> 80 carry set instead (signed numbers problem)
; swap A and B
JP PE, ERROOR ; IF B>A, C SET, ERR
LD HL, MSGTALKING ; PRINT TARGET DEVICE
CALL PRTSTR
LD A, B ; RETRIEVE TARGET CON
CALL PRTHEX
CALL NEWLINE
AND $00
RET
;
;NOT COMPATIBLE WITH THE DBGMON FUNCTION OF THE SAME NAME
;
NONBLANK:
LD A,(HL) ; LOAD NEXT CHARACTER
OR A ; STRING ENDS WITH A NULL
RET Z ; IF NULL, RETURN POINTING TO NULL
CP ' ' ; CHECK FOR BLANK
RET NZ ; RETURN IF NOT BLANK
INC HL ; IF BLANK, INCREMENT CHARACTER POINTER
JR NONBLANK ; AND LOOP
;
;
;===============================================================================
; END ROUTINES THAT ARE NOT COMPATIBLE WITH DBGMON
;===============================================================================
;
;
;===============================================================================
; BEGIN ROUTINES THAT ARE LIFTED FROM DBGMON
;===============================================================================
;
;
; PRINT THE VALUE IN A IN HEX WITHOUT DESTROYING ANY REGISTERS
;
PRTHEX:
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 COUT ; PRINT IT
LD A,E ; GET THE LOW ORDER HEX CHAR
CALL COUT ; PRINT IT
POP DE ; RESTORE DE
RET ; DONE
;
; 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
;
;
; ADD THE VALUE IN A TO HL (HL := HL + A)
;
ADDHL:
ADD A,L ; A := A + L
LD L,A ; PUT RESULT BACK IN L
RET NC ; IF NO CARRY, WE ARE DONE
INC H ; IF CARRY, INCREMENT H
RET ; AND RETURN
;
;__________________________________________________________________________________________________
;
; UTILITY PROCS TO PRINT SINGLE CHARACTERS WITHOUT TRASHING ANY REGISTERS
;
;__________________________________________________________________________________________________
;
PC_SPACE:
PUSH AF
LD A,' '
JR PC_PRTCHR
PC_COLON:
PUSH AF
LD A,':'
JR PC_PRTCHR
PC_CR:
PUSH AF
LD A,CHR_CR
JR PC_PRTCHR
PC_LF:
PUSH AF
LD A,CHR_LF
JR PC_PRTCHR
PC_PRTCHR:
CALL COUT
POP AF
RET
NEWLINE2:
CALL NEWLINE
NEWLINE:
CALL PC_CR
CALL PC_LF
RET
PRTSTR:
LD A,(HL)
INC HL
CP '$'
RET Z
CALL COUT
JR PRTSTR
;
;__COUT_______________________________________________________________________
;
; OUTPUT CHARACTER FROM A
;_____________________________________________________________________________
;
COUT:
; SAVE ALL INCOMING REGISTERS
PUSH AF
PUSH BC
PUSH DE
PUSH HL
;
; OUTPUT CHARACTER TO CONSOLE VIA HBIOS
LD E,A ; OUTPUT CHAR TO E
LD C,CIO_CONSOLE ; CONSOLE UNIT TO C
LD B,BF_CIOOUT ; HBIOS FUNC: OUTPUT CHAR
CALL HBIOS_SYS ; HBIOS OUTPUTS CHARACTER
;
; RESTORE ALL REGISTERS
POP HL
POP DE
POP BC
POP AF
RET
;
;__CIN________________________________________________________________________
;
; INPUT CHARACTER TO A
;_____________________________________________________________________________
;
CIN:
; SAVE INCOMING REGISTERS (AF IS OUTPUT)
PUSH BC
PUSH DE
PUSH HL
;
; INPUT CHARACTER FROM CONSOLE VIA HBIOS
LD C,CIO_CONSOLE ; CONSOLE UNIT TO C
LD B,BF_CIOIN ; HBIOS FUNC: INPUT CHAR
CALL HBIOS_SYS ; HBIOS READS CHARACTER
LD A,E ; MOVE CHARACTER TO A FOR RETURN
;
; RESTORE REGISTERS (AF IS OUTPUT)
POP HL
POP DE
POP BC
RET
;
;__CST________________________________________________________________________
;
; RETURN INPUT STATUS IN A (0 = NO CHAR, !=0 CHAR WAITING)
;_____________________________________________________________________________
;
CST:
; SAVE INCOMING REGISTERS (AF IS OUTPUT)
PUSH BC
PUSH DE
PUSH HL
;
; GET CONSOLE INPUT STATUS VIA HBIOS
LD C,CIO_CONSOLE ; CONSOLE UNIT TO C
LD B,BF_CIOIST ; HBIOS FUNC: INPUT STATUS
CALL HBIOS_SYS ; HBIOS RETURNS STATUS IN A
;
; RESTORE REGISTERS (AF IS OUTPUT)
POP HL
POP DE
POP BC
RET
;
;
;__ISHEX______________________________________________________________________
;
; CHECK BYTE AT (HL) FOR HEX CHAR, RET Z IF SO, ELSE NZ
;_____________________________________________________________________________
;
ISHEX:
LD A,(HL) ; CHAR TO AS
CP '0' ; < '0'?
JR C,ISHEX1 ; YES, NOT 0-9, CHECK A-F
CP '9' + 1 ; > '9'
JR NC,ISHEX1 ; YES, NOT 0-9, CHECK A-F
XOR A ; MUST BE 0-9, SET ZF
RET ; AND DONE
ISHEX1:
CP 'A' ; < 'A'?
JR C,ISHEX2 ; YES, NOT A-F, FAIL
CP 'F' + 1 ; > 'F'
JR NC,ISHEX2 ; YES, NOT A-F, FAIL
XOR A ; MUST BE A-F, SET ZF
RET ; AND DONE
ISHEX2:
OR $FF ; CLEAR ZF
RET ; AND DONE
;
;__HEXBYTE____________________________________________________________________
;
; GET ONE BYTE OF HEX DATA FROM BUFFER IN HL, RETURN IN A
;_____________________________________________________________________________
;
HEXBYTE:
LD C,0 ; INIT WORKING VALUE
HEXBYTE1:
CALL ISHEX ; DO WE HAVE A HEX CHAR?
JR NZ,HEXBYTE3 ; IF NOT, WE ARE DONE
LD B,4 ; SHIFT WORKING VALUE (C := C * 16)
HEXBYTE2:
SLA C ; SHIFT ONE BIT
RET C ; RETURN W/ CF SET INDICATING OVERFLOW ERROR
DJNZ HEXBYTE2 ; LOOP FOR 4 BITS
CALL NIBL ; CONVERT HEX CHAR TO BINARY VALUE IN A & INC HL
OR C ; COMBINE WITH WORKING VALUE
LD C,A ; AND PUT BACK IN WORKING VALUE
JR HEXBYTE1 ; DO ANOTHER CHARACTER
HEXBYTE3:
LD A,C ; WORKING VALUE TO A
OR A ; CLEAR CARRY
RET
;
;__NIBL_______________________________________________________________________
;
; GET ONE BYTE OF HEX DATA FROM BUFFER IN HL, RETURN IN A
;_____________________________________________________________________________
;
NIBL:
LD A,(HL) ; GET K B. DATA
INC HL ; INC KB POINTER
CP 40H ; TEST FOR ALPHA
JR NC,ALPH
AND 0FH ; GET THE BITS
RET
ALPH:
AND 0FH ; GET THE BITS
ADD A,09H ; MAKE IT HEX A-F
RET
;
;===============================================================================
; END ROUTINES THAT ARE LIFTED FROM DBGMON
;===============================================================================
;
;
;===============================================================================
; ERROR RESPONCES
;===============================================================================
;
ERROOR: ; REQUESTED DEV OUT OF RANGE (SYNTAX)
CALL NEWLINE
LD A, 'R'
CALL COUT
LD HL,TARGET_CON
LD A,(HL)
CALL PRTHEX
LD A, ':'
CALL COUT
LD A, 'M'
CALL COUT
LD HL,CIODEV_MAX
LD A,(HL)
CALL PRTHEX
LD HL,MSGOOR
JR ERROR
ERRHEXRD: ; COMMAND HEX READ ERROR (SYNTAX)
LD HL,MSGHEXRD
JR ERROR
ERRUSE: ; COMMAND USAGE ERROR (SYNTAX)
LD HL,MSGUSE
JR ERROR
ERRPRM: ; COMMAND PARAMETER ERROR (SYNTAX)
LD HL,MSGPRM
JR ERROR
ERROR: ; PRINT ERROR STRING AND RETURN ERROR SIGNAL
CALL NEWLINE ; PRINT NEWLINE
CALL PRTSTR ; PRINT ERROR STRING
OR $FF ; SIGNAL ERROR
RET ; DONE
;===============================================================================
; STORAGE SECTION
;===============================================================================
;
; CHAR DEV COUNT
CIODEV_CNT .DB $0
CIODEV_MAX .DB $0
;TALK LOOP DATA, DEFAULT TO LOOPBACK
USER_CON .DB $80
TARGET_CON .DB $80
; PING PONG POINTERS
RF_DEV .DB 0
WT_DEV .DB 0
; TARGET CHARACTER DEVICE DATA
TGT_DEV:
.DB 0 ; HBIOS CHAR NUM
.DB 0 ; C: DEVICE ATTRIBUTES
.DB 0 ; D: DEVICE TYPE
.DB 0 ; E: DEVICE NUMBER
.DB 0 ; H: DEVICE MODE
.DB 0 ; L: DEVICE I/O BASE ADDRESS
; STRING LITERALS
MSGUSE .TEXT "USAGE: HTALK <CIO_DEV_ID>$"
MSGPRM .TEXT "PARAMETER ERROR$"
MSGOOR .TEXT "CIO VAL TOO LARGE$"
MSGHEXRD .TEXT "HEX READ ERR$"
MSGTALKING .TEXT "CONNECTING TO CHAR:$"
DEV_STR_TBL:
.TEXT "CHAR:$"
.TEXT "ATTR:$"
.TEXT "TYPE:$"
.TEXT "NUMB:$"
.TEXT "MODE:$"
.TEXT "ADDR:$"
STR_DEVS_FOUND .TEXT "NUM CHAR DEVICES FOUND - $"
STR_EXITMSG .TEXT "HTALK DONE$"
STR_BANNER .TEXT "HTALK V1.0 (CTRL-C TO EXIT)$"
STR_HBIOS .TEXT "HBIOS DETECTED$"
STR_BIOERR .TEXT "*** UNKNOWN BIOS - BAILING OUT ***$"
STKSAV .DW 0 ; STACK POINTER SAVED AT START
.FILL STKSIZ,0 ; STACK
STACK .EQU $ ; STACK TOP
;
.END

View File

@@ -1,6 +1,6 @@
OBJECTS = sysgen.com syscopy.com assign.com format.com talk.com \
mode.com rtc.com timer.com rtchb.com
SUBDIRS = XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd Survey
SUBDIRS = HTalk XM FDU FAT Tune Test ZMP ZMD Dev VGM cpuspd Survey
DEST = ../../Binary/Apps
TOOLS =../../Tools

View File

@@ -7,20 +7,24 @@
; keyboard, and mouse.
;
; WBW 2022-03-28: Add menu driven port selection
; Add support for RHYOPHYRE
; Add support for Rhyophyre
; 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
;
;=======================================================================
;
; PS/2 Keyboard/Mouse controller port addresses (adjust as needed)
;
; MBC:
; Nhyodyne:
iocmd_mbc .equ $E3 ; PS/2 controller command port address
iodat_mbc .equ $E2 ; PS/2 controller data port address
; RPH:
; Rhyophyre:
iocmd_rph .equ $8D ; PS/2 controller command port address
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
;
cpumhz .equ 8 ; for time delay calculations (not critical)
;
@@ -77,10 +81,12 @@ setup1:
jr z,setup1
call upcase
call prtchr
cp '1' ; MBC
cp '1' ; Nhyodyne
jr z,setup_mbc
cp '2' ; RHYOPHYRE
cp '2' ; Rhyophyre
jr z,setup_rph
cp '3' ; Duodyne
jr z,setup_duo
cp 'X'
jr z,exit
jr setup
@@ -101,6 +107,14 @@ setup_rph:
ld de,str_rph
jr setup2
;
setup_duo:
ld a,iocmd_duo
ld (iocmd),a
ld a,iodat_duo
ld (iodat),a
ld de,str_duo
jr setup2
;
setup2:
call prtstr
call crlf2
@@ -181,6 +195,12 @@ test_kbd:
;
call ctlr_test
jr nz,test_kbd_fail
;
ld a,$20 ; kbd enabled, mse disabled, no ints
call ctlr_setup
jr nz,test_kbd_fail
;
call ctlr_flush
;
call test_kbd_basic
jr nz,test_kbd_fail
@@ -228,9 +248,13 @@ test_mse:
ld a,$10 ; kbd disabled, mse enabled, no ints
call ctlr_setup
jr nz,test_mse_fail
;
call ctlr_flush
;
call mse_reset
jr nz,test_mse_fail
;
call ctlr_flush
;
call mse_ident
jr nz,test_mse_fail
@@ -262,15 +286,21 @@ test_kbdmse:
ld a,$00 ; kbd enabled, mse enabled, no ints
call ctlr_setup
jr nz,test_kbdmse_fail
;
call ctlr_flush
;
call kbd_reset
jr nz,test_kbdmse_fail
;
call ctlr_flush
;
ld a,2
call kbd_setsc
;
call mse_reset
jr nz,test_kbdmse_fail
;
call ctlr_flush
;
call mse_stream
jr nz,test_kbdmse_fail
@@ -290,15 +320,13 @@ test_kbdmse_fail:
; inventory the supported scan code sets.
;
test_kbd_basic:
ld a,$20 ; Xlat off for this checking
call ctlr_setup
ret nz
;
call kbd_reset
ret nz
;
call ctlr_flush
;
call kbd_ident
;ret nz
ret nz
;
ld b,3 ; Loop control, 3 scan code sets
ld c,1 ; Current scan code number
@@ -436,6 +464,19 @@ ctlr_setup:
xor a
ret
;
; Flush incoming data buffer
;
ctlr_flush:
call crlf2
ld de,str_ctlr_flush
call prtstr
ctlr_flush1:
call delay ; small delay
call check_read ; data pending?
ret nz ; return if nothing there
call get_data_dbg ; get and discard byte
jr ctlr_flush1 ; loop
;
; Perform a keyboard reset
;
kbd_reset:
@@ -612,13 +653,17 @@ mse_reset:
call crlf2
ld de,str_mse_reset
call prtstr
ld a,$f2 ; Identify mouse command
ld a,$ff ; Identify mouse command
call put_data_mse_dbg
jp c,err_ctlr_to ; handle controller error
call get_data_dbg
jp c,err_ctlr_to ; handle controller error
cp $fa ; Is it an ack as expected?
jp nz,err_mse_reset
call get_data_dbg
jp c,err_ctlr_to ; handle controller error
cp $aa ; Success?
jp nz,err_mse_reset
call crlf
ld de,str_mse_reset_ok
call prtstr
@@ -634,18 +679,61 @@ mse_ident:
ld a,$f2 ; Identify mouse command
call put_data_mse_dbg
jp c,err_ctlr_to ; handle controller error
mse_ident0:
call get_data_dbg
jp c,err_ctlr_to ; handle controller error
;cp $00 ; extraneous?
;jr z,mse_ident0 ; ignore it, get another
cp $fa ; Is it an ack as expected?
jp nz,err_mse_ident
call get_data_dbg
jp c,err_ctlr_to ; handle controller error
; Now we need to receive 0-2 bytes. There is no way to know
; how many are coming, so we receive bytes until there is a
; timeout error. Timeout is shortened here so that we don't
; have to wait seconds for the routine to complete normally.
; A short timeout is more than sufficient here.
ld ix,workbuf
ld a,(timeout) ; save current timeout
push af
ld a,stimout ; set a short timeout
ld (timeout),a
ld b,8 ; buf max
ld c,0 ; buf len
mse_ident1:
push bc
call get_data_dbg
pop bc
jr c,mse_ident2
ld (ix),a
inc ix
inc c
djnz mse_ident1
mse_ident2:
pop af ; restore original timeout
ld (timeout),a
call crlf
ld de,str_mse_ident_disp
call prtstr
pop af
call prtdecb
ld a,'['
call prtchr
ld ix,workbuf
ld a,c ; bytes to print
or a ; check for zero
jr z,mse_ident4 ; handle zero
ld b,a ; setup loop counter
jr mse_ident3a
mse_ident3:
ld a,','
call prtchr
mse_ident3a:
ld a,(ix)
call prthex
inc ix
djnz mse_ident3
mse_ident4:
ld a,']'
call prtchr
xor a
ret
;
@@ -658,8 +746,13 @@ mse_stream:
ld a,$f4 ; Stream packets cmd
call put_data_mse_dbg
jp c,err_ctlr_to ; handle controller error
mse_stream0:
call get_data_dbg
jp c,err_ctlr_to ; handle controller error
;cp $00 ; extraneous?
;jr z,mse_stream0 ; ignore it, get another
cp $FA ; Is it an ack as expected?
jp nz,err_mse_stream
xor a
@@ -1344,14 +1437,16 @@ delay1:
; Constants
;=======================================================================
;
str_banner .db "PS/2 Keyboard/Mouse Information v0.6a, 2-Apr-2022",0
str_banner .db "PS/2 Keyboard/Mouse Information v0.8, 6-Nov-2023",0
str_hwmenu .db "PS/2 Controller Port Options:\r\n\r\n"
.db " 1 - MBC\r\n"
.db " 2 - RHYOPHYRE\r\n"
.db " 1 - Nhyodyne\r\n"
.db " 2 - Rhyophyre\r\n"
.db " 3 - Duodyne\r\n"
.db " X - Exit Application\r\n"
.db "\r\nSelection? ",0
str_mbc .db "MBC",0
str_rph .db "RHYOPHYRE",0
str_mbc .db "Nhyodyne",0
str_rph .db "Rhyophyre",0
str_duo .db "Duodyne",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"
@@ -1382,6 +1477,7 @@ str_trans_off .db "***** Testing Keyboard with Scan Code Translation DISABLED *
str_trans_on .db "***** Testing Keyboard with Scan Code Translation ENABLED *****",0
str_basic_mse .db "***** Basic Mouse Tests *****",0
str_kbdmse .db "***** Test All Devices Combined *****",0
str_ctlr_flush .db "Flushing controller input buffer",0
str_kbd_reset .db "Attempting Keyboard Reset",0
str_kbd_reset_ok .db "Keyboard Reset OK",0
str_err_kbd_reset .db "Keyboard Reset Failed",0

View File

@@ -32,6 +32,7 @@
; Use CPM3 BDOS direct BIOS call to get DRVTBL adr
; 2023-06-19 [WBW] Update for revised DIODEVICE API
; 2023-09-19 [WBW] Added CHUSB & CHSD device support
; 2023-10-13 [WBW] Fixed DPH creation to select correct DPB
;_______________________________________________________________________________
;
; ToDo:
@@ -665,10 +666,10 @@ makdphwbw: ; determine appropriate dpb (WBW mode, unit number in A)
jr makdph0 ; jump ahead
makdph00:
ld e,6 ; assume floppy
cp $10 ; floppy?
cp $01 ; floppy?
jr z,makdph0 ; yes, jump ahead
ld e,3 ; assume ram floppy
cp $20 ; ram floppy?
cp $02 ; ram floppy?
jr z,makdph0 ; yes, jump ahead
ld e,4 ; everything else is assumed to be hard disk
jr makdph0 ; yes, jump ahead
@@ -1935,13 +1936,13 @@ stack .equ $ ; stack top
; Messages
;
indent .db " ",0
msgban1 .db "ASSIGN v1.7 for RomWBW CP/M ",0
msgban1 .db "ASSIGN v1.8 for RomWBW CP/M ",0
msg22 .db "2.2",0
msg3 .db "3",0
msbban2 .db ", 19-Sep-2023",0
msbban2 .db ", 13-Oct-2023",0
msghb .db " (HBIOS Mode)",0
msgub .db " (UBIOS Mode)",0
msgban3 .db "Copyright 2021, Wayne Warthen, GNU GPL v3",0
msgban3 .db "Copyright 2023, Wayne Warthen, GNU GPL v3",0
msguse .db "Usage: ASSIGN D:[=[{D:|<device>[<unitnum>]:[<slicenum>]}]][,...]",13,10
.db " ex. ASSIGN (display all active assignments)",13,10
.db " ASSIGN /? (display version and usage)",13,10

View File

@@ -8,7 +8,8 @@ call BuildShared || exit /b
call BuildImages || exit /b
call BuildROM %* || exit /b
call BuildZRC || exit /b
call BuildZZRC || exit /b
call BuildZ1RCC || exit /b
call BuildZZRCC || exit /b
if "%1" == "dist" (
call Clean || exit /b

4
Source/BuildZ1RCC.cmd Normal file
View File

@@ -0,0 +1,4 @@
@echo off
setlocal
pushd Z1RCC && call Build || exit /b & popd

View File

@@ -1,4 +0,0 @@
@echo off
setlocal
pushd ZZRC && call Build || exit /b & popd

4
Source/BuildZZRCC.cmd Normal file
View File

@@ -0,0 +1,4 @@
@echo off
setlocal
pushd ZZRCC && call Build || exit /b & popd

View File

@@ -346,8 +346,7 @@ read:
ld b,17h ; HBIOS DEVICE function
rst 08 ; Do it, D=device type
ld a,d ; put in accum
and 0F0h ; isolate high bits
cp 10h ; floppy?
cp 01h ; floppy?
jr nz,read2 ; if not, do LBA i/o
; Floppy I/O

View File

@@ -13,7 +13,7 @@
extrn @dtbl,@ctbl
extrn @date,@hour,@min,@sec
extrn @srch1
extrn @hbbio
extrn @hbbio,@hbusr
extrn addhla
extrn phex16, phex8
extrn cin, cout
@@ -44,9 +44,9 @@ tpa$bank equ 0
if banked
; Clone page zero from bank 0 to additional banks
ld b,4 ; last bank
ld b,2 ; last bank
ld c,0 ; src bank
init$2:
init$1:
push bc ; save bank id's
call ?xmove ; set src/dest banks
ld bc,0100h ; size is one page
@@ -54,7 +54,7 @@ init$2:
ld de,0 ; src adr is 0
call ?move ; do it
pop bc ; restore bank id's
djnz init$2 ; loop till done
djnz init$1 ; loop till done
endif
@@ -62,6 +62,35 @@ init$2:
ld hl,signon$msg ; signon message
call ?pmsg ; print it
if banked
; Confirm that HBIOS is configured with enough RAM banks
; to accommodate banked version of CP/M 3. We use 2
; additional banks which live below the user bank. So we
; check that the these don't overlap with the RomWBW HBIOS
; bank.
ld bc,0F8F2h ; HBIOS GET BNKINFO
call 0FFF0h ; D: BIOS Bank, E: User Bank
ld a,d
ld (@hbbio),a
ld a,e
ld (@hbusr),a
sub 3 ; 2 extra banks (+1 for compare)
cp d ; lowest cpm bank - hbios bank
jr nc,init$2 ; continue if space available
ld hl,noram$msg ; signon message
call ?pmsg ; print it
ld b,0F0h ; HBIOS system reset
ld c,1h ; reset type warm (back to loader)
call 0FFFFh ; do it
endif
init$2:
; Check for HBIOS/CBIOS mismatch
ld b,0F1h ; hbios version
rst 08 ; do it, de=maj/min/up/pat
@@ -731,6 +760,10 @@ clrflg db 0 ; RAM disk cleared flag
clr$msg db 'RAM Disk Initialized',13,10,13,10,0
vermis$msg db 7,'*** WARNING: HBIOS/CBIOS Version Mismatch ***',13,10,13,10,0
if banked
noram$msg db 7,'*** ERROR: Insufficient RAM for banked CP/M 3 ***',13,10,13,10,0
endif
if zpm
signon$msg db 13,10,'ZPM3'

View File

@@ -41,22 +41,22 @@ HASHDRVM = N
HASHDRVN = N
HASHDRVO = N
HASHDRVP = N
ALTBNKSA = N
ALTBNKSB = N
ALTBNKSC = N
ALTBNKSD = N
ALTBNKSE = N
ALTBNKSF = N
ALTBNKSG = N
ALTBNKSH = N
ALTBNKSI = N
ALTBNKSJ = N
ALTBNKSK = N
ALTBNKSL = N
ALTBNKSM = N
ALTBNKSN = N
ALTBNKSO = N
ALTBNKSP = N
ALTBNKSA = Y
ALTBNKSB = Y
ALTBNKSC = Y
ALTBNKSD = Y
ALTBNKSE = Y
ALTBNKSF = Y
ALTBNKSG = Y
ALTBNKSH = Y
ALTBNKSI = Y
ALTBNKSJ = Y
ALTBNKSK = Y
ALTBNKSL = Y
ALTBNKSM = Y
ALTBNKSN = Y
ALTBNKSO = Y
ALTBNKSP = Y
NDIRRECA = 08
NDIRRECB = 00
NDIRRECC = 00

View File

@@ -22,4 +22,5 @@ pushd Prop && call Clean & popd
pushd RomDsk && call Clean & popd
pushd Doc && call Clean & popd
pushd ZRC && call Clean & popd
pushd ZZRC && call Clean & popd
pushd Z1RCC && call Clean & popd
pushd ZZRCC && call Clean & popd

View File

@@ -52,6 +52,7 @@ found:
| FAT | No | Yes | Yes |
| TUNE | No | Yes | Yes |
| WDATE | No | Yes | Yes |
| HTALK | No | Yes | Yes |
`\clearpage`{=latex}
@@ -628,9 +629,9 @@ shown on your console. The `TALK` application does this.
`TALK` operates at the operating system level (not HBIOS).
The parameter to `TALK` refers to logical CP/M serial devices. Upon
execution all characters types at the console will be sent to the
execution all characters typed at the console will be sent to the
device specified and all characters received by the specified device
will be echoes on the console.
will be echoed on the console.
Press Control+Z on the console to terminate the application.
@@ -646,6 +647,36 @@ provided in the RomWBW distribution.
`\clearpage`{=latex}
# HTALK
`HTALK` is a variation of the `TALK` utility, but it works directly
against HBIOS Character Units.
## Syntax
`HTALK COMn:`
## Usage
`HTALK` operates at the HBIOS level.
The parameter to `TALK` refers to a HBIOS character unit. Upon
execution all characters typed at the console will be sent to the
device specified and all characters received by the specified device
will be echoed on the console.
Press Control+Z on the console to terminate the application.
## Notes
## Etymology
The `TALK` command was created and donated to RomWBW by Tom Plano. It
is an original product designed specifically for RomWBW.
`\clearpage`{=latex}
# RTC
Many RomWBW systems provide real time clock hardware. The RTC

View File

@@ -201,6 +201,7 @@ below, **carefully** pick the appropriate ROM image for your hardware.
| [Nhyodyne Z80 MBC]^1^ | MBC | MBC_std.rom | 38400 |
| [Rhyophyre Z180 SBC]^1^ | - | RPH_std.rom | 38400 |
| [Z80 ZRC CPU Module]^7^ | RCBus | RCZ80_zrc.rom | 115200 |
| [Z180 Z1RCC CPU Module]^7^ | RCBus | RCZ180_z1rcc.rom | 115200 |
| [Z280 ZZRCC CPU Module]^7^ | RCBus | RCZ280_zzrc.rom | 115200 |
| [Z280 ZZ80MB SBC]^7^ | RCBus | RCZ280_zz80mb.rom | 115200 |
| [Z80-Retro SBC]^8^ | - | Z80RETRO_std.rom | 38400 |
@@ -595,6 +596,14 @@ technique is useful when:
The RAM disk and ROM disk drives will be available even if you have
no physical disk devices attached to your system.
Booting an operating system from ROM is not intended as a way to use
your operating system on a long-term basis. The ROM disk has only
a small subset of the operating system files. Additionally, you
cannot easily customize your ROM disk because you cannot write to it.
For any significant use of an operating system, you should boot directly
to the disk/slice that contains the complete operating system. This
is described in the next section.
## Starting Operating Systems from Disk
In order to make use of the more sophisticated operating systems
@@ -618,7 +627,7 @@ has been assigned to the disk and slice you selected to boot.
If you receive the error message "Disk not bootable!", you have
either failed to properly initialize the disk and slice requested
or you have selected the wrong disk/slice.
or you have selected an invalid/unavailable disk/slice.
The following example shows a disk boot into the first slice of disk
unit 4 which happens to be the CP/M 2.2 operating system on this disk.
@@ -696,6 +705,26 @@ have specified. It does not know what operating system is at that
location. The layout of operating systems on disk media is described in
the Using Disks section of this document.
### Auto-Submit Batch Files
All of the operating systems supplied with RomWBW have the ability to
execute a "batch" of commands by creating a batch submission file
containing the commands to be executed. The specifics of using
batch files in a specific operating system is covered in its specific
documentation.
At boot, the operating system will look for a specific batch file
(`PROFILE.SUB` for CP/M 2.2 and 3) on the boot drive and execute that
batch file automatically. This allows you to automatically customize
your operating system with any commands desired at boot. CP/M 2.2 did
not originally have the ability to automatically excute a batch file at
boot, but the CBIOS in RomWBW has added this capability.
Since RomWBW can utilize many disk slices, it is very easy to create
slices for specific workflows (editing, software development, games,
etc.). You can then just boot to the slice that is optimized for the
task you want to perform.
## System Management
### Listing Disk Device Inventory
@@ -901,7 +930,7 @@ Configuring Drives...
```
You will probably see more drive letters than this. The drive letter
assignment process is described below in the Drive Letter Assignment
assignment process is described below in the [Drive Letter Assignment]
section. Be aware that RomWBW will only assign drive letters to disk
interfaces that actually have media in them. If you do not see drive
letters assigned as expected, refer to the prior system boot messages
@@ -992,6 +1021,69 @@ rest of the drive letters will be offset to accommodate this. This is
done because most legacy operating systems expect that A: will be the
boot drive.
### Default Drive Letter Assignment
As shown above, when an operating system is booted, RomWBW will
automatically assign drive letters to physical disk devices. The
assignment process varies depending on: 1) the drive/slice you choose to
boot from, and 2) the number and type of physical drives in your
system.
If you boot an operating system from ROM, then the first two drive
letters will be assigned to your RAM disk (A:) and your ROM disk (B:).
It may seem odd that the RAM disk is assigned to A: in this case. The
reason for this is to accommodate certain functions that require that A:
be a writable disk drive. For example, A: **must** be writable in order
to submit batch files.
If you boot to a physical disk device, then the first drive letter (A:)
will be assigned to the disk/slice that you chose to boot from. The A:
drive letter is considered special by most operating systems and is
automatically used in some cases. By making the selected disk/slice the
A: drive, you can setup different disks/slices for specific uses and
just boot to it.
After the first drive letter is assigned (as well as the second drive
letter in the case of a ROM boot), RomWBW will assign additional drive
letters based on the disk drives in the system. Additional drive
letters will be assigned in the following order:
- RAM Disk
- ROM Disk
- Floppy Disk(s)
- Hard Disk(s)
If a disk/slice was already assigned as the A: (or B:) drive letter,
then it will not be assigned again.
In the case of floppy, RAM, and ROM disks, a single drive letter will be
assigned to each physical disk (even if there is no disk media in the
drive).
In the case of hard disks, 1-8 drive letters will be assigned to the
initial 1-8 slices of the disk drive. The number of drive letters
assigned to each hard disk depends on the number of hard disks in the
system:
- 1 Hard Disk: 8 drive letters (slices)
- 2 Hard Disks: 4 drive letters (slices) per disk
- 3+ Hard Disks: 2 drive letters (slices) per disk
This somewhat complicated algorithm is used to try and maximize the
limited number of operating system drive letters available (16) to
the available disk devices as evenly as possible.
Note that for hard disk devices, drive letters will only be assigned
to disk devices that actually contain media. So, for example, if you
have an SD Card slot in your system, but it has no SD Card inserted, then
no drive letters will be assigned to it.
Since drive letter assignments are easily changed at any time using the
`ASSIGN` command, you can customize your assignments as desired after
starting the operating system. Even better, you can use an auto-submit
batch file to customzie the assignments at startup without any user
intervention.
## ROM & RAM Disks
A typical RomWBW system has 512KB of ROM and 512KB of RAM. Some
@@ -1609,7 +1701,7 @@ filesystem partition and any CP/M filesystem slices that don't fit. You
will get "no disk" errors if you attempt to access a slice past the
end of the physical hard disk.
**WARNING**:Your hard disk may be too small to contain the full 64
**WARNING**: Your hard disk may be too small to contain the full 64
CP/M filesystem slices. The true number of CP/M filesystem slices that
will fit on your specific physical hard disk can be calculated as
described in [Hard Disk Capacity].
@@ -1625,12 +1717,20 @@ them using `CLRDIR` first.
A great way to maintain your own data on a hard disk is to put this
data in slices beyond the first 6. By doing so, you can always
"reimage" your drive with the combo image without overlaying the data
"re-image" your drive with the combo image without overlaying the data
stored in the slices beyond the first 6. Just be very careful to use
the same combo image layout (hd512 or hd1k) as you used originally.
Also remember to calculate the maximum number of slices your hard disk
will support and do not exceed this number.
**WARNING**: The combo disk image includes a partition table at the
start of the image. If you re-image drive with the combo image, you
will overwrite this partition table. This is fine as long as you don't
make any changes to the partition table. If you manually customize the
partition table (using `FDISK80` or other partition management
software), those changes will be lost if you re-image your disk with a
new combo disk image.
#### Custom Hard Disk Image
If you want to use specific slices in a specific order, you can easily
@@ -1640,8 +1740,9 @@ For hard disks, each .img file represents a single slice (CP/M
filesystem). Since a hard disk can contain many slices, you can just
concatenate the slices (.img files) together to create your desired hard
disk image. For example, if you want to create a hard disk image that
has slices for CP/M 2.2, CP/M 3, and WordStar in the hd512 format, you would use
the command line of your modern computer to create the final image:
has slices for CP/M 2.2, CP/M 3, and WordStar in the hd512 format, you
would use the command line of your modern computer to create the final
image:
Windows:
@@ -2363,6 +2464,53 @@ You can also contact Phillip for detailed information on the Z180
implementation of FreeRTOS for RomWBW.
[feilipu](https://github.com/feilipu)
## Fuzix
Fuzix is a Unix-ish operating system for small systems. It is the work
of Alan Cox and is hosted on GitHub at
<https://github.com/EtchedPixels/FUZIX>. Fuzix itself is a stand-alone
operating system, but it frequently utilizes RomWBW to boot and launch
on RomWBW-supported platforms.
For those Fuzix platforms that leverage RomWBW for startup, you will
program your ROM with the normal RomWBW ROM -- there
is no Fuzix-specific ROM. A Fuzix disk image for your system is then
written to your disk media. After booting your system via the normal
RomWBW ROM, you start Fuzix simply by choosing the disk device
containing the Fuzix image at the RomWBW Loader prompt.
To create a Fuzix disk image:
* Locate and download the Fuzix disk image for your system from
<https://www.fuzix.org/>.
* Remove the 1KB header from the image file. The Fuzix disk images
are built to run under an emulator that requires a 1KB prefix. You
must remove this prefix before writing the image to your physical
disk media. Unix dd is the easiest way to do this:
`dd bs=1024 skip=1 if=sc126-0.3.ide of=sc126-0.3.trimmed`
* Write the trimmed image to your disk media. This can also be
done with dd or with Win32DiskImager under Windows.
To boot into Fuzix:
* Power-up or reset your system. RomWBW should load normally
and bring you to the RomWBW Boot Loader prompt.
* Change your baud rate to 38,400. This can be done from the
RomWBW Boot Loader prompt with the following command:
`I 0 38400`
You will also need to change your terminal baud rate at this time.
* At the `bootdev:` prompt, enter `hda1`. Fuzix should load and
you will be prompted for a date/time.
* At the `login:` prompt, enter `root`. No password is required.
# Custom Applications
The operation of the RomWBW hosted operating systems is enhanced through
@@ -2604,6 +2752,166 @@ SAMPLE2.TXT ==> 4:/SAMPLE2.TXT ... [OK]
2 File(s) Copied
```
# Real Time Clock
RomWBW supports a variety of real time clock hardware. If your
system has this hardware, then it will be able to maintain the
current date and time even while your system is turned off.
Additionally, depending on the operating system being used, you may be
able to utilize date/time stamping of files.
You can determine if your system has a real time clock present (and
functioning) by looking at the boot messages. Here is an example of
a boot message reflecting the detection of a valid real time clock
module:
`DSRTC: MODE=STD IO=0x8A Thu 2023-10-19 14:07:11 CHARGE=ON`
This example is from a DSRTC clock module. You may have a different
one, but it will always display the current date/time.
In some cases, your real time clock will support charging of the
battery or super-capacitor while the system has power. The status of
this charging is displayed.
If the date/time of your RTC needs to be updated, you will need to do
this with one of the utilities described below. There is no ability to
update the date/time of the RTC in the RomWBW Boot Loader or Monitor.
## Date/Time Utilities
RomwWBW includes two utilities for displaying or setting the date/time
stored by the RTC. They are both a bit different and are briefly
described below.
### WDATE Utility
The `WDATE` utility (contributed by Kevin Boone) is an application
that will display and/or update the current date/time. Its operation is
described in $doc_apps$. This utility works with any of the supported
RomWBW RTC hardware. Here is an example of displaying and updating the
date/time with this utility:
```
A>wdate
Thursday 19 October 14:14:43 2023
A>wdate 23 10 19 14 24 30
A>wdate
Thursday 19 October 14:24:34 2023
```
Note that `WDATE` does not have anything to do with date/time stamping
of files. It merely displays and sets the real time clock value.
### RTC Utility
Like `WDATE`, the `RTC` utility (contributed by Andrew Lynch) will let
you display and set the current date/time. However, this utility only
works with the DSRTC hardware (DS1302 chip). It is a "direct to
hardware application". Its operation is described in $doc_apps$. Here
is an example of displaying and updatting the date/time with this
utility:
```
A>rtc
Start RTC Program
RomWBW HBIOS, Mark 4 RTC Latch Port 0x8A
RTC: Version 1.9
Commands: E)xit T)ime st(A)rt S)et R)aw L)oop C)harge N)ocharge D)elay I)nit G)et P)ut B)oot W)arm-start H)elp
RTC>t
Current time: 23-10-19 14:30:25-05
RTC>i
Init date/time.
YEAR:23
MONTH:10
DATE:19
HOURS:14
MINUTES:31
SECONDS:00
DAY:05
```
The `RTC` utility is also capable of turning the charging feature of
the DS1320 chip on or off. Here is an example of turning if off and
back on:
```
A>rtc
Start RTC Program
RomWBW HBIOS, Mark 4 RTC Latch Port 0x8A
RTC: Version 1.9
Commands: E)xit T)ime st(A)rt S)et R)aw L)oop C)harge N)ocharge D)elay I)nit G)et P)ut B)oot W)arm-start H)elp
RTC>n
Trickle charger disabled.
RTC>c
Trickle charger enabled.
```
Do **not** enable charging unless you are sure that your system
supports this. If your RTC is being powered by a normal battery, it
would be dangerous to enable charging.
## Date/Time File Stamping
If an RTC is available in your system, then most operating systems
can use it to date/time stamp files. This just means recording the
date/time of file creation, update, and or access in the directory.
This capability is available in all of the RomWBW operating system
except the original DRI CP/M 2.2.
In some cases (such as ZSDOS), you must load an RSX (memory resident
utility) to enable date/time stamping of files. Additionally, you
will need to initialize the directory. The procedure varies in each
operation system, so you must review the associated documentation.
The date/time stamping mechanisms for each operating system are
generally not compatible. If you initialize a directory for a type
of stamping, you should be careful not to manipulate that directory
with a different operating system with a different date/time stamping
mechanism. Doing so may corrupt the directory.
The RomWBW disk images do not have date/time stamping initialized. This
is to avoid any chance of directory corruption.
## Timezone
None of the operating systems distributed with RomWBW have any concept
of timezone. When files are date/time stamped, the date/time will
simply be whatever date/time the RTC currently has.
The normal practice is to set the RTC to your local time. This implies
that you would need to manually adjust the RTC for daylight savings time
and/or when you travel to a different time zone.
The date/time stamps of files in directories will also be stored in
local time. This includes files stored in a FAT filesystem. If you
subsequently view the directory from modern machines (Windows, Linux,
etc.), the date/time displayed will depend on the behavior of the
modern system.
For example, Linux assumes that the date/time of files
is UTC. So, if you create a file on a FAT filesystem with your RomWBW
computer and then use Linux to view the directory, the date/time stamps
will seem "off" by a few hours.
The only alternative you may consider is setting the date/time of your
RTC to UTC. Since UTC is consistent across all timezones and daylight
savings time, your file date/time stamps will also be consistent. Of
course, this will mean that your RomWBW computer will display a
date/time that seems wrong because it is not local time.
# CP/NET Networking
Digital Research created a simple network file sharing system called
@@ -3301,8 +3609,10 @@ directed to complete a partial flash using the /P command line switch.
# Related Projects
Outside of the hardware platforms adapted to RomWBW, there are a variety
of software projects that either target RomWBW specifically or provide
a RomWBW-specific variation.
of projects that either target RomWBW specifically or provide
a RomWBW-specific variation. These efforts are greatly appreciated
and are listed below. Please contact the author if there are any other
such projects that are not listed.
## Z88DK
@@ -3338,6 +3648,16 @@ the CP/M OS variants. This tool (`WDATE`) is included on the RomWBW
OS disk images. The project is hosted at
<https://github.com/kevinboone/wdate-cpm>.
## Assembly Language Programming for the RC2014 Zed
Bruce Hall has written a very nice document that describes how to
develop assembly language applications on RomWBW. It begins with the
setup and configuration of a new RC2014 Zed system running RomWBW.
It describes not only generic CP/M application development, but also
RomWBW HBIOS programming and bare metal programming. The latest copy
of this document is hosted at
[http://w8bh.net/Assembly for RC2014Z.pdf](http://w8bh.net/Assembly%20for%20RC2014Z.pdf).
# Acknowledgments
I want to acknowledge that a great deal of the code and inspiration
@@ -4012,7 +4332,7 @@ the RomWBW HBIOS configuration.
|-------------------|--------------------|
| ROM Image Files | RCZ80_zrc.rom |
| Console Baud Rate | 115200 |
| Interrupts | Mode 1 |
| Interrupts | Mode 1 |
- CPU speed is detected at startup if DS1302 RTC is active
- Otherwise 14.7456 MHz assumed
@@ -4027,7 +4347,29 @@ the RomWBW HBIOS configuration.
- VGARC Video & Keyboard Module
- Serial baud rate is usually determined by hardware for ACIA and
SIO interfaces
### Z180 Z1RCC CPU Module
| | |
|-------------------|--------------------|
| ROM Image Files | RCZ180_z1rcc.rom |
| Console Baud Rate | 115200 |
| Interrupts | Mode 2 |
- CPU speed is detected at startup if DS1302 RTC is active
- Otherwise 18.432 MHz assumed
- System timer is generated by Z180 CPU
- Hardware auto-detected:
- DS1302 RTC
- Z180 ASCI Serial Ports
- SIO Serial Interface Module
- EP Dual UART Serial Interface Module
- WDC Floppy Disk Controller w/ 3.5" HD Drives
- IDE Hard Disk Interface Module
- PPIDE Hard Disk Interface Module
- Use of Interrupt Mode 2 requires proper IEI/IEO configuration
for all peripherals generating interrupts
`\clearpage`{=latex}
### Z280 ZZRCC CPU Module

View File

@@ -27,7 +27,18 @@ Bank ID Module Start Size
0x04 - N ROM Disk Data
RAM Bank Layout
Typical ROM Bank Layout
Bank ID Usage
------- ------
0x00 Boot Bank (HBIOS image)
0x01 ROM Loader, Monitor, ROM OSes
0x02 ROM Applications
0x03 Reserved
0x04-0x0F ROM Disk Banks
Typical RAM Bank Layout
Bank ID Usage
------- ------
@@ -39,7 +50,7 @@ Bank ID Usage
0x8F Common
ROMless Bank Layout
Typical ROMless Bank Layout
Bank ID Usage
------- ------

View File

@@ -216,11 +216,12 @@ call Build RCZ80 zrc || exit /b
call Build RCZ80 zrc_ram || exit /b
call Build RCZ180 ext || exit /b
call Build RCZ180 nat || exit /b
call Build RCZ180 z1rcc || exit /b
call Build RCZ280 ext || exit /b
call Build RCZ280 nat || exit /b
call Build RCZ280 zz80mb || exit /b
call Build RCZ280 zzrc || exit /b
call Build RCZ280 zzrc_ram || exit /b
call Build RCZ280 zzrcc || exit /b
call Build RCZ280 zzrcc_ram || exit /b
call Build SCZ180 sc126 || exit /b
call Build SCZ180 sc130 || exit /b
call Build SCZ180 sc131 || exit /b
@@ -234,5 +235,6 @@ call Build Z80RETRO std || exit /b
call Build S100 std || exit /b
call Build DUO std || exit /b
call Build HEATH std || exit /b
call Build EPITX std || exit /b
goto :eof

View File

@@ -28,7 +28,7 @@ $ErrorAction = 'Stop'
#
$PlatformListZ80 = "SBC", "MBC", "ZETA", "ZETA2", "RCZ80", "Z80RETRO", "DUO", "UNA", "HEATH"
$PlatformListZ180 = "N8", "MK4", "RCZ180", "SCZ180", "DYNO", "RPH", "S100"
$PlatformListZ180 = "N8", "MK4", "RCZ180", "SCZ180", "DYNO", "RPH", "S100", "EPITX"
$PlatformListZ280 = "RCZ280"
#

View File

@@ -15,11 +15,12 @@ if [ "${ROM_PLATFORM}" == "dist" ] ; then
ROM_PLATFORM="N8"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="RCZ180"; ROM_CONFIG="ext"; bash Build.sh
ROM_PLATFORM="RCZ180"; ROM_CONFIG="nat"; bash Build.sh
ROM_PLATFORM="RCZ180"; ROM_CONFIG="z1rcc"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="ext"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="nat"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="zz80mb"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="zzrc"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="zzrc_ram"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="zzrcc"; bash Build.sh
ROM_PLATFORM="RCZ280"; ROM_CONFIG="zzrcc_ram"; bash Build.sh
# ROM_PLATFORM="RCZ80"; ROM_CONFIG="mt"; bash Build.sh
# ROM_PLATFORM="RCZ80"; ROM_CONFIG="duart"; bash Build.sh
ROM_PLATFORM="RCZ80"; ROM_CONFIG="std"; bash Build.sh
@@ -46,6 +47,7 @@ if [ "${ROM_PLATFORM}" == "dist" ] ; then
ROM_PLATFORM="ZETA"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="ZETA2"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="HEATH"; ROM_CONFIG="std"; bash Build.sh
ROM_PLATFORM="EPITX"; ROM_CONFIG="std"; bash Build.sh
exit
fi

View File

@@ -43,6 +43,5 @@ PCFENABLE .SET TRUE ; ENABLE PCF8584 I2C CONTROLLER
MDFFENABLE .SET FALSE ; MD: ENABLE FLASH FILE SYSTEM
;
UARTINTS .SET FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
;UARTCFG .SET UARTCFG | SER_RTS
;
ESPENABLE .SET TRUE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)

View File

@@ -34,8 +34,6 @@ 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)
;
ASCIENABLE .SET TRUE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
;ASCI0CFG .SET SER_115200_8N1 ; ASCI 0: SERIAL LINE CONFIG
;ASCI1CFG .SET SER_115200_8N1 ; ASCI 1: SERIAL LINE CONFIG
;
FDENABLE .SET TRUE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)
;

View File

@@ -0,0 +1,64 @@
;
;==================================================================================================
; Z180 Mini ITX 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 PLATFORM_NAME "Z180 MiniITX"
;
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
;
#include "cfg_epitx.asm"
;
CRTACT .SET TRUE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
;
CPUOSC .SET 18432000 ; CPU OSC FREQ IN MHZ
;
Z180_CLKDIV .SET 1 ; Z180: CHK DIV: 0=OSC/2, 1=OSC, 2=OSC*2
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)
;
HBIOS_MUTEX .SET FALSE ; ENABLE REENTRANT CALLS TO HBIOS (ADDS OVERHEAD)
;
LEDENABLE .SET FALSE ; ENABLE STATUS LED (SINGLE LED)
;
DSRTCENABLE .SET FALSE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
INTRTCENABLE .SET TRUE ; ENABLE PERIODIC INTERRUPT CLOCK DRIVER (INTRTC.ASM)
;
UARTENABLE .SET TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
ASCIENABLE .SET TRUE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
ACIAENABLE .SET FALSE ; ACIA: ENABLE MOTOROLA 6850 ACIA DRIVER (ACIA.ASM)
SIOENABLE .SET FALSE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
;
TMSENABLE .SET TRUE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
;
AY38910ENABLE .SET FALSE ; AY: AY-3-8910 / YM2149 SOUND DRIVER
;
FDENABLE .SET TRUE ; FD: DRIVER MODE: FDMODE_[DIO|ZETA|ZETA2|DIDE|N8|DIO3|RCSMC|RCWDC|DYNO|EPFDC]
FDMODE .SET FDMODE_EPFDC ; FD: DRIVER MODE: FDMODE_[DIO|ZETA|DIDE|N8|DIO3]
;
IDEENABLE .SET FALSE ; IDE: ENABLE IDE DISK DRIVER (IDE.ASM)
;
PPIDEENABLE .SET FALSE ; PPIDE: ENABLE PARALLEL PORT IDE DISK DRIVER (PPIDE.ASM)
;
SDENABLE .SET TRUE ; SD: ENABLE SD CARD DISK DRIVER (SD.ASM)
;
PRPENABLE .SET FALSE ; PRP: ENABLE ECB PROPELLER IO BOARD DRIVER (PRP.ASM)

View File

@@ -47,7 +47,6 @@ ICMENABLE .SET FALSE ; ENABLES ORIGINAL DSKY ICM DRIVER (7218)
PKDENABLE .SET TRUE ; ENABLES DSKY NG PKD DRIVER (8259)
;
UARTINTS .SET FALSE ; UART: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
;UARTCFG .SET UARTCFG | SER_RTS
;
ESPENABLE .SET TRUE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)
;

View File

@@ -0,0 +1,76 @@
;
;==================================================================================================
; RCBUS Z180 Z1RCC CONFIGURATION (ROMLESS)
;==================================================================================================
;
; 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 PLATFORM_NAME "Z1RCC", " [", CONFIG, "]"
;
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
;
#include "cfg_rcz180.asm"
;
CPUOSC .SET 18432000 ; CPU OSC FREQ IN MHZ
CRTACT .SET FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
;
FPLED_ENABLE .SET TRUE ; FP: ENABLES FRONT PANEL LEDS
FPSW_ENABLE .SET TRUE ; FP: ENABLES FRONT PANEL SWITCHES
;
MEMMGR .SET MM_Z180 ; MEMORY MANAGER: MM_[SBC|Z2|N8|Z180]
;
RAMSIZE .SET 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .SET 0 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
;
Z180_CLKDIV .SET 1 ; Z180: CHK DIV: 0=OSC/2, 1=OSC, 2=OSC*2
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)
;
MDROM .SET FALSE ; MD: ENABLE ROM DISK
MDRAM .SET TRUE ; MD: ENABLE RAM DISK
;
DSRTCENABLE .SET TRUE ; DSRTC: ENABLE DS-1302 CLOCK DRIVER (DSRTC.ASM)
INTRTCENABLE .SET TRUE ; ENABLE PERIODIC INTERRUPT CLOCK DRIVER (INTRTC.ASM)
;
UARTENABLE .SET TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
ASCIENABLE .SET TRUE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
ACIAENABLE .SET FALSE ; ACIA: ENABLE MOTOROLA 6850 ACIA DRIVER (ACIA.ASM)
SIOENABLE .SET TRUE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
;
TMSENABLE .SET FALSE ; TMS: ENABLE TMS9918 VIDEO/KBD DRIVER (TMS.ASM)
TMSMODE .SET TMSMODE_MSX ; TMS: DRIVER MODE: TMSMODE_[SCG|N8|MBC|MSX|MSX9958|MSXKBD|COLECO]
MKYENABLE .SET FALSE ; MSX 5255 PPI KEYBOARD COMPATIBLE DRIVER (REQUIRES TMS VDA DRIVER)
VRCENABLE .SET FALSE ; VRC: ENABLE VGARC VIDEO/KBD DRIVER (VRC.ASM)
VDAEMU_SERKBD .SET 0 ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
;
;
AY38910ENABLE .SET FALSE ; AY: AY-3-8910 / YM2149 SOUND DRIVER
AYMODE .SET AYMODE_RCZ180 ; AY: DRIVER MODE: AYMODE_[SCG|N8|RCZ80|RCZ180|MSX|LINC]
SN76489ENABLE .SET FALSE ; SN: ENABLE SN76489 SOUND DRIVER
;
FDENABLE .SET TRUE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)
FDMODE .SET FDMODE_RCWDC ; FD: DRIVER MODE: FDMODE_[DIO|ZETA|ZETA2|DIDE|N8|DIO3|RCSMC|RCWDC|DYNO|EPFDC]
;
IDEENABLE .SET TRUE ; IDE: ENABLE IDE DISK DRIVER (IDE.ASM)
PPIDEENABLE .SET TRUE ; PPIDE: ENABLE PARALLEL PORT IDE DISK DRIVER (PPIDE.ASM)
SDENABLE .SET FALSE ; SD: ENABLE SD CARD DISK DRIVER (SD.ASM)
SDCNT .SET 1 ; SD: NUMBER OF SD CARD DEVICES (1-2), FOR DSD/SC/MT SC ONLY
;
PRPENABLE .SET FALSE ; PRP: ENABLE ECB PROPELLER IO BOARD DRIVER (PRP.ASM)

View File

@@ -1,6 +1,6 @@
;
;==================================================================================================
; RCBUS Z280 STANDARD CONFIGURATION (NATIVE Z280 MMU W/ LINEAR MEMORY ON ZZRC)
; RCBUS Z280 ZZRCC CONFIGURATION
;==================================================================================================
;
; THE COMPLETE SET OF DEFAULT CONFIGURATION SETTINGS FOR THIS PLATFORM ARE FOUND IN THE
@@ -22,7 +22,7 @@
; PLEASE REFER TO THE CUSTOM BUILD INSTRUCTIONS (README.TXT) IN THE SOURCE DIRECTORY (TWO
; DIRECTORIES ABOVE THIS ONE).
;
#DEFINE PLATFORM_NAME "ZZRC", " [", CONFIG, "]"
#DEFINE PLATFORM_NAME "ZZRCC", " [", CONFIG, "]"
;
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
;
@@ -47,7 +47,7 @@ Z280_IOWAIT .SET 1 ; Z280: I/O WAIT STATES TO ADD ABOVE 1 W/S BUILT-IN (0-3)
Z280_INTWAIT .SET 0 ; Z280: INT ACK WAIT STATUS (0-3)
;
MDROM .SET TRUE ; MD: ENABLE ROM DISK
MDRAM .SET FALSE ; MD: ENABLE RAM DISK
MDRAM .SET TRUE ; MD: ENABLE RAM DISK
;
Z2UENABLE .SET TRUE ; Z2U: ENABLE Z280 UART SERIAL DRIVER (Z2U.ASM)
Z2UOSC .SET (CPUOSC / 8) ; Z2U: OSC FREQUENCY IN MHZ

View File

@@ -1,6 +1,6 @@
;
;==================================================================================================
; RCBUS Z280 STANDARD CONFIGURATION (NATIVE Z280 MMU W/ LINEAR MEMORY ON ZZRC)
; RCBUS Z280 ZZRCC CONFIGURATION (ROMLESS)
;==================================================================================================
;
; THE COMPLETE SET OF DEFAULT CONFIGURATION SETTINGS FOR THIS PLATFORM ARE FOUND IN THE
@@ -22,7 +22,7 @@
; PLEASE REFER TO THE CUSTOM BUILD INSTRUCTIONS (README.TXT) IN THE SOURCE DIRECTORY (TWO
; DIRECTORIES ABOVE THIS ONE).
;
#DEFINE PLATFORM_NAME "ZZRC", " [", CONFIG, "]"
#DEFINE PLATFORM_NAME "ZZRCC", " [", CONFIG, "]"
;
#DEFINE BOOT_DEFAULT "H" ; DEFAULT BOOT LOADER CMD ON <CR> OR AUTO BOOT
;

View File

@@ -31,7 +31,6 @@ INTMODE .SET 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2
CRTACT .SET TRUE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
;
UARTENABLE .SET TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
;UARTCFG .SET UARTCFG | SER_RTS
UARTSBC .SET TRUE ; UART: AUTO-DETECT SBC/ZETA ONBOARD UART
;
FDENABLE .SET TRUE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)

View File

@@ -31,7 +31,6 @@ INTMODE .SET 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2
CRTACT .SET TRUE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
;
UARTENABLE .SET TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
;UARTCFG .SET UARTCFG | SER_RTS
UARTSBC .SET TRUE ; UART: AUTO-DETECT SBC/ZETA ONBOARD UART
;
FDENABLE .SET TRUE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)

View File

@@ -178,10 +178,26 @@ ACIA1_INT:
;
ACIA_INTRCV:
; CHECK TO SEE IF SOMETHING IS ACTUALLY THERE
CALL DELAY
LD C,(IY+3) ; CMD/STAT PORT TO C
IN A,(C) ; GET STATUS
RRA ; READY BIT TO CF
RET NC ; NOTHING AVAILABLE ON CURRENT CHANNEL
LD B,A
AND $01 ; ISOLATE READY BIT
JR NZ,ACIA_INTRCV1
;
#IF FALSE
CALL PC_LT
LD A,B
CALL PRTHEXBYTE
INC C
IN A,(C)
CALL PRTHEXBYTE
CALL PC_GT
OR $FF
#ENDIF
;
RET
;
ACIA_INTRCV1:
; RECEIVE CHARACTER INTO BUFFER

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_UNSUP ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 8000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -46,15 +46,15 @@ RTCIO .EQU $94 ; RTC LATCH REGISTER ADR
KIOENABLE .EQU FALSE ; ENABLE ZILOG KIO SUPPORT
KIOBASE .EQU $80 ; KIO BASE I/O ADDRESS
;
CTCENABLE .EQU FALSE ; ENABLE ZILOG CTC SUPPORT
CTCENABLE .EQU TRUE ; ENABLE ZILOG CTC SUPPORT
CTCDEBUG .EQU FALSE ; ENABLE CTC DRIVER DEBUG OUTPUT
CTCBASE .EQU $B0 ; CTC BASE I/O ADDRESS
CTCBASE .EQU $60 ; CTC BASE I/O ADDRESS
CTCTIMER .EQU TRUE ; ENABLE CTC PERIODIC TIMER
CTCMODE .EQU CTCMODE_CTR ; CTC MODE: CTCMODE_[NONE|CTR|TIM16|TIM256]
CTCPRE .EQU 256 ; PRESCALE CONSTANT (1-256)
CTCPRECH .EQU 2 ; PRESCALE CHANNEL (0-3)
CTCTIMCH .EQU 3 ; TIMER CHANNEL (0-3)
CTCOSC .EQU (4915200/8) ; CTC CLOCK FREQUENCY
CTCOSC .EQU (7372800/8) ; CTC CLOCK FREQUENCY
;
PCFENABLE .EQU FALSE ; ENABLE PCF8584 I2C CONTROLLER
PCFBASE .EQU $56 ; PCF8584 BASE I/O ADDRESS
@@ -88,6 +88,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -122,17 +123,18 @@ DS7RTCMODE .EQU DS7RTCMODE_PCF ; DS7RTC: OPERATING MODE: DS7RTC_[PCF]
DUARTENABLE .EQU FALSE ; DUART: ENABLE 2681/2692 SERIAL DRIVER (DUART.ASM)
;
UARTENABLE .EQU TRUE ; UART: ENABLE 8250/16550-LIKE SERIAL DRIVER (UART.ASM)
UARTOSC .EQU 1843200 ; UART: OSC FREQUENCY IN MHZ
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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART
UARTRC .EQU FALSE ; UART: AUTO-DETECT RC UART
UARTDUAL .EQU FALSE ; UART: AUTO-DETECT DUAL UART
UARTDUAL .EQU TRUE ; UART: AUTO-DETECT DUAL UART
;
ASCIENABLE .EQU FALSE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
;
@@ -140,18 +142,18 @@ Z2UENABLE .EQU FALSE ; Z2U: ENABLE Z280 UART SERIAL DRIVER (Z2U.ASM)
;
ACIAENABLE .EQU FALSE ; ACIA: ENABLE MOTOROLA 6850 ACIA DRIVER (ACIA.ASM)
;
SIOENABLE .EQU FALSE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
SIOENABLE .EQU TRUE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
SIODEBUG .EQU FALSE ; SIO: ENABLE DEBUG OUTPUT
SIOBOOT .EQU 0 ; SIO: REBOOT ON RCV CHAR (0=DISABLED)
SIOCNT .EQU 1 ; SIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
SIO0MODE .EQU SIOMODE_ZP ; SIO 0: CHIP TYPE: SIOMODE_[STD|RC|SMB|ZP|Z80R]
SIO0BASE .EQU $B0 ; SIO 0: REGISTERS BASE ADR
SIO0ACLK .EQU (4915200/8) ; SIO 0A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0BASE .EQU $60 ; SIO 0: REGISTERS BASE ADR
SIO0ACLK .EQU (7372800/4) ; SIO 0A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0ACFG .EQU DEFSERCFG ; SIO 0A: SERIAL LINE CONFIG
SIO0ACTCC .EQU -1 ; SIO 0A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO0BCLK .EQU (4915200/8) ; SIO 0B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0ACTCC .EQU 0 ; SIO 0A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO0BCLK .EQU (7372800/4) ; SIO 0B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0BCFG .EQU DEFSERCFG ; SIO 0B: SERIAL LINE CONFIG
SIO0BCTCC .EQU -1 ; SIO 0B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO0BCTCC .EQU 1 ; SIO 0B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
;
XIOCFG .EQU DEFSERCFG ; XIO: SERIAL LINE CONFIG
;
@@ -229,14 +231,14 @@ SDCNT .EQU 1 ; SD: NUMBER OF SD CARD DEVICES (1-2), FOR DSD/SC/MT ONLY
SDTRACE .EQU 1 ; SD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
SDCSIOFAST .EQU FALSE ; SD: ENABLE TABLE-DRIVEN BIT INVERTER IN CSIO MODE
;
CHENABLE .EQU FALSE ; CH: ENABLE CH375/376 USB SUPPORT
CHENABLE .EQU TRUE ; 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)
CHCNT .EQU 1 ; CH: NUMBER OF BOARDS TO DETECT (1-2)
CH0BASE .EQU $BE ; CH 0: BASE I/O ADDRESS
CH0BASE .EQU $4E ; CH 0: BASE I/O ADDRESS
CH0USBENABLE .EQU TRUE ; CH 0: ENABLE USB DISK
CH0SDENABLE .EQU FALSE ; CH 0: ENABLE SD DISK
CH0SDENABLE .EQU TRUE ; CH 0: ENABLE SD DISK
CH1BASE .EQU $FF ; CH 1: BASE I/O ADDRESS
CH1USBENABLE .EQU FALSE ; CH 1: ENABLE USB DISK
CH1SDENABLE .EQU FALSE ; CH 1: ENABLE SD DISK
@@ -254,16 +256,16 @@ ESPCONENABLE .EQU TRUE ; ESP: ENABLE ESP32 CONSOLE IO DRIVER VIDEO/KBD SUPPORT
HDSKENABLE .EQU FALSE ; HDSK: ENABLE SIMH HDSK DISK DRIVER (HDSK.ASM)
HDSKTRACE .EQU 1 ; HDSK: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
;
PIOENABLE .EQU FALSE ; PIO: ENABLE ZILOG PIO DRIVER (PIO.ASM)
PIOENABLE .EQU TRUE ; PIO: ENABLE ZILOG PIO DRIVER (PIO.ASM)
PIOCNT .EQU 2 ; PIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
PIO0BASE .EQU $B8 ; PIO 0: REGISTERS BASE ADR
PIO1BASE .EQU $BC ; PIO 1: REGISTERS BASE ADR
PIO0BASE .EQU $68 ; PIO 0: REGISTERS BASE ADR
PIO1BASE .EQU $6C ; PIO 1: REGISTERS BASE ADR
;
LPTENABLE .EQU FALSE ; LPT: ENABLE CENTRONICS PRINTER DRIVER (LPT.ASM)
LPTENABLE .EQU TRUE ; LPT: ENABLE CENTRONICS PRINTER DRIVER (LPT.ASM)
LPTMODE .EQU LPTMODE_SPP ; LPT: DRIVER MODE: LPTMODE_[NONE|SPP|MG014]
LPTCNT .EQU 1 ; LPT: NUMBER OF CHIPS TO DETECT (1-2)
LPTTRACE .EQU 1 ; LPT: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
LPT0BASE .EQU $E8 ; LPT 0: REGISTERS BASE ADR
LPT0BASE .EQU $48 ; LPT 0: REGISTERS BASE ADR
LPT1BASE .EQU $EC ; LPT 1: REGISTERS BASE ADR
;
PPAENABLE .EQU FALSE ; PPA: ENABLE PPA DISK DRIVER (PPA.ASM)

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -136,6 +137,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

330
Source/HBIOS/cfg_epitx.asm Normal file
View File

@@ -0,0 +1,330 @@
;
;==================================================================================================
; ROMWBW 2.X CONFIGURATION DEFAULTS FOR SC Z180 VARIANTS (SC126, SC130, ETC.)
;==================================================================================================
;
; THIS FILE CONTAINS THE FULL SET OF DEFAULT CONFIGURATION SETTINGS FOR THE PLATFORM
; INDICATED ABOVE. THIS FILE SHOULD *NOT* NORMALLY BE CHANGED. INSTEAD, YOU SHOULD
; OVERRIDE ANY SETTINGS YOU WANT USING A CONFIGURATION FILE IN THE CONFIG DIRECTORY
; UNDER THIS DIRECTORY.
;
; THIS FILE CAN BE CONSIDERED A REFERENCE THAT LISTS ALL POSSIBLE CONFIGURATION SETTINGS
; FOR THE PLATFORM.
;
#DEFINE PLATFORM_NAME "MiniITX"
;
#INCLUDE "hbios.inc"
;
PLATFORM .EQU PLT_EPITX ; PLT_[SBC|ZETA|ZETA2|N8|MK4|UNA|RCZ80|RCZ180|EZZ80|SCZ180|DYNO|RCZ280|MBC|EPITX]
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
HBIOS_MUTEX .EQU FALSE ; ENABLE REENTRANT CALLS TO HBIOS (ADDS OVERHEAD)
USELZSA2 .EQU TRUE ; ENABLE FONT COMPRESSION
TICKFREQ .EQU 50 ; DESIRED PERIODIC TIMER INTERRUPT FREQUENCY (HZ)
;
BOOT_TIMEOUT .EQU -1 ; AUTO BOOT TIMEOUT IN SECONDS, -1 TO DISABLE, 0 FOR IMMEDIATE
BOOT_DELAY .EQU 0 ; FIXED BOOT DELAY IN SECONDS PRIOR TO CONSOLE OUTPUT
;
CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
MEMMGR .EQU MM_Z180 ; MEMORY MANAGER: MM_[SBC|Z2|N8|Z180|Z280|MBC|RPH]
RAMBIAS .EQU ROMSIZE ; OFFSET OF START OF RAM IN PHYSICAL ADDRESS SPACE
;
Z180_BASE .EQU $C0 ; Z180: I/O BASE ADDRESS FOR INTERNAL REGISTERS
Z180_CLKDIV .EQU 1 ; Z180: CHK DIV: 0=OSC/2, 1=OSC, 2=OSC*2
Z180_MEMWAIT .EQU 0 ; Z180: MEMORY WAIT STATES (0-3)
Z180_IOWAIT .EQU 1 ; Z180: I/O WAIT STATES TO ADD ABOVE 1 W/S BUILT-IN (0-3)
Z180_TIMER .EQU TRUE ; Z180: ENABLE Z180 SYSTEM PERIODIC TIMER
;
RTCIO .EQU $0C ; RTC LATCH REGISTER ADR - TODO
;
KIOENABLE .EQU FALSE ; ENABLE ZILOG KIO SUPPORT
KIOBASE .EQU $80 ; KIO BASE I/O ADDRESS
;
CTCENABLE .EQU FALSE ; ENABLE ZILOG CTC SUPPORT
CTCDEBUG .EQU FALSE ; ENABLE CTC DRIVER DEBUG OUTPUT
CTCBASE .EQU $88 ; CTC BASE I/O ADDRESS
CTCTIMER .EQU FALSE ; ENABLE CTC PERIODIC TIMER
;
PCFENABLE .EQU FALSE ; ENABLE PCF8584 I2C CONTROLLER
PCFBASE .EQU $F0 ; PCF8584 BASE I/O ADDRESS
;
EIPCENABLE .EQU FALSE ; EIPC: ENABLE Z80 EIPC (Z84C15) INITIALIZATION
;
SKZENABLE .EQU FALSE ; ENABLE SERGEY'S Z80-512K FEATURES
;
WDOGMODE .EQU WDOG_NONE ; WATCHDOG MODE: WDOG_[NONE|EZZ80|SKZ]
;
FPENABLE .EQU FALSE ; ENABLES FRONT PANEL SWITCHES
FPBASE .EQU $00 ; FRONT PANEL I/O PORT BASE ADDRESS
DIAGENABLE .EQU TRUE ; ENABLES OUTPUT TO 8 BIT LED DIAGNOSTIC PORT
DIAGPORT .EQU $00 ; DIAGNOSTIC PORT ADDRESS
DIAGDISKIO .EQU TRUE ; ENABLES DISK I/O ACTIVITY ON DIAGNOSTIC LEDS
;
FPLED_ENABLE .EQU FALSE ; FP: ENABLES FRONT PANEL LEDS
FPLED_IO .EQU $00 ; FP: PORT ADDRESS FOR FP LEDS
FPLED_DSKACT .EQU FALSE ; FP: ENABLES DISK I/O ACTIVITY ON FP LEDS
FPSW_ENABLE .EQU FALSE ; FP: ENABLES FRONT PANEL SWITCHES
FPSW_IO .EQU $00 ; FP: PORT ADDRESS FOR FP SWITCHES
;
DIAGLVL .EQU DL_CRITICAL ; ERROR LEVEL REPORTING
;
LEDENABLE .EQU FALSE ; ENABLES STATUS LED (SINGLE LED)
LEDMODE .EQU LEDMODE_STD ; LEDMODE_[STD|RTC]
LEDPORT .EQU $0E ; STATUS LED PORT ADDRESS
LEDDISKIO .EQU TRUE ; ENABLES DISK I/O ACTIVITY ON STATUS LED
;
DSKYENABLE .EQU FALSE ; ENABLES DSKY FUNCTIONALITY
DSKYDSKACT .EQU TRUE ; ENABLES DISK ACTIVITY ON DSKY DISPLAY
ICMENABLE .EQU FALSE ; ENABLES ORIGINAL DSKY ICM DRIVER (7218)
ICMPPIBASE .EQU $60 ; BASE I/O ADDRESS OF ICM PPI
PKDENABLE .EQU FALSE ; ENABLES DSKY NG PKD DRIVER (8259)
PKDPPIBASE .EQU $60 ; BASE I/O ADDRESS OF PKD PPI
PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
; TODO - ADD PS/2 BITBANGER
VDAEMU_SERKBD .EQU $00 ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
ANSITRACE .EQU 1 ; ANSI DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPKTRACE .EQU 1 ; PPK DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
KBDTRACE .EQU 1 ; KBD DRIVER TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPKKBLOUT .EQU KBD_US ; PPK KEYBOARD LANGUAGE: KBD_[US|DE]
KBDKBLOUT .EQU KBD_US ; KBD KEYBOARD LANGUAGE: KBD_[US|DE]
MKYENABLE .EQU FALSE ; MSX 5255 PPI KEYBOARD COMPATIBLE DRIVER (REQUIRES TMS VDA DRIVER)
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]
DSRTCCHG .EQU FALSE ; DSRTC: FORCE BATTERY CHARGE ON (USE WITH CAUTION!!!)
;
DS1501RTCENABLE .EQU FALSE ; DS1501RTC: ENABLE DS-1501 CLOCK DRIVER (DS1501RTC.ASM)
DS1501RTC_BASE .EQU $50 ; DS1501RTC: I/O BASE ADDRESS
;
BQRTCENABLE .EQU FALSE ; BQRTC: ENABLE BQ4845 CLOCK DRIVER (BQRTC.ASM)
BQRTC_BASE .EQU $50 ; BQRTC: I/O BASE ADDRESS
;
INTRTCENABLE .EQU FALSE ; ENABLE PERIODIC INTERRUPT CLOCK DRIVER (INTRTC.ASM)
;
RP5RTCENABLE .EQU FALSE ; RP5C01 RTC BASED CLOCK (RP5RTC.ASM)
;
HTIMENABLE .EQU FALSE ; ENABLE SIMH TIMER SUPPORT
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]
;
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
DUART0ACFG .EQU DEFSERCFG ; DUART 0A: SERIAL LINE CONFIG
DUART0BCFG .EQU DEFSERCFG ; DUART 0B: SERIAL LINE CONFIG
DUART1BASE .EQU $40 ; DUART 1: BASE ADDRESS OF CHIP
DUART1ACFG .EQU DEFSERCFG ; DUART 1A: SERIAL LINE CONFIG
DUART1BCFG .EQU DEFSERCFG ; DUART 1B: SERIAL LINE CONFIG
;
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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART
UARTRC .EQU TRUE ; UART: AUTO-DETECT RC UART
UARTDUAL .EQU FALSE ; UART: AUTO-DETECT DUAL UART
;
ASCIENABLE .EQU TRUE ; ASCI: ENABLE Z180 ASCI SERIAL DRIVER (ASCI.ASM)
ASCIINTS .EQU TRUE ; ASCI: INCLUDE INTERRUPT SUPPORT UNDER IM1/2/3
ASCISWAP .EQU FALSE ; ASCI: SWAP CHANNELS
ASCIBOOT .EQU 0 ; ASCI: REBOOT ON RCV CHAR (0=DISABLED)
ASCI0CFG .EQU DEFSERCFG ; ASCI 0: SERIAL LINE CONFIG
ASCI1CFG .EQU DEFSERCFG ; ASCI 1: SERIAL LINE CONFIG
;
Z2UENABLE .EQU FALSE ; Z2U: ENABLE Z280 UART SERIAL DRIVER (Z2U.ASM)
;
ACIAENABLE .EQU FALSE ; ACIA: ENABLE MOTOROLA 6850 ACIA DRIVER (ACIA.ASM)
;
SIOENABLE .EQU FALSE ; SIO: ENABLE ZILOG SIO SERIAL DRIVER (SIO.ASM)
SIODEBUG .EQU FALSE ; SIO: ENABLE DEBUG OUTPUT
SIOBOOT .EQU 0 ; SIO: REBOOT ON RCV CHAR (0=DISABLED)
SIOCNT .EQU 2 ; SIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
SIO0MODE .EQU SIOMODE_RC ; SIO 0: CHIP TYPE: SIOMODE_[STD|RC|SMB|ZP|Z80R]
SIO0BASE .EQU $80 ; SIO 0: REGISTERS BASE ADR
SIO0ACLK .EQU 7372800 ; SIO 0A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0ACFG .EQU SER_115200_8N1 ; SIO 0A: SERIAL LINE CONFIG
SIO0ACTCC .EQU -1 ; SIO 0A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO0BCLK .EQU 7372800 ; SIO 0B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO0BCFG .EQU SER_115200_8N1 ; SIO 0B: SERIAL LINE CONFIG
SIO0BCTCC .EQU -1 ; SIO 0B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO1MODE .EQU SIOMODE_RC ; SIO 1: CHIP TYPE: SIOMODE_[STD|RC|SMB|ZP|Z80R]
SIO1BASE .EQU $84 ; SIO 1: REGISTERS BASE ADR
SIO1ACLK .EQU 7372800 ; SIO 1A: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO1ACFG .EQU SER_115200_8N1 ; SIO 1A: SERIAL LINE CONFIG
SIO1ACTCC .EQU -1 ; SIO 1A: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
SIO1BCLK .EQU 7372800 ; SIO 1B: OSC FREQ IN HZ, ZP=2457600/4915200, RC/SMB=7372800
SIO1BCFG .EQU SER_115200_8N1 ; SIO 1B: SERIAL LINE CONFIG
SIO1BCTCC .EQU -1 ; SIO 1B: CTC CHANNEL 0=A, 1=B, 2=C, 3=D, -1 FOR NONE
;
XIOCFG .EQU DEFSERCFG ; XIO: SERIAL LINE CONFIG
;
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]
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)
SCONENABLE .EQU FALSE ; SCON: ENABLE S100 CONSOLE DRIVER (SCON.ASM)
;
MDENABLE .EQU TRUE ; MD: ENABLE MEMORY (ROM/RAM) DISK DRIVER (MD.ASM)
MDROM .EQU TRUE ; MD: ENABLE ROM DISK
MDRAM .EQU TRUE ; MD: ENABLE RAM DISK
MDTRACE .EQU 1 ; MD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
MDFFENABLE .EQU FALSE ; MD: ENABLE FLASH FILE SYSTEM
;
FDENABLE .EQU TRUE ; FD: ENABLE FLOPPY DISK DRIVER (FD.ASM)
FDMODE .EQU FDMODE_EPFDC ; FD: DRIVER MODE: FDMODE_[DIO|ZETA|ZETA2|DIDE|N8|DIO3|RCSMC|RCWDC|DYNO|EPFDC|MBC]
FDCNT .EQU 2 ; FD: NUMBER OF FLOPPY DRIVES ON THE INTERFACE (1-2)
FDTRACE .EQU 1 ; FD: TRACE LEVEL (0=NO,1=FATAL,2=ERRORS,3=ALL)
FDMAUTO .EQU TRUE ; FD: AUTO SELECT DEFAULT/ALTERNATE MEDIA FORMATS
FD0TYPE .EQU FDT_3HD ; FD 0: DRIVE TYPE: FDT_[3DD|3HD|5DD|5HD|8]
FD1TYPE .EQU FDT_3HD ; FD 1: DRIVE TYPE: FDT_[3DD|3HD|5DD|5HD|8]
;
RFENABLE .EQU FALSE ; RF: ENABLE RAM FLOPPY DRIVER
;
IDEENABLE .EQU FALSE ; IDE: ENABLE IDE DISK DRIVER (IDE.ASM)
IDETRACE .EQU 1 ; IDE: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
IDECNT .EQU 1 ; IDE: NUMBER OF IDE INTERFACES TO DETECT (1-3), 2 DRIVES EACH
IDE0MODE .EQU IDEMODE_RC ; IDE 0: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC]
IDE0BASE .EQU $10 ; IDE 0: IO BASE ADDRESS
IDE0DATLO .EQU $00 ; IDE 0: DATA LO PORT FOR 16-BIT I/O
IDE0DATHI .EQU $00 ; IDE 0: DATA HI PORT FOR 16-BIT I/O
IDE0A8BIT .EQU TRUE ; IDE 0A (MASTER): 8 BIT XFER
IDE0B8BIT .EQU TRUE ; IDE 0B (MASTER): 8 BIT XFER
IDE1MODE .EQU IDEMODE_NONE ; IDE 1: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC]
IDE1BASE .EQU $00 ; IDE 1: IO BASE ADDRESS
IDE1DATLO .EQU $00 ; IDE 1: DATA LO PORT FOR 16-BIT I/O
IDE1DATHI .EQU $00 ; IDE 1: DATA HI PORT FOR 16-BIT I/O
IDE1A8BIT .EQU TRUE ; IDE 1A (MASTER): 8 BIT XFER
IDE1B8BIT .EQU TRUE ; IDE 1B (MASTER): 8 BIT XFER
IDE2MODE .EQU IDEMODE_NONE ; IDE 2: DRIVER MODE: IDEMODE_[DIO|DIDE|MK4|RC]
IDE2BASE .EQU $00 ; IDE 2: IO BASE ADDRESS
IDE2DATLO .EQU $00 ; IDE 2: DATA LO PORT FOR 16-BIT I/O
IDE2DATHI .EQU $00 ; IDE 2: DATA HI PORT FOR 16-BIT I/O
IDE2A8BIT .EQU TRUE ; IDE 2A (MASTER): 8 BIT XFER
IDE2B8BIT .EQU TRUE ; IDE 2B (MASTER): 8 BIT XFER
;
PPIDEENABLE .EQU FALSE ; PPIDE: ENABLE PARALLEL PORT IDE DISK DRIVER (PPIDE.ASM)
PPIDETRACE .EQU 1 ; PPIDE: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPIDECNT .EQU 1 ; PPIDE: NUMBER OF PPI CHIPS TO DETECT (1-3), 2 DRIVES PER CHIP
PPIDE0BASE .EQU $20 ; PPIDE 0: PPI REGISTERS BASE ADR
PPIDE0A8BIT .EQU FALSE ; PPIDE 0A (MASTER): 8 BIT XFER
PPIDE0B8BIT .EQU FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
PPIDE1BASE .EQU $00 ; PPIDE 1: PPI REGISTERS BASE ADR
PPIDE1A8BIT .EQU FALSE ; PPIDE 1A (MASTER): 8 BIT XFER
PPIDE1B8BIT .EQU FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
PPIDE2BASE .EQU $00 ; PPIDE 2: PPI REGISTERS BASE ADR
PPIDE2A8BIT .EQU FALSE ; PPIDE 2A (MASTER): 8 BIT XFER
PPIDE2B8BIT .EQU FALSE ; PPIDE 0B (SLAVE): 8 BIT XFER
;
SDENABLE .EQU TRUE ; SD: ENABLE SD CARD DISK DRIVER (SD.ASM)
SDMODE .EQU SDMODE_EPITX ; SD: DRIVER MODE: SDMODE_[JUHA|N8|CSIO|PPI|UART|DSD|MK4|SC|MT|EPITX]
SDPPIBASE .EQU $40 ; SD: BASE I/O ADDRESS OF PPI FOR PPI MODDE
SDCNT .EQU 1 ; SD: NUMBER OF SD CARD DEVICES (1-2), FOR DSD & SC ONLY
SDTRACE .EQU 2 ; SD: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
SDCSIOFAST .EQU FALSE ; SD: ENABLE TABLE-DRIVEN BIT INVERTER IN CSIO MODE
SDMTSWAP .EQU FALSE ; SD: SWAP THE LOGICAL ORDER OF THE SPI PORTS OF THE MT011
;
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)
CHCNT .EQU 1 ; CH: NUMBER OF BOARDS TO DETECT (1-2)
CH0BASE .EQU $BE ; CH 0: BASE I/O ADDRESS
CH0USBENABLE .EQU TRUE ; CH 0: ENABLE USB DISK
CH0SDENABLE .EQU FALSE ; CH 0: ENABLE SD DISK
CH1BASE .EQU $FF ; CH 1: BASE I/O ADDRESS
CH1USBENABLE .EQU FALSE ; CH 1: ENABLE USB DISK
CH1SDENABLE .EQU FALSE ; CH 1: ENABLE SD DISK
;
PRPENABLE .EQU FALSE ; PRP: ENABLE ECB PROPELLER IO BOARD DRIVER (PRP.ASM)
PRPSDENABLE .EQU TRUE ; PRP: ENABLE PROPIO DRIVER SD CARD SUPPORT
PRPSDTRACE .EQU 1 ; PRP: SD CARD TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PRPCONENABLE .EQU TRUE ; PRP: ENABLE PROPIO DRIVER VIDEO/KBD SUPPORT
;
PPPENABLE .EQU FALSE ; PPP: ENABLE ZETA PARALLEL PORT PROPELLER BOARD DRIVER (PPP.ASM)
;
ESPENABLE .EQU FALSE ; ESP: ENABLE ESP32 IO BOARD DRIVER (ESP.ASM)
;
HDSKENABLE .EQU FALSE ; HDSK: ENABLE SIMH HDSK DISK DRIVER (HDSK.ASM)
;
PIOENABLE .EQU FALSE ; PIO: ENABLE ZILOG PIO DRIVER (PIO.ASM)
PIOCNT .EQU 2 ; PIO: NUMBER OF CHIPS TO DETECT (1-2), 2 CHANNELS PER CHIP
PIO0BASE .EQU $B8 ; PIO 0: REGISTERS BASE ADR
PIO1BASE .EQU $BC ; PIO 1: REGISTERS BASE ADR
;
LPTENABLE .EQU FALSE ; LPT: ENABLE CENTRONICS PRINTER DRIVER (LPT.ASM)
LPTMODE .EQU LPTMODE_MG014 ; LPT: DRIVER MODE: LPTMODE_[NONE|SPP|MG014]
LPTCNT .EQU 1 ; LPT: NUMBER OF CHIPS TO DETECT (1-2)
LPTTRACE .EQU 1 ; LPT: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
LPT0BASE .EQU $0C ; LPT 0: REGISTERS BASE ADR
LPT1BASE .EQU $00 ; LPT 1: REGISTERS BASE ADR
;
PPAENABLE .EQU FALSE ; PPA: ENABLE PPA DISK DRIVER (PPA.ASM)
PPACNT .EQU 1 ; PPA: NUMBER OF PPA DEVICES (1-2)
PPATRACE .EQU 1 ; PPA: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
PPAMODE .EQU PPAMODE_MG014 ; PPA: DRIVER MODE: PPAMODE_[NONE|SPP|MG014]
PPA0BASE .EQU LPT0BASE ; PPA 0: BASE I/O ADDRESS OF PPI FOR PPA
PPA1BASE .EQU LPT1BASE ; PPA 1: BASE I/O ADDRESS OF PPI FOR PPA
;
IMMENABLE .EQU FALSE ; IMM: ENABLE IMM DISK DRIVER (IMM.ASM)
IMMCNT .EQU 1 ; IMM: NUMBER OF IMM DEVICES (1-2)
IMMTRACE .EQU 1 ; IMM: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
IMMMODE .EQU IMMMODE_MG014 ; IMM: DRIVER MODE: IMMMODE_[NONE|SPP|MG014]
IMM0BASE .EQU LPT0BASE ; IMM 0: BASE I/O ADDRESS OF PPI FOR IMM
IMM1BASE .EQU LPT1BASE ; IMM 1: BASE I/O ADDRESS OF PPI FOR IMM
;
SYQENABLE .EQU FALSE ; SYQ: ENABLE IMM DISK DRIVER (SYQ.ASM)
SYQCNT .EQU 1 ; SYQ: NUMBER OF SYQ DEVICES (1-2)
SYQTRACE .EQU 1 ; SYQ: TRACE LEVEL (0=NO,1=ERRORS,2=ALL)
SYQMODE .EQU IMMMODE_MG014 ; SYQ: DRIVER MODE: SYQMODE_[NONE|SPP|MG014]
SYQ0BASE .EQU LPT0BASE ; SYQ 0: BASE I/O ADDRESS OF PPI FOR SYQ
SYQ1BASE .EQU LPT1BASE ; SYQ 1: BASE I/O ADDRESS OF PPI FOR SYQ
;
PIO_4P .EQU FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR ECB 4P BOARD
PIO_ZP .EQU FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR ECB ZILOG PERIPHERALS BOARD (PIO.ASM)
PIO_SBC .EQU FALSE ; PIO: ENABLE PARALLEL PORT DRIVER FOR 8255 CHIP
;
UFENABLE .EQU FALSE ; UF: ENABLE ECB USB FIFO DRIVER (UF.ASM)
;
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_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]
;
SPKENABLE .EQU FALSE ; SPK: ENABLE RTC LATCH IOBIT SOUND DRIVER (SPK.ASM)
;
DMAENABLE .EQU FALSE ; DMA: ENABLE DMA DRIVER (DMA.ASM)
DMABASE .EQU $E0 ; DMA: DMA BASE ADDRESS
DMAMODE .EQU DMAMODE_Z180 ; DMA: DMA MODE (NONE|ECB|Z180|Z280|RC|MBC|DUO)
;
YM2612ENABLE .EQU FALSE ; YM2612: ENABLE YM2612 DRIVER
VGMBASE .EQU $C0 ; YM2612: BASE ADDRESS FOR VGM BOARD (YM2612/SN76489s/CTC)

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 7372800 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 1 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -136,6 +137,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -27,7 +27,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 8000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -119,6 +119,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -166,6 +167,7 @@ UARTCFG .EQU DEFSERCFG ; UART: LINE CONFIG FOR UART PORTS
UARTCASSPD .EQU SER_300_8N1 ; UART: ECB CASSETTE UART DEFAULT SPEED
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO 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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_HILO ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_LOW ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 8000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -85,6 +85,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -125,6 +126,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -130,6 +131,7 @@ UARTCFG .EQU DEFSERCFG ; UART: LINE CONFIG FOR UART PORTS
UARTCASSPD .EQU SER_300_8N1 ; UART: ECB CASSETTE UART DEFAULT SPEED
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO ONBOARD UART
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
UARTCAS .EQU TRUE ; UART: AUTO-DETECT ECB CASSETTE UART
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU TRUE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -92,6 +92,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -132,6 +133,7 @@ UARTCFG .EQU DEFSERCFG ; UART: LINE CONFIG FOR UART PORTS
UARTCASSPD .EQU SER_300_8N1 ; UART: ECB CASSETTE UART DEFAULT SPEED
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO ONBOARD UART
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
UARTCAS .EQU TRUE ; UART: AUTO-DETECT ECB CASSETTE UART
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU TRUE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -96,6 +96,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -142,6 +143,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 12000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -136,6 +137,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 7372800 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 1 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -46,7 +46,7 @@ RTCIO .EQU $C0 ; RTC LATCH REGISTER ADR
KIOENABLE .EQU FALSE ; ENABLE ZILOG KIO SUPPORT
KIOBASE .EQU $80 ; KIO BASE I/O ADDRESS
;
CTCENABLE .EQU FALSE ; ENABLE ZILOG CTC SUPPORT
CTCENABLE .EQU TRUE ; ENABLE ZILOG CTC SUPPORT
CTCDEBUG .EQU FALSE ; ENABLE CTC DRIVER DEBUG OUTPUT
CTCBASE .EQU $88 ; CTC BASE I/O ADDRESS
CTCTIMER .EQU FALSE ; ENABLE CTC PERIODIC TIMER
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -136,6 +137,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -130,6 +131,7 @@ UARTCFG .EQU DEFSERCFG ; UART: LINE CONFIG FOR UART PORTS
UARTCASSPD .EQU SER_300_8N1 ; UART: ECB CASSETTE UART DEFAULT SPEED
UARTSBC .EQU FALSE ; UART: AUTO-DETECT SBC/ZETA/DUO 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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_57600_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_57600_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -136,6 +137,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 8000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -85,6 +85,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -125,6 +126,7 @@ 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
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
UARTCAS .EQU TRUE ; UART: AUTO-DETECT ECB CASSETTE UART
UARTMFP .EQU TRUE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU TRUE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 18432000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_115200_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_115200_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -90,6 +90,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -135,6 +136,7 @@ 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
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
UARTCAS .EQU FALSE ; UART: AUTO-DETECT ECB CASSETTE UART
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 14745600 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -88,6 +88,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -122,6 +123,7 @@ 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
UARTAUX .EQU FALSE ; UART: AUTO-DETECT AUX UART
UARTSBCFORCE .EQU FALSE ; UART: FORCE DETECTION OF SBC UART (FOR SIMH)
UARTCAS .EQU FALSE ; UART: AUTO-DETECT ECB CASSETTE UART
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 20000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 0 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -77,6 +77,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -112,6 +113,7 @@ 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 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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -30,7 +30,7 @@ CPUSPDCAP .EQU SPD_FIXED ; CPU SPEED CHANGE CAPABILITY SPD_FIXED|SPD_HILO
CPUSPDDEF .EQU SPD_HIGH ; CPU SPEED DEFAULT SPD_UNSUP|SPD_HIGH|SPD_LOW
CPUOSC .EQU 8000000 ; CPU OSC FREQ IN MHZ
INTMODE .EQU 2 ; INTERRUPTS: 0=NONE, 1=MODE 1, 2=MODE 2, 3=MODE 3 (Z280)
DEFSERCFG .EQU SER_38400_8N1 ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
DEFSERCFG .EQU SER_38400_8N1 | SER_RTS ; DEFAULT SERIAL LINE CONFIG (SEE STD.ASM)
;
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB (MUST MATCH YOUR HARDWARE!!!)
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB (MUST MATCH YOUR HARDWARE!!!)
@@ -88,6 +88,7 @@ PKDOSC .EQU 3000000 ; OSCILLATOR FREQ FOR PKD (IN HZ)
H8PENABLE .EQU FALSE ; ENABLES HEATH H8 FRONT PANEL
;
BOOTCON .EQU 0 ; BOOT CONSOLE DEVICE
SECCON .EQU $FF ; SECONDARY CONSOLE DEVICE
CRTACT .EQU FALSE ; ACTIVATE CRT (VDU,CVDU,PROPIO,ETC) AT STARTUP
VDAEMU .EQU EMUTYP_ANSI ; VDA EMULATION: EMUTYP_[TTY|ANSI]
VDAEMU_SERKBD .EQU $FF ; VDA EMULATION: SERIAL KBD UNIT #, OR $FF FOR HW KBD
@@ -123,6 +124,7 @@ 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
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
UARTMFP .EQU FALSE ; UART: AUTO-DETECT MF/PIC UART
UART4 .EQU FALSE ; UART: AUTO-DETECT 4UART UART

View File

@@ -18,9 +18,8 @@
; added to the RESET routine when using CH376.
;
; TODO:
; - Implement auto-recovery on error status.
;
CHUSB_FASTIO .EQU TRUE ; USE INIR/OTIR?
; - Implement auto-recovery on error status?
; - !!! Move CH_MODE to config variable !!!
;
; PORT OFFSETS FROM BASE PORT
;
@@ -33,6 +32,12 @@ CHTYP_NONE .EQU 0 ; NONE
CHTYP_375 .EQU 1 ; CH375
CHTYP_376 .EQU 2 ; CH376
;
; CH MODE MANAGEMENT
;
CH_MODE_UNK .EQU 0 ; CURRENT MODE UNKNOWN
CH_MODE_USB .EQU 1 ; CURRENT MODE = USB
CH_MODE_SD .EQU 2 ; CURRENT MODE = SD
;
; CH375/376 COMMANDS
;
CH_CMD_VER .EQU $01 ; GET IC VER
@@ -41,6 +46,7 @@ CH_CMD_EXIST .EQU $06 ; CHECK EXISTS
CH_CMD_MAXLUN .EQU $0A ; GET MAX LUN NUMBER
CH_CMD_PKTSEC .EQU $0B ; SET PACKETS PER SECTOR
CH_CMD_SETRETRY .EQU $0B ; SET RETRIES
CH_CMD_FILESIZE .EQU $0C ; GET FILE SIZE (376)
CH_CMD_MODE .EQU $15 ; SET USB MODE
CH_CMD_TSTCON .EQU $16 ; TEST CONNECT
CH_CMD_ABRTNAK .EQU $17 ; ABORT DEVICE NAK RETRIES
@@ -49,7 +55,16 @@ CH_CMD_RD6 .EQU $27 ; READ USB DATA (375 & 376)
CH_CMD_RD5 .EQU $28 ; READ USB DATA (375)
CH_CMD_WR5 .EQU $2B ; WRITE USB DATA (375)
CH_CMD_WR6 .EQU $2C ; WRITE USB DATA (376)
CH_CMD_WRREQDAT .EQU $2D ; WRITE REQUESTED DATA (376)
CH_CMD_SET_FN .EQU $2F ; SET FILENAME (376)
CH_CMD_DSKMNT .EQU $31 ; DISK MOUNT
CH_CMD_FOPEN .EQU $32 ; FILE OPEN (376)
CH_CMD_FCREAT .EQU $34 ; FILE CREATE (376)
CH_CMD_BYTE_LOC .EQU $39 ; BYTE LOCATE
CH_CMD_BYTERD .EQU $3A ; BYTE READ
CH_CMD_BYTERDGO .EQU $3B ; BYTE READ GO
CH_CMD_BYTEWR .EQU $3C ; BYTE WRITE
CH_CMD_BYTEWRGO .EQU $3D ; BYTE WRITE GO
CH_CMD_DSKCAP .EQU $3E ; DISK CAPACITY
CH_CMD_AUTOSET .EQU $4D ; USB AUTO SETUP
CH_CMD_DSKINIT .EQU $51 ; DISK INIT
@@ -129,6 +144,8 @@ CH_INIT2:
LD A,(IY+CH_IOBASE) ; GET IO BASE ADDRES
CALL PRTHEXBYTE ; DISPLAY IT
;
XOR A ; UNKNOWN MODE
LD (CH_MODE),A ; SAVE IT
;CALL CH_FLUSH ; FLUSH DEVICE OUTPUT QUEUE
CALL CH_RESET ; FULL CH37X RESET
CALL CH_DETECT ; DETECT CHIP PRESENCE
@@ -347,18 +364,63 @@ CH_GETVER:
CALL CH_RD ; GET VERSION BYTE
RET ; DONE
;
; SET MODE TO VALUE IN A
; AVOID CHANGING MODES IF CURRENT MODE = NEW MODE
; THE CH376 DOES NOT SEEM TO MAINTAIN SEPARATE OPERATING CONTEXTS FOR
; THE USB AND SD DEVICES. IF BOTH ARE IN OPERATION, THEN A MODE
; SWITCH REQUIRES A COMPLETE REINITIALIZATION OF THE REQUESTED
; DEVICE.
;
CH_SETMODE:
PUSH BC ; SAVE BC
PUSH DE ; SAVE DE
PUSH HL ; SAVE HL
;PRTS("\r\nSETMODE:$") ; *DEBUG*
LD L,A ; SAVE REQUESTED MODE
LD A,(CH_MODE) ; GET CURRENT MODE
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP L ; COMPARE
JR Z,CH_SETMODE_Z ; IF EQUAL, DONE
;
; NEED TO CHANGE MODES
LD A,L ; GET REQUESTED MODE
CP CH_MODE_USB ; USB?
JR Z,CH_SETMODE_USB ; IF SO, DO IT
CP CH_MODE_SD ; SD?
JR Z,CH_SETMODE_SD ; IF SO, DO IT
OR $FF ; SIGNAL ERROR
JR CH_SETMODE_Z ; BAIL OUT
;
CH_SETMODE_USB:
CALL CHUSB_RESET ; FULL USB STACK RESET
JR CH_SETMODE_Z ; MOVE ON
;
CH_SETMODE_SD:
CALL CHSD_RESET ; FULL SD STACK RESET
JR CH_SETMODE_Z ; MOVE ON
;
CH_SETMODE_Z:
POP HL ; RECOVER HL
POP DE ; RECOVER DE
POP BC ; RECOVER BC
RET ; DONE
;
;
CH_STR_NOHW .TEXT " NOT PRESENT$"
CH_STR_UPGRADE .TEXT " !!!UPGRADE REQUIRED!!!$"
;
CH_STR_375 .TEXT "CH375$"
CH_STR_376 .TEXT "CH376$"
CH_MODE .DB CH_MODE_UNK
;
CH_STR_NOHW .TEXT " NOT PRESENT$"
;
CH_STR_375 .TEXT "CH375$"
CH_STR_376 .TEXT "CH376$"
;
;==================================================================================================
; CH375/376 USB SUB-DRIVER
;==================================================================================================
;
CHUSB_FASTIO .EQU TRUE ; USE INIR/OTIR?
;
; CHUSB DEVICE STATUS
;
CHUSB_STOK .EQU 0
@@ -368,7 +430,7 @@ CHUSB_STIOERR .EQU -3
CHUSB_STTO .EQU -4
CHUSB_STNOTSUP .EQU -5
;
; CH DEVICE CONFIGURATION
; CHUSB DEVICE CONFIGURATION
;
CHUSB_CFGSIZ .EQU 12 ; SIZE OF USB CFG TBL ENTRIES
;
@@ -481,6 +543,10 @@ CHUSB_DEFMED:
;
;
CHUSB_READ:
LD A,CH_MODE_USB ; REQUEST USB MODE
CALL CH_SETMODE ; DO IT
JP NZ,CHUSB_CMDERR ; HANDLE ERROR
;
CALL HB_DSKREAD ; HOOK HBIOS DISK READ SUPERVISOR
LD (CHUSB_DSKBUF),HL ; SAVE DISK BUFFER ADDRESS
LD A,CH_CMD_DSKRD ; DISK READ COMMAND
@@ -542,6 +608,10 @@ CHUSB_READ2:
;
;
CHUSB_WRITE:
LD A,CH_MODE_USB ; REQUEST USB MODE
CALL CH_SETMODE ; DO IT
JP NZ,CHUSB_CMDERR ; HANDLE ERROR
;
CALL HB_DSKWRITE ; HOOK HBIOS DISK WRITE SUPERVISOR
LD (CHUSB_DSKBUF),HL ; SAVE DISK BUFFER ADDRESS
LD A,CH_CMD_DSKWR ; DISK READ COMMAND
@@ -631,7 +701,7 @@ CHUSB_STATUS:
; RESET THE INTERFACE AND REDISCOVER MEDIA
;
CHUSB_RESET:
;PRTS("\n\rRESET:$") ; *DEBUG*
;PRTS("\n\rRES USB:$") ; *DEBUG*
;CALL CH_FLUSH ; DISCARD ANY GARBAGE
;CALL CH_RESET ; FULL CH37X RESET
;
@@ -656,6 +726,9 @@ CHUSB_RESET:
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CALL CH_NAP ; SMALL WAIT
;
LD A,CH_MODE_USB ; WE ARE NOW IN USB MODE
LD (CH_MODE),A ; SAVE IT
;
; INITIALIZE DISK
LD B,24 ; TRY A FEW TIMES
@@ -671,29 +744,28 @@ CHUSB_RESET1:
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $14 ; SUCCESS?
JR Z,CHUSB_RESET2 ; IF SO, CONTINUE
;JR Z,CHUSB_RESET1A ; IF SO, CHECK READY
JR Z,CHUSB_RESET1A ; IF SO, CHECK READY
CP $16 ; NO MEDIA
JP Z,CHUSB_NOMEDIA ; HANDLE IT
CALL CH_NAP ; SMALL DELAY
DJNZ CHUSB_RESET1 ; LOOP AS NEEDED
JP CHUSB_TO ; HANDLE TIMEOUT
;;;;
;;;CHUSB_RESET1A:
;;; CALL CHUSB_DSKRES ; DISK RESET
;;; CP $14 ; GOOD?
;;; JR Z,CHUSB_RESET2
;;; CALL CHUSB_DSKRDY ; CHECK IF DISK READY
;;; CP $14 ; GOOD?
;;; JR Z,CHUSB_RESET2 ; IF SO, MOVE ON
;;; DJNZ CHUSB_RESET1 ; KEEP TRYING
;
CHUSB_RESET1A:
;CALL CHUSB_DSKRES ; DISK RESET
;CP $14 ; GOOD?
;JR Z,CHUSB_RESET2
;CALL CHUSB_DSKRDY ; CHECK IF DISK READY
;CP $14 ; GOOD?
;JR Z,CHUSB_RESET2 ; IF SO, MOVE ON
;DJNZ CHUSB_RESET1 ; KEEP TRYING
;
CHUSB_RESET2:
; USE OF CH376 DISK_MOUNT COMMAND SEEMS TO IMPROVE
; COMPATIBILITY WITH SOME OLDER USB THUMBDRIVES.
LD A,(IY+CH_TYPE) ; CH37X TYPE?
CP CHTYP_376 ; IS CH376?
CALL Z,CHUSB_DSKMNT ; IF SO, ISSUE MOUNT
CALL Z,CHUSB_DSKMNT ; IF SO, TRY MOUNT, IGNORE ERRS
;CALL CHUSB_AUTOSET ; *DEBUG*
;CALL CHUSB_TSTCON ; *DEBUG*
;CALL CHUSB_MAXLUN ; *DEBUG*
@@ -714,7 +786,7 @@ CHUSB_RESET2:
CHUSB_DEVICE:
LD D,DIODEV_CHUSB ; D := DEVICE TYPE
LD E,(IY+CH_DEV) ; E := PHYSICAL DEVICE NUMBER
LD C,%01110011 ; USB HARD DISK ATTRIBUTES
LD C,%00110011 ; USB HARD DISK ATTRIBUTES
LD H,(IY+CH_TYPE) ; H := MODE
LD L,(IY+CH_IOBASE) ; L := BASE I/O ADDRESS
XOR A ; SIGNAL SUCCESS
@@ -791,28 +863,34 @@ CHUSB_DSKMNT:
;CALL PRTHEXBYTE ; *DEBUG*
CP $14 ; SUCCESS?
RET NZ ; ABORT IF NOT
;
#IF FALSE
CALL CH_CMD_RD ; SEND READ COMMAND
CALL CH_RD ; GET LENGTH
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
LD B,A ; LOOP COUNTER
LD HL,HB_WRKBUF ; USE WORK BUFFER FOR DATA
DSKMNT1:
CHUSB_DSKMNT1:
CALL CH_RD ; GET A BYTE
LD (HL),A ; SAVE IT
INC HL ; BUMP BUF PTR
DJNZ DSKMNT1 ; LOOP FOR ALL DATA
DJNZ CHUSB_DSKMNT1 ; LOOP FOR ALL DATA
;
;LD DE,HB_WRKBUF ; *DEBUG*
;CALL DUMP_BUFFER ; *DEBUG*
;
;CALL CHUSB_PRTPREFIX ; PRINT DEVICE PREFIX
;LD HL,HB_WRKBUF + 8
;LD B,28
DSKMNT2:
;LD A,(HL)
;INC HL
;CALL COUT
;DJNZ DSKMNT2
CALL CHUSB_PRTPREFIX ; PRINT DEVICE PREFIX
LD HL,HB_WRKBUF + 8
LD B,28
CHUSB_DSKMNT2:
LD A,(HL)
INC HL
CALL COUT
DJNZ CHUSB_DSKMNT2
#ENDIF
;
XOR A
RET
;
; PERFORM DISK SIZE
@@ -1081,17 +1159,30 @@ CHUSB_STR_ST_MAP:
CHUSB_STR_STOK .TEXT "OK$"
CHUSB_STR_STNOMEDIA .TEXT "NO MEDIA$"
CHUSB_STR_STCMDERR .TEXT "COMMAND ERROR$"
CHUSB_STR_STIOERR .TEXT "IO ERROR$"
CHUSB_STR_STIOERR .TEXT "IO ERROR$"
CHUSB_STR_STTO .TEXT "TIMEOUT$"
CHUSB_STR_STNOTSUP .TEXT "NOT SUPPORTED$"
CHUSB_STR_STUNK .TEXT "UNKNOWN ERROR$"
;
;==================================================================================================
; CH375/376 SD CARD SUB-DRIVER
;==================================================================================================
;
; CH DEVICE CONFIGURATION
#DEFINE CHSD_IMGFILE "DISK.IMG"
;
CHSD_FASTIO .EQU TRUE ; USE INIR/OTIR?
;
; CHUSB DEVICE STATUS
;
CHSD_STOK .EQU 0
CHSD_STNOMEDIA .EQU -1
CHSD_STCMDERR .EQU -2
CHSD_STIOERR .EQU -3
CHSD_STTO .EQU -4
CHSD_STNOTSUP .EQU -5
CHSD_STNOFILE .EQU -6
;
; CHSD DEVICE CONFIGURATION
;
CHSD_CFGSIZ .EQU 12 ; SIZE OF USB CFG TBL ENTRIES
;
@@ -1144,36 +1235,581 @@ CHSD_INIT:
INC A ; BUMP TO NEXT UNIT NUM TO ASSIGN
LD (CHSD_DEVNUM),A ; SAVE IT
;
CALL NEWLINE ; FORMATTING
PRTS("CHSD$") ; LABEL FOR IO ADDRESS
LD A,(IY+CH_DEV) ; GET DEVICE NUM
CALL PRTDECB ; PRINT IT
CALL PC_COLON ; FORMATTING
; ADD UNIT TO GLOBAL DISK UNIT TABLE
LD BC,CHSD_FNTBL ; BC := FUNC TABLE ADR
PUSH IY ; CFG ENTRY POINTER
POP DE ; COPY TO DE
CALL DIO_ADDENT ; ADD ENTRY TO GLOBAL DISK DEV TABLE
;
CALL CHSD_RESET ; RESET & DISCOVER MEDIA
#IF (CHSDTRACE <= 1)
CALL NZ,CHSD_PRTSTAT
#ENDIF
RET NZ ; ABORT ON FAILURE
;
; START PRINTING DEVICE INFO
CALL CHSD_PRTPREFIX ; PRINT DEVICE PREFIX
;
; PRINT STORAGE CAPACITY (BLOCK COUNT)
PRTS(" BLOCKS=0x$") ; PRINT FIELD LABEL
LD A,CHSD_MEDCAP ; OFFSET TO CAPACITY FIELD
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
CALL LD32 ; GET THE CAPACITY VALUE
CALL PRTHEX32 ; PRINT HEX VALUE
;
; PRINT STORAGE SIZE IN MB
PRTS(" SIZE=$") ; PRINT FIELD LABEL
LD B,11 ; 11 BIT SHIFT TO CONVERT BLOCKS --> MB
CALL SRL32 ; RIGHT SHIFT
CALL PRTDEC32 ; PRINT DWORD IN DECIMAL
PRTS("MB$") ; PRINT SUFFIX
;
XOR A ; SIGNAL SUCCESS
RET
;
; DRIVER FUNCTION TABLE
;
CHSD_FNTBL:
.DW CHSD_STATUS
.DW CHSD_RESET
.DW CHSD_SEEK
.DW CHSD_READ
.DW CHSD_WRITE
.DW CHSD_VERIFY
.DW CHSD_FORMAT
.DW CHSD_DEVICE
.DW CHSD_MEDIA
.DW CHSD_DEFMED
.DW CHSD_CAP
.DW CHSD_GEOM
#IF (($ - CHSD_FNTBL) != (DIO_FNCNT * 2))
.ECHO "*** INVALID CHSD FUNCTION TABLE ***\n"
#ENDIF
;
CHSD_VERIFY:
CHSD_FORMAT:
CHSD_DEFMED:
SYSCHKERR(ERR_NOTIMPL) ; NOT IMPLEMENTED
RET
;
;
;
CHSD_READ:
LD A,CH_MODE_SD ; REQUEST SD MODE
CALL CH_SETMODE ; DO IT
JP NZ,CHSD_CMDERR ; HANDLE ERROR
;
CALL HB_DSKREAD ; HOOK HBIOS DISK READ SUPERVISOR
LD (CHSD_DSKBUF),HL ; SAVE DISK BUFFER ADDRESS
CALL CHSD_RWSTART ; SET LBA OFFSET
RET NZ
;
;PRTS("\n\rREAD:$") ; *DEBUG*
LD A,CH_CMD_BYTERD ; BYTE READ
CALL CH_CMD ; SEND COMMAND
CALL CH_NAP
LD A,0 ; LSB
CALL CH_WR ; SEND IT
LD A,2 ; MSB
CALL CH_WR ; SEND IT
CALL CH_POLL ; GET RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $1D ; DATA READY TO READ?
JP NZ,CHSD_IOERR ; HANDLE I/O ERROR
;
LD HL,(CHSD_DSKBUF)
CHSD_READ1:
CALL CH_CMD_RD ; SEND READ USB DATA CMD
CALL CH_RD ; GET DATA LENGTH
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
;
#IF (CHSD_FASTIO)
LD B,A ; BYTE COUNT TO READ
LD C,(IY+CH_IOBASE) ; BASE PORT
INIR ; DO IT FAST
#ELSE
LD B,A ; SAVE IT
CHSD_READ2:
CALL CH_RD ; GET DATA BYTE
LD (HL),A ; SAVE IN BUFFER
INC HL ; INC BUF PTR
DJNZ CHSD_READ2 ; LOOP TILL DONE W/ ALL BYTES
#ENDIF
;
LD A,CH_CMD_BYTERDGO ; BYTE READ GO COMMAND
CALL CH_CMD ; SEND IT
CALL CH_NAP
CALL CH_POLL ; GET RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $1D ; MORE?
JR Z,CHSD_READ1 ; IF SO, GET MORE
CP $14 ; GOOD FINISH?
JP NZ,CHSD_IOERR ; HANDLE ERROR
;
; INCREMENT LBA
PUSH HL ; SAVE HL
LD A,CHSD_LBA ; LBA OFFSET
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
CALL INC32HL ; INCREMENT THE VALUE
POP HL ; RESTORE HL
;
XOR A ; SIGNAL SUCCESS
RET
;
;
;
CHSD_WRITE:
LD A,CH_MODE_SD ; REQUEST SD MODE
CALL CH_SETMODE ; DO IT
JP NZ,CHSD_CMDERR ; HANDLE ERROR
;
CALL HB_DSKWRITE ; HOOK HBIOS DISK WRITE SUPERVISOR
LD (CHSD_DSKBUF),HL ; SAVE DISK BUFFER ADDRESS
CALL CHSD_RWSTART ; SET LBA OFFSET'
RET NZ
;
;PRTS("\n\rWRITE:$") ; *DEBUG*
LD A,CH_CMD_BYTEWR ; BYTE WRITE
CALL CH_CMD ; SEND COMMAND
LD A,0 ; LSB
CALL CH_WR ; SEND IT
LD A,2 ; MSB
CALL CH_WR ; SEND IT
CALL CH_POLL ; GET RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $1E ; DATA READY TO GO?
JP NZ,CHSD_IOERR ; HANDLE I/O ERROR
;
LD HL,(CHSD_DSKBUF)
CHSD_WRITE1:
LD A,CH_CMD_WRREQDAT ; WRITE REQUESTED DATA CMD
CALL CH_CMD ; SEND IT
CALL CH_RD ; GET DATA LENGTH
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
;
#IF (CHSD_FASTIO)
LD B,A ; BYTE COUNT TO WRITE
LD C,(IY+CH_IOBASE) ; BASE PORT
OTIR ; DO IT FAST
#ELSE
LD B,A ; SAVE IT
CHSD_WRITE2:
CALL CH_WR ; WRITE DATA BYTE
LD (HL),A ; SAVE IN BUFFER
INC HL ; INC BUF PTR
DJNZ CHSD_WRITE2 ; LOOP TILL DONE W/ ALL BYTES
#ENDIF
;
LD A,CH_CMD_BYTEWRGO ; BYTE WRITE GO COMMAND
CALL CH_CMD ; SEND IT
CALL CH_NAP
CALL CH_POLL ; GET RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $1E ; MORE?
JR Z,CHSD_WRITE1 ; IF SO, SEND MORE
CP $14 ; GOOD FINISH?
JP NZ,CHSD_IOERR ; HANDLE ERROR
;
; INCREMENT LBA
PUSH HL ; SAVE HL
LD A,CHSD_LBA ; LBA OFFSET
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
CALL INC32HL ; INCREMENT THE VALUE
POP HL ; RESTORE HL
;
XOR A ; SIGNAL SUCCESS
RET
;
; SEEK TO CURRENT LBA
;
CHSD_RWSTART:
;PRTS("\n\rRWST:$") ; *DEBUG*
LD A,CH_CMD_BYTE_LOC ; BYTE LOCATE COMMAND (SEEK)
CALL CH_CMD ; SEND IT
;
; GET CURRENT LBA OFFSET
LD A,CHSD_LBA ; OFFSET TO CAPACITY FIELD
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
CALL LD32 ; OFFSET = DE:HL
;
; CONVERT OFFSET FROM LBA TO BYTE
LD B,9
CHSD_RWSTART1:
SLA L
RL H
RL E
RL D
DJNZ CHSD_RWSTART1
;CALL PRTHEX32 ; *DEBUG*
;
; SEND THE BYTE OFFSET (LSB FIRST)
LD A,L
CALL CH_WR
LD A,H
CALL CH_WR
LD A,E
CALL CH_WR
LD A,D
CALL CH_WR
;
CALL CH_POLL ; WAIT FOR RESPONSE
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $14 ; CHECK RESULT
JP NZ,CHUSB_CMDERR ; HANDLE CMD ERROR
;
XOR A
RET
;
;
;
CHSD_STATUS:
; RETURN UNIT STATUS
LD A,(IY+CHSD_STAT) ; GET STATUS OF SELECTED DEVICE
OR A ; SET FLAGS
RET ; AND RETURN
;
; RESET THE INTERFACE AND REDISCOVER MEDIA
;
CHSD_RESET:
;PRTS("\n\rRES SD:$") ; *DEBUG*
;
; ACTIVATE SD MODE
LD A,CH_CMD_MODE ; SET MODE COMMAND
CALL CH_CMD ; SEND IT
LD A,3 ; SD MODE
CALL CH_WR ; SEND IT
CALL CH_NAP ; SMALL WAIT
CALL CH_RD ; GET RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CALL CH_NAP ; SMALL WAIT
;
LD A,CH_MODE_SD ; WE ARE NOW IN SD MODE
LD (CH_MODE),A ; SAVE IT
;
CALL CHSD_DSKMNT ; MOUNT DISK
RET NZ
;
; OPEN DISK IMAGE FILE
LD DE,CHSD_FNAME
CALL CHSD_FOPEN
RET NZ
;
; GET FILESIZE
CALL CHSD_FILESIZE
RET NZ
;
; SET STATUS AND RETURN
XOR A ; CLEAR STATUS
LD (IY+CHSD_STAT),A ; RECORD STATUS
OR A ; SET FLAGS
RET ; AND RETURN
;
;
;
CHSD_DEVICE:
LD D,DIODEV_CHSD ; D := DEVICE TYPE
LD E,(IY+CH_DEV) ; E := PHYSICAL DEVICE NUMBER
LD C,%00110010 ; SD HARD DISK ATTRIBUTES
LD H,(IY+CH_TYPE) ; H := MODE
LD L,(IY+CH_IOBASE) ; L := BASE I/O ADDRESS
XOR A ; SIGNAL SUCCESS
RET
;
; CHSD_GETMED
;
CHSD_MEDIA:
LD A,E ; GET FLAGS
OR A ; SET FLAGS
JR Z,CHSD_MEDIA1 ; JUST REPORT CURRENT STATUS AND MEDIA
CALL CHSD_RESET ; RESET CHSD INTERFACE
;
CHSD_MEDIA1:
LD A,(IY+CHSD_STAT) ; GET STATUS
OR A ; SET FLAGS
LD D,0 ; NO MEDIA CHANGE DETECTED
LD E,MID_HD ; ASSUME WE ARE OK
RET Z ; RETURN IF GOOD INIT
LD E,MID_NONE ; SIGNAL NO MEDIA
LD A,ERR_NOMEDIA ; NO MEDIA ERROR
OR A ; SET FLAGS
RET ; AND RETURN
;
;
;
CHSD_SEEK:
BIT 7,D ; CHECK FOR LBA FLAG
CALL Z,HB_CHS2LBA ; CLEAR MEANS CHS, CONVERT TO LBA
RES 7,D ; CLEAR FLAG REGARDLESS (DOES NO HARM IF ALREADY LBA)
LD (IY+CHSD_LBA+0),L ; SAVE NEW LBA
LD (IY+CHSD_LBA+1),H ; ...
LD (IY+CHSD_LBA+2),E ; ...
LD (IY+CHSD_LBA+3),D ; ...
XOR A ; SIGNAL SUCCESS
RET ; AND RETURN
;
;
;
CHSD_CAP:
LD A,(IY+CHSD_STAT) ; GET STATUS
PUSH AF ; SAVE IT
LD A,CHSD_MEDCAP ; OFFSET TO CAPACITY FIELD
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
CALL LD32 ; GET THE CURRENT CAPACITY INTO DE:HL
LD BC,512 ; 512 BYTES PER BLOCK
POP AF ; RECOVER STATUS
OR A ; SET FLAGS
RET
;
;
;
CHSD_GEOM:
; FOR LBA, WE SIMULATE CHS ACCESS USING 16 HEADS AND 16 SECTORS
; RETURN HS:CC -> DE:HL, SET HIGH BIT OF D TO INDICATE LBA CAPABLE
CALL CHSD_CAP ; GET TOTAL BLOCKS IN DE:HL, BLOCK SIZE TO BC
LD L,H ; DIVIDE BY 256 FOR # TRACKS
LD H,E ; ... HIGH BYTE DISCARDED, RESULT IN HL
LD D,16 | $80 ; HEADS / CYL = 16, SET LBA CAPABILITY BIT
LD E,16 ; SECTORS / TRACK = 16
RET ; DONE, A STILL HAS CHSD_CAP STATUS
;
; CH37X HELPER ROUTINES
;
;
; PERFORM DISK MOUNT
;
CHSD_DSKMNT:
;PRTS("\n\rMOUNT:$") ; *DEBUG*
LD A,CH_CMD_DSKMNT ; DISK QUERY
CALL CH_CMD ; DO IT
CALL CH_POLL ; WAIT FOR RESPONSE
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $82 ; NO DISK?
JP Z,CHSD_NOMEDIA ; HANDLE NO MEDIA ERROR
CP $14 ; SUCCESS?
JP NZ,CHSD_CMDERR ; HANDLE ERROR
;
#IF FALSE
CALL CH_CMD_RD ; SEND READ COMMAND
CALL CH_RD ; GET LENGTH
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
LD B,A ; LOOP COUNTER
LD HL,HB_WRKBUF ; USE WORK BUFFER FOR DATA
CHSD_DSKMNT1:
CALL CH_RD ; GET A BYTE
LD (HL),A ; SAVE IT
INC HL ; BUMP BUF PTR
DJNZ CHSD_DSKMNT1 ; LOOP FOR ALL DATA
;
;LD DE,HB_WRKBUF ; *DEBUG*
;CALL DUMP_BUFFER ; *DEBUG*
;
CALL CHSD_PRTPREFIX ; PRINT DEVICE PREFIX
LD HL,HB_WRKBUF + 8
LD B,28
CHSD_DSKMNT2:
LD A,(HL)
INC HL
CALL COUT
DJNZ CHSD_DSKMNT2
#ENDIF
;
XOR A
RET
;
; SET FILE NAME
;
CHSD_SETFNAME:
;PRTS("\n\rSETFNAME:$") ; *DEBUG*
LD A,CH_CMD_SET_FN ; SET FILE NAME COMMAND
CALL CH_CMD ; SEND IT
CALL CH_NAP
;CALL DELAY ; MAY NOT BE NEEDED
;CALL PC_SPACE ; *DEBUG*
CHSD_SETFNAME1:
;CALL DELAY
LD A,(DE) ; GET NEXT BYTE
INC DE ; BUMP POINTER
CALL CH_WR ; SEND IT
;CALL COUT ; *DEBUG*
OR A ; CHECK FOR NUL (EOS)
RET Z ; IF NUL, DONE
JR CHSD_SETFNAME1 ; SEND MORE CHARACTERS
;
; OPEN FILE
;
CHSD_FOPEN:
CALL CHSD_SETFNAME
;PRTS("\n\rFOPEN:$") ; *DEBUG*
LD A,CH_CMD_FOPEN ; FILE OPEN COMMAND
CALL CH_CMD ; SEND IT
CALL CH_POLL ; WAIT FOR RESULT
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEXBYTE ; *DEBUG*
CP $42 ; MISSING FILE?
JP Z,CHSD_NOFILE ; HANDLE ERROR
CP $14 ; SUCCESS?
JP NZ,CHSD_IOERR ; HANDLE ERROR
RET ; RETURN WITH ZF SET APPROPRIATELY
;
; GET FILE SIZE
;
CHSD_FILESIZE:
;PRTS("\n\rFSIZE:$")
LD A,CH_CMD_FILESIZE ; FILE SIZE COMMAND
CALL CH_CMD ; SEND IT
LD A,$68 ; REQUIRED CMD PARAMETER
CALL CH_WR ; SEND IT
CALL CH_NAP
LD A,CHSD_MEDCAP ; MEDIA CAPACITY OFFSET
CALL LDHLIYA ; HL := IY + A, REG A TRASHED
PUSH HL ; SAVE ADDRESS
CALL CH_RD
LD L,A
CALL CH_RD
LD H,A
CALL CH_RD
LD E,A
CALL CH_RD
LD D,A
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEX32 ; *DEBUG*
LD B,9 ; ROTATE 9 BITS FOR DIV 512
CHSD_FILESIZE1:
SRL D
RR E
RR H
RR L
DJNZ CHSD_FILESIZE1 ; LOOP TILL DONE
POP BC ; RECOVER ADDRESS TO BC
;CALL PC_SPACE ; *DEBUG*
;CALL PRTHEX32 ; *DEBUG*
CALL ST32 ; STORE IT
XOR A ; SIGNAL SUCCESS
RET ; AND DONE
;
; ERROR HANDLERS
;
;
CHSD_NOFILE:
LD A,CHSD_STNOFILE
JR CHSD_ERR
;
CHSD_NOMEDIA:
LD A,CHSD_STNOMEDIA
JR CHSD_ERR
;
CHSD_CMDERR:
LD A,CHSD_STCMDERR
JR CHSD_ERR
;
CHSD_IOERR:
LD A,CHSD_STIOERR
JR CHSD_ERR
;
CHSD_TO:
LD A,CHSD_STTO
JR CHSD_ERR
;
CHSD_NOTSUP:
LD A,CHSD_STNOTSUP
JR CHSD_ERR
;
CHSD_ERR:
LD (IY+CHSD_STAT),A ; SAVE NEW STATUS
;
CHSD_ERR2:
#IF (CHSDTRACE >= 2)
CALL CHSD_PRTSTAT
#ENDIF
OR A ; SET FLAGS
RET
;
;
;
CHSD_PRTERR:
RET Z ; DONE IF NO ERRORS
; FALL THRU TO CHSD_PRTSTAT
;
; PRINT FULL DEVICE STATUS LINE
;
CHSD_PRTSTAT:
PUSH AF
PUSH DE
PUSH HL
LD A,(IY+CHSD_STAT)
CALL CHSD_PRTPREFIX ; PRINT UNIT PREFIX
CALL PC_SPACE ; FORMATTING
CALL CHSD_PRTSTATSTR
POP HL
POP DE
POP AF
RET
;
; PRINT STATUS STRING
;
CHSD_PRTSTATSTR:
PUSH AF
PUSH DE
PUSH HL
LD A,(IY+CHSD_STAT)
NEG
LD HL,CHSD_STR_ST_MAP
ADD A,A
CALL ADDHLA
LD E,(HL)
INC HL
LD D,(HL)
CALL WRITESTR
POP HL
POP DE
POP AF
RET
;
; PRINT DIAGNONSTIC PREFIX
;
CHSD_PRTPREFIX:
PUSH AF
CALL NEWLINE
PRTS("CHSD$")
LD A,(IY+CH_DEV) ; GET CURRENT DEVICE NUM
CALL PRTDECB
CALL PC_COLON
POP AF
RET
CHSD_DEVNUM .DB 0 ; TEMP DEVICE NUM USED DURING INIT
;
;=============================================================================
; DATA STORAGE
;=============================================================================
;
CH_FWVER .DW 0,0 ; MMNNBBB (M=MAJOR, N=MINOR, B=BUILD)
CHSD_DEVNUM .DB 0 ; TEMP DEVICE NUM USED DURING INIT
CHSD_DSKBUF .DW 0
;
CHSD_IOFNADR .DW 0 ; PENDING IO FUNCTION ADDRESS
CHSD_FNAME .DB "/", CHSD_IMGFILE, 0
;
CHSD_DSKBUF .DW 0
CHSD_STR_ST_MAP:
.DW CHSD_STR_STOK
.DW CHSD_STR_STNOMEDIA
.DW CHSD_STR_STCMDERR
.DW CHSD_STR_STIOERR
.DW CHSD_STR_STTO
.DW CHSD_STR_STNOTSUP
.DW CHSD_STR_STNOFILE
;
CHSD_DSKSTAT .DB 0
CHSD_ERRCODE .DW 0,0
CHSD_CSDBUF .FILL 16,0
;
CHSD_CMD .DB 0
;
CHSD_TIMEOUT .DW $0000 ; FIX: MAKE THIS CPU SPEED RELATIVE
CHSD_STR_STOK .TEXT "OK$"
CHSD_STR_STNOMEDIA .TEXT "NO MEDIA$"
CHSD_STR_STCMDERR .TEXT "COMMAND ERROR$"
CHSD_STR_STIOERR .TEXT "IO ERROR$"
CHSD_STR_STTO .TEXT "TIMEOUT$"
CHSD_STR_STNOTSUP .TEXT "NOT SUPPORTED$"
CHSD_STR_STNOFILE .TEXT "MISSING "
.TEXT CHSD_IMGFILE
.TEXT " FILE$"
CHSD_STR_STUNK .TEXT "UNKNOWN ERROR$"

View File

@@ -25,7 +25,7 @@ CTC_TIM256CFG .EQU %00110111 ; CTC TIMER/256 MODE CONFIG
; DETERMINE WHICH CHANNEL CAUSED AN INTERRUPT.
;==================================================================================================
;
#IF (INTMODE != 2)
#IF (CTCTIMER & (INTMODE != 2))
.ECHO "*** WARNING: CTC TIMER DISABLED -- INTMODE 2 REQUIRED!!!\n"
#ENDIF
;

View File

@@ -71,6 +71,8 @@
;
#DEFINE HBIOS
;
SUPCTS .EQU FALSE ; SUPPRESS CTS DURING HBIOS BOOT
;
; MAKE SURE EXACTLY ONE OF ROMBOOT, APPBOOT, IMGBOOT IS DEFINED.
;
MODCNT .EQU 0
@@ -991,7 +993,8 @@ HBX_BUF_END .EQU $
.DW 0 ; HB_DSTADR: BNKCPY DESTINATION ADDRESS
.DB BID_USR ; HB_DSTBNK: BNKCPY DESTINATION BANK ID
.DW 0 ; HB_CPYLEN: BNKCPY LENGTH
.FILL 4,0 ; FILLER, RESERVED FOR FUTURE HBIOS USE
.DW 0 ; RESERVED FOR OPTIONAL TICK CTR, PLATFORM DEPENDENT
.DW 0 ; RESERVED FOR FUTURE HBIOS USE
.DB 0 ; SHADOW VALUE FOR RTC LATCH PORT
.DB $FE ; HB_LOCK: HBIOS MUTEX LOCK
JP HBX_INVOKE ; HB_INVOKE: FIXED ADR ENTRY FOR HBX_INVOKE (ALT FOR RST 08)
@@ -1114,12 +1117,17 @@ BOOTWAIT:
JR NZ,BOOTWAIT
#ENDIF
;
;#IF ((PLATFORM == PLT_MBC) | (PLATFORM == PLT_SBC))
; INITIALIZE RTC LATCH BYTE
; EARLY RTC LATCH BYTE INITIALIZATION
; FOR SOME PLATFORMS THIS CONTROLS HI/LO SPEED CIRCUIT
LD A,(RTCDEFVAL) ; GET DEFAULT VALUE
; NOTE: WE WANT TO USE (RTCDEFVAL) HERE, BUT THE Z2 MEMORY
; MANAGER STARTS UP WITH THE FIRST 16K OF ROM MAPPED TO ALL
; 4 16K BANKS OF CPU SPACE. SO, IF RTCDEVFAL IS LOCATED AFTER
; PAST 16K, WE DON'T HAVE ACCESS TO IT. FOR NOW, WE JUST USE
; RTCDEF WHICH IS SUBOPTIMAL, BUT PROBABLY DOES NOT CAUSE ANY
; PROBLEMS.
;LD A,(RTCDEFVAL) ; GET DEFAULT VALUE
LD A,RTCDEF ; DEFAULT VALUE
OUT (RTCIO),A ; SET IT
;#ENDIF
;
#IF (PLATFORM == PLT_N8)
LD A,N8_DEFACR ; ENSURE N8 ACR
@@ -1141,7 +1149,9 @@ BOOTWAIT:
XOR A ; LED IS INVERTED, TURN IT ON
#ENDIF
#IF (LEDMODE == LEDMODE_RTC)
LD A,(RTCDEFVAL) ; DEFAULT LATCH VALUE
; CAN'T USE (RTCDEFVAL) YET, SEE COMMENTS ABOVE
;LD A,(RTCDEFVAL) ; DEFAULT LATCH VALUE
LD A,RTCDEF ; DEFAULT LATCH VALUE
OR %00000001 ; LED 0 ON
#ENDIF
OUT (LEDPORT),A
@@ -1347,6 +1357,41 @@ Z280_INITZ:
OUT (FPLED_IO),A
#ENDIF
;
; Z180 MINI-ITX MADNESS TO INITIALIZE THE PPIO. WE HAVE THE MAIN RAM AT
; $8000 AND ROM AT $0 AT THIS POINT AND THE Z180 MMU SET UP. NOW
; GET THE 82C55 PROGRAMMED.
;
#IF (PLATFORM == PLT_EPITX)
; THE 82C55 IS BRAINDEAD AND FLIPS OUTPUT LINES TO 0 WHEN WE SET
; THE MODE. WE BOOT WITH THE ROM ENABLED BUT THE RESET WILL ENABLE
; LOW RAM. SOME MENTAL BACKFLIPS REQUIRED TO MAKE THIS WORK
LD HL,BOOTFLIP
LD DE,$8000
LD BC,$10
LDIR
JP $8000
;
BOOTFLIP:
; SET THE MODE. ALSO CLEARS ALL THE OUTPUT BITS SO WE BLIP THE
; I2C, KEYBOARD ETC BUT NOBODY WILL CARE. HOWEVER WE ALSO FLIP
; TO ALL RAM MODE HENCE THIS IS EXECUTED HIGH
; A OUT B IN C HIGH IN C LOW IN
LD A,$8B
OUT ($43),A
LD A,$FF
OUT ($40),A
JP ROMRESUME
;
ROMRESUME:
; THIS WILL GLITCH EXTRAM ON SO WE MUST NOW BE IN ROM
LD A,$8A ; C LOW NOW OUTPUT
OUT ($43),A
LD A,$FF
OUT ($42),A ; EXTRAM OFF, RAM BACK IN, SPI 7
; AND DONE. MODE REMAINS THIS WAY FOREVER
;
#ENDIF
;
; WE USE THE TWO BYTES IMMEDIATELY BELOW THE PROXY TO STORE A COUPLE
; VALUES TEMPORARILY BECAUSE WE MAY BE OPERATING IN ROM AT THIS POINT.
@@ -1432,11 +1477,15 @@ S100MON_SKIP:
LD A,(HB_CURBNK) ; GET HB_CURBNK
LD (HBX_LOC - 2),A ; ... AND SAVE TEMP FOR APPBNK
;
; THE RTCVAL FIELD OF THE PROXY DATA NEEDS TO BE INITIALIZED HERE
; BECAUSE IT CANNOT BE PRE-INITIALIZED (SEE COMMENTS ABOVE WHERE
; RTCVAL EQUATE IS DEFINED).
; WE CAN NOW DO THE REAL INITIALIZATION OF THE RTC LATCH BASED ON
; (RTCDEFVAL). AT THIS POINT WE SHOULD HAVE ACCESS TO THE ROM LOCATION
; WHERE RTCDEFVAL IS STORED AND THE PROXY IS INSTALLED IN UPPER RAM
; WHERE WE WILL STORE THE WORKING SHADOW COPY (HB_RTCVAL).
; SEE COMMENTS ABOVE REGARDING THE FUNKY WAY THAT THE RTCDEFVAL IS
; CREATED.
;
LD A,(RTCDEFVAL)
OUT (RTCIO),A ; SET IT
LD (HB_RTCVAL),A
;
#IFDEF TESTING
@@ -1599,51 +1648,43 @@ MBC_SINGLE:
;
#ENDIF
;
; IF ALREADY EXECUTING IN RAM, BYPASS RAM BANK INSTALLATION
;
LD A,(HB_RAMFLAG)
OR A
JR NZ,HB_START1
;
; IF BID_BOOT AND BID_BIOS ARE THE SAME, THEN IT IS NEVER APPROPRIATE
; TO COPY THE HBIOS IMAGE FROM BID_BOOT TO BID_BIOS. THIS IS TYPICALLY
; THE CASE FOR A ROMLESS SYSTEM.
;
#IF (BID_BOOT != BID_BIOS)
;
; INSTALL HBIOS IN RAM BANK
;
LD A,(HB_CURBNK)
;
; CHECK TO SEE IF WE ARE ALREADY RUNNING IN THE HBIOS
; BANK AND SKIP THE COPY IF SO (DON'T COPY OVER OURSELVES).
; THIS SITUATION OCCURS ON A ROMLESS STARTUP OR WHEN DOING A
; FULL RESTART OF A SYSTEM USING THE EXISTING HBIOS COPY.
CP BID_BIOS
JR Z,HB_START1
;
LD (HB_SRCBNK),A
LD A,BID_BIOS
LD (HB_DSTBNK),A
LD HL,0
LD DE,0
LD BC,$8000
#IF (MEMMGR == MM_Z280)
#IF (MEMMGR == MM_Z280)
CALL Z280_BNKCPY
#ELSE
#ELSE
CALL HBX_BNKCPY
#ENDIF
#ENDIF
;
; TRANSITION TO HBIOS IN RAM BANK
;
#IF (MEMMGR == MM_Z280)
#IF (MEMMGR == MM_Z280)
LD A,BID_BIOS
LD B,$10 ; FIRST SYSTEM PDR
CALL Z280_BNKSEL
JR HB_START1
#ELSE
#ELSE
LD A,BID_BIOS ; BIOS BANK ID
LD IX,HB_START1 ; EXECUTION RESUMES HERE
CALL HBX_BNKCALL ; CONTINUE IN RAM BANK, DO NOT RETURN
HALT ; WE SHOULD NOT COME BACK HERE!
#ENDIF
;
#ENDIF
;
HB_RAMFLAG .DB FALSE ; INITIALLY FALSE, SET TO TRUE BELOW AFTER RAM TRANSITION
;
; EXECUTION RESUMES HERE AFTER SWITCH TO RAM BANK
;
HB_START1: ; BNKCALL ARRIVES HERE, BUT NOW RUNNING IN RAM BANK
@@ -1857,11 +1898,13 @@ HB_CPU1:
;
; CLEAR DISPATCH TABLE ENTRIES
;
XOR A ; ZERO
LD (CIO_CNT),A ; CIO DEVICES
LD (DIO_CNT),A ; DIO DEVICES
LD (VDA_CNT),A ; VDA DEVICES
LD (SND_CNT),A ; SND DEVICES
XOR A ; ZERO
LD (CIO_CNT),A ; CIO DEVICES
LD (DIO_CNT),A ; DIO DEVICES
LD (VDA_CNT),A ; VDA DEVICES
LD (SND_CNT),A ; SND DEVICES
LD (RTC_DISPACT),A ; RTC DEVICE
LD (DSKY_DISPACT),A ; DSKY DEVICE
;
#IF (DSRTCENABLE)
CALL DSRTC_PREINIT
@@ -2060,7 +2103,7 @@ HB_CPU3:
LD A,(CB_CPUMHZ) ; CPU SPEED TO ACCUM AND INIT
CALL DELAY_INIT ; .. SPEED COMPENSATED DELAY
;
#IF (INTMODE == 2)
#IF ((INTMODE == 2) | ((INTMODE == 1) & (CPUFAM == CPU_Z180)))
; SETUP Z80 IVT AND INT MODE 2
LD A,HBX_IVT >> 8 ; SETUP HI BYTE OF IVT ADDRESS
LD I,A ; ... AND PLACE IT IN I REGISTER
@@ -2071,7 +2114,9 @@ HB_CPU3:
OUT0 (Z180_IL),A ; ... AND PLACE IN Z180 IL REGISTER
#ENDIF
#IF (INTMODE == 2)
IM 2 ; SWITCH TO INT MODE 2
#ENDIF
#ENDIF
;
#IF (INTMODE == 3)
@@ -2300,12 +2345,15 @@ HB_BOOTDLY:
JR C,HB_CONRDY ; IF TOO HIGH, JUST USE FAILSAFE
LD A,BOOTCON ; GET REQUESTED CONSOLE DEV
LD (CB_CONDEV),A ; SAVE IT
;
HB_CONRDY:
;
#IF (SUPCTS)
;
; MOST SERIAL PORTS ARE CONFIGURED WITH HARDWARE FLOW CONTROL ENABLED.
; IF THERE IS A PROBLEM WITH THE RTS SIGNAL, THEN OUTPUT TO THE CONSOLE
; IF THERE IS A PROBLEM WITH THE CTS SIGNAL, THEN OUTPUT TO THE CONSOLE
; WILL BE STALLED WHICH CAN LEAD A USER TO THINK THE SYSTEM IS TOTALLY
; DEAD WHEN, IN FACT, IT IS JUST WAITING FOR RTS TO BE ASSERTED. ALSO,
; DEAD WHEN, IN FACT, IT IS JUST WAITING FOR CTS TO BE ASSERTED. ALSO,
; IF THE USER IS BOOTING TO A CRT DEVICE AND DISCONNECTS THE CONSOLE
; SERIAL PORT, THE SYSTEM WILL WAIT FOR RTS AND NEVER BOOT. SO, HERE
; WE SAVE THE ACTIVE CONSOLE CONFIGURATION, THEN TURN OFF HARDWARE
@@ -2315,16 +2363,18 @@ HB_CONRDY:
; RETRIEVE THE CONFIG FROM THE CONSOLE PORT
LD B,BF_CIOQUERY ; HBIOS QUERY CIO CONFIG
LD A,(CB_CONDEV) ; GET CONSOLE DEVICE
LD (HB_BOOTCON),A ; SAVE IT FOR LATER
LD (HB_BOOTCONSAV),A ; SAVE IT FOR LATER
LD C,A ; BOOT CONSOLE TO C
CALL HB_DISPATCH ; INTERNAL HBIOS CALL
LD (HB_BOOTCFG),DE ; SAVE CONFIG
LD (HB_CONCFGSAV),DE ; SAVE CONFIG
RES 5,D ; CLEAR RTS BIT
LD B,BF_CIOINIT ; HBIOS CIO INIT
LD A,(CB_CONDEV) ; GET CONSOLE DEVICE
LD C,A ; BOOT CONSOLE TO C
CALL HB_DISPATCH ; INTERNAL HBIOS CALL
;
#ENDIF
;
#IF (WBWDEBUG == USEMIO) ; OUTPUT ANY CACHED DEBUG TEXT
LD HL,MIOOUTPTR
LD E,(HL)
@@ -2848,19 +2898,27 @@ HB_FP1:
;
HB_FP2:
; IF SEC SWITCH IS SET, WE WANT TO BUMP TO SECONDARY
; CRT OR SERIAL DEVICE. FOR NOW, WE ARE GOING TO CHEAT AND
; JUST INCREMENT THE CONSOLE DEVICE UNIT. THIS SHOULD WORK
; ASSUMING NORMAL ORDERING OF THE CHARACTER DEVICE UNITS.
; CRT OR SERIAL DEVICE. IF AN OVERRIDE IS SPECIFIED USING
; SECCON, USE THAT, OTHERWISE INCREMENT THE DEFAULT UNIT.
; THIS SHOULD WORK ASSUMING NORMAL ORDERING OF THE
; CHARACTER DEVICE UNITS.
LD A,B ; RECOVER SWITCH SETTINGS
AND SW_SEC ; TEST SEC BIT
JR Z,HB_FPZ ; IF NOT SET, THEN ALL DONE
;
; INCREMENT CONSOLE UNIT, BUT MAKE SURE IT DOES NOT EXCEED
; THE HIGHEST CHAR UNIT IN SYSTEM.
LD A,(CIO_CNT) ; GET CHAR UNIT COUNT
LD B,A ; MOVE TO B
LD A,SECCON ; GET SEC CONSOLE SETTING
CP $FF ; $FF MEANS USE INCREMENT
JR NZ,HB_FP3 ; BYPASS IF NOT $FF
;
; INCREMENT CONSOLE UNIT
LD A,(HB_NEWCON) ; GET NEW CONSOLE UNIT
INC A ; BUMP TO SECONDARY
;
HB_FP3:
; MAKE SURE NEW CONSOLE UNIT DOES NOT EXCEED THE HIGHEST
; CHAR UNIT IN SYSTEM.
CP B ; A (UNIT) >= B (CNT)?
JR NC,HB_FPZ ; ABORT IF UNIT TOO HIGH
LD (HB_NEWCON),A ; UPDATE NEW CONSOLE UNIT
@@ -2871,6 +2929,19 @@ HB_FPZ:
;
INITSYS3:
;
#IF (SUPCTS)
;
; RESTORE BOOT CONSOLE CONFIGURATION
;
CALL LDELAY ; ALLOW SERIAL PORT TO FLUSH
LD B,BF_CIOINIT ; HBIOS CIO INIT
LD A,(HB_BOOTCONSAV) ; ORIGINAL BOOT CONSOLE DEVICE
LD C,A ; BOOT CONSOLE TO C
LD DE,(HB_CONCFGSAV) ; SAVED ORIGINAL CONSOLE CFG
CALL HB_DISPATCH ; INTERNAL HBIOS CALL
;
#ENDIF
;
; IF WE ARE GOING TO SWITCH CONSOLES, IT IS IMPLEMENTED HERE. A
; MESSAGE IS PRINTED ON THE OLD CONSOLE INDICATING WHERE THE NEW
; CONSOLE IS AND THE NEW CONSOLE RECEIVES AN HBIOS BANNER.
@@ -2891,16 +2962,6 @@ INITSYS3:
CALL NZ,WRITESTR ; OUTPUT IF CONSOLE MOVED
;
INITSYS3A:
;
; RESTORE BOOT CONSOLE CONFIGURATION
;
CALL LDELAY ; ALLOW SERIAL PORT TO FLUSH
LD B,BF_CIOINIT ; HBIOS CIO INIT
LD A,(HB_BOOTCON) ; ORIGINAL BOOT CONSOLE DEVICE
LD C,A ; BOOT CONSOLE TO C
LD DE,(HB_BOOTCFG) ; SAVED ORIGINAL CONSOLE CFG
CALL HB_DISPATCH ; INTERNAL HBIOS CALL
;
CALL PRTSUM ; PRINT UNIT/DEVICE SUMMARY TABLE
;
#IF 0
@@ -5413,10 +5474,10 @@ HB_BADINTCNT .DB 0
LD A,L
RRCA
RRCA
CALL PRTHEXBYTE
PRTS("H: $")
;CALL PRTHEXBYTE
;PRTS("H: $")
CALL XREGDMP
CALL NEWLINE
;CALL CONTINUE
OR $FF ; SIGNAL INTERRUPT HANDLED
RET
@@ -7754,6 +7815,11 @@ HB_BOOTCON .DB 0 ; INITIAL BOOT CONSOLE SAVE AREA
HB_BOOTCFG .DW 0 ; CONSOLE CONFIG SAVE AREA
HB_NEWCON .DB 0 ; NEW CONSOLE TO SWITCH TO
;
#IF (SUPCTS)
HB_BOOTCONSAV .DB 0 ; INITIAL BOOT CONSOLE SAVE AREA
HB_CONCFGSAV .DW 0 ; CONSOLE CONFIG SAVE AREA
#ENDIF
;
HB_HASFP .DB 0 ; NON-ZERO MEANS FP EXISTS
;
HB_WRKBUF .FILL 512,0 ; INTERNAL DISK BUFFER

View File

@@ -153,6 +153,7 @@ PLT_Z80RETRO .EQU 15 ; Z80 RETRO COMPUTER
PLT_S100 .EQU 16 ; S100 COMPUTERS Z180 SYSTEM
PLT_DUO .EQU 17 ; DUODYNE Z80 SYSTEM
PLT_HEATH .EQU 18 ; HEATHKIT H8 Z80 SYSTEM
PLT_EPITX .EQU 19 ; Z180 MINI-ITX
;
; HBIOS GLOBAL ERROR RETURN VALUES
;

View File

@@ -357,6 +357,19 @@ SD_DO .EQU %00000001 ; DATA OUT (CARD -> CPU) MISO
SD_CINIT .EQU FALSE ; INITIALIZE OUTPUT PORT
SD_INVCS .EQU FALSE ; INVERT CS
#ENDIF
; FOR NOW WE JUST HOOK UP ONE UNIT. THERE ARE EIGHT PORTS FOR DIFFERENT
; THINGS BUT THIS WILL GET US GOING
#IF (SDMODE == SDMODE_EPITX) ; Z180 ITX - CSIO, 82C55 for CS
SD_DEVMAX .EQU 1 ; NUMBER OF PHYSICAL UNITS (SOCKETS)
SD_OPRREG .EQU $42 ; 82C55 PORT C, LOW 3 ARE \CS MUX
SD_OPRDEF .EQU %11111111 ; QUIESCENT STATE (ROM ENABLED)
SD_CS0 .EQU %11111000 ; SPI CHANNEL 0 (4 INPUTS, ROM EN, CHAN 0)
SD_CNTR .EQU Z180_CNTR
SD_TRDR .EQU Z180_TRDR
SD_IOBASE .EQU SD_OPRREG ; IOBASE
SD_INVCS .EQU FALSE ; INVERT CS
#ENDIF
;
#IF (SD_DEVCNT > SD_DEVMAX)
.ECHO "*** ERROR: SDCNT EXCEEDS MAXIMUM SUPPORTED BY INTERFACE!!!\n"
@@ -586,6 +599,22 @@ SD_INIT:
LD A,SD_IOBASE
CALL PRTHEXBYTE
#ENDIF
;
#IF (SDMODE == SDMODE_EPITX)
PRTS(" MODE=EPITX$")
#IF (SDCSIOFAST)
PRTS(" FAST$")
#ENDIF
PRTS(" OPR=0x$")
LD A,SD_OPRREG
CALL PRTHEXBYTE
PRTS(" CNTR=0x$")
LD A,SD_CNTR
CALL PRTHEXBYTE
PRTS(" TRDR=0x$")
LD A,SD_TRDR
CALL PRTHEXBYTE
#ENDIF
;
CALL SD_PROBE ; CHECK FOR HARDWARE
JR Z,SD_INIT00 ; CONTINUE IF PRESENT
@@ -847,7 +876,7 @@ SD_IO:
OR A ; SET FLAGS
RET Z ; ZERO SECTOR I/O, RETURN W/ E=0 & A=0
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
; CONSIDER CAPTURING CURRENT CNTR VALUE HERE AND USE IT
; IN SD_CSIO_DEF
@@ -1026,7 +1055,7 @@ SD_INITCARD:
CALL SD_CHKCD ; CHECK CARD DETECT
JP Z,SD_NOMEDIA ; Z=NO MEDIA, HANDLE IF SO
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
CALL SD_CSIO_DEF ; ENSURE CSIO AT DEFAULT SPEED
#ENDIF
;
@@ -1040,7 +1069,7 @@ SD_INITCARD1:
DJNZ SD_INITCARD1 ; LOOP AS NEEDED
;
; MAKE SURE WE FINISH SENDING
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
CALL SD_WAITTX ; WAIT FOR TE TO CLEAR
CALL DLY32 ; WAIT A BIT MORE FOR FINAL BIT
#ENDIF
@@ -1776,7 +1805,7 @@ SD_SETUP:
OUT (SD_PPIX),A
#ENDIF
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
; CSIO SETUP FOR Z180 CSIO
; LD A,2 ; DIV 80, 225KHZ @ 18MHZ CLK
LD A,6 ; DIV 1280, 14KHZ @ 18MHZ CLK
@@ -1789,7 +1818,7 @@ SD_SETUP:
OUT (SD_OPRREG),A
#ENDIF
;
#IF ((SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_DSD) | (SDMODE == SDMODE_PPI) | (SDMODE == SDMODE_MT))
#IF ((SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_DSD) | (SDMODE == SDMODE_PPI) | (SDMODE == SDMODE_MT) | (SDMODE == SDMODE_EPITX))
LD A,SD_OPRDEF
LD (SD_OPRVAL),A
OUT (SD_OPRREG),A
@@ -1894,10 +1923,16 @@ SD_SELECT1:
#IF (SD_DEVCNT > 1)
OR SD_CS1
#ENDIF
#ELSE
#IF (SDMODE == SDMODE_EPITX)
LD A,(SD_OPRVAL)
AND $F8
OR SD_CS0 ; WILL DO 1-7 LATER
#ELSE
LD A,(SD_OPRVAL) ; GET CURRENT OPRVAL BACK
OR SD_CS0
#ENDIF
#ENDIF
;
SD_SELECT2:
; ADJUST BIT(S) FOR INTERFACES USING INVERTED CS BITS
@@ -1921,7 +1956,7 @@ SD_SELECT2:
; DESELECT CARD
;
SD_DESELECT:
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
; DON'T REMOVE CS UNTIL WE ARE DONE SENDING!
CALL SD_WAITTX ; WAIT FOR TE TO CLEAR
;
@@ -1938,9 +1973,13 @@ SD_DESELECT:
LD A,(SD_OPRVAL)
#IF (((SDMODE == SDMODE_SC) | (SDMODE_MT)) & (SD_DEVCNT > 1))
AND ~(SD_CS0 | SD_CS1)
#ELSE
#if (SDMODE == SDMODE_EPITX)
OR 7 ; CHAN 7 IS USED FOR DESELECTS
#ELSE
AND ~SD_CS0
#ENDIF
#ENDIF
; ADJUST BIT(S) FOR INTERFACES USING INVERTED CS BITS
#IF ((SDMODE == SDMODE_PPI) | (SDMODE == SDMODE_UART) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_PIO) | (SDMODE == SDMODE_Z80R))
#IF ((SDMODE == SDMODE_SC) & (SD_DEVCNT > 1))
@@ -1953,9 +1992,9 @@ SD_DESELECT:
OUT (SD_OPRREG),A
RET
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
;
; CSIO WAIT FOR TRANSMIT READY (TX REGSITER EMPTY)
; CSIO WAIT FOR TRANSMIT READY (TX REGISTER EMPTY)
;
SD_WAITTX:
IN0 A,(SD_CNTR) ; GET CSIO STATUS
@@ -1981,7 +2020,7 @@ SD_PUT:
OUT (SD_WRTR),A
#ELSE
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
CALL MIRROR ; MSB<-->LSB MIRROR BITS, RESULT IN C
CALL SD_WAITTX ; MAKE SURE WE ARE DONE SENDING
OUT0 (SD_TRDR),C ; PUT BYTE IN BUFFER
@@ -2059,7 +2098,7 @@ SD_GET:
#IF (SDMODE == SDMODE_MT)
IN A,(SD_RDTR)
#ELSE
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
CALL SD_WAITTX ; MAKE SURE WE ARE DONE SENDING
IN0 A,(SD_CNTR) ; GET CSIO STATUS
SET 5,A ; START RECEIVER
@@ -2153,7 +2192,7 @@ SD_GET1:
;
; SET CSIO TO DEFAULT SPEED
;
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC))
#IF ((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX))
;
SD_CSIO_DEF:
; SET CSIO FOR DEFAULT OPERATION
@@ -2406,7 +2445,7 @@ SD_DSKBUF .DW 0 ; ADR OF ACTIVE DISK BUFFER
; MSB<-->LSB MIRROR BITS IN A, RESULT IN C
;
MIRROR:
#IF (((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC)) & SDCSIOFAST)
#IF (((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX)) & SDCSIOFAST)
; FASTEST BUT USES MOST CODE SPACE
LD BC,MIRTAB ; 256 BYTE MIRROR TABLE
ADD A,C ; ADD OFFSET
@@ -2439,7 +2478,7 @@ MIRROR2:
;
; LOOKUP TABLE TO MIRROR BITS IN A BYTE
;
#IF (((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC)) & SDCSIOFAST)
#IF (((SDMODE == SDMODE_CSIO) | (SDMODE == SDMODE_MK4) | (SDMODE == SDMODE_SC) | (SDMODE == SDMODE_EPITX)) & SDCSIOFAST)
MIRTAB .DB 00H, 80H, 40H, 0C0H, 20H, 0A0H, 60H, 0E0H, 10H, 90H, 50H, 0D0H, 30H, 0B0H, 70H, 0F0H
.DB 08H, 88H, 48H, 0C8H, 28H, 0A8H, 68H, 0E8H, 18H, 98H, 58H, 0D8H, 38H, 0B8H, 78H, 0F8H

View File

@@ -303,6 +303,14 @@ BE_AGAIN:
BE_END:
HB_EI
POP IX
;
; Above flow flips the speaker bit an odd number of times which
; leaves the bit set to the opposite value it started at. This
; ensures that the bit is properly reset to its original value.
;
LD A,(HB_RTCVAL) ; Get the current RTC latch value
OUT (RTCIO),A ; Set it
;
RET ; ALWAYS EXITS WITH SUCCESS STATUS (A=0)
;
;======================================================================

View File

@@ -197,6 +197,7 @@ SDMODE_MT .EQU 9 ; MT (Shift register SPI WIZNET for RCBUS)
SDMODE_USR .EQU 10 ; USER DEFINED (in sd.asm) (NOT COMPLETE)
SDMODE_PIO .EQU 11 ; Z80 PIO bitbang
SDMODE_Z80R .EQU 12 ; Z80 Retro
SDMODE_EPITX .EQU 13 ; Mini ITX Z180
;
; AY SOUND CHIP MODE SELECTIONS
;
@@ -640,27 +641,26 @@ RAMD_BNKS .EQU (BID_RAMDN - BID_RAMD0 + 1)
;
#ENDIF
;
#IF TRUE
.ECHO "BID_BUF: " \ .ECHO BID_BUF \ .ECHO "\n"
.ECHO "BID_AUX: " \ .ECHO BID_AUX \ .ECHO "\n"
.ECHO "BID_BIOS: " \ .ECHO BID_BIOS \ .ECHO "\n"
.ECHO "BID_USR: " \ .ECHO BID_USR \ .ECHO "\n"
.ECHO "BID_COM: " \ .ECHO BID_COM \ .ECHO "\n"
.ECHO "BID_BOOT: " \ .ECHO BID_BOOT \ .ECHO "\n"
.ECHO "BID_IMG0: " \ .ECHO BID_IMG0 \ .ECHO "\n"
.ECHO "BID_IMG1: " \ .ECHO BID_IMG1 \ .ECHO "\n"
.ECHO "BID_IMG2: " \ .ECHO BID_IMG2 \ .ECHO "\n"
.ECHO "BID_ROMD0: " \ .ECHO BID_ROMD0 \ .ECHO "\n"
.ECHO "BID_ROMDN: " \ .ECHO BID_ROMDN \ .ECHO "\n"
.ECHO "BID_RAMD0: " \ .ECHO BID_RAMD0 \ .ECHO "\n"
.ECHO "BID_RAMDN: " \ .ECHO BID_RAMDN \ .ECHO "\n"
#IF FALSE
.ECHO "--- RAM/ROM CAPACITY ---\n"
.ECHO "BID_ROM0: " \ .ECHO BID_ROM0 \ .ECHO "\n"
.ECHO "BID_ROMN: " \ .ECHO BID_ROMN \ .ECHO "\n"
.ECHO "BID_RAM0: " \ .ECHO BID_RAM0 \ .ECHO "\n"
.ECHO "BID_RAMN: " \ .ECHO BID_RAMN \ .ECHO "\n"
.ECHO "--- BANK LAYOUT ---\n"
.ECHO "BID_BOOT: " \ .ECHO BID_BOOT \ .ECHO "\n"
.ECHO "BID_IMG0: " \ .ECHO BID_IMG0 \ .ECHO "\n"
.ECHO "BID_IMG1: " \ .ECHO BID_IMG1 \ .ECHO "\n"
.ECHO "BID_IMG2: " \ .ECHO BID_IMG2 \ .ECHO "\n"
.ECHO "BID_ROMD0: " \ .ECHO BID_ROMD0 \ .ECHO "\n"
.ECHO "BID_ROMDN: " \ .ECHO BID_ROMDN \ .ECHO "\n"
.ECHO "BID_BIOS: " \ .ECHO BID_BIOS \ .ECHO "\n"
.ECHO "BID_RAMD0: " \ .ECHO BID_RAMD0 \ .ECHO "\n"
.ECHO "BID_RAMDN: " \ .ECHO BID_RAMDN \ .ECHO "\n"
.ECHO "BID_BUF: " \ .ECHO BID_BUF \ .ECHO "\n"
.ECHO "BID_AUX: " \ .ECHO BID_AUX \ .ECHO "\n"
.ECHO "BID_USR: " \ .ECHO BID_USR \ .ECHO "\n"
.ECHO "BID_COM: " \ .ECHO BID_COM \ .ECHO "\n"
#ENDIF
;
; MEMORY LAYOUT
@@ -838,7 +838,7 @@ INT_CTC0A .EQU 0 ; ZILOG CTC 0, CHANNEL A
INT_CTC0B .EQU 1 ; ZILOG CTC 0, CHANNEL B
INT_CTC0C .EQU 2 ; ZILOG CTC 0, CHANNEL C
INT_CTC0D .EQU 3 ; ZILOG CTC 0, CHANNEL D
;INT_SIO0 .EQU 7 ; ZILOG SIO 0, CHANNEL A & B
INT_SIO0 .EQU 6 ; ZILOG SIO 0, CHANNEL A & B
INT_SIO1 .EQU 8 ; ZILOG SIO 1, CHANNEL A & B
INT_PIO0A .EQU 9 ; ZILOG PIO 0, CHANNEL A
INT_PIO0B .EQU 10 ; ZILOG PIO 0, CHANNEL B

View File

@@ -1,9 +1,10 @@
;======================================================================
; TM9918 AND V9958 VDU DRIVER
;
; WRITTEN BY: DOUGLAS GOODALL
; UPDATED BY: WAYNE WARTHEN -- 4/7/2013
; UPDATED BY: DEAN NETHERTON -- 5/26/2021 - V9958 SUPPORT
; WRITTEN BY: DOUGLAS GOODALL
; UPDATED BY: WAYNE WARTHEN -- 4/7/2013
; UPDATED BY: DEAN NETHERTON -- 5/26/2021 - V9958 SUPPORT
; UPDATED BY: JOSE L. COLLADO -- 11/15/2023 - MEMORY MAP CHANGES
;======================================================================
;
; TODO:
@@ -15,14 +16,36 @@
; TMS DRIVER - CONSTANTS
;======================================================================
;
;
;
; 40 Column Video Memory Map
; -----------------------------------
; Start Length
; Pattern Table: $0000 $0800 Font data (8 x 256)
; Unused: $0800 $1000
; Sprite Patterns: $1800 $0800
; Color Table: $2000 $1800
; Name Table: $3800 $0400 Display characters (40 x 25)
; Sprite Attributes: $3B00 $0100
; Unused: $3C00 $0400
;
; 80 Column Video Memory Map (MSX like)
; -------------------------------------
; Start Length
; Pattern Table: $1000 $0800 Font data (8 x 256)
; Sprite Patterns: $???? $????
; Color Table: $???? $????
; Name Table: $0000 $0800 Display characters (80 x 25)
; Sprite Attributes: $???? $????
; Unused: $???? $????
;
TMSCTRL1: .EQU 1 ; CONTROL BITS
TMSINTEN: .EQU 5 ; INTERRUPT ENABLE BIT
;
#IF TMSTIMENABLE
.ECHO "TMS INTERRUPTS ENABLED\n"
#ENDIF
;
#IF ((TMSMODE == TMSMODE_MSX) | (TMSMODE == TMSMODE_MSX9958))
TMS_DATREG .EQU $98 ; READ/WRITE DATA
TMS_CMDREG .EQU $99 ; READ STATUS / WRITE REG SEL
@@ -31,8 +54,8 @@ TMS_PPIB .EQU 0 ; PPI PORT B
TMS_PPIC .EQU 0 ; PPI PORT C
TMS_PPIX .EQU 0 ; PPI CONTROL PORT
#ENDIF
#IF (TMSMODE == TMSMODE_COLECO))
;
#IF (TMSMODE == TMSMODE_COLECO)
TMS_DATREG .EQU $BE ; READ/WRITE DATA
TMS_CMDREG .EQU $BF ; READ STATUS / WRITE REG SEL
TMS_PPIA .EQU 0 ; PPI PORT A
@@ -40,14 +63,14 @@ TMS_PPIB .EQU 0 ; PPI PORT B
TMS_PPIC .EQU 0 ; PPI PORT C
TMS_PPIX .EQU 0 ; PPI CONTROL PORT
#ENDIF
;
#IF (TMSMODE == TMSMODE_MSXKBD)
TMS_DATREG .EQU $98 ; READ/WRITE DATA
TMS_CMDREG .EQU $99 ; READ STATUS / WRITE REG SEL
TMS_KBDDATA .EQU $E0 ; KBD CTLR DATA PORT
TMS_KBDST .EQU $E1 ; KBD CTLR STATUS/CMD PORT
#ENDIF
;
#IF (TMSMODE == TMSMODE_N8)
TMS_DATREG .EQU $98 ; READ/WRITE DATA
TMS_CMDREG .EQU $99 ; READ STATUS / WRITE REG SEL
@@ -56,7 +79,7 @@ TMS_PPIB .EQU $85 ; PPI PORT B
TMS_PPIC .EQU $86 ; PPI PORT C
TMS_PPIX .EQU $87 ; PPI CONTROL PORT
#ENDIF
;
#IF (TMSMODE == TMSMODE_SCG)
TMS_DATREG .EQU $98 ; READ/WRITE DATA
TMS_CMDREG .EQU $99 ; READ STATUS / WRITE REG SEL
@@ -68,7 +91,6 @@ TMS_PPIX .EQU 0 ; PPI CONTROL PORT
#ENDIF
;
#IF (TMSMODE == TMSMODE_MBC)
TMS_DATREG .EQU $98 ; READ/WRITE DATA
TMS_CMDREG .EQU $99 ; READ STATUS / WRITE REG SEL
TMS_ACR .EQU $9C ; AUX CONTROL REGISTER
@@ -79,14 +101,20 @@ TMS_PPIX .EQU 0 ; PPI CONTROL PORT
TMS_KBDDATA .EQU $E2 ; KBD CTLR DATA PORT
TMS_KBDST .EQU $E3 ; KBD CTLR STATUS/CMD PORT
#ENDIF
;
TMS_ROWS .EQU 24
;
#IF ((TMSMODE == TMSMODE_MSX9958) | (TMSMODE == TMSMODE_MBC))
TMS_FNTVADDR .EQU $1000 ; VRAM ADDRESS OF FONT DATA
TMS_FNTSIZE .EQU 8*256 ; ### JLC Mod for JBL compatibility ### = 8x8 Font 256 Chars
TMS_CHRVADDR .EQU $0000 ; VRAM ADDRESS OF CHAR SCREEN DATA (NEW CONSTANT) = REG2 * $400
TMS_COLS .EQU 80
#ELSE
TMS_FNTVADDR .EQU $0800 ; VRAM ADDRESS OF FONT DATA
#ELSE ; ALL OTHER MODES...
;TMS_FNTVADDR .EQU $0800 ; VRAM ADDRESS OF FONT DATA
TMS_FNTVADDR .EQU $0000 ; VRAM ADDRESS OF FONT DATA ### JLC Mod for JBL compatibility ### = REG4 * $800
TMS_FNTSIZE .EQU 8*256 ; ### JLC Mod for JBL compatibility ### = 8x8 Font 256 Chars
; ### JLC Fix to allow Name Table Addresses other than $0000 and JBL Compatibility ###
TMS_CHRVADDR .EQU $3800 ; VRAM ADDRESS OF CHAR SCREEN DATA (NEW CONSTANT) = REG2 * $400
TMS_COLS .EQU 40
#ENDIF
;
@@ -99,15 +127,16 @@ TERMENABLE .SET TRUE ; INCLUDE TERMINAL PSEUDODEVICE DRIVER
; IF YOU SEE SCREEN CORRUPTION, ADJUST THIS!!!
;
#IF (CPUFAM == CPU_Z180)
; BELOW WAS TUNED FOR Z180 AT 18MHZ
#DEFINE TMS_IODELAY EX (SP),HL \ EX (SP),HL ; 38 W/S
; BELOW WAS TUNED FOR Z180 AT 18MHZ
#DEFINE TMS_IODELAY EX (SP),HL \ EX (SP),HL ; 38 W/S
;#DEFINE TMS_IODELAY NOP \ NOP \ NOP \ NOP \ NOP ; 20 W/S ### JLC Mod for Clock/2 (9 MHz) ###
#ELSE
; BELOW WAS TUNED FOR SBC AT 8MHZ
#IF ((TMSMODE == TMSMODE_MSX9958) | (TMSMODE == TMSMODE_MBC))
#DEFINE TMS_IODELAY NOP \ NOP \ NOP \ NOP \ NOP \ NOP \ NOP ; V9958 NEEDS AT WORST CASE, APPROX 4us (28T) DELAY BETWEEN I/O (WHEN IN TEXT MODE)
#ELSE
#DEFINE TMS_IODELAY NOP \ NOP ; 8 W/S
#ENDIF
; BELOW WAS TUNED FOR SBC AT 8MHZ
#IF ((TMSMODE == TMSMODE_MSX9958) | (TMSMODE == TMSMODE_MBC))
#DEFINE TMS_IODELAY NOP \ NOP \ NOP \ NOP \ NOP \ NOP \ NOP ; V9958 NEEDS AT WORST CASE, APPROX 4us (28T) DELAY BETWEEN I/O (WHEN IN TEXT MODE)
#ELSE
#DEFINE TMS_IODELAY NOP \ NOP ; 8 W/S
#ENDIF
#ENDIF
;
;======================================================================
@@ -155,6 +184,9 @@ TMS_INIT:
#IF (TMSMODE == TMSMODE_MSX)
PRTS("MSX$")
#ENDIF
#IF (TMSMODE == TMSMODE_COLECO) ; ### JLC Mod for completeness ###
PRTS("COLECO$")
#ENDIF
#IF (TMSMODE == TMSMODE_MSXKBD)
PRTS("RCKBD$")
#ENDIF
@@ -166,9 +198,10 @@ TMS_INIT:
LD A,TMS_DATREG
CALL PRTHEXBYTE
CALL TMS_PROBE ; CHECK FOR HW EXISTENCE
;JP TMS_INIT1 ; ### JLC DEBUG: ALLWAYS CONTINUE ###
JR Z,TMS_INIT1 ; CONTINUE IF PRESENT
;
; HARDWARE NOT PRESENT
; *** HARDWARE NOT PRESENT ***
PRTS(" NOT PRESENT$")
OR $FF ; SIGNAL FAILURE
RET
@@ -193,9 +226,9 @@ TMS_INIT1:
CALL HB_ADDIM1 ; ADD TO IM1 CALL LIST
LD A, (TMS_INITVDU_REG_1)
SET TMSINTEN, A ; SET INTERRUPT ENABLE BIT
LD (TMS_INITVDU_REG_1), A
LD C, TMSCTRL1
SET TMSINTEN,A ; SET INTERRUPT ENABLE BIT
LD (TMS_INITVDU_REG_1),A
LD C, TMSCTRL1
CALL TMS_SET
#ENDIF
;
@@ -266,11 +299,11 @@ TMS_VDAINI:
RET
TMS_VDAQRY:
LD C,$00 ; MODE ZERO IS ALL WE KNOW
LD D,TMS_ROWS ; ROWS
LD E,TMS_COLS ; COLS
LD HL,0 ; EXTRACTION OF CURRENT BITMAP DATA NOT SUPPORTED YET
XOR A ; SIGNAL SUCCESS
LD C,$00 ; MODE ZERO IS ALL WE KNOW
LD D,TMS_ROWS ; ROWS
LD E,TMS_COLS ; COLS
LD HL,0 ; EXTRACTION OF CURRENT BITMAP DATA NOT SUPPORTED YET
XOR A ; SIGNAL SUCCESS
RET
TMS_VDARES:
@@ -294,11 +327,11 @@ TMS_VDARES1: ; ENTRY POINT TO AVOID TMS_Z180IO RECURSION
RET
TMS_VDADEV:
LD D,VDADEV_TMS ; D := DEVICE TYPE
LD E,0 ; E := PHYSICAL UNIT IS ALWAYS ZERO
LD H,TMSMODE ; H := MODE
LD L,TMS_DATREG ; L := BASE I/O ADDRESS
XOR A ; SIGNAL SUCCESS
LD D,VDADEV_TMS ; D := DEVICE TYPE
LD E,0 ; E := PHYSICAL UNIT IS ALWAYS ZERO
LD H,TMSMODE ; H := MODE
LD L,TMS_DATREG ; L := BASE I/O ADDRESS
XOR A ; SIGNAL SUCCESS
RET
TMS_VDASCS:
@@ -310,28 +343,28 @@ TMS_VDASCP:
CALL TMS_Z180IO
#ENDIF
CALL TMS_CLRCUR
CALL TMS_XY ; SET CURSOR POSITION
CALL TMS_XY ; SET CURSOR POSITION
CALL TMS_SETCUR
XOR A ; SIGNAL SUCCESS
XOR A ; SIGNAL SUCCESS
RET
TMS_VDASAT:
XOR A ; NOT POSSIBLE, JUST SIGNAL SUCCESS
XOR A ; NOT POSSIBLE, JUST SIGNAL SUCCESS
RET
TMS_VDASCO:
XOR A ; NOT POSSIBLE, JUST SIGNAL SUCCESS
XOR A ; NOT POSSIBLE, JUST SIGNAL SUCCESS
RET
TMS_VDAWRC:
#IF (CPUFAM == CPU_Z180)
CALL TMS_Z180IO
#ENDIF
CALL TMS_CLRCUR ; CURSOR OFF
LD A,E ; CHARACTER TO WRITE GOES IN A
CALL TMS_PUTCHAR ; PUT IT ON THE SCREEN
CALL TMS_CLRCUR ; CURSOR OFF
LD A,E ; CHARACTER TO WRITE GOES IN A
CALL TMS_PUTCHAR ; PUT IT ON THE SCREEN
CALL TMS_SETCUR
XOR A ; SIGNAL SUCCESS
XOR A ; SIGNAL SUCCESS
RET
TMS_VDAFIL:
@@ -339,11 +372,11 @@ TMS_VDAFIL:
CALL TMS_Z180IO
#ENDIF
CALL TMS_CLRCUR
LD A,E ; FILL CHARACTER GOES IN A
EX DE,HL ; FILL LENGTH GOES IN DE
CALL TMS_FILL ; DO THE FILL
LD A,E ; FILL CHARACTER GOES IN A
EX DE,HL ; FILL LENGTH GOES IN DE
CALL TMS_FILL ; DO THE FILL
CALL TMS_SETCUR
XOR A ; SIGNAL SUCCESS
XOR A ; SIGNAL SUCCESS
RET
TMS_VDACPY:
@@ -353,11 +386,11 @@ TMS_VDACPY:
CALL TMS_CLRCUR
; LENGTH IN HL, SOURCE ROW/COL IN DE, DEST IS TMS_POS
; BLKCPY USES: HL=SOURCE, DE=DEST, BC=COUNT
PUSH HL ; SAVE LENGTH
CALL TMS_XY2IDX ; ROW/COL IN DE -> SOURCE ADR IN HL
POP BC ; RECOVER LENGTH IN BC
LD DE,(TMS_POS) ; PUT DEST IN DE
CALL TMS_BLKCPY ; DO A BLOCK COPY
PUSH HL ; SAVE LENGTH
CALL TMS_XY2IDX ; ROW/COL IN DE -> SOURCE ADR IN HL
POP BC ; RECOVER LENGTH IN BC
LD DE,(TMS_POS) ; PUT DEST IN DE
CALL TMS_BLKCPY ; DO A BLOCK COPY
CALL TMS_SETCUR
XOR A
RET
@@ -368,20 +401,20 @@ TMS_VDASCR:
#ENDIF
CALL TMS_CLRCUR
TMS_VDASCR0:
LD A,E ; LOAD E INTO A
OR A ; SET FLAGS
JR Z,TMS_VDASCR2 ; IF ZERO, WE ARE DONE
PUSH DE ; SAVE E
JP M,TMS_VDASCR1 ; E IS NEGATIVE, REVERSE SCROLL
CALL TMS_SCROLL ; SCROLL FORWARD ONE LINE
POP DE ; RECOVER E
DEC E ; DECREMENT IT
JR TMS_VDASCR0 ; LOOP
LD A,E ; LOAD E INTO A
OR A ; SET FLAGS
JR Z,TMS_VDASCR2 ; IF ZERO, WE ARE DONE
PUSH DE ; SAVE E
JP M,TMS_VDASCR1 ; E IS NEGATIVE, REVERSE SCROLL
CALL TMS_SCROLL ; SCROLL FORWARD ONE LINE
POP DE ; RECOVER E
DEC E ; DECREMENT IT
JR TMS_VDASCR0 ; LOOP
TMS_VDASCR1:
CALL TMS_RSCROLL ; SCROLL REVERSE ONE LINE
POP DE ; RECOVER E
INC E ; INCREMENT IT
JR TMS_VDASCR0 ; LOOP
CALL TMS_RSCROLL ; SCROLL REVERSE ONE LINE
POP DE ; RECOVER E
INC E ; INCREMENT IT
JR TMS_VDASCR0 ; LOOP
TMS_VDASCR2:
CALL TMS_SETCUR
XOR A
@@ -393,23 +426,23 @@ TMS_VDASCR2:
;----------------------------------------------------------------------
TMS_VDARDC:
OR $FF ; UNSUPPORTED FUNCTION
OR $FF ; UNSUPPORTED FUNCTION
RET
; DUMMY FUNCTIONS BELOW BECAUSE SCG BOARD HAS NO
; KEYBOARD INTERFACE
TMS_STAT:
XOR A ; SIGNAL NOTHING READY
JP CIO_IDLE ; DO IDLE PROCESSING
XOR A ; SIGNAL NOTHING READY
JP CIO_IDLE ; DO IDLE PROCESSING
TMS_FLUSH:
XOR A ; SIGNAL SUCCESS
XOR A ; SIGNAL SUCCESS
RET
TMS_READ:
LD E,26 ; RETURN <SUB> (CTRL-Z)
XOR A ; SIGNAL SUCCESS
LD E,26 ; RETURN <SUB> (CTRL-Z)
XOR A ; SIGNAL SUCCESS
RET
;
;======================================================================
@@ -469,7 +502,7 @@ TMS_RD:
; ON RETURN, ZF SET INDICATES HARDWARE FOUND
;
TMS_PROBE:
; SET WRITE ADDRESS TO $0
; SET WRITE ADDRESS TO $0000
LD HL,0
CALL TMS_WR
; WRITE TEST PATTERN TO FIRST TWO BYTES
@@ -481,19 +514,18 @@ TMS_PROBE:
OUT (TMS_DATREG),A ; SECOND BYTE
;TMS_IODELAY ; DELAY
CALL DLY64 ; DELAY
; SET READ ADDRESS TO $0
;
; SET READ ADDRESS TO $0000
LD HL,0
CALL TMS_RD
; READ TEST PATTERN
LD C,$A5 ; VALUE TO EXPECT
IN A,(TMS_DATREG) ; READ FIRST BYTE
;CALL PRTHEXBYTE
;TMS_IODELAY ; DELAY
CALL DLY64 ; DELAY
CP C ; COMPARE
RET NZ ; RETURN ON MISCOMPARE
IN A,(TMS_DATREG) ; READ SECOND BYTE
;CALL PRTHEXBYTE
;TMS_IODELAY ; DELAY
CALL DLY64 ; DELAY
CPL ; COMPLEMENT IT
@@ -505,12 +537,12 @@ TMS_PROBE:
;----------------------------------------------------------------------
;
TMS_CRTINIT:
; SET WRITE ADDRESS TO $0
; SET WRITE ADDRESS TO $0000 Beginning of VRAM
LD HL,0
CALL TMS_WR
;
; FILL ENTIRE RAM CONTENTS
LD DE,$4000
; FILL ENTIRE 16KB VRAM CONTENTS with $00 ### JLC Comment fix ###
LD DE,$4000 ; 16KB
TMS_CRTINIT1:
XOR A
OUT (TMS_DATREG),A
@@ -521,9 +553,9 @@ TMS_CRTINIT1:
JR NZ,TMS_CRTINIT1
;
; INITIALIZE VDU REGISTERS
LD C,0 ; START WITH REGISTER 0
LD C,0 ; START WITH REGISTER 0
LD B,TMS_INITVDULEN ; NUMBER OF REGISTERS TO INIT
LD HL,TMS_INITVDU ; HL = POINTER TO THE DEFAULT VALUES
LD HL,TMS_INITVDU ; HL = POINTER TO THE DEFAULT VALUES
TMS_CRTINIT2:
LD A,(HL) ; GET VALUE
CALL TMS_SET ; WRITE IT
@@ -565,7 +597,7 @@ TMS_LOADFONT:
#ENDIF
;
; FILL TMS_FNTVADDR BYTES FROM FONTDATA
LD DE,TMS_FNTVADDR
LD DE,TMS_FNTSIZE ; ### JLC Mod for JBL compatibility ###
TMS_LOADFONT1:
LD A,(HL)
OUT (TMS_DATREG),A
@@ -622,20 +654,20 @@ TMS_SETCUR:
LD HL,0 ; ZERO HL
LD L,A ; HL IS NOW RAW CHAR INDEX
LD B,3 ; LEFT SHIFT BY 3 BITS
TMS_SETCUR0: ; MULT BY 8 FOR FONT INDEX
TMS_SETCUR0: ; MULT BY 8 FOR FONT INDEX
SLA L ; SHIFT LSB INTO CARRY
RL H ; SHFT MSB FROM CARRY
DJNZ TMS_SETCUR0 ; LOOP 3 TIMES
LD DE,TMS_FNTVADDR ; OFFSET TO START OF FONT TABLE
LD DE,TMS_FNTVADDR ; OFFSET TO START OF FONT TABLE
ADD HL,DE ; ADD TO FONT INDEX
CALL TMS_RD ; SETUP TO READ GLYPH
LD B,8 ; 8 BYTES
LD HL,TMS_BUF ; INTO BUFFER
TMS_SETCUR1: ; READ GLYPH LOOP
TMS_SETCUR1: ; READ GLYPH LOOP
IN A,(TMS_DATREG) ; GET NEXT BYTE
TMS_IODELAY ; IO DELAY
LD (HL),A ; SAVE VALUE IN BUF
INC HL ; BUMP BUF POINTER
INC HL ; BUMP BUF POINTER
DJNZ TMS_SETCUR1 ; LOOP FOR 8 BYTES
;
; NOW WRITE INVERTED GLYPH INTO FONT INDEX 255
@@ -643,7 +675,7 @@ TMS_SETCUR1: ; READ GLYPH LOOP
CALL TMS_WR ; SETUP TO WRITE THE INVERTED GLYPH
LD B,8 ; 8 BYTES PER GLYPH
LD HL,TMS_BUF ; POINT TO BUFFER
TMS_SETCUR2: ; WRITE INVERTED GLYPH LOOP
TMS_SETCUR2: ; WRITE INVERTED GLYPH LOOP
LD A,(HL) ; GET THE BYTE
INC HL ; BUMP THE BUF POINTER
XOR $FF ; INVERT THE VALUE
@@ -689,6 +721,9 @@ TMS_XY2IDX:
CALL MULT8 ; MULTIPLY TO GET ROW OFFSET
LD E,A ; GET COLUMN BACK
ADD HL,DE ; ADD IT IN
; ### JLC Fix to allow Name Table Addresses other than $0000 and JBL Compatibility ###
LD DE,TMS_CHRVADDR ; Add offset Address to start of Name Table (Char)
ADD HL,DE
RET ; RETURN
;
;----------------------------------------------------------------------
@@ -735,10 +770,11 @@ TMS_FILL1:
;----------------------------------------------------------------------
;
TMS_SCROLL:
LD HL,0 ; SOURCE ADDRESS OF CHARACER BUFFER
; ### JLC Fix to allow Name Table Addresses other than $0000 and JBL Compatibility ###
LD HL,TMS_CHRVADDR ; SOURCE ADDRESS OF CHARACTER BUFFER
LD C,TMS_ROWS - 1 ; SET UP LOOP COUNTER FOR ROWS - 1
;
TMS_SCROLL0: ; READ LINE THAT IS ONE PAST CURRENT DESTINATION
TMS_SCROLL0: ; READ LINE THAT IS ONE PAST CURRENT DESTINATION
PUSH HL ; SAVE CURRENT DESTINATION
LD DE,TMS_COLS
ADD HL,DE ; POINT TO NEXT ROW SOURCE
@@ -786,7 +822,10 @@ TMS_SCROLL3:
;----------------------------------------------------------------------
;
TMS_RSCROLL:
; ### JLC Fix to allow Name Table Addresses other than $0000 and JBL Compatibility ###
LD HL,TMS_COLS * (TMS_ROWS - 1)
LD DE,TMS_CHRVADDR ; Add offset Address to start of Name Table (Char)
ADD HL,DE
LD C,TMS_ROWS - 1
;
TMS_RSCROLL0: ; READ THE LINE THAT IS ONE PRIOR TO CURRENT DESTINATION
@@ -838,33 +877,33 @@ TMS_RSCROLL3:
;
TMS_BLKCPY:
; SAVE DESTINATION AND LENGTH
PUSH BC ; LENGTH
PUSH DE ; DEST
PUSH BC ; LENGTH
PUSH DE ; DEST
;
; READ FROM THE SOURCE LOCATION
TMS_BLKCPY1:
CALL TMS_RD ; SET UP TO READ FROM ADDRESS IN HL
LD DE,TMS_BUF ; POINT TO BUFFER
CALL TMS_RD ; SET UP TO READ FROM ADDRESS IN HL
LD DE,TMS_BUF ; POINT TO BUFFER
LD B,C
TMS_BLKCPY2:
IN A,(TMS_DATREG) ; GET THE NEXT BYTE
TMS_IODELAY ; DELAY
LD (DE),A ; SAVE IN BUFFER
INC DE ; BUMP BUF PTR
DJNZ TMS_BLKCPY2 ; LOOP AS NEEDED
IN A,(TMS_DATREG) ; GET THE NEXT BYTE
TMS_IODELAY ; DELAY
LD (DE),A ; SAVE IN BUFFER
INC DE ; BUMP BUF PTR
DJNZ TMS_BLKCPY2 ; LOOP AS NEEDED
;
; WRITE TO THE DESTINATION LOCATION
POP HL ; RECOVER DESTINATION INTO HL
CALL TMS_WR ; SET UP TO WRITE
LD DE,TMS_BUF ; POINT TO BUFFER
POP BC ; GET LOOP COUNTER BACK
POP HL ; RECOVER DESTINATION INTO HL
CALL TMS_WR ; SET UP TO WRITE
LD DE,TMS_BUF ; POINT TO BUFFER
POP BC ; GET LOOP COUNTER BACK
LD B,C
TMS_BLKCPY3:
LD A,(DE) ; GET THE CHAR FROM BUFFER
OUT (TMS_DATREG),A ; WRITE TO VDU
TMS_IODELAY ; DELAY
INC DE ; BUMP BUF PTR
DJNZ TMS_BLKCPY3 ; LOOP AS NEEDED
LD A,(DE) ; GET THE CHAR FROM BUFFER
OUT (TMS_DATREG),A ; WRITE TO VDU
TMS_IODELAY ; DELAY
INC DE ; BUMP BUF PTR
DJNZ TMS_BLKCPY3 ; LOOP AS NEEDED
;
RET
;
@@ -915,7 +954,7 @@ TMS_INTHNDL:
; CALL MKY_INT
;#ENDIF
CALL HB_TIMINT ; RETURN NZ - HANDLED
CALL HB_TIMINT ; RETURN NZ - HANDLED
OR $FF
RET
#ENDIF
@@ -924,28 +963,27 @@ TMS_INTHNDL:
; TMS DRIVER - DATA
;==================================================================================================
;
TMS_POS .DW 0 ; CURRENT DISPLAY POSITION
TMS_CURSAV .DB 0 ; SAVES ORIGINAL CHARACTER UNDER CURSOR
TMS_BUF .FILL 256,0 ; COPY BUFFER
TMS_POS .DW 0 ; CURRENT DISPLAY POSITION
TMS_CURSAV .DB 0 ; SAVES ORIGINAL CHARACTER UNDER CURSOR
TMS_BUF .FILL 256,0 ; COPY BUFFER
;
;==================================================================================================
; TMS DRIVER - INSTANCE DATA
;==================================================================================================
;
TMS_IDAT:
#IF ((TMSMODE == TMSMODE_MSX) | (TMSMODE == TMSMODE_MSX9958) | (TMSMODE == TMSMODE_N8) | (TMSMODE == TMSMODE_SCG))
.DB TMS_PPIA ; PPI PORT A
.DB TMS_PPIB ; PPI PORT B
.DB TMS_PPIC ; PPI PORT C
.DB TMS_PPIX ; PPI CONTROL PORT
.DB TMS_PPIA ; PPI PORT A
.DB TMS_PPIB ; PPI PORT B
.DB TMS_PPIC ; PPI PORT C
.DB TMS_PPIX ; PPI CONTROL PORT
#ENDIF
#IF ((TMSMODE == TMSMODE_MSXKBD) | (TMSMODE == TMSMODE_MBC))
.DB KBDMODE_PS2 ; PS/2 8242 KEYBOARD CONTROLLER
.DB TMS_KBDST ; 8242 CMD/STATUS PORT
.DB TMS_KBDDATA ; 8242 DATA PORT
.DB 0 ; FILLER
.DB KBDMODE_PS2 ; PS/2 8242 KEYBOARD CONTROLLER
.DB TMS_KBDST ; 8242 CMD/STATUS PORT
.DB TMS_KBDDATA ; 8242 DATA PORT
.DB 0 ; FILLER
#ENDIF
;
.DB TMS_DATREG
@@ -958,8 +996,8 @@ TMS_IDAT:
; Control Registers (write CMDREG):
;
; Reg Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Description
; 0 - - - - - - M2 EXTVID
; 1 4/16K BL GINT M1 M3 - SI MAG
; 0 - - - - - - M3 EXTVID
; 1 4/16K BL GINT M1 M2 - SI MAG
; 2 - - - - PN13 PN12 PN11 PN10
; 3 CT13 CT12 CT11 CT10 CT9 CT8 CT7 CT6
; 4 - - - - - PG13 PG12 PG11
@@ -994,32 +1032,50 @@ TMS_IDAT:
; INT Set at each screen update, used for interrupts.
;
#IF ((TMSMODE == TMSMODE_MSX9958) | (TMSMODE == TMSMODE_MBC))
TMS_INITVDU:
.DB $04 ; REG 0 - NO EXTERNAL VID, SET M4 = 1
;
; NOTE: YAMAHA 9938/58 DOCUMENTATION SAYS R3 IS SAME AS 9918 (ADR >> 10),
; BUT THIS SEEMS TO BE WRONG AND CORRECTLY DOCUMENTED AT
; https://www.msx.org/wiki/Screen_Modes_Description#SCREEN_0_in_80-column_.28Text_mode_2.29
; BITS 1-0 SHOULD BE 1. BITS 8-2 SHOULD BE (ADR >> 8).
;
TMS_INITVDU: ; V9958 REGISTER SET
.DB $04 ; REG 0 - NO EXTERNAL VID, SET M4 = 1 FOR 80 COLS
TMS_INITVDU_REG_1:
.DB $50 ; REG 1 - ENABLE SCREEN, SET MODE 1
.DB $03 ; REG 2 - PATTERN NAME TABLE := 0
.DB $50 ; REG 1 - ENABLE SCREEN, SET M1
.DB $03 ; REG 2 - SET PATTERN NAME TABLE TO (TMS_CHRVADDR >> 8) | $03
.DB $00 ; REG 3 - NO COLOR TABLE
.DB $02 ; REG 4 - SET PATTERN GENERATOR TABLE TO (TMS_FNTVADDR -> $1000)
.DB $00 ; REG 5 - SPRITE ATTRIBUTE IRRELEVANT
.DB $00 ; REG 6 - NO SPRITE GENERATOR TABLE
.DB $F0 ; REG 7 - WHITE ON BLACK
.DB $88 ; REG 8 - COLOUR BUS INPUT, DRAM 64K
.DB $00 ; REG 9
.DB $00 ; REG 10 - COLOUR TABLE A14-A16 (TMS_FNTVADDR - $1000)
#ELSE ; TMS REGISTER SET
TMS_INITVDU:
.DB $00 ; REG 0 - NO EXTERNAL VID
;
#ELSE ; _______TMS9918 REGISTER SET ### JLC Mod for JBL compatibility & MODE II Readiness ###_______
;
TMS_INITVDU: ; V9918 REGISTER SET
.DB $00 ; REG 0 - SET TEXT MODE, NO EXTERNAL VID
TMS_INITVDU_REG_1:
.DB $50 ; REG 1 - ENABLE SCREEN, SET MODE 1
.DB $00 ; REG 2 - PATTERN NAME TABLE := 0
.DB $00 ; REG 3 - NO COLOR TABLE
.DB $01 ; REG 4 - SET PATTERN GENERATOR TABLE TO (TMS_FNTVADDR -> $0800)
.DB $00 ; REG 5 - SPRITE ATTRIBUTE IRRELEVANT
.DB $00 ; REG 6 - NO SPRITE GENERATOR TABLE
.DB $F0 ; REG 7 - WHITE ON BLACK
.DB $D0 ; REG 1 - SET 16K VRAM, ENABLE SCREEN, NO INTERRUPTS, TEXT MODE ($50 TO BLANK SCREEN)
.DB $0E ; REG 2 - SET PATTERN NAME TABLE TO (TMS_CHRVADDR >> 10)
.DB $FF ; REG 3 - NO COLOR TABLE, SET TO MODE II DEFAULT VALUE
.DB $00 ; REG 4 - SET PATTERN GENERATOR TABLE TO (TMS_FNTVADDR -> $0000)
.DB $76 ; REG 5 - SPRITE ATTRIBUTE IRRELEVANT, SET TO MODE II DEFAULT VALUE
.DB $03 ; REG 6 - NO SPRITE GENERATOR TABLE, SET TO MODE II DEFAULT VALUE
.DB $E1 ; REG 7 - GREY ON BLACK ### JLC Mod Change default text color for better readability YMMV ###
;
;TMS_INITVDU:
; .DB $00 ; REG 0 - NO EXTERNAL VID
;TMS_INITVDU_REG_1:
; .DB $50 ; REG 1 - ENABLE SCREEN, SET TEXT MODE & BLANK SCREEN ### JLC comment fix (NOT MODE 1) ###
; .DB $00 ; REG 2 - PATTERN NAME TABLE := 0
; .DB $00 ; REG 3 - NO COLOR TABLE
; .DB $01 ; REG 4 - SET PATTERN GENERATOR TABLE TO (TMS_FNTVADDR -> $0800)
; .DB $00 ; REG 5 - SPRITE ATTRIBUTE IRRELEVANT
; .DB $00 ; REG 6 - NO SPRITE GENERATOR TABLE
; .DB $F0 ; REG 7 - WHITE ON TRANSPARENT
;
#ENDIF
;
TMS_INITVDULEN .EQU $ - TMS_INITVDU

View File

@@ -52,17 +52,23 @@ UART_EFR .EQU 2 ; LCR=$BF: ENHANCED FEATURE REG (READ/WRITE)
UART_INTACT .EQU 7 ; INT RCV ACTIVE BIT
UART_FIFOACT .EQU 6 ; FIFO ACTIVE BIT
UART_AFCACT .EQU 5 ; AUTO FLOW CONTROL ACTIVE BIT
UART_CTSBAD .EQU 4 ; CTS STALL DETECTED
;
#IF (PLATFORM == PLT_DUO)
UARTSBASE .EQU $58
#ELSE
UARTSBASE .EQU $68
#ENDIF
UARTABASE .EQU $A8
UARTCBASE .EQU $80
UARTMBASE .EQU $18
UART4BASE .EQU $C0
UARTRBASE .EQU $A0
#IF (PLATFORM == PLT_DUO)
UARTDBASE .EQU $70
#ELSE
UARTDBASE .EQU $80
#ENDIF
;
#IF (UARTINTS)
;
@@ -173,7 +179,19 @@ UART_INITUNIT:
LD A,(HL) ; PUT IN ACCUM
INC (HL) ; INCREMENT IT (FOR NEXT LOOP)
LD (IY),A ; UDPATE UNIT NUM
;
; CHECK FOR CTS STALL (CTS SHOULD BE ASSERTED HERE)
BIT 5,(IY+5) ; IS RTS REQUESTED?
JR Z,UART_INITUNIT1 ; IF NOT, SKIP CTS CHECK
UART_INP(UART_MSR) ; LOAD MODEM STATUS REG
BIT 4,A ; CTS
JR NZ,UART_INITUNIT1 ; IF CTS HIGH (GOOD), SKIP AHEAD
;
; CTS LOOKS BORKED, SHUT OFF RTS/CTS FLOW CONTROL
RES 5,(IY+5) ; CLEAR RTS BIT OF CONFIG MSB
SET UART_CTSBAD,(IY+1) ; RECORD BAD CTS
;
UART_INITUNIT1:
; SET DEFAULT CONFIG
LD DE,-1 ; LEAVE CONFIG ALONE
JP UART_INITDEVX ; IMPLEMENT IT AND RETURN
@@ -197,8 +215,21 @@ UART_INIT1:
LD A,(IY+1) ; GET UART TYPE
OR A ; SET FLAGS
CALL NZ,UART_PRTCFG ; PRINT IF NOT ZERO
JR Z,UART_INIT2 ; SKIP IF ZERO (NOT DETECTED)
PUSH AF ; SAVE TYPE VALUE
CALL UART_PRTCFG ; PRINT IF NOT ZERO
POP AF ; RESTORE TYPE VALUE
BIT UART_CTSBAD,A ; CTS STALL?
JR Z,UART_INIT2 ; IF NOT, SKIP AHEAD
CALL NEWLINE ; FORMATTING
PRTS("UART$") ; FORMATTING
LD A,(IY) ; DEVICE NUM
CALL PRTDECB ; PRINT DEVICE NUM
PRTS(": $") ; FORMATTING
LD DE,UART_STR_BADCTS ; LOAD WARNING MESSAGE
CALL WRITESTR ; ... AND PRINT IT
;
UART_INIT2:
POP BC ; RESTORE LOOP CONTROL
INC C ; NEXT UNIT
DJNZ UART_INIT1 ; LOOP TILL DONE
@@ -992,6 +1023,8 @@ UART_STR_16850 .DB "16850$"
;
UART_PAR_MAP .DB "NONENMNS"
;
UART_STR_BADCTS .DB "CTS STALL, HARDWARE FLOW CONTROL SUSPENDED$"
;
; WORKING VARIABLES
;
UART_DEV .DB 0 ; DEVICE NUM USED DURING INIT
@@ -1009,6 +1042,16 @@ UART_CFG_SBC:
.DW UARTCFG ; LINE CONFIGURATION
.DW UARTSBC_RCVBUF ; POINTER TO RCV BUFFER STRUCT
#ENDIF
#IF (UARTAUX)
UART_CFG_AUX:
; AUX SERIAL PORT
.DB 0 ; DEVICE NUMBER (UPDATED DURING INIT)
.DB 0 ; UART TYPE
.DB UARTABASE ; IO PORT BASE (RBR, THR)
.DB UARTABASE + UART_LSR ; LINE STATUS PORT (LSR)
.DW UARTCFG ; LINE CONFIGURATION
.DW 0 ; NO INT HANDLER
#ENDIF
#IF (UARTCAS)
UART_CFG_CAS:
; CASSETTE INTERFACE SERIAL PORT

View File

@@ -407,8 +407,8 @@ XREGDMP:
LD (REGDMP_SP),SP ; SAVE STACK POINTER
;LD (RD_STKSAV),SP ; SAVE ORIGINAL STACK POINTER
;LD SP,RD_STACK ; SWITCH TO PRIVATE STACK
LD (RD_STKSAV),SP ; SAVE ORIGINAL STACK POINTER
LD SP,RD_STACK ; SWITCH TO PRIVATE STACK
PUSH AF
PUSH BC
@@ -462,7 +462,7 @@ XREGDMP:
POP BC
POP AF
;LD SP,(RD_STKSAV) ; BACK TO ORIGINAL STACK FRAME
LD SP,(RD_STKSAV) ; BACK TO ORIGINAL STACK FRAME
JP $FFFF ; RETURN, $FFFF IS DYNAMICALLY UPDATED
REGDMP_RET .EQU $-2 ; RETURN ADDRESS GOES HERE
@@ -470,9 +470,9 @@ REGDMP_RET .EQU $-2 ; RETURN ADDRESS GOES HERE
REGDMP_PC .DW 0
REGDMP_SP .DW 0
;
;RD_STKSAV .DW 0
; .FILL $FF,16*2 ; 16 LEVEL PRIVATE STACK
;RD_STACK .EQU $
RD_STKSAV .DW 0
.FILL $FF,16*2 ; 16 LEVEL PRIVATE STACK
RD_STACK .EQU $
;
;
;

54
Source/Images/AddRom.cmd Normal file
View File

@@ -0,0 +1,54 @@
@echo off
setlocal
set PATH=..\..\Tools\cpmtools;%PATH%
set BINLOC=..\..\Binary
set DISKIMG=hd1k_combo.img
if "%1"=="" goto :usage
if not exist %BINLOC%\%DISKIMG% goto :noimage
if not exist %BINLOC%\%1.rom goto :nofile
echo.
cpmrm.exe -f wbw_hd1k_0 %BINLOC%/%DISKIMG% 0:rom.img
cpmcp.exe -f wbw_hd1k_0 %BINLOC%/%DISKIMG% %BINLOC%/%1.rom 0:rom.img
if errorlevel 1 goto :err
::cpmls.exe -f wbw_hd1k_0 %BINLOC%/%DISKIMG% 0:rom.img
echo %1.rom has been added to %DISKIMG% as ROM.IMG in user area 0
echo.
goto :eof
:noimage
echo.
echo %BINLOC%\%DISKIMG% file not found!!!
echo.
goto :eof
:nofile
echo.
echo %BINLOC%\%1.rom file not found!!!
echo.
goto :eof
:usage
echo.
echo Usage:
echo AddRom romname
echo.
echo romname is the root filename of an existing ROM image in the %BINLOC% directory
echo.
echo Example:
echo AddRom RCZ80_std
echo.
goto :eof
:err
echo.
echo An error occurred copying %1.rom into hd1k_combo.img!
echo.

Binary file not shown.

Binary file not shown.

View File

@@ -17,6 +17,11 @@ FLASH4 has been tested and confirmed working on:
It should work on many other machines that run RomWBW or UNA BIOS. If you test
it on another machine please let me know the outcome.
FLASH030 (also included) is a Linux version of the same software. It is
targetted at my 68030 machine but should be very easy to port to other
machines. It expects a machine with a larger address space, and thus omits much
of the bank switching and other tricks required on Z80 platforms.
= Introduction =

View File

@@ -1,4 +1,4 @@
SUPERSUB DOCUMENTATION (revised 09/13/81)
SUPERSUB DOCUMENTATION (revised 09/25/84)
----------------------
09/05/81
@@ -11,6 +11,17 @@ are familiar with that utility and its use.
------------------
Version 1.3 update:
George Cary has added MP/M capability to version 1.2 of SuperSUB. In
version 1.3 I fixed a problem that caused SuperSUB to bomb when the
.SUB file did not end in a 1AH (which is an ascii end-of-file
character). It was depending on the 1AH to end the file, and ignoring
the physical end-of-file. Physical end-of-file will now terminate
properly. - Jeffrey J. Nonken
------------------
Version 1.1 update:
Control-character translation has been added. This facility works
@@ -138,4 +149,4 @@ NOTES
5) Interactive mode may be aborted by typing control-C as the first
character of a line. Also, all normal CP/M editing characters are
available.



Binary file not shown.

View File

@@ -1,282 +1,112 @@
File: UNARC.DOC
Subject: User Documentation for UNARC Program
Version: 1.6
Date: March 27, 1987
------------------------------------------------------------------------------
UNARC
CP/M Archive File Extraction Utility
Copyright (C) 1986, 1987 by Robert A. Freed
All Rights Reserved
This file provides user-level documentation and operating instructions for
UNARC version 1.6, released March 27, 1987. Refer to the notice at the end of
this file regarding rights of use and distribution of this program.
The release message file, UNARC.MSG, provides a list of all additional files
distributed with the current UNARC release and describes the program changes
from the previous version 1.4 and 1.5 releases.
ABSTRACT
--------
UNARC is a utility program for CP/M systems which allows the listing, typeout,
printing, checking, and extraction of subfiles contained in "archive" library
(*.ARC or *.ARK) files. These are commonly used for compressed file storage
on remote access bulletin board systems. UNARC provides the CP/M user the
ability to process such files after downloading them via modem from these
remote systems.
REQUIREMENTS
------------
UNARC requires CP/M version 2 or higher. The program is offered in two
versions. The standard version, UNARC.COM, requires a Z80 processor (or
compatible equivalent, e.g. HD64180 or NSC800). An alternate version,
UNARCA.COM, is provided for systems with 8080 or 8085 processors (or 16-bit
systems using the NEC V20 for CP/M emulation). Identical capabilities are
provided by the two program versions.
NOTE
Although UNARCA.COM can execute on ANY system capable of
supporting CP/M, it is larger and significantly slower than
UNARC.COM and should be avoided by users of Z80-based systems.
UNARC is written in Z80 assembly language and requires only 5K bytes of disk
storage (6K for UNARCA). As distributed, the program requires at least 30K
bytes of available memory space (TPA) for full support of all archive file
formats (31K TPA size for UNARCA). (Smaller systems may be able to use some
of the program's capabilities.)
ABOUT ARC/ARK FILES
-------------------
The files which UNARC processes utilize a format that was introduced by the
ARC shareware utility program, which executes on 16-bit computers running the
MS-DOS (or PC-DOS) operating system. This format has achieved widespread
popularity since the ARC program first appeared in March 1985, and it has
become the de facto standard for file storage on remote access systems
catering to 16-bit computer users. More recently this file format has
achieved increased popularity on RCP/M (Remote CP/M) systems.
NOTE
Most RCP/M system operators have adopted the convention of naming
CP/M archive files with the filetype ARK. This differentiates
these from MS-DOS archive files, which use the filetype ARC. This
is a naming convention only: There is no difference in format,
and UNARC will accept files of either type interchangeably.
An archive is a group of files collected together into a single file in such a
way that the individual files may be recovered intact. In this respect,
archives are similar in function to libraries (*.LBR files), which have been
commonplace on CP/M systems since 1982, when the original LU library utility
program was introduced by Gary P. Novosielski. (However, the two file formats
are not compatible.)
The distinguishing characteristic of an ARC archive is that its component
files are automatically compressed when they are added to the archive, so that
the resulting file occupies a minimum amount of disk space. Of course, file
compression techniques have also been commonplace in the CP/M world since
1981, when the public domain SQ and USQ "squeeze and unsqueeze" programs were
introduced by Richard Greenlaw.
The SQ/USQ programs and their numerous popular descendants utilize a well-
known general-purpose form of data compression (Huffman coding). This
technique, which is also utilized in ARC files, performs well for many text
files but often produces poor compression of binary files (e.g. object program
.COM files). The ARC program also provides an advanced data compression
method, which it terms "crunching." This method (which is based on the
Lempel-Ziv-Welch or "LZW" algorithm) performs better than squeezing in most
cases, often achieving 50% or better compression of ASCII text files, 15-40%
compression of binary object files, and as much as 95% compression of bit-
mapped graphics image files.
Five different methods are actually employed for storing files in an archive.
The method chosen for a particular file is the one which results in the best
compression for that file:
(1) No compression ("unpacked"). The file is stored in its original form.
(2) Run-length encoding ("packed"). Repeated sequences of 3-255 identical
bytes are compressed into a three-byte sequence.
(3) Huffman coding ("squeezed"). Each 8-bit byte (after run-length encoding)
is encoded by a variable number of bits, with bit length (approximately)
inversely proportional to the frequency of occurence of the corresponding
byte.
(4) LZW compression ("crunched"). Variable-length strings of bytes (in
theory, up to nearly 4000 bytes in length) are represented by a single
(maximum) 12-bit code (after run-length encoding).
(5) LZW compression ("squashed"). This is a variation of crunching which
uses (maximum) 13-bit codes (and no run-length encoding).
Note that since one of the five methods involves no compression at all, the
resulting archive entry will never be larger than the original file.
NOTE
The most recent release of the MS-DOS ARC program (version 5.20)
has eliminated squeezing as a compression technique. However,
UNARC continues to process squeezed files for compatibility with
archives created by earlier versions of ARC and by other MS-DOS
archiving programs (notably PKARC).
The squashed compression method was recently introduced by the
MS-DOS programs PKARC and PKXARC. UNARC can process files which
use this method, although it is not universally accepted by other
MS-DOS archive extraction programs (including ARC).
During its lifetime, the ARC program has undergone numerous revisions which
have employed different variations on some of the above methods, particularly
LZW compression. In order to retain compatibility with archives created by
earlier program revisions, ARC stores a "version" indicator with each file in
an archive. Based on this indicator, the latest release of the ARC program
can always extract files created by older releases (although it will only use
the latest data compression versions when adding new files to an archive).
NOTE
The current release of UNARC supports archive file versions
generated by all releases of the following MS-DOS programs through
(at least) the indicated program versions:
ARC 5.20 (24 Oct 86), by System Enhancement Associates, Inc.
ARCA 1.22 (13 Sep 86), by Wayne Chin and Vernon Buerg
ARCH 5.38 (26 Jun 86), by Les Satenstein
PKARC 2.0 (15 Dec 86), by Phil Katz (PKWARE, Inc.)
(UNARC does not recognize, but is unaffected by, the non-standard
archive and file commenting feature of PKARC.)
Although the above discussion has emphasized the origin of archive files for
the MS-DOS operating system, their use has recently spread to many other
systems. Programs compatible with MS-DOS ARC have appeared for UNIX, Atari
68000, VAX/VMS, and TOPS-20 systems. A CP/M utility for building archive
files will also be available in the near future.
For additional information about archive files and the MS-DOS ARC utility,
refer to the documentation file, ARC.DOC, which is available from most remote
access systems which utilize archive files. For additional information about
the LZW algorithm (and data compression methods in general), refer to the
article "A Technique for High-Performance Data Compression", by Terry A.
Welch, in IEEE Computer magazine, Vol. 17, No. 6, June 1984.
USING UNARC
-----------
The UNARC program provides an on-line help message, which is generated by
running the program with an empty command line:
A>UNARC
UNARC 1.6 27 Mar 87
CP/M Archive File Extractor
Usage: UNARC [d:]arcfile[.typ] [d:][afn] [N|P|C]
Examples:
B>UNARC A:SAVE.ARK *.* ; List all files in CP/M archive SAVE on drive A
B>UNARC A:SAVE.ARC *.* ; List all files in MS-DOS archive SAVE on drive A
A>UNARC SAVE ; Same as either of above
A>UNARC SAVE *.* N ; Same as above (no screen pauses)
A>UNARC SAVE *.DOC ; List just .DOC files
A>UNARC SAVE READ.ME ; Typeout the file READ.ME
A>UNARC SAVE READ.ME N ; Typeout the file READ.ME (no screen pauses)
A>UNARC SAVE A: ; Extract all files to drive A
A>UNARC SAVE B:*.DOC ; Extract .DOC files to drive B
A>UNARC SAVE C:READ.ME ; Extract file READ.ME to drive C
A>UNARC SAVE PRN.DAT P ; Print the file PRN.DAT (no formatting)
A>UNARC SAVE *.* C ; Check validity of all files in archive
As shown by this help display, the UNARC utility provides the following
capabilities:
(1) Listing the directory of an archive
(2) Extracting component files from an archive
(3) Typing the contents of a component file at the console
(4) Printing a component file directly on the CP/M list device
(5) Checking the validity of an archive and its component files
The particular operation to be performed is determined by the form of the file
parameter(s) in the command line, as described separately in the sections
which follow. The following characteristics apply to all operations:
The first command line parameter must specify the name of an archive file. A
drive name and filetype are optional. The filetype, if omitted, defaults to
"ARK" or, if no such file exists, the alternate (MS-DOS) default "ARC" is
assumed.
The standard CP/M terminal control characters, CTRL-S (to suspend console
output) and CTRL-C (to abort the program), may be used at any time. CTRL-K
may also be used as an alternate for CTRL-C. Printer output to the CP/M list
device may be obtained by typing CTRL-P at CCP command level before executing
UNARC.
In addition, by default UNARC will pause after every 23 lines of console
output. At this time, the message "[more]" will appear at the bottom of the
console screen. The listing may be resumed by typing any key (other than
CTRL-S, CTRL-C, or CTRL-K, which will function as described above). If the
space bar is used, one more line of console output will be displayed (over-
writing the "[more]" message) and the program will again pause. If any other
key is typed (e.g. RETURN), another 23 lines of output will be allowed to
scroll onto the screen before the next pause. (LINE FEED may be used to
prevent overprinting of the "[more]" line, e.g. for hard-copy terminals.)
If continuous display is desired, this automatic pause feature may be disabled
by specifying "N" at the end of the command line. The "N" must be the last
command line character, and it must be preceded by a space. Also, there must
be two preceding file parameters on the command line. E.g., note the
difference between the following commands:
A>UNARC SAVE N ; Typeout the file N. in archive SAVE
A>UNARC SAVE *.* N ; List all files in archive SAVE with no pauses
The N option may not be used in conjunction with the P (Print) or C (Check)
options.
LISTING AN ARCHIVE DIRECTORY
----------------------------
By default, UNARC produces a detailed console listing of the component files
in an archive. (In fact, there is no way to suppress this listing; it is
generated during all UNARC operations.) If only the archive file name appears
on the command line, UNARC will generate a complete directory of all component
files in the specified archive file. Otherwise, the second command line
parameter may be used to select a particular file to be listed (or group of
files, if it contains the ambiguous file specification characters "*" or "?").
If no disk drive name is provided for the second parameter, and this parameter
specifies a group of files, the directory listing is the only output generated
by the program.
A sample directory listing is illustrated here:
A>UNARC CODES
Archive File = CODES.ARK
UNARCU
Universal Archive File Extraction Utility
Version 1.0
Modified for Universal use by Lars Nelson
September 17, 2023
Modified for ZCPR3 by Gene Pizzetta
December 9, 1990
Original CP/M 2.2 version is
Copyright (C) 1986, 1987 by Robert A. Freed
All Rights Reserved
UNARCU allows the listing, typeout, printing, checking, and extraction of
member files contained in ARK and ARC archive files. These are commonly
used for compressed file storage on remote access bulletin boards. This is
a universal version and runs on the following CP/M compatible systems:
CP/M 2.2 with DRI CCP or ZCPRD&J
ZSDOS 1.2 and 2.0 with DRI CCP, ZCPRD&J or Zsystem
CP/M 3 with DRI CCP or Z3Plus
ZPM3 with DRI CCP or ZCCP
DU file specification is supported on all systems. If Zsystem is active
then named directories can be used and the bad directories flag is
automatically checked.
If datestamping is available then extracted files will recieve the ARK file's
stored date stamp. The program handles DateStamper, NZTIME and CP.M Plus
date stamping methods.
UNARCU requires at least 32K of free memory (TPA) for full support of all
archive file formats, but smaller systems may be able to use some of the
program's capabilities.
USAGE:
UNARCU {DU: or dir:}arcfile{.typ} {DU: or dir:}{afn.aft} {{/}options}
If a DIR or DU specification is not given for the archive file, the current
drive/user is assumed. The second filename, which can be ambiguous,
refers to a member file or files in the archive. DIR: file specification
only available when Zsystem is active. DU: specification always available.
If a DU or DIR specification is provided for the member filespec, it will be
extracted to that directory. To extract to the current directory, only a
colon is required. If a directory specification is given without a filename,
all files ("*.*") is assumed.
If no DU or DIR specification is given, UNARCU acts differently depending
on whether the member name is ambiguous or not. If the member name is
unambiguous, and the filetype is not restricted, the file will be typed to
the screen. If the member name is ambiguous, or if no member name is
given at all, a directory of the ARK will be displayed.
If no filetype is given for the archive file, UNARCU first tries ARK and then
ARC.
An on-line help message will be displayed if UNARCU is called with no
command tail or if the command tail is "//".
OPTIONS: Options may or may not be preceded by a slash, but the slash is
required if the options are not the third token (element) on the command
line.
C Check the validity of the archive and the given member
files. If a member filespec is not given, all files
("*.*") is assumed.
E Toggle erasing of existing files without asking on and
off. UNARCU may be configured to automatically erase,
during member file extraction, existing files in the
target directory that have the same name. Or it can
be configured to ask first. This option will turn off
user query before erasure, if it is on by default, and
vice versa.
N Toggle console paging on or off. UNARCU may be
configured to default to console paging or not. This
option will turn paging off, if the the default is on,
and vice-versa. Paging effects both archive directory
display and member file type-out. During member file
extraction, console paging is always off.
P Sends a member file to the printer (LST device). The
member name cannot be ambiguous. The file will be
printed continuously, with no formatting or paging.
UNARCU can be aborted at any time with ^C or ^K.
If screen paging is enabled, UNARCU pauses after the screen fills. The
listing may be resumed by typing any key other than ^S, ^C, or ^K. The
space bar displays one more line of output (overwriting the "[more]"
message) and the program will again pause. For hard copy terminals, line
feed may be used to prevent overprinting of the "[more]" line. If paging
is disabled, the display can be paused with ^S.
LISTING AN ARCHIVE DIRECTORY: UNARC always produces a detailed
console listing of all the member files of an archive, or of those members
which match the second file specification, if one is given. If no member
name is given, or if the member name is ambiguous, then UNARCU only lists
the directory, without doing anything else. (That is, unless the C option is
included.)
A sample directory listing:
A0>UNARCU CODES
Archive File = A0:CODES.ARK
Name Length Disk Method Ver Stored Saved Date Time CRC
============ ======= ==== ======== === ======= ===== ========= ====== ====
ABLE .DOC 24320 24k Crunched 8 11777 52% 30 Apr 86 10:50a 42C0
@@ -285,97 +115,82 @@ CHARLIE .TXT 234 1k Packed 3 99 58% 2 May 86 4:11p 8927
==== ======= ==== ======= === ====
Total 3 41706 42k 26626 36% 58A4
The listing is equivalent to the "verbose" listing of the MS-DOS ARC
program, with the addition of the "Disk" and "Ver" fields, which are unique
to UNARCU and previous UNARC versions. The listing requires 78-columns
of terminal width.
This listing is equivalent to the "verbose" listing of the MS-DOS ARC program
(with the addition of the "Disk" and "Ver" fields, which are unique to UNARC).
The listing requires a 78-column terminal width; there is currently no "short"
listing format.
"Name" is the filename which will be generated if the file is extracted by
UNARCU. This is not necessarily the same as the name recorded in the
archive file. Although CP/M and MS-DOS file naming conventions are
identical, two conversions are made to guarantee filename validity: Lower-
case letters are converted to upper-case and non-printing characters are
converted to dollar signs ("$"). Archive entries are usually maintained and
listed in alphabetical order.
"Name" is the file name which will be generated if the file is extracted by
UNARC on a CP/M system. (This is not necessarily the same as the name
recorded in the archive file. Although CP/M and MS-DOS file naming
conventions are identical, two conversions are made to guarantee file name
validity under CP/M: Lower-case letters are converted to upper-case, and
non-printing characters are converted to dollar signs, "$".) Archive entries
are usually maintained (and hence listed) in alphabetic name order.
"Length" is the uncompressed file length, i.e., the number of bytes the file
will occupy if extracted to disk, exclusive of any additional length imposed
by the file system. MS-DOS permits files of arbitrary lengths, but CP/M
restricts files to multiples of 128 bytes.
"Length" is the uncompressed file length, i.e. the number of bytes the file
will occupy if extracted to disk, exclusive of any additional length imposed
by the CP/M file system. Note that MS-DOS permits files of arbitrary lengths
(unlike CP/M which restricts all files to a multiple of 128 bytes).
"Disk" is the actual amount of space required to extract the file to a CP/M
disk, expressed as a multiple of 1K (1024) bytes. The number is dependent
on the output drive's allocation block size, which can range from 1K to 16K
bytes. Typically, 1K is used for single-density floppy disks, 2K for
double-density floppies, and 4K for hard disks. In the absence of an
explicit output drive, UNARCU uses the block size of the currently logged
drive, or a configured default size.
"Disk" is the actual amount of disk space required to extract the file to a
CP/M disk, expressed as a multiple of 1K (1024) bytes. Note that this number
is dependent on the disk data allocation block size. (CP/M permits various
block sizes, ranging from 1K to 16K bytes. Typical sizes are 1K for single-
density floppy disks, 2K for double-density floppies, and 4K for hard disks,
although these values are quite system-dependent.) In the absence of an
explicit output drive name, UNARC uses the block size of the default
(currently "logged") disk drive (i.e. the drive which appears in the CCP
prompt).
"Method" is the compression method used: "Unpacked", "Packed",
"Squeezed", "Crunched", "Squashed", or "Unknown!". If the method
"Unknown!" appears, it likely indicates a faulty archive file or a newer
compression method not yet supported by UNARCU.
"Method" is the compression method used, specified as "Unpacked", "Packed",
"Squeezed", "Crunched", "Squashed", or "Unknown!". If the method "Unknown!"
appears, it most likely indicates (if not a faulty archive file) a newer
release of the MS-DOS ARC program that supports a new compression method (or a
new variation of an existing method). In this case, a corresponding new
release of UNARC will be required to extract the file.
"Ver" is the version of compression method used. UNARC supports versions
1-9: unpacked files, versions 1 or 2; packed files, version 3; squeezed
files, version 4; crunched files, versions 5 and squashed files, version 9.
"Ver" further identifies the version of compression used. Currently, UNARC
supports versions 1-9: unpacked files can have versions 1 or 2; packed files,
version 3; squeezed files, version 4; crunched files, versions 5-8; and
squashed files, version 9. The highest version number associated with each
compression method is the one generated by the most recent release of the
MS-DOS ARC program.
"Stored" is the compressed file length, that is, the number of bytes
occupied by the file in the archive, not including the directory information
overhead, which adds an additional 29 bytes to each member file.
"Stored" is the compressed file length, i.e. the number of bytes occupied by
the file in the archive. (This does not include the overhead associated with
the directory information itself, which adds an additional 29 bytes to the
size of each component file.)
"Saved" is the percentage of the original file length which was saved by
compression; i.e., higher values indicate better compression. (The MS-DOS ARC
documentation refers to this as the "stowage factor.") The value shown on the
totals line applies to the archive as a whole, not including the directory
"Saved" indicates the percentage of the original file length which was saved
by compression. Higher values indicate better compression. The MS-DOS
ARC documentation refers to this as the "stowage factor". The value shown
in the totals applies to the archive as a whole, excluding directory
overhead.
"Date" and "Time" refer to the last file modification, as of the time it was
added to the archive. (Date and time stamping is, of course, one of the nice
features of MS-DOS which is lacking in standard CP/M 2.2.)
"Date" and "Time" are the file modification stamp at the time it was added
to the archive.
"CRC" is an internal 16-bit cyclic redundancy check value which is computed
when a file is added to an archive (expressed in hexadecimal). As a test of
file validity, UNARC re-computes this value when it extracts a file (see
below). Note that this value is calculated by a different method than that
used by either of the two popular public domain programs, CRCK and CHEK. (It
is however quite valid as a reliable error-detection mechanism.) This value
is shown in the listing for completeness only. The value shown on the totals
line is the 16-bit sum of all displayed CRC values. This is useful as a
single "checksum" value for comparing entire archives. (Since the CRC values
are computed before compression takes place, the total should be the same for
all archives created from the same set of input files, independent of any
particular variations in file order or compression methods.)
"CRC" is an internal 16-bit cyclic redundancy check value computed when a
file is added to an archive, expressed in hexadecimal. UNARCU checks file
validity by recomputing this value when it extracts a file. The value is
calculated by a different method than that used by either of the two
popular public domain programs, CRCK and CHEK, but it is a quite valid and
reliable error-detection mechanism. The value is given for completeness
only. The total in the last line is the 16-bit sum of the displayed CRC
values and is useful for comparing entire archives. Since the CRC values
are computed before compression, the total should be the same for all
archives created from the same set of input files, without regard for
variations in file order or compression methods.
The "Total" line is displayed only if multiple files appear in the listing,
and it includes a count of the number of files listed.
The "Total" line is displayed only if more than one file appears in the
listing.
EXTRACTING FILES FROM AN ARCHIVE: If the second command line
parameter contains a DU or DIR specification UNARCU will extract the
selected member file or files to to the indicated disk directory. If the
directory specification is given without a filename, all member files will be
extracted to the indicated directory. If only a colon is given, the current
drive/user will be assumed.
Below is a directory listing as might be generated during file extraction,
along with some possible warning messages:
EXTRACTING FILES FROM AN ARCHIVE
--------------------------------
If the second command line parameter contains a disk drive name, UNARC will
extract the selected file(s) from the archive to CP/M file(s) on the indicated
disk drive. If only a drive name appears, all component files of the archive
will be extracted. The following illustrates a sample archive directory
listing as generated during a file extraction operation:
A>UNARC CODES B:
Archive File = CODES.ARK
Output Drive = B:
A0>UNARCU CODES B1:
Archive File = A0:CODES.ARK
Output Directory = B1:
Name Length Disk Method Ver Stored Saved Date Time CRC
============ ======= ==== ======== === ======= ===== ========= ====== ====
ABLE .DOC 24320 24k Crunched 8 11777 52% 30 Apr 86 10:50a 42C0
@@ -388,236 +203,235 @@ CHARLIE .TXT 234 2k Packed 3 99 58% 2 May 86 4:11p 8927
==== ======= ==== ======= === ====
Total 3 41706 44k 26616 36% 58A4
"Replace existing output file (y/n)?" appears if a file of the same name
exists in the output directory, requiring a "Y" or "N" response. Any
response other than "Y" will be consided to be the same as "N". If UNARCU
has been configured to erase without query, this message will not appear.
The above listing also illustrates several warning messages which may occur
when extracting files from an archive.
The first two of the "Warning:" messages above indicate that either the
cyclic redundancy check (CRC) value or the extracted file length does not
match the value recorded in the archive header when the original file was
added. The third warning message is displayed if the proper format for
the beginning of a new member is not detected, but UNARCU recovered by
skipping a certain number of bytes in the archive file. If a recovery
attempt fails, UNARC aborts and issues a different message, "Invalid archive
file format". The appearance of any of these messages probably means the
file data has been corrupted in some way.
The message "Replace existing output file (y/n)?" appears if a file of the
same name already exists on the output drive. The user must answer "Y" (or
"y") to allow the extraction to proceed (in which case, the existing file is
unceremoniously deleted). Any other response will cause UNARC to preserve the
existing file, bypass the extraction operation for the current file, and
(except for a CTRL-C response) skip to the next file to be extracted (if any).
If the original MS-DOS file length was not an exact multiple of 128 bytes,
the final record of the extracted file will be padded with 1Ah characters
(ASCII ^Z).
The first two warning messages illustrated above are provided as a check on
the validity of the extracted file. These indicate that either the cyclic
redundancy check (CRC) value computed by UNARC, or the resulting extracted
file length, does not match the corresponding value recorded in the archive
when the original file was added to it. The final warning message occurs if
UNARC fails to detect the proper format for the start of a new subfile, but
can recover by skipping a certain number of bytes in the archive file. (If
the recovery attempt fails, UNARC aborts with the message "Invalid archive
file format.") The appearance of any of these messages most likely indicates
that the file data has been corrupted in some way (e.g. during modem
transmission from a remote system).
Disk space in the listing will be correct for the specified output directory.
In the two examples above, drive A has 1K allocation blocks while drive B
has a 2K blocks, which accounts for the differences in the two listings. To
determine the exact disk space requirements before extracting files, log
into the desired output drive and take an UNARCU directory listing of the
ARK file.
Note that if the original (i.e. MS-DOS) file length was not an exact multiple
of 128 bytes (as required by CP/M), UNARC will pad the final record of the
extracted file with hex "1A" (ASCII CTRL-Z) bytes. This provides the correct
end-of-file termination for text files, according to CP/M conventions.
If a file extraction is aborted with ^C, any partial output file will have to
be deleted manually.
Also, the disk space shown in the archive directory listing will be correct
for the specified disk drive. (In the above examples, drive A: has a 1K data
allocation block size while drive B: has a 2K block size, which accounts for
the differences in the two listings.) In order to determine the exact disk
space requirements in advance of a file extraction operation, the user may
first "log into" the desired output drive (i.e. select it as the default
drive), and run UNARC to obtain a directory listing only. (This is a
consideration only on systems with mixed disk drive types.)
A file extraction operation may be aborted at any time by entering CTRL-C from
the console. In this case, any partial output file will remain on disk and
should be deleted manually following the program abort. (Any existing file of
the same name will have already been deleted, however.)
TYPING OUT A FILE IN AN ARCHIVE
-------------------------------
A console typeout of the contents of a single component file in an archive may
be requested by specifying a non-ambiguous file name (and no disk drive name)
in the second command line parameter. For example:
A>UNARC CODES ABLE.DOC
Archive File = CODES.ARK
TYPING MEMBER FILES: Typing the contents of a member file in an archive
to the console may be requested by giving a non-ambiguous filename and no
output disk directory as the second command line parameter. For example:
A0>UNARCU CODES ABLE.DOC
Archive File = A0:CODES.ARK
Name Length Disk Method Ver Stored Saved Date Time CRC
============ ======= ==== ======== === ======= ===== ========= ====== ====
ABLE .DOC 24320 24k Crunched 8 11777 52% 30 Apr 86 10:50a 42C0
-------------------------------------------------------------------------------
This is file ABLE.DOC, contained within the archive CODES.ARK. Typeout will
proceed until the end of this file or may be aborted by CTRL-C.....
proceed until the end of this file, so you'd better be patient. For somebody
who has nothing to say, I've written an awfully big file here. If you don't
want to read all 24K of it, you can type ^C ....
The specified file is assumed to contain valid ASCII text data. All bytes
are masked to seven bits and all control characters are ignored except
horizontal tabs, which are expanded to blanks with stops at every eighth
column), and line feeds, vertical tabs, and form feeds, all of which generate
a new line. SUB (^Z) is interpreted as the end of the file. Backspaces and
carriage returns are ignored, so text will not be obscured.
UNARCU will refuse to type files whose filetype indicates are not ASCII text
files, including COM, CMD, EXE, OBJ, OVL, REL, PRL, CRL, IRL, INI, SYS,
BAD, ARK, ARC, LBR, ?Q?, ?Y? and ?Z?. If one of these or other restricted
types is given, directory information only is listed.
CRC and file length checking are not performed when a file is typed to the
screen.
PRINTING MEMBER FILES: A single member file may be sent to the printer
(CP/M LST device) with the "P" option as the third parameter on the
command line with or without a preceding slash. In addition, the member
name must be non-ambiguous and must not be preceded by a drive or user
specification. For example:
A0>UNARCU CODES CHARLIE.TXT P
or
A0>UNARCU CODES CHARLIE.TXT /P
The contents of the specified file is passed directly to the printer without
alteration, additional formatting, or even paging. The user should make
sure it contains data suitable for printer output. This unfiltered operation
is particularly well-suited for the output of binary graphics images to
dot-matrix printers. These files can be extremely large, but compress quite
well, often to less than 5% of their original size. The same filetypes
excluded from typing are also excluded from printing. Printing may be
paused or aborted with ^S and ^C respectively.
CHECKING MEMBER FILES: With the "C" option UNARCU can be directed to
extract one or more member files from an archive, without actually storing
them as disk files. This operation performs file CRC and length checking,
so it is useful for verifying correct modem data transmission of an archive.
If the "C" is the second parameter on the command line, it must be
preceded by a slash. In that case all files in the archive will be checked.
If a member filename is given, it may be ambiguous, but it cannot be
preceded by a disk directory specification. For example:
A0>UNARCU CODES *.DOC C
or
A0>UNARCU CODES /C
FILE DATE STAMPING: ARK and ARC files contain only a member file's
modification date and time. When a member is extracted under ZSDOS or
CP/M 3 with date stamping, its modification date will be transferred to disk
as both the create and modification file date stamps. If the modification
date is not included in the archive, then the extracted file will be stamped
with the current date and time.
SECURITY: Z-Node security is handled automatically by UNARCU when
Zsystem is running. If the Wheel byte is off (reset), file extraction,
archive checking, and file printing are all disabled. In addition, UNARCU
can be configured to disable file type-out or to limit type-out to a maximum
number of lines.
The specified file is assumed to contain valid ASCII text data. In
particular, all bytes are masked to seven bits, and all ASCII control
characters are ignored except for HT (horizontal tab, which is expanded to
blanks with assumed tab stops at every eighth column), LF, VT or FF (line
feed, vertical tab or form feed, which generate a new typeout line), and SUB
(CTRL-Z, which by CP/M convention indicates end-of-file and terminates the
typeout). Note that BS (backspace) and CR (carriage return) are ignored, so
that text will not be obscured within files which utilize these for over-
printing (i.e. when directed to a printer).
Directory security depends on the file specification parsing of ZCPR 3.3 or
higher to indicate that the DU or DIR are illegal. Security should be
adequate, however, under other CPR's.
The following filetypes, which are usually associated with binary (non-text)
data, are specifically excluded from typeout operations: COM, EXE, OBJ, OV?,
REL, ?RL, INT, SYS, BAD, LBR, ARC, ARK, ?Q?, and ?Z?. If one of these types
is specified, only the directory information for the requested file is listed.
PROGRAM CONFIGURATION OPTIONS: Several configuration bytes are
available to tailor the program for specific requirements, particularly for
RCP/M systems. With the Wheel byte off, UNARCU can be used by remote
callers only for archive directory listing and, optionally, for member file
typeout.
Note that CRC and file length checking are not performed during a typeout
operation, as they are during extraction to a disk file.
Configuration bytes also determine the default conditions for the N and E
command line options and the filetypes excluded from type-out.
Other configuration points are provided for non-standard systems and need
not concern the majority of users running ZCPR3, NZ-COM, or Z3PLUS.
Patching is accomplished using ZCNFG and the configuration file,
UNARCUnn.CFG, where nn is the current version. The options are discussed
in detail in the CFG file help screens. ZCNFG will find the CFG file
automatically, even if you change the name of the program, as long as you
do not change the name of the CFG file.
PRINTING A FILE IN AN ARCHIVE
-----------------------------
For most users no configuration is necessary.
A single component file in an archive may be output directly to the printer
(CP/M list device) by specifying a trailing "P" on the command line. The "P"
must be the last command line character, and it must be separated from the
second file parameter by a space. (The file parameter must specify a non-
ambiguous file name and no disk drive name.) For example:
ABOUT ARC/ARK FILES: The files which UNARCU processes utilize a format
that was introduced by the ARC shareware utility program, which executes
on 16-bit computers running the MS-DOS (or PC-DOS) operating system.
This format has achieved widespread popularity since the ARC program
first appeared in March 1985, and it has become the de facto standard for
file storage on remote access systems catering to 16-bit computer users.
This file format also achieved popularity on RCP/Ms (Remote CP/M) systems.
While ARC files have given way to ZIP files in general, many ARC files are
available on the web containing CP/M software.
A>UNARC CODES CHARLIE.TXT P
RCP/M system operators adopted the convention of naming CP/M archive
files with the filetype ARK. This differentiates these from MS-DOS archive
files, which use the filetype ARC. This is a naming convention only; there
is no difference in format, and UNARC will accept files of either type
interchangeably.
The specified file is assumed to contain data suitable for printer output and
is passed directly to the printer without alteration or additional formatting.
This operation is particularly well-suited for output of binary graphics
images on dot-matrix printers, since these can be extemely large but tend to
compress quite well (e.g. to less than 5% of their original size). Note that
the binary data filetypes which are excluded from typeout operations are also
excluded from printing operations. Printing may be paused or aborted by use
of the console CTRL-S and CTRL-C characters.
An archive is a group of files compressed and collected together into a
single file in such a way that the individual files may be recovered intact.
In this respect, archives are similar in function to libraries (LBR files),
which have been commonplace on CP/M systems since 1982, when the
original LU library utility program was introduced by Gary P. Novosielski.
The two file formats, however, are not compatible.)
The distinguishing characteristic of an ARC archive is that its component
files are automatically compressed when they are added to the archive, so
that the resulting file occupies a minimum amount of disk space. Of
course, file compression techniques have also been commonplace in the CP/M
world since 1981, when the public domain SQ and USQ "squeeze and
unsqueeze" programs were introduced by Richard Greenlaw.
The SQ/USQ programs and their numerous popular descendants utilize a
well-known general-purpose form of data compression (Huffman coding).
This technique, which is also utilized in ARC files, performs well for many
text files but often produces poor compression of binary files (e.g., object
program COM files). The ARC program also provides an advanced data
compression method, which it terms "crunching." This method (which is
based on the Lempel-Ziv-Welch or "LZW" algorithm) performs better than
squeezing in most cases, often achieving 50% or better compression of ASCII
text files, 15-40% compression of binary object files, and as much as 95%
compression of bit-mapped graphics image files.
CHECKING FILES IN AN ARCHIVE
----------------------------
Five different methods are actually employed for storing files in an
archive. The method chosen for a particular file is the one which results
in the best compression for that file:
1. No compression ("unpacked"). The file is stored in its
original form.
2. Run-length encoding ("packed"). Repeated sequences of 3-
255 identical bytes are compressed into a three-byte sequence.
3. Huffman coding ("squeezed"). Each 8-bit byte (after run-
length encoding) is encoded by a variable number of bits, with
bit length (approximately) inversely proportional to the
frequency of occurence of the corresponding byte.
4. LZW compression ("crunched"). Variable-length strings
of bytes (in theory, up to nearly 4000 bytes in length) are
represented by a single (maximum) 12-bit code (after run-length
encoding).
5. LZW compression ("squashed"). This is a variation of
crunching which uses (maximum) 13-bit codes (and no run-length
encoding).
UNARC may be directed to extract one or more component files from an archive,
without actually storing these as disk files, by specifying a trailing "C" on
the command line. This operation performs file CRC and length checking, and
it is useful for verifying correct modem data transmission of an archive. The
"C" must be the last command line character, and it must be separated from the
second file parameter by a space. (The file parameter must not specify a disk
drive name, which indicates extraction to disk.) To check an entire archive,
specify "*.*" for the second file parameter, for example:
Since one of the five methods involves no compression at all, the resulting
archive entry will never be larger than the original file.
A>UNARC CODES *.* C
The last release of the MS-DOS ARC program (version 5.20) has eliminated
squeezing as a compression technique. However, UNARC continues to
process squeezed files for compatibility with archives created by earlier
versions of ARC and by other MS-DOS archiving programs (notably PKARC).
The squashed compression method was introduced by the MS-DOS programs
PKARC and PKXARC. UNARC can process files which use this method,
although it is not universally accepted by other MS-DOS archive extraction
programs (including ARC).
During its lifetime, the ARC program has undergone numerous revisions
which have employed different variations on some of the above methods,
particularly LZW compression. In order to retain compatibility with
archives created by earlier program revisions, ARC stores a "version"
indicator with each file in an archive. Based on this indicator, the latest
release of the ARC program can always extract files created by older
releases (although it will only use the latest data compression versions when
adding new files to an archive).
PROGRAM OPTIONS
---------------
The current release of UNARC supports archive file versions generated by
all releases of the following MS-DOS programs through (at least) the
indicated program versions:
ARC 5.20 (24 Oct 86), by System Enhancement Associates, Inc.
ARCA 1.22 (13 Sep 86), by Wayne Chin and Vernon Buerg
ARCH 5.38 (26 Jun 86), by Les Satenstein
PKARC 2.0 (15 Dec 86), by Phil Katz (PKWARE, Inc.)
UNARC does not recognize, but is unaffected by, the non-standard archive
and file commenting feature of PKARC.
UNARC provides several options which may be used to tailor the program for
specific non-universal requirements. Many of these are intended for RCP/M
(Remote CP/M) system operators, to allow generation of a secure version of
UNARC which can be used by remote callers for purposes of archive directory
listing and/or file typeout only (but not file extraction). Others are
provided for specialized non-standard CP/M systems and need not concern the
majority of users running CP/M 2.2, CP/M 3.0 (CP/M Plus), or ZCPR3/ZRDOS
systems. Additional options provide user preference features (such as the
number of screen lines between console output pauses, or the list of filetypes
excluded from typeout operations).
Although the above discussion has emphasized the origin of archive files
for the MS-DOS operating system, their use did spread to many other
systems. Programs compatible with MS-DOS ARC have appeared for UNIX,
Atari 68000, VAX/VMS, and TOPS-20 systems. A CP/M utility for building
archive files is also available.
All of these options are described in UNARCOVL.ASM, an assembly language
source file that can be edited and assembled to generate a HEX-format overlay
for easy patching of the UNARC.COM or UNARCA.COM program files. Complete
details are provided for technically-oriented users in UNARCOVL.ASM. However,
the default options in the distributed program files are suitable for the
majority of users with standard CP/M operating systems.
PROGRAM DISTRIBUTION
--------------------
The UNARC program, its documentation, and all related files are distributed in
archive file format (of course!). The distribution file is named UNARCxx.ARK,
where "xx" is derived from the current version number (e.g. UNARC16.ARK for
version 1.6). (This does not include the program source code, which is
distributed separately.) This archive has the special characteristic that it
is "self-unpacking." I.e., a separate copy of the UNARC.COM program file is
NOT required to extract the component files from this archive.
The procedure for extracting the distribution files is quite simple: First,
copy or rename UNARCxx.ARK to a program file, UNARCxx.COM, on the current disk
drive. (Note that the filename, UNARCxx, must NOT be changed.) Then, run
this program with a single optional command line parameter specifying the disk
drive to which all distribution files will be extracted (defaults to current
drive).
For example, assuming UNARC16.ARK is on drive B: and the files are to be
extracted to drive C:, the following CP/M commands may be used:
A>B: ; Set current drive for UNARC16.ARK
B>REN UNARC16.COM=UNARC16.ARK ; Rename it to UNARC16.COM
B>UNARC16 C: ; Run it to extract all files to drive C:
Note that this self-unpacking capability is provided only by the distributed
archive file, and it will not work if that file is altered or reconstructed.
AUTHOR'S NOTE
-------------
I undertook writing the UNARC program to satisfy my curiosity about software
developments in the MS-DOS/PC-DOS world. At the time I began work on UNARC,
the MS-DOS ARC program had been in existence for over a year and had achieved
widespread popularity and acceptance in the 16-bit community. Unfortunately,
the lack of a compatible equivalent for CP/M systems rendered a large amount
of public domain software inaccessible to 8-bit users such as myself. (Note
that 16-bit software can indeed be of interest to users of 8-bit systems, e.g.
Pascal and C language programs.)
Also, an increasing number of RCP/M systems now cater to both 8-bit and 16-bit
users. Since the release of UNARC 1.0 (May 3, 1986), I have been encouraged
to see that the program has found a welcome home on many such systems.
Special thanks are due to Irv Hoff and Norman Beeler for providing archive
file support in the KMD20 and LUX52 series of programs, respectively. With
the increasing popularity of .ARC files on many different computer systems, I
believe that continued such support of this compression format is both
desirable and inevitable for CP/M systems. At the time of this writing I am
about to release NOAH, a companion program to UNARC which will allow CP/M
users to generate ARC-compatible files.
Bob Freed
March 27, 1987
NOTICE
The UNARC program and its associated documentation is the copy-
righted property of its author -- it is NOT in the public domain.
HOWEVER... Free use, distribution, and modification of these
files is permitted (and encouraged), subject to the following
conditions:
(1) Such use or distribution must be for non-profit purposes only.
(2) The author's copyright notice may not be altered or removed.
(3) Modifications to this program or its documentation files may
not be distributed without notification of and approval by
the author.
(4) The source program code may not be used, in whole or in part,
in any other publicly-distributed or derivative work without
similar notification and approval.
No fee is requested or expected for the use and distribution of
this program subject to the above conditions. The author reserves
the right to modify these conditions for any future revisions of
this program. Questions, comments, suggestions, commercial
inquiries, and bug reports or fixes are welcomed by the author:
Robert A. Freed
62 Miller Road
Newton Centre, MA 02159
Telephone (617) 332-3533
------------------------------------------------------------------------------

For additional information about archive files and the MS-DOS ARC utility,
refer to the documentation file, ARC.DOC, which is available on the web.
For additional information about the LZW algorithm (and data compression
methods in general), refer to the article "A Technique for High-Performance
Data Compression", by Terry A. Welch, in IEEE Computer magazine, Vol. 17,
No. 6, June 1984.


Binary file not shown.

View File

@@ -22,6 +22,7 @@
../../Binary/Apps/syscopy.com 15:
../../Binary/Apps/sysgen.com 15:
../../Binary/Apps/talk.com 15:
../../Binary/Apps/htalk.com 15:
../../Binary/Apps/tbasic.com 15:
../../Binary/Apps/timer.com 15:
../../Binary/Apps/tune.com 15:

View File

@@ -18,6 +18,7 @@ d_cpm22/ReadMe.txt 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -34,6 +34,7 @@
../../Binary/Apps/syscopy.com 0:
#../../Binary/Apps/sysgen.com 0:
#../../Binary/Apps/talk.com 0:
#../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -19,6 +19,7 @@ d_cpm22/u0/XSUB.COM 0:
../../Binary/Apps/rtc.com 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/xm.com 0:
#

View File

@@ -22,6 +22,7 @@ d_cpm22/u0/*.* 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -32,6 +32,7 @@
../../Binary/Apps/syscopy.com 15:
../../Binary/Apps/sysgen.com 15:
../../Binary/Apps/talk.com 15:
#../../Binary/Apps/htalk.com 15:
#../../Binary/Apps/tbasic.com 15:
../../Binary/Apps/timer.com 15:
#../../Binary/Apps/tune.com 15:

View File

@@ -31,6 +31,7 @@ d_cpm22/u0/XSUB.COM 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -22,6 +22,7 @@
../../Binary/Apps/syscopy.com 15:
../../Binary/Apps/sysgen.com 15:
../../Binary/Apps/talk.com 15:
../../Binary/Apps/htalk.com 15:
../../Binary/Apps/tbasic.com 15:
../../Binary/Apps/timer.com 15:
../../Binary/Apps/tune.com 15:

View File

@@ -18,6 +18,7 @@ d_cpm22/ReadMe.txt 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -34,6 +34,7 @@
../../Binary/Apps/syscopy.com 0:
#../../Binary/Apps/sysgen.com 0:
#../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -35,6 +35,7 @@ d_zsdos/u0/*.* 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -22,6 +22,7 @@ d_cpm22/u0/*.* 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -33,6 +33,7 @@
../../Binary/Apps/syscopy.com 15:
../../Binary/Apps/sysgen.com 15:
../../Binary/Apps/talk.com 15:
../../Binary/Apps/htalk.com 15:
../../Binary/Apps/tbasic.com 15:
../../Binary/Apps/timer.com 15:
../../Binary/Apps/tune.com 15:

View File

@@ -31,6 +31,7 @@ d_cpm22/u0/XSUB.COM 0:
../../Binary/Apps/syscopy.com 0:
../../Binary/Apps/sysgen.com 0:
../../Binary/Apps/talk.com 0:
../../Binary/Apps/htalk.com 0:
../../Binary/Apps/tbasic.com 0:
../../Binary/Apps/timer.com 0:
../../Binary/Apps/tune.com 0:

View File

@@ -1,42 +1,19 @@
#
# order is actually important, because of build dependencies
#
BUILDPROP := 1
UNAME := $(shell uname)
ifeq ($(UNAME), Linux)
# Inhibit building Propeller on unsupported
# Linux host architectures such as ARM eg. Raspberry Pi
BUILDPROP := 0
ARCH := $(shell uname -m)
ifeq ($(ARCH), x86_64)
BUILDPROP := 1
endif
ifeq ($(ARCH), i686)
BUILDPROP := 1
endif
ifeq ($(ARCH), i386)
BUILDPROP := 1
endif
ifeq ($(ARCH), x86)
BUILDPROP := 1
endif
# Add here any more supported x86 based
# uname machine strings for building Propeller
endif
.PHONY: doc prop shared bp images rom zrc zzrc
.PHONY: doc prop shared bp images rom zrc z1rcc zzrcc
all: prop shared images rom zrc zzrc
.ONESHELL:
.SHELLFLAGS = -cex
all: prop shared images rom zrc z1rcc zzrcc
doc:
$(MAKE) --directory Doc $(ACTION)
prop:
ifeq ($(BUILDPROP), 1)
$(MAKE) --directory Prop $(ACTION)
else
$(info Builing Propeller is not supported on this $(ARCH) host Linux OS)
endif
shared:
$(MAKE) --directory HDIAG $(ACTION)
@@ -67,14 +44,14 @@ rom:
zrc:
$(MAKE) --directory ZRC $(ACTION)
zzrc:
$(MAKE) --directory ZZRC $(ACTION)
z1rcc:
$(MAKE) --directory Z1RCC $(ACTION)
zzrcc:
$(MAKE) --directory ZZRCC $(ACTION)
clean: ACTION=clean
clean: all
diff: ACTION=diff
diff: all

View File

@@ -3,17 +3,17 @@ setlocal
set TOOLS=../../Tools
set PATH=%TOOLS%\bst;%PATH%
set PATH=%TOOLS%\OpenSpin;%PATH%
call :bstc PropIO
call :bstc PropIO2
call :bstc ParPortProp
call :openspin PropIO
call :openspin PropIO2
call :openspin ParPortProp
goto :eof
:bstc
:openspin
echo.
echo Building %1...
bstc Spin\%1 -e -l || exit /b
move /Y %1.eeprom "..\..\Binary" || exit /b
openspin -e Spin\%1.spin || exit /b
move /Y Spin\%1.eeprom "..\..\Binary" || exit /b
goto :eof

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