mirror of https://github.com/wwarthen/RomWBW.git
108 changed files with 12113 additions and 1976 deletions
@ -1,9 +1,10 @@ |
|||
@echo off |
|||
|
|||
setlocal |
|||
|
|||
pushd Source && call Clean && popd |
|||
|
|||
if exist *.img del *.img /Q |
|||
if exist debug.log del debug.log |
|||
if exist *.log del *.log /Q |
|||
|
|||
if exist Output\*.* del Output\*.* /Q |
|||
|
|||
Binary file not shown.
File diff suppressed because it is too large
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,159 +0,0 @@ |
|||
param([string]$Platform = "", [string]$Config = "", [string]$RomSize = "", [string]$SYS = "", [string]$RomName = "") |
|||
|
|||
$Platform = $Platform.ToUpper() |
|||
while ($true) |
|||
{ |
|||
if (($Platform -eq "N8VEM") -or ($Platform -eq "ZETA") -or ($Platform -eq "N8") -or ($Platform -eq "MK4") -or ($Platform -eq "S2I") -or ($Platform -eq "S100")) {break} |
|||
$Platform = (Read-Host -prompt "Platform [N8VEM|ZETA|N8|MK4|S2I|S100]").Trim().ToUpper() |
|||
} |
|||
|
|||
while ($true) |
|||
{ |
|||
$ConfigFile = "config_${Platform}_${Config}.asm" |
|||
if (Test-Path $ConfigFile) {break} |
|||
if ($Config -ne "") {Write-Host "${ConfigFile} does not exist!"} |
|||
|
|||
"Configurations available:" |
|||
Get-Item "config_${Platform}_*.asm" | foreach {Write-Host " >", $_.Name.Substring(8 + $Platform.Length, $_.Name.Length - 12 - $Platform.Length)} |
|||
$Config = (Read-Host -prompt "Configuration").Trim() |
|||
} |
|||
|
|||
while ($true) |
|||
{ |
|||
if (($RomSize -eq "512") -or ($RomSize -eq "1024")) {break} |
|||
$RomSize = (Read-Host -prompt "ROM Size [512|1024]").Trim() |
|||
} |
|||
|
|||
if (($Platform -eq "N8") -or ($Platform -eq "MK4")) {$CPUType = "180"} else {$CPUType = "80"} |
|||
|
|||
$SYS = $SYS.ToUpper() |
|||
while ($true) |
|||
{ |
|||
if (($SYS -eq "CPM") -or ($SYS -eq "ZSYS")) {break} |
|||
$SYS = (Read-Host -prompt "System [CPM|ZSYS]").Trim().ToUpper() |
|||
} |
|||
|
|||
if ($RomName -eq "") {$RomName = "${Platform}_${Config}"} |
|||
while ($RomName -eq "") |
|||
{ |
|||
$CP = (Read-Host -prompt "ROM Name [${Config}]").Trim() |
|||
if ($RomName -eq "") {$RomName = $Config} |
|||
} |
|||
|
|||
$ErrorAction = 'Stop' |
|||
|
|||
$TasmPath = '..\tools\tasm32' |
|||
$CpmToolsPath = '..\tools\cpmtools' |
|||
|
|||
$env:TASMTABS = $TasmPath |
|||
$env:PATH = $TasmPath + ';' + $CpmToolsPath + ';' + $env:PATH |
|||
|
|||
$OutDir = "../OutputUNALOAD" |
|||
$RomFmt = "n8vem_rom${RomSize}" |
|||
$BlankFile = "blank${RomSize}KB-UNALOAD.dat" |
|||
$RomDiskFile = "RomDisk.tmp" |
|||
$RomFile = "${OutDir}/${RomName}.rom" |
|||
$SysImgFile = "${OutDir}/${RomName}.sys" |
|||
$LoaderFile = "${OutDir}/${RomName}.com" |
|||
|
|||
"" |
|||
"Building ${RomName}: ${ROMSize}KB ROM configuration ${Config} for Z${CPUType}..." |
|||
"" |
|||
|
|||
$TimeStamp = '"' + (Get-Date -Format 'dd-MMM-yyyy') + '"' |
|||
|
|||
Function Asm($Component, $Opt, $Architecture=$CPUType, $Output="${Component}.bin") |
|||
{ |
|||
$Cmd = "tasm -t${Architecture} -g3 ${Opt} ${Component}.asm ${Output}" |
|||
$Cmd | write-host |
|||
Invoke-Expression $Cmd | write-host |
|||
if ($LASTEXITCODE -gt 0) {throw "TASM returned exit code $LASTEXITCODE"} |
|||
} |
|||
|
|||
Function Concat($InputFileList, $OutputFile) |
|||
{ |
|||
Set-Content $OutputFile -Value $null |
|||
foreach ($InputFile in $InputFileList) |
|||
{ |
|||
Add-Content $OutputFile -Value ([System.IO.File]::ReadAllBytes($InputFile)) -Encoding byte |
|||
} |
|||
} |
|||
|
|||
# Generate the build settings include file |
|||
|
|||
@" |
|||
; RomWBW Configured for ${Platform} ${Config}, $(Get-Date -Format "s") |
|||
; |
|||
#DEFINE TIMESTAMP ${TimeStamp} |
|||
; |
|||
#DEFINE UNALOAD |
|||
; |
|||
ROMSIZE .EQU ${ROMSize} ; SIZE OF ROM IN KB |
|||
PLATFORM .EQU PLT_${Platform} ; HARDWARE PLATFORM |
|||
; |
|||
; INCLUDE PLATFORM SPECIFIC DEVICE DEFINITIONS |
|||
; |
|||
#INCLUDE "std-n8vem.inc" |
|||
; |
|||
#INCLUDE "${ConfigFile}" |
|||
; |
|||
"@ | Out-File "build.inc" -Encoding ASCII |
|||
|
|||
# Build components |
|||
|
|||
if ($SYS -eq "CPM") |
|||
{ |
|||
# Asm 'ccpb03' -Output 'cp.bin' |
|||
# Asm 'bdosb01' -Output 'dos.bin' |
|||
|
|||
# Copy-Item '..\cpm22\ccpb03.bin' 'cp.bin' |
|||
# Copy-Item '..\cpm22\bdosb01.bin' 'dos.bin' |
|||
|
|||
# Copy-Item '..\cpm22\ccp22.bin' 'cp.bin' |
|||
# Copy-Item '..\cpm22\bdos22.bin' 'dos.bin' |
|||
|
|||
Copy-Item '..\cpm22\os2ccp.bin' 'cp.bin' |
|||
Copy-Item '..\cpm22\os3bdos.bin' 'dos.bin' |
|||
} |
|||
if ($SYS -eq "ZSYS") |
|||
{ |
|||
Copy-Item '..\zcpr-dj\zcpr.bin' 'cp.bin' |
|||
Copy-Item '..\zsdos\zsdos.bin' 'dos.bin' |
|||
} |
|||
|
|||
Asm 'syscfg' |
|||
Asm 'cbios' "-dBLD_SYS=SYS_${SYS}" |
|||
Asm 'dbgmon' |
|||
Asm 'prefix' |
|||
Asm 'bootrom' |
|||
Asm 'bootapp' |
|||
Asm 'loader' |
|||
Asm 'pgzero' |
|||
Asm 'hbios' |
|||
Asm 'hbfill' |
|||
Asm 'romfill' |
|||
|
|||
# Generate result files using components above |
|||
|
|||
"Building ${RomName} output files..." |
|||
|
|||
Concat 'cp.bin','dos.bin','cbios.bin' 'os.bin' |
|||
Concat 'prefix.bin','os.bin' $SysImgFile |
|||
Concat 'pgzero.bin','bootrom.bin','syscfg.bin','loader.bin','romfill.bin','dbgmon.bin','os.bin','hbfill.bin' 'rom1.bin' |
|||
Concat 'pgzero.bin','bootrom.bin','syscfg.bin','loader.bin','hbios.bin' 'rom2.bin' |
|||
Concat 'bootapp.bin','syscfg.bin','loader.bin','hbios.bin','dbgmon.bin','os.bin' $LoaderFile |
|||
|
|||
# Create the RomDisk image |
|||
|
|||
"Building ${RomSize}KB ${RomName} ROM disk data file..." |
|||
|
|||
Copy-Item $BlankFile $RomDiskFile |
|||
cpmcp -f $RomFmt $RomDiskFile ../RomDsk/${SYS}_${RomSize}KB/*.* 0: |
|||
cpmcp -f $RomFmt $RomDiskFile ../RomDsk/cfg_${Platform}_${Config}/*.* 0: |
|||
cpmcp -f $RomFmt $RomDiskFile ../Apps/*.com 0: |
|||
cpmcp -f $RomFmt $RomDiskFile ${OutDir}/${RomName}.sys 0:${SYS}.sys |
|||
|
|||
Concat '..\UNA\unaboot.bin','..\UNA\unabios.bin','rom1.bin','..\UNA\unafat.bin','rom2.bin',$RomDiskFile $RomFile |
|||
|
|||
# Cleanup |
|||
Remove-Item $RomDiskFile |
|||
@ -0,0 +1,108 @@ |
|||
; |
|||
;================================================================================================== |
|||
; ROMWBW 2.X CONFIGURATION FOR ZETA W/ PPISD |
|||
;================================================================================================== |
|||
; |
|||
; BUILD CONFIGURATION OPTIONS |
|||
; |
|||
CPUFREQ .EQU 20 ; IN MHZ, USED TO COMPUTE DELAY FACTORS |
|||
; |
|||
BOOTCON .EQU CIODEV_UART ; CONSOLE DEVICE FOR BOOT MESSAGES (MUST BE PRIMARY SERIAL PORT FOR PLATFORM) |
|||
DEFCON .EQU CIODEV_UART ; DEFAULT CONSOLE DEVICE (LOADER AND MONITOR): CIODEV_UART, CIODEV_CRT, CIODEV_PRPCON, CIODEV_PPPCON |
|||
ALTCON .EQU DEFCON ; ALT CONSOLE DEVICE (USED WHEN CONFIG JUMPER SHORTED) |
|||
CONBAUD .EQU 38400 ; BAUDRATE FOR CONSOLE DURING HARDWARE INIT |
|||
DEFVDA .EQU VDADEV_NONE ; DEFAULT VDA DEVICE (VDADEV_NONE, VDADEV_VDU, VDADEV_CVDU, VDADEV_N8V, VDADEV_UPD7220) |
|||
DEFEMU .EQU EMUTYP_TTY ; DEFAULT VDA EMULATION (EMUTYP_TTY, EMUTYP_ANSI, ...) |
|||
TERMTYPE .EQU TERM_ANSI ; TERM_TTY=0, TERM_ANSI=1, TERM_WYSE=2 |
|||
; |
|||
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB, MUST MATCH YOUR HARDWARE!!! |
|||
CLRRAMDISK .EQU CLR_AUTO ; CLR_ALWAYS, CLR_NEVER, CLR_AUTO (CLEAR IF INVALID DIR AREA) |
|||
; |
|||
DSKYENABLE .EQU FALSE ; TRUE FOR DSKY SUPPORT (DO NOT COMBINE WITH PPIDE) |
|||
; |
|||
SIMRTCENABLE .EQU FALSE ; SIMH CLOCK DRIVER |
|||
DSRTCENABLE .EQU TRUE ; DS-1302 CLOCK DRIVER |
|||
; |
|||
UARTENABLE .EQU TRUE ; TRUE FOR UART SUPPORT (ALMOST ALWAYS WANT THIS TO BE TRUE) |
|||
UARTCNT .EQU 1 ; NUMBER OF UARTS |
|||
UART0IOB .EQU $68 ; UART0 IOBASE |
|||
UART0BAUD .EQU CONBAUD ; UART0 BAUDRATE |
|||
UART0FIFO .EQU TRUE ; UART0 TRUE ENABLES UART FIFO (16550 ASSUMED, N8VEM AND ZETA ONLY) |
|||
UART0AFC .EQU FALSE ; UART0 TRUE ENABLES AUTO FLOW CONTROL (YOUR TERMINAL/UART MUST SUPPORT RTS/CTS FLOW CONTROL!!!) |
|||
; |
|||
ASCIENABLE .EQU FALSE ; TRUE FOR Z180 ASCI SUPPORT |
|||
ASCI0BAUD .EQU CONBAUD ; ASCI0 BAUDRATE (IMPLEMENTED BY Z180_CNTLB0) |
|||
ASCI1BAUD .EQU CONBAUD ; ASCI1 BAUDRATE (IMPLEMENTED BY Z180_CNTLB1) |
|||
; |
|||
VDUENABLE .EQU FALSE ; TRUE FOR VDU BOARD SUPPORT |
|||
CVDUENABLE .EQU FALSE ; TRUE FOR CVDU BOARD SUPPORT |
|||
UPD7220ENABLE .EQU FALSE ; TRUE FOR uPD7220 BOARD SUPPORT |
|||
N8VENABLE .EQU FALSE ; TRUE FOR N8 (TMS9918) VIDEO/KBD SUPPORT |
|||
; |
|||
DEFIOBYTE .EQU $00 ; DEFAULT INITIAL VALUE FOR CP/M IOBYTE, $00=TTY, $01=CRT (MUST HAVE CRT HARDWARE) |
|||
ALTIOBYTE .EQU DEFIOBYTE ; ALT INITIAL VALUE (USED WHEN CONFIG JUMPER SHORTED) |
|||
WRTCACHE .EQU TRUE ; ENABLE WRITE CACHING IN CBIOS (DE)BLOCKING ALGORITHM |
|||
DSKTRACE .EQU FALSE ; ENABLE TRACING OF CBIOS DISK FUNCTION CALLS |
|||
; |
|||
MDENABLE .EQU TRUE ; TRUE FOR ROM/RAM DISK SUPPORT (ALMOST ALWAYS WANT THIS ENABLED) |
|||
MDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF MDENABLE = TRUE) |
|||
; |
|||
FDENABLE .EQU TRUE ; TRUE FOR FLOPPY SUPPORT |
|||
FDMODE .EQU FDMODE_ZETA2 ; FDMODE_DIO, FDMODE_ZETA, FDMODE_DIDE, FDMODE_N8, FDMODE_DIO3 |
|||
FDTRACE .EQU 1 ; 0=SILENT, 1=FATAL ERRORS, 2=ALL ERRORS, 3=EVERYTHING (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIA .EQU FDM144 ; FDM720, FDM144, FDM360, FDM120 (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIAALT .EQU FDM720 ; ALTERNATE MEDIA TO TRY, SAME CHOICES AS ABOVE (ONLY RELEVANT IF FDMAUTO = TRUE) |
|||
FDMAUTO .EQU TRUE ; SELECT BETWEEN MEDIA OPTS ABOVE AUTOMATICALLY |
|||
; |
|||
RFENABLE .EQU FALSE ; TRUE FOR RAM FLOPPY SUPPORT |
|||
; |
|||
IDEENABLE .EQU FALSE ; TRUE FOR IDE SUPPORT |
|||
IDEMODE .EQU IDEMODE_DIO ; IDEMODE_DIO, IDEMODE_DIDE |
|||
IDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
IDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
IDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPIDEENABLE .EQU FALSE ; TRUE FOR PPIDE SUPPORT (DO NOT COMBINE WITH DSKYENABLE) |
|||
PPIDEIOB .EQU $60 ; PPIDE IOBASE |
|||
PPIDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPIDEENABLE = TRUE) |
|||
PPIDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
PPIDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PPIDESLOW .EQU FALSE ; ADD DELAYS TO HELP PROBLEMATIC HARDWARE (TRY THIS IF PPIDE IS UNRELIABLE) |
|||
; |
|||
SDENABLE .EQU TRUE ; TRUE FOR SD SUPPORT |
|||
SDMODE .EQU SDMODE_PPI ; SDMODE_JUHA, SDMODE_CSIO, SDMODE_UART, SDMODE_PPI, SDMODE_DSD |
|||
SDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
SDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
SDCSIOFAST .EQU FALSE ; TABLE-DRIVEN BIT INVERTER |
|||
; |
|||
PRPENABLE .EQU FALSE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPIOB .EQU $A8 ; PORT IO ADDRESS BASE |
|||
PRPSDENABLE .EQU TRUE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PRPSDENABLE = TRUE) |
|||
PRPSDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PRPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
PPPENABLE .EQU FALSE ; TRUE FOR PARPORTPROP SUPPORT |
|||
PPPSDENABLE .EQU TRUE ; TRUE FOR PARPORTPROP SD SUPPORT |
|||
PPPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPPENABLE = TRUE) |
|||
PPPSDCAPACITY .EQU 64 ; CAPACITY OF PPP SD DEVICE (IN MB) |
|||
PPPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
HDSKENABLE .EQU FALSE ; TRUE FOR SIMH HDSK SUPPORT |
|||
HDSKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
HDSKCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPKENABLE .EQU FALSE ; TRUE FOR PARALLEL PORT KEYBOARD |
|||
PPKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPKENABLE = TRUE) |
|||
KBDENABLE .EQU FALSE ; TRUE FOR PS/2 KEYBOARD ON I8242 |
|||
KBDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF KBDENABLE = TRUE) |
|||
; |
|||
TTYENABLE .EQU FALSE ; INCLUDE TTY EMULATION SUPPORT |
|||
ANSIENABLE .EQU FALSE ; INCLUDE ANSI EMULATION SUPPORT |
|||
ANSITRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF ANSIENABLE = TRUE) |
|||
; |
|||
BOOTTYPE .EQU BT_MENU ; BT_MENU (WAIT FOR KEYPRESS), BT_AUTO (BOOT_DEFAULT AFTER BOOT_TIMEOUT SECS) |
|||
BOOT_TIMEOUT .EQU 20 ; APPROX TIMEOUT IN SECONDS FOR AUTOBOOT, 0 FOR IMMEDIATE |
|||
BOOT_DEFAULT .EQU 'Z' ; SELECTION TO INVOKE AT TIMEOUT |
|||
; |
|||
#DEFINE AUTOCMD "" ; AUTO STARTUP COMMAND FOR CP/M |
|||
@ -0,0 +1,108 @@ |
|||
; |
|||
;================================================================================================== |
|||
; ROMWBW 2.X CONFIGURATION FOR ZETA W/ PARPORTPROP |
|||
;================================================================================================== |
|||
; |
|||
; BUILD CONFIGURATION OPTIONS |
|||
; |
|||
CPUFREQ .EQU 20 ; IN MHZ, USED TO COMPUTE DELAY FACTORS |
|||
; |
|||
BOOTCON .EQU CIODEV_UART ; CONSOLE DEVICE FOR BOOT MESSAGES (MUST BE PRIMARY SERIAL PORT FOR PLATFORM) |
|||
DEFCON .EQU CIODEV_PPPCON ; DEFAULT CONSOLE DEVICE (LOADER AND MONITOR): CIODEV_UART, CIODEV_CRT, CIODEV_PRPCON, CIODEV_PPPCON |
|||
ALTCON .EQU CIODEV_UART ; ALT CONSOLE DEVICE (USED WHEN CONFIG JUMPER SHORTED) |
|||
CONBAUD .EQU 38400 ; BAUDRATE FOR CONSOLE DURING HARDWARE INIT |
|||
DEFVDA .EQU VDADEV_NONE ; DEFAULT VDA DEVICE (VDADEV_NONE, VDADEV_VDU, VDADEV_CVDU, VDADEV_N8V, VDADEV_UPD7220) |
|||
DEFEMU .EQU EMUTYP_TTY ; DEFAULT VDA EMULATION (EMUTYP_TTY, EMUTYP_ANSI, ...) |
|||
TERMTYPE .EQU TERM_ANSI ; TERM_TTY=0, TERM_ANSI=1, TERM_WYSE=2 |
|||
; |
|||
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB, MUST MATCH YOUR HARDWARE!!! |
|||
CLRRAMDISK .EQU CLR_AUTO ; CLR_ALWAYS, CLR_NEVER, CLR_AUTO (CLEAR IF INVALID DIR AREA) |
|||
; |
|||
DSKYENABLE .EQU FALSE ; TRUE FOR DSKY SUPPORT (DO NOT COMBINE WITH PPIDE) |
|||
; |
|||
SIMRTCENABLE .EQU FALSE ; SIMH CLOCK DRIVER |
|||
DSRTCENABLE .EQU TRUE ; DS-1302 CLOCK DRIVER |
|||
; |
|||
UARTENABLE .EQU TRUE ; TRUE FOR UART SUPPORT (ALMOST ALWAYS WANT THIS TO BE TRUE) |
|||
UARTCNT .EQU 1 ; NUMBER OF UARTS |
|||
UART0IOB .EQU $68 ; UART0 IOBASE |
|||
UART0BAUD .EQU CONBAUD ; UART0 BAUDRATE |
|||
UART0FIFO .EQU TRUE ; UART0 TRUE ENABLES UART FIFO (16550 ASSUMED, N8VEM AND ZETA ONLY) |
|||
UART0AFC .EQU FALSE ; UART0 TRUE ENABLES AUTO FLOW CONTROL (YOUR TERMINAL/UART MUST SUPPORT RTS/CTS FLOW CONTROL!!!) |
|||
; |
|||
ASCIENABLE .EQU FALSE ; TRUE FOR Z180 ASCI SUPPORT |
|||
ASCI0BAUD .EQU CONBAUD ; ASCI0 BAUDRATE (IMPLEMENTED BY Z180_CNTLB0) |
|||
ASCI1BAUD .EQU CONBAUD ; ASCI1 BAUDRATE (IMPLEMENTED BY Z180_CNTLB1) |
|||
; |
|||
VDUENABLE .EQU FALSE ; TRUE FOR VDU BOARD SUPPORT |
|||
CVDUENABLE .EQU FALSE ; TRUE FOR CVDU BOARD SUPPORT |
|||
UPD7220ENABLE .EQU FALSE ; TRUE FOR uPD7220 BOARD SUPPORT |
|||
N8VENABLE .EQU FALSE ; TRUE FOR N8 (TMS9918) VIDEO/KBD SUPPORT |
|||
; |
|||
DEFIOBYTE .EQU $01 ; DEFAULT INITIAL VALUE FOR CP/M IOBYTE, $00=TTY, $01=CRT (MUST HAVE CRT HARDWARE) |
|||
ALTIOBYTE .EQU $00 ; ALT INITIAL VALUE (USED WHEN CONFIG JUMPER SHORTED) |
|||
WRTCACHE .EQU TRUE ; ENABLE WRITE CACHING IN CBIOS (DE)BLOCKING ALGORITHM |
|||
DSKTRACE .EQU FALSE ; ENABLE TRACING OF CBIOS DISK FUNCTION CALLS |
|||
; |
|||
MDENABLE .EQU TRUE ; TRUE FOR ROM/RAM DISK SUPPORT (ALMOST ALWAYS WANT THIS ENABLED) |
|||
MDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF MDENABLE = TRUE) |
|||
; |
|||
FDENABLE .EQU TRUE ; TRUE FOR FLOPPY SUPPORT |
|||
FDMODE .EQU FDMODE_ZETA2 ; FDMODE_DIO, FDMODE_ZETA, FDMODE_DIDE, FDMODE_N8, FDMODE_DIO3 |
|||
FDTRACE .EQU 1 ; 0=SILENT, 1=FATAL ERRORS, 2=ALL ERRORS, 3=EVERYTHING (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIA .EQU FDM144 ; FDM720, FDM144, FDM360, FDM120 (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIAALT .EQU FDM720 ; ALTERNATE MEDIA TO TRY, SAME CHOICES AS ABOVE (ONLY RELEVANT IF FDMAUTO = TRUE) |
|||
FDMAUTO .EQU TRUE ; SELECT BETWEEN MEDIA OPTS ABOVE AUTOMATICALLY |
|||
; |
|||
RFENABLE .EQU FALSE ; TRUE FOR RAM FLOPPY SUPPORT |
|||
; |
|||
IDEENABLE .EQU FALSE ; TRUE FOR IDE SUPPORT |
|||
IDEMODE .EQU IDEMODE_DIO ; IDEMODE_DIO, IDEMODE_DIDE |
|||
IDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
IDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
IDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPIDEENABLE .EQU FALSE ; TRUE FOR PPIDE SUPPORT (DO NOT COMBINE WITH DSKYENABLE) |
|||
PPIDEIOB .EQU $60 ; PPIDE IOBASE |
|||
PPIDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPIDEENABLE = TRUE) |
|||
PPIDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
PPIDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PPIDESLOW .EQU FALSE ; ADD DELAYS TO HELP PROBLEMATIC HARDWARE (TRY THIS IF PPIDE IS UNRELIABLE) |
|||
; |
|||
SDENABLE .EQU FALSE ; TRUE FOR SD SUPPORT |
|||
SDMODE .EQU SDMODE_NONE ; SDMODE_JUHA, SDMODE_CSIO, SDMODE_UART, SDMODE_PPI, SDMODE_DSD |
|||
SDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
SDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
SDCSIOFAST .EQU FALSE ; TABLE-DRIVEN BIT INVERTER |
|||
; |
|||
PRPENABLE .EQU FALSE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPIOB .EQU $A8 ; PORT IO ADDRESS BASE |
|||
PRPSDENABLE .EQU TRUE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PRPSDENABLE = TRUE) |
|||
PRPSDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PRPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
PPPENABLE .EQU TRUE ; TRUE FOR PARPORTPROP SUPPORT |
|||
PPPSDENABLE .EQU TRUE ; TRUE FOR PARPORTPROP SD SUPPORT |
|||
PPPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPPENABLE = TRUE) |
|||
PPPSDCAPACITY .EQU 64 ; CAPACITY OF PPP SD DEVICE (IN MB) |
|||
PPPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
HDSKENABLE .EQU FALSE ; TRUE FOR SIMH HDSK SUPPORT |
|||
HDSKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
HDSKCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPKENABLE .EQU FALSE ; TRUE FOR PARALLEL PORT KEYBOARD |
|||
PPKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPKENABLE = TRUE) |
|||
KBDENABLE .EQU FALSE ; TRUE FOR PS/2 KEYBOARD ON I8242 |
|||
KBDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF KBDENABLE = TRUE) |
|||
; |
|||
TTYENABLE .EQU FALSE ; INCLUDE TTY EMULATION SUPPORT |
|||
ANSIENABLE .EQU FALSE ; INCLUDE ANSI EMULATION SUPPORT |
|||
ANSITRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF ANSIENABLE = TRUE) |
|||
; |
|||
BOOTTYPE .EQU BT_MENU ; BT_MENU (WAIT FOR KEYPRESS), BT_AUTO (BOOT_DEFAULT AFTER BOOT_TIMEOUT SECS) |
|||
BOOT_TIMEOUT .EQU 20 ; APPROX TIMEOUT IN SECONDS FOR AUTOBOOT, 0 FOR IMMEDIATE |
|||
BOOT_DEFAULT .EQU 'Z' ; SELECTION TO INVOKE AT TIMEOUT |
|||
; |
|||
#DEFINE AUTOCMD "" ; AUTO STARTUP COMMAND FOR CP/M |
|||
@ -0,0 +1,108 @@ |
|||
; |
|||
;================================================================================================== |
|||
; ROMWBW 2.X CONFIGURATION FOR ZETA |
|||
;================================================================================================== |
|||
; |
|||
; BUILD CONFIGURATION OPTIONS |
|||
; |
|||
CPUFREQ .EQU 20 ; IN MHZ, USED TO COMPUTE DELAY FACTORS |
|||
; |
|||
BOOTCON .EQU CIODEV_UART ; CONSOLE DEVICE FOR BOOT MESSAGES (MUST BE PRIMARY SERIAL PORT FOR PLATFORM) |
|||
DEFCON .EQU CIODEV_UART ; DEFAULT CONSOLE DEVICE (LOADER AND MONITOR): CIODEV_UART, CIODEV_CRT, CIODEV_PRPCON, CIODEV_PPPCON |
|||
ALTCON .EQU DEFCON ; ALT CONSOLE DEVICE (USED WHEN CONFIG JUMPER SHORTED) |
|||
CONBAUD .EQU 38400 ; BAUDRATE FOR CONSOLE DURING HARDWARE INIT |
|||
DEFVDA .EQU VDADEV_NONE ; DEFAULT VDA DEVICE (VDADEV_NONE, VDADEV_VDU, VDADEV_CVDU, VDADEV_N8V, VDADEV_UPD7220) |
|||
DEFEMU .EQU EMUTYP_TTY ; DEFAULT VDA EMULATION (EMUTYP_TTY, EMUTYP_ANSI, ...) |
|||
TERMTYPE .EQU TERM_ANSI ; TERM_TTY=0, TERM_ANSI=1, TERM_WYSE=2 |
|||
; |
|||
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB, MUST MATCH YOUR HARDWARE!!! |
|||
CLRRAMDISK .EQU CLR_AUTO ; CLR_ALWAYS, CLR_NEVER, CLR_AUTO (CLEAR IF INVALID DIR AREA) |
|||
; |
|||
DSKYENABLE .EQU FALSE ; TRUE FOR DSKY SUPPORT (DO NOT COMBINE WITH PPIDE) |
|||
; |
|||
SIMRTCENABLE .EQU FALSE ; SIMH CLOCK DRIVER |
|||
DSRTCENABLE .EQU TRUE ; DS-1302 CLOCK DRIVER |
|||
; |
|||
UARTENABLE .EQU TRUE ; TRUE FOR UART SUPPORT (ALMOST ALWAYS WANT THIS TO BE TRUE) |
|||
UARTCNT .EQU 1 ; NUMBER OF UARTS |
|||
UART0IOB .EQU $68 ; UART0 IOBASE |
|||
UART0BAUD .EQU CONBAUD ; UART0 BAUDRATE |
|||
UART0FIFO .EQU TRUE ; UART0 TRUE ENABLES UART FIFO (16550 ASSUMED, N8VEM AND ZETA ONLY) |
|||
UART0AFC .EQU FALSE ; UART0 TRUE ENABLES AUTO FLOW CONTROL (YOUR TERMINAL/UART MUST SUPPORT RTS/CTS FLOW CONTROL!!!) |
|||
; |
|||
ASCIENABLE .EQU FALSE ; TRUE FOR Z180 ASCI SUPPORT |
|||
ASCI0BAUD .EQU CONBAUD ; ASCI0 BAUDRATE (IMPLEMENTED BY Z180_CNTLB0) |
|||
ASCI1BAUD .EQU CONBAUD ; ASCI1 BAUDRATE (IMPLEMENTED BY Z180_CNTLB1) |
|||
; |
|||
VDUENABLE .EQU FALSE ; TRUE FOR VDU BOARD SUPPORT |
|||
CVDUENABLE .EQU FALSE ; TRUE FOR CVDU BOARD SUPPORT |
|||
UPD7220ENABLE .EQU FALSE ; TRUE FOR uPD7220 BOARD SUPPORT |
|||
N8VENABLE .EQU FALSE ; TRUE FOR N8 (TMS9918) VIDEO/KBD SUPPORT |
|||
; |
|||
DEFIOBYTE .EQU $00 ; DEFAULT INITIAL VALUE FOR CP/M IOBYTE, $00=TTY, $01=CRT (MUST HAVE CRT HARDWARE) |
|||
ALTIOBYTE .EQU DEFIOBYTE ; ALT INITIAL VALUE (USED WHEN CONFIG JUMPER SHORTED) |
|||
WRTCACHE .EQU TRUE ; ENABLE WRITE CACHING IN CBIOS (DE)BLOCKING ALGORITHM |
|||
DSKTRACE .EQU FALSE ; ENABLE TRACING OF CBIOS DISK FUNCTION CALLS |
|||
; |
|||
MDENABLE .EQU TRUE ; TRUE FOR ROM/RAM DISK SUPPORT (ALMOST ALWAYS WANT THIS ENABLED) |
|||
MDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF MDENABLE = TRUE) |
|||
; |
|||
FDENABLE .EQU TRUE ; TRUE FOR FLOPPY SUPPORT |
|||
FDMODE .EQU FDMODE_ZETA2 ; FDMODE_DIO, FDMODE_ZETA, FDMODE_DIDE, FDMODE_N8, FDMODE_DIO3 |
|||
FDTRACE .EQU 1 ; 0=SILENT, 1=FATAL ERRORS, 2=ALL ERRORS, 3=EVERYTHING (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIA .EQU FDM144 ; FDM720, FDM144, FDM360, FDM120 (ONLY RELEVANT IF FDENABLE = TRUE) |
|||
FDMEDIAALT .EQU FDM720 ; ALTERNATE MEDIA TO TRY, SAME CHOICES AS ABOVE (ONLY RELEVANT IF FDMAUTO = TRUE) |
|||
FDMAUTO .EQU TRUE ; SELECT BETWEEN MEDIA OPTS ABOVE AUTOMATICALLY |
|||
; |
|||
RFENABLE .EQU FALSE ; TRUE FOR RAM FLOPPY SUPPORT |
|||
; |
|||
IDEENABLE .EQU FALSE ; TRUE FOR IDE SUPPORT |
|||
IDEMODE .EQU IDEMODE_DIO ; IDEMODE_DIO, IDEMODE_DIDE |
|||
IDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
IDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
IDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPIDEENABLE .EQU FALSE ; TRUE FOR PPIDE SUPPORT (DO NOT COMBINE WITH DSKYENABLE) |
|||
PPIDEIOB .EQU $60 ; PPIDE IOBASE |
|||
PPIDETRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPIDEENABLE = TRUE) |
|||
PPIDE8BIT .EQU FALSE ; USE IDE 8BIT TRANSFERS (PROBABLY ONLY WORKS FOR CF CARDS!) |
|||
PPIDECAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PPIDESLOW .EQU FALSE ; ADD DELAYS TO HELP PROBLEMATIC HARDWARE (TRY THIS IF PPIDE IS UNRELIABLE) |
|||
; |
|||
SDENABLE .EQU FALSE ; TRUE FOR SD SUPPORT |
|||
SDMODE .EQU SDMODE_PPI ; SDMODE_JUHA, SDMODE_CSIO, SDMODE_UART, SDMODE_PPI, SDMODE_DSD |
|||
SDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
SDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
SDCSIOFAST .EQU FALSE ; TABLE-DRIVEN BIT INVERTER |
|||
; |
|||
PRPENABLE .EQU FALSE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPIOB .EQU $A8 ; PORT IO ADDRESS BASE |
|||
PRPSDENABLE .EQU TRUE ; TRUE FOR PROPIO SD SUPPORT (FOR N8VEM PROPIO ONLY!) |
|||
PRPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PRPSDENABLE = TRUE) |
|||
PRPSDCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
PRPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
PPPENABLE .EQU FALSE ; TRUE FOR PARPORTPROP SUPPORT |
|||
PPPSDENABLE .EQU TRUE ; TRUE FOR PARPORTPROP SD SUPPORT |
|||
PPPSDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPPENABLE = TRUE) |
|||
PPPSDCAPACITY .EQU 64 ; CAPACITY OF PPP SD DEVICE (IN MB) |
|||
PPPCONENABLE .EQU TRUE ; TRUE FOR PROPIO CONSOLE SUPPORT (PS/2 KBD & VGA VIDEO) |
|||
; |
|||
HDSKENABLE .EQU FALSE ; TRUE FOR SIMH HDSK SUPPORT |
|||
HDSKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF IDEENABLE = TRUE) |
|||
HDSKCAPACITY .EQU 64 ; CAPACITY OF DEVICE (IN MB) |
|||
; |
|||
PPKENABLE .EQU FALSE ; TRUE FOR PARALLEL PORT KEYBOARD |
|||
PPKTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF PPKENABLE = TRUE) |
|||
KBDENABLE .EQU FALSE ; TRUE FOR PS/2 KEYBOARD ON I8242 |
|||
KBDTRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF KBDENABLE = TRUE) |
|||
; |
|||
TTYENABLE .EQU FALSE ; INCLUDE TTY EMULATION SUPPORT |
|||
ANSIENABLE .EQU FALSE ; INCLUDE ANSI EMULATION SUPPORT |
|||
ANSITRACE .EQU 1 ; 0=SILENT, 1=ERRORS, 2=EVERYTHING (ONLY RELEVANT IF ANSIENABLE = TRUE) |
|||
; |
|||
BOOTTYPE .EQU BT_MENU ; BT_MENU (WAIT FOR KEYPRESS), BT_AUTO (BOOT_DEFAULT AFTER BOOT_TIMEOUT SECS) |
|||
BOOT_TIMEOUT .EQU 20 ; APPROX TIMEOUT IN SECONDS FOR AUTOBOOT, 0 FOR IMMEDIATE |
|||
BOOT_DEFAULT .EQU 'Z' ; SELECTION TO INVOKE AT TIMEOUT |
|||
; |
|||
#DEFINE AUTOCMD "" ; AUTO STARTUP COMMAND FOR CP/M |
|||
@ -1,10 +1,4 @@ |
|||
# Create a "dummy" rom image, filled with hex E5 |
|||
# |
|||
Set-Content -Value ([byte[]](0xE5) * (512KB - 64KB)) -Encoding byte -Path 'Blank512KB.dat' |
|||
Set-Content -Value ([byte[]](0xE5) * (1MB - 64KB)) -Encoding byte -Path 'Blank1024KB.dat' |
|||
|
|||
Set-Content -Value ([byte[]](0xE5) * (512KB - 128KB)) -Encoding byte -Path 'Blank512KB-UNA.dat' |
|||
Set-Content -Value ([byte[]](0xE5) * (1MB - 128KB)) -Encoding byte -Path 'Blank1024KB-UNA.dat' |
|||
|
|||
Set-Content -Value ([byte[]](0xE5) * (512KB - 160KB)) -Encoding byte -Path 'Blank512KB-UNALOAD.dat' |
|||
Set-Content -Value ([byte[]](0xE5) * (1MB - 160KB)) -Encoding byte -Path 'Blank1024KB-UNALOAD.dat' |
|||
Set-Content -Value ([byte[]](0xE5) * (512KB - 128KB)) -Encoding byte -Path 'Blank512KB.dat' |
|||
Set-Content -Value ([byte[]](0xE5) * (1MB - 128KB)) -Encoding byte -Path 'Blank1024KB.dat' |
|||
|
|||
@ -0,0 +1,121 @@ |
|||
;___BOOTAPP____________________________________________________________________________________________________________ |
|||
; |
|||
; APPLICATION BOOT MANAGER |
|||
; |
|||
; USED TO LOAD AN APPLICATION IMAGE BASED COPY OF THE SYSTEM |
|||
; REFER TO BANKEDBIOS.TXT FOR MORE INFORMATION. |
|||
;______________________________________________________________________________________________________________________ |
|||
; |
|||
; MEMORY MAP |
|||
; |
|||
; LOC LEN DESC |
|||
; ----- ----- -------------- |
|||
; $0000 $1000 BOOTAPP CODE |
|||
; $1000 $1000 DBGMON IMAGE |
|||
; $2000 $3000 CPM IMAGE |
|||
; $5000 $3000 ZSYS IMAGE |
|||
; $8000 *** END *** |
|||
; |
|||
#INCLUDE "std.asm" |
|||
; |
|||
.ORG $100 |
|||
; |
|||
DI ; NO INTERRUPTS |
|||
IM 1 ; INTERRUPT MODE 1 |
|||
LD SP,STACK ; PRIVATE STACK |
|||
; |
|||
; BANNER |
|||
CALL NEWLINE |
|||
LD DE,STR_BANNER |
|||
CALL WRITESTR |
|||
; |
|||
MENU: |
|||
CALL NEWLINE |
|||
CALL NEWLINE |
|||
LD DE,STR_BOOTMENU |
|||
CALL WRITESTR |
|||
CALL CINUC |
|||
CP 'M' ; MONITOR |
|||
JP Z,GOMON |
|||
CP 'C' ; CP/M BOOT FROM ROM |
|||
JP Z,GOCPM |
|||
CP 'Z' ; ZSYSTEM BOOT FROM ROM |
|||
JP Z,GOZSYS |
|||
; |
|||
LD DE,STR_INVALID |
|||
CALL WRITESTR |
|||
JR MENU |
|||
; |
|||
GOMON: |
|||
LD DE,STR_BOOTMON |
|||
CALL WRITESTR |
|||
LD HL,$1000 |
|||
LD DE,$C000 |
|||
LD BC,$1000 |
|||
LDIR |
|||
JP MON_SERIAL |
|||
; |
|||
GOCPM: |
|||
LD DE,STR_BOOTCPM |
|||
CALL WRITESTR |
|||
LD HL,$2000 |
|||
LD DE,CPM_LOC |
|||
LD BC,$3000 - $400 |
|||
LDIR |
|||
#IF (PLATFORM == PLT_UNA) |
|||
LD DE,$0100 ; BOOT DEV/UNIT/LU=0 (ROM DRIVE) |
|||
#ELSE |
|||
LD DE,$0000 ; BOOT DEV/UNIT/LU=0 (ROM DRIVE) |
|||
#ENDIF |
|||
JP CPM_ENT |
|||
; |
|||
GOZSYS: |
|||
LD DE,STR_BOOTZSYS |
|||
CALL WRITESTR |
|||
LD HL,$5000 |
|||
LD DE,CPM_LOC |
|||
LD BC,$3000 - $400 |
|||
LDIR |
|||
#IF (PLATFORM == PLT_UNA) |
|||
LD DE,$0100 ; BOOT DEV/UNIT/LU=0 (ROM DRIVE) |
|||
#ELSE |
|||
LD DE,$0000 ; BOOT DEV/UNIT/LU=0 (ROM DRIVE) |
|||
#ENDIF |
|||
JP CPM_ENT |
|||
; |
|||
; READ A CONSOLE CHARACTER AND CONVERT TO UPPER CASE |
|||
; |
|||
CINUC: |
|||
CALL CIN |
|||
AND 7FH ; STRIP HI BIT |
|||
CP 'A' ; KEEP NUMBERS, CONTROLS |
|||
RET C ; AND UPPER CASE |
|||
CP 7BH ; SEE IF NOT LOWER CASE |
|||
RET NC |
|||
AND 5FH ; MAKE UPPER CASE |
|||
RET |
|||
; |
|||
#DEFINE CIOMODE_HBIOS |
|||
#INCLUDE "util.asm" |
|||
; |
|||
; STRINGS |
|||
;_____________________________________________________________________________________________________________________________ |
|||
; |
|||
STR_BOOTMON .DB "START MONITOR\r\n$" |
|||
STR_BOOTCPM .DB "BOOT CPM FROM ROM\r\n$" |
|||
STR_BOOTZSYS .DB "BOOT ZSYSTEM FROM ROM\r\n$" |
|||
STR_INVALID .DB "INVALID SELECTION\r\n$" |
|||
; |
|||
STR_BANNER .DB "\r\n", PLATFORM_NAME, " Boot Loader$" |
|||
STR_BOOTMENU .DB "\r\nBoot: (C)PM, (Z)System, (M)onitor,\r\n" |
|||
.DB " (L)ist devices, or Device ID ===> $" |
|||
; |
|||
;______________________________________________________________________________________________________________________ |
|||
; |
|||
; PAD OUT REMAINDER |
|||
; |
|||
.FILL $1000 - $,$FF ; PAD OUT REMAINDER |
|||
; |
|||
STACK .EQU $ ; STACK IN SLACK SPACE |
|||
; |
|||
.END |
|||
@ -0,0 +1,829 @@ |
|||
UNA error codes |
|||
=============== |
|||
|
|||
All UNA BIOS calls return a completion code in the C-register. If no |
|||
error has occurred, the code will be Zero, and the Z-flag will be |
|||
set. If any error has occurred, the Z-flag will be clear, and the |
|||
C-register indicates the nature of the error. |
|||
|
|||
|
|||
Calling conventions: |
|||
=================== |
|||
|
|||
UNA BIOS calls are made with a function code in the C-register. Some |
|||
calls will have a unit number in the B-register; other calls will |
|||
have a subfunction number in the B-register. Parameters are passed |
|||
in the other registers, as documented for each BIOS call. The BIOS |
|||
is invoked with an "RST 8" single-byte instruction. |
|||
|
|||
Values are returned in various registers, or buffers, as specified |
|||
for each function call. Unless a value is specifically returned in a |
|||
register, the register is preserved across the BIOS call. The |
|||
exception to this rule is the AF register. Neither is preserved; and |
|||
the Flags-register always returns the Z-flag to indicate any error |
|||
condition (set==no error, clear==error code in C-register). |
|||
|
|||
|
|||
Error codes: |
|||
=========== |
|||
|
|||
; error.s |
|||
|
|||
; error codes follow |
|||
NO_ERROR = 0 |
|||
; |
|||
; Mild errors 1..63 |
|||
; |
|||
ERR_NOT_YET = 1 ; Method still being implemented |
|||
|
|||
; Definite errors 64..127 |
|||
; |
|||
ERR_UNKNOWN = 65 ; Unknown call |
|||
ERR_UNIT_NO = 66 ; unit no. bad |
|||
ERR_METHOD = 67 ; method number is bad |
|||
ERR_ADDRESS = 68 ; address out of range (must be >=0x8000) |
|||
ERR_DECODE = 69 ; not an encoded value (decode.s) |
|||
ERR_CAPACITY = 70 ; LBA address beyond disk capacity |
|||
ERR_NO_MEDIA = 71 ; no Media in drive socket |
|||
ERR_WRONG_MEDIA = 72 ; not SDSC or SDHC |
|||
ERR_WRITE_PROT = 73 ; media is write-protected |
|||
|
|||
ERR_NO_PROTO = 129 ; no Instance prototype found |
|||
ERR_NO_MEMORY = 130 ; ran out of Heap memory |
|||
ERR_NO_UNIT = 131 ; no new unit available |
|||
ERR_SIO_BAUD = 132 ; serial baud rate setup not possible |
|||
ERR_DISK_IO = 133 ; disk I/O error |
|||
ERR_TIMEOUT = 134 ; timeout |
|||
ERR_CRC16 = 135 ; CRC16 error on data read |
|||
|
|||
CATASTROPHE_HEAP = 241 ; HEAP catastrophe |
|||
DRIVE_TRANSFER_NOT_SET = 242 ; DRIVE NOT 8 & NOT 16 BIT |
|||
|
|||
|
|||
;end error.s |
|||
|
|||
|
|||
|
|||
BIOS calls: |
|||
========== |
|||
|
|||
|
|||
*** Serial I/O calls |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 10 -- INIT |
|||
; |
|||
; Enter with: |
|||
; C = 0x10 |
|||
; B = unit number |
|||
; DE = setup parameters or -1 (use previous values) |
|||
; |
|||
; Exit with: |
|||
; C = error code (0==no error) |
|||
; Z flag is clear/set on error/no error |
|||
; |
|||
; Setup Parameter Word: |
|||
; _______________________________ _______________________________ |
|||
; | | | encoded || | | | | | |
|||
; | |rts| Baud Rate ||dtr|xon| parity |stp| 8/7/6 | |
|||
; |_______|___|___|_______________||___|___|___________|___|_______| |
|||
; 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 |
|||
; D register E register |
|||
; |
|||
; _______________________________ _______________________________ |
|||
; | | re| te|~rs| er|8/7 pe stp|| | | | | | | |
|||
; | 0 | 1 | 1 | 0 | 0 | m2 m1 m0|| 0 | 0 | ps|peo| dr| SSS | |
|||
; |___|___|___|___|___|___________||___|___|___|___|___|___________| |
|||
; 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0 |
|||
; CNTLA0 CNTLB0 |
|||
; |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 11 -- Read a character (wait for input) |
|||
; |
|||
; Enter with: |
|||
; C = 0x11 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; E = character read in |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 12 -- Write a character |
|||
; |
|||
; Enter with: |
|||
; C = 0x12 function code |
|||
; B = unit number |
|||
; E = character to write out |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 13 -- Input status (number of waiting characters) |
|||
; |
|||
; Enter with: |
|||
; C = 0x13 |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; E = number of characters in input queue |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 14 -- Output status (space available in output buffer) |
|||
; |
|||
; Enter with: |
|||
; C = 0x13 |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; E = number of empty character slots in output queue |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 15 -- Output characters until terminator |
|||
; i.e., output string |
|||
; |
|||
; Enter with: |
|||
; C = 0x15 |
|||
; B = unit number |
|||
; DE = buffer address |
|||
; L = terminator (usually NUL or '$') |
|||
; |
|||
; Exit with: |
|||
; C = completion code |
|||
; All other registers preserved |
|||
; |
|||
; Errors: |
|||
; NO_ERROR Z flag is set |
|||
; ERR_ADDRESS Z flag is clear (NZ) |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 16 -- Input count characters |
|||
; |
|||
; Enter with: |
|||
; C = 0x16 |
|||
; B = unit number |
|||
; DE = buffer address |
|||
; HL = count of characters to input |
|||
; |
|||
; Exit with: |
|||
; C = completion code |
|||
; HL = count of characters actually read |
|||
; All other registers preserved |
|||
; |
|||
; Errors: |
|||
; NO_ERROR Z flag is set |
|||
; XXX Z flag is clear (NZ) |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 17 -- Output count characters |
|||
; |
|||
; Enter with: |
|||
; C = 0x17 |
|||
; B = unit number |
|||
; DE = buffer address |
|||
; HL = count of characters to put out |
|||
; |
|||
; Exit with: |
|||
; C = completion code |
|||
; HL = count of characters actually put out |
|||
; All other registers preserved |
|||
; |
|||
; Errors: |
|||
; NO_ERROR Z flag is set |
|||
; XXX Z flag is clear (NZ) |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
*** IDE disk calls (c.f., SD card disk calls) |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 40 -- Reset the IDE device and controller |
|||
; |
|||
; Enter with: |
|||
; C = 0x40 function code |
|||
; B = unit number (0...) |
|||
; D = flags2 values |
|||
; E = flags value |
|||
; DE == -1 means use previously set values |
|||
; |
|||
; Exit with: |
|||
; C = error code, or success=0 |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 41 -- set Logical Block Address for next transfer |
|||
; |
|||
; Enter with: |
|||
; C = 0x41 function code |
|||
; B = unit number |
|||
; DE:HL = 28-bit LBA address of next transfer (R/W) |
|||
; |
|||
; Exit with: |
|||
; C = error code |
|||
; |
|||
; Errors: |
|||
; ERR_CAPACITY LBA address exceeds drive capacity |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 42 -- Read Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x42 function code |
|||
; B = unit number |
|||
; DE = address of n*512 byte buffer |
|||
; L = number of sectors to read |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; DE = unchanged |
|||
; L = number of sectors read |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 43 -- Write Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x43 function code |
|||
; B = unit number |
|||
; DE = address of n*512 byte buffer |
|||
; L = number of sectors to write |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; DE = unchanged |
|||
; L = number of sectors written |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 44 -- Verify Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x44 function code |
|||
; B = unit number |
|||
; L = number of sectors to verify |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; L = number of sectors verified |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 45 -- Get IDE Disk Information |
|||
; |
|||
; Enter with: |
|||
; C = 0x45 function code |
|||
; B = unit number |
|||
; DE = pointer to 512 byte buffer (first call) |
|||
; if DE == null (0), then return what was previously noted |
|||
; |
|||
; Exit with: |
|||
; B = 'or' of flags and flags2 |
|||
; DE:HL = sector capacity of the disk |
|||
; |
|||
; |
|||
; LBA capacity of disk noted in private instance data |
|||
; logical CHS information noted |
|||
; disk ID string noted |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_TIMEOUT |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 46 -- Get Disk Geometry Information |
|||
; |
|||
; Enter with: |
|||
; C = 0x46 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; DE = number of cylinders |
|||
; H = number of heads per cylinder |
|||
; L = number of sectors per track |
|||
; |
|||
; Errors: |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 47 -- Get Disk Error Status |
|||
; |
|||
; Enter with: |
|||
; C = 0x47 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; D = contents of Status register after last operation |
|||
; E = contents of Error register after last operation |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 48 -- Get Disk Type |
|||
; |
|||
; Enter with: |
|||
; C = 0x48 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; D = disk driver ID |
|||
; E = disk software type (may be different from Floppies) |
|||
; L = total disk units in the system |
|||
; H = disk physical type (pertinent to Floppies) |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
*** SDcard disk calls (c.f., IDE disk calls) |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 40 -- Reset the Disk device and controller |
|||
; |
|||
; Enter with: |
|||
; C = 0x40 function code |
|||
; B = unit number (0...) |
|||
; D = flags2 values |
|||
; E = flags value |
|||
; DE == -1 means use previously set values |
|||
; |
|||
; Exit with: |
|||
; C = error code, or success=0 |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 41 -- set Logical Block Address for next transfer |
|||
; |
|||
; Enter with: |
|||
; C = 0x41 function code |
|||
; B = unit number |
|||
; DE:HL = 32-bit LBA address of next transfer (R/W) |
|||
; |
|||
; Exit with: |
|||
; C = error code |
|||
; |
|||
; Errors: |
|||
; ERR_CAPACITY LBA address exceeds drive capacity |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 42 -- Read Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x42 function code |
|||
; B = unit number |
|||
; DE = address of n*512 byte buffer |
|||
; L = number of sectors to read |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; DE = unchanged |
|||
; L = number of sectors read |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_NO_MEDIA |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 43 -- Write Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x43 function code |
|||
; B = unit number |
|||
; DE = address of n*512 byte buffer |
|||
; L = number of sectors to write |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; DE = unchanged |
|||
; L = number of sectors written |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_NO_MEDIA |
|||
; ERR_WRITE_PROT |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 44 -- Verify Sectors |
|||
; |
|||
; Enter with: |
|||
; C = 0x44 function code |
|||
; B = unit number |
|||
; L = number of sectors to verify |
|||
; |
|||
; Exit with: |
|||
; C = 0 if no error |
|||
; L = number of sectors verified |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 45 -- Get (IDE) Disk Information |
|||
; |
|||
; Enter with: |
|||
; C = 0x45 function code |
|||
; B = unit number |
|||
; DE = pointer to 512 byte buffer (36 bytes used for SD cards) |
|||
; if DE == NULL(0), then nothing is to be returned in the buffer |
|||
; |
|||
; Exit with: |
|||
; B = 'or' of flags and flags2 |
|||
; DE:HL = sector capacity of the disk |
|||
; |
|||
; Buffer contains CID, CSD, OCR information from Function 40 call |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 46 -- Get Disk Geometry Information |
|||
; |
|||
; Enter with: |
|||
; C = 0x46 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; DE = number of cylinders |
|||
; H = number of heads per cylinder |
|||
; L = number of sectors per track |
|||
; |
|||
; Errors: |
|||
; ERR_DISK_IO |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 47 -- Get Disk Error Status |
|||
; |
|||
; Enter with: |
|||
; C = 0x47 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; D = contents of Status register after last operation |
|||
; E = contents of Error register after last operation |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 48 -- Get Disk Type |
|||
; |
|||
; Enter with: |
|||
; C = 0x48 function code |
|||
; B = unit number |
|||
; |
|||
; Exit with: |
|||
; D = disk driver ID |
|||
; E = disk software type (may be different from Floppies) |
|||
; L = total disk units in the system |
|||
; H = disk physical type (pertinent to Floppies) |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
*** CPU functions with no Unit number |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF0 RESET / INITIALIZE |
|||
; |
|||
; Enter with: |
|||
; C = 0xF0 |
|||
; |
|||
; Exit with: |
|||
; DE = lowest heap address |
|||
; HL = amount of heap memory in bytes |
|||
; |
|||
; Errors: |
|||
; CATASTROPHE_HEAP ; ran out of HEAP memory |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF1 Get HMA |
|||
; |
|||
; Enter with: |
|||
; C = 0xF1 |
|||
; |
|||
; Exit with: |
|||
; HL = start address of HBIOS stub in high memory |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF2 GET/SET NVRAM |
|||
; |
|||
; Enter with: |
|||
; C = 0xF2 |
|||
; B = 0 get NVRAM copy from CPU instance |
|||
; = 1 set NVRAM copy to CPU instance |
|||
; DE = destination/source buffer (31 chars) |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS ; if address is <0x8000 |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF3 FIND PROTOTYPE |
|||
; |
|||
; Enter with: |
|||
; C = 0xF3 |
|||
; B ID of Instance Prototype to Find |
|||
; |
|||
; Exit with: |
|||
; DE = HBIOS memory address of prototype |
|||
; |
|||
; Errors: |
|||
; ERR_NO_PROTO |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF4 PEEK |
|||
; |
|||
; Enter with: |
|||
; C = 0xF4 |
|||
; DE = address in range 0..7FFF |
|||
; |
|||
; Exit with: |
|||
; B = Byte value at (DE) |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF5 POKE |
|||
; |
|||
; Enter with: |
|||
; C = 0xF5 |
|||
; B = Byte value to POKE at (DE) |
|||
; DE = address in range 0..7FFF |
|||
; |
|||
; Exit with: |
|||
; nothing |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF6 NEW INSTANCE |
|||
; |
|||
; Enter with: |
|||
; C = 0xF6 |
|||
; DE = Instance Prototype pointer |
|||
; L = new instance device code |
|||
; |
|||
; Exit with: |
|||
; DE = new Instance pointer |
|||
; B = new Unit number |
|||
; |
|||
; Errors: |
|||
; ERR_NO_MEMORY |
|||
; ERR_NO_UNIT |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF7 MALLOC |
|||
; |
|||
; Enter with: |
|||
; C = 0xF7 |
|||
; DE = number of bytes to allocate from the heap |
|||
; |
|||
; Exit with: |
|||
; DE = number of bytes actually allocated |
|||
; HL = address in HBIOS memory of DE bytes |
|||
; |
|||
; Errors: |
|||
; ERR_NO_MEMORY |
|||
; DE = 0 |
|||
; HL = max. allocation remaining |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF8 get PHI -- get the CPU clock rate |
|||
; |
|||
; Enter with: |
|||
; C = 0xF8 |
|||
; |
|||
; Exit with: |
|||
; DE:HL = CPU clock rate (phi) in Hz |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xF9 get CPU info |
|||
; get the CPU type and encoded clock rate (PHI) |
|||
; |
|||
; Enter with: |
|||
; C = 0xF9 |
|||
; |
|||
; Exit with: |
|||
; D = CPU model number (0=Z80, 1,2,3=level of Z180 |
|||
; E = CPU encoded clock rate (PHI) or 0xFF if not encoded |
|||
; |
|||
; Errors: |
|||
; none |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; get BIOS info -- get BIOS information in various forms |
|||
; |
|||
; Enter with: |
|||
; C = 0xFA |
|||
; B = <subfunction code> |
|||
; |
|||
; Subfunction entry codes: |
|||
; |
|||
; Get 4 character signature |
|||
; B = 0 get 4 character signature in registers |
|||
; DE & HL D='-', E='A', H='N', L='U' |
|||
; Returns: |
|||
; DE = 0x2D41 |
|||
; HL = 0x4E55 |
|||
; |
|||
; |
|||
; Get 79 character BIOS version string + null |
|||
; B = 1 get 79 character BIOS version string + null |
|||
; DE = pointer to an 80 character buffer in high memory |
|||
; |
|||
; Returns: |
|||
; buffer is filled with up to 80 bytes |
|||
; |
|||
; |
|||
; Get 511 character BIOS version + copyright + license notice + null |
|||
; B = 2 get 511 long informatin + null terminator |
|||
; DE = pointer to a 512 character buffer in high memory |
|||
; |
|||
; Returns: |
|||
; buffer is filled with up to 512 bytes |
|||
; |
|||
; |
|||
; Get current execution environment (32K page codes) |
|||
; B = 3 |
|||
; |
|||
; Returns: |
|||
; DE = currently executing page, ROM or RAM (usually EXEC_PAGE) |
|||
; HL = page containing UBIOS in RAM (always UBIOS_PAGE) |
|||
; (see "pages.inc" for the encodings) |
|||
; |
|||
; |
|||
; Get BIOS date and version information |
|||
; B = 4 |
|||
; |
|||
; Returns: |
|||
; B = subversion load sequence number |
|||
; D = major version number |
|||
; E = minor version number in bits (0..6) |
|||
; alpha/beta indicator if bit 7 is set |
|||
; HL = BIOS date, packed (7/4/5) where Y=year-2000 |
|||
; YYYYYYY MMMM DDDDD |
|||
; |
|||
; |
|||
; Get user execution environment (32K page codes) |
|||
; B = 5 |
|||
; |
|||
; Returns: |
|||
; DE = low memory user RAM page (EXEC_PAGE) |
|||
; HL = high memory user RAM page (HIGH_PAGE) |
|||
; (see "pages.inc" for the encodings) |
|||
; |
|||
; |
|||
; Errors: |
|||
; ERR_ADDRESS if DE is not in the upper 32k (B==1 or 2) |
|||
; ERR_METHOD if B-reg value is not recognized |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Function 0xFB Get/set lower page bank |
|||
; |
|||
; Enter with: |
|||
; C = 0xFB |
|||
; |
|||
; B = 0 get the page currently mapped into low memory |
|||
; page returned in DE |
|||
; = 1 set map the page in DE into low memory |
|||
; and return the current page in DE |
|||
; DE = page (from 'pages.inc') to map in, if B==1 |
|||
; |
|||
; Exit with: |
|||
; DE = page currently mapped into low 32k memory bank |
|||
; = page previously mapped into low 32k mem. bank (set) |
|||
; |
|||
; Errors: |
|||
; ERR_METHOD if B is not 0 or 1 |
|||
; |
|||
; CAUTION: This is a dangerous function. It may only be called from |
|||
; the high memory bank, since it changes the low memory mapping. |
|||
; Likewise, the stack must be in the high memory bank. |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; Get/set bootstrap history |
|||
; |
|||
; Enter with: |
|||
; C = 0xFC |
|||
; |
|||
; B = 0 get the saved bootstrap history |
|||
; = 1 set the bootstrap history for later retrieval |
|||
; |
|||
; Data registers to retain, if a Set |
|||
; |
|||
; Get or Set Data: |
|||
; DE = ROM page last booted (or -1, if not applicable) |
|||
; L = most recently booted disk unit number (or -1, if |
|||
; not applicable) |
|||
; Exit with: |
|||
; Registers with data, if a Get |
|||
; H = current boot disk BIOS unit number (from NVRAM) |
|||
; |
|||
; Errors: |
|||
; ERR_METHOD if B is not 0 or 1 |
|||
; |
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1,948 @@ |
|||
; |
|||
;================================================================================================== |
|||
; LOADER |
|||
;================================================================================================== |
|||
; |
|||
; INCLUDE GENERIC STUFF |
|||
; |
|||
#INCLUDE "std.asm" |
|||
; |
|||
MONIMG .EQU $1000 |
|||
CPMIMG .EQU $2000 |
|||
ZSYSIMG .EQU $5000 |
|||
; |
|||
.ORG 0 |
|||
; |
|||
;================================================================================================== |
|||
; NORMAL PAGE ZERO SETUP, RET/RETI/RETN AS APPROPRIATE |
|||
;================================================================================================== |
|||
; |
|||
.FILL (000H - $),0FFH ; RST 0 |
|||
JP 0100H ; JUMP TO BOOT CODE |
|||
.FILL (008H - $),0FFH ; RST 8 |
|||
#IF (PLATFORM == PLT_UNA) |
|||
JP $FFFD ; INVOKE UBIOS FUNCTION |
|||
#ELSE |
|||
JP $FFF0 ; INVOKE HBIOS FUNCTION |
|||
#ENDIF |
|||
.FILL (010H - $),0FFH ; RST 10 |
|||
RET |
|||
.FILL (018H - $),0FFH ; RST 18 |
|||
RET |
|||
.FILL (020H - $),0FFH ; RST 20 |
|||
RET |
|||
.FILL (028H - $),0FFH ; RST 28 |
|||
RET |
|||
.FILL (030H - $),0FFH ; RST 30 |
|||
RET |
|||
.FILL (038H - $),0FFH ; INT |
|||
RETI |
|||
.FILL (066H - $),0FFH ; NMI |
|||
RETN |
|||
; |
|||
.FILL (100H - $),0FFH ; PAD REMAINDER OF PAGE ZERO |
|||
; |
|||
; |
|||
;================================================================================================== |
|||
; LOADER |
|||
;================================================================================================== |
|||
; |
|||
DI ; NO INTERRUPTS |
|||
IM 1 ; INTERRUPT MODE 1 |
|||
LD SP,BL_STACK ; SETUP STACK |
|||
; |
|||
; COPY OURSELVES TO HI RAM FOR PHASE 2 |
|||
; |
|||
LD HL,0 ; COPY FROM START OF ROM IMAGE |
|||
LD DE,$8000 ; TO HIMEM $8000 |
|||
LD BC,$1000 ; COPY 4K |
|||
LDIR |
|||
; |
|||
JP PHASE2 ; CONTINUE EXECUTION IN HIMEM RAM |
|||
; |
|||
; THIS IS THE PHASE 2 CODE THAT MUST EXECUTE IN UPPER MEMORY |
|||
; |
|||
.ORG $ + $8000 ; SET ORG BASED ON OUR NEW LOCATION IN RAM |
|||
PHASE2: |
|||
; BANNER |
|||
CALL NEWLINE |
|||
LD DE,STR_BANNER |
|||
CALL WRITESTR |
|||
|
|||
; RUN THE BOOT LOADER MENU |
|||
JP DOBOOTMENU |
|||
; |
|||
;__DOBOOT________________________________________________________________________________________________________________________ |
|||
; |
|||
; PERFORM BOOT FRONT PANEL ACTION |
|||
;________________________________________________________________________________________________________________________________ |
|||
; |
|||
DOBOOTMENU: |
|||
CALL NEWLINE |
|||
CALL NEWLINE |
|||
LD DE,STR_BOOTMENU |
|||
CALL WRITESTR |
|||
|
|||
#IF (DSKYENABLE) |
|||
LD HL,BOOT ; POINT TO BOOT MESSAGE |
|||
CALL SEGDISPLAY ; DISPLAY MESSAGE |
|||
#ENDIF |
|||
|
|||
#IF (BOOTTYPE == BT_AUTO) |
|||
LD BC,1000 * BOOT_TIMEOUT |
|||
LD (BL_TIMEOUT),BC |
|||
#ENDIF |
|||
|
|||
DB_BOOTLOOP: |
|||
; |
|||
; CHECK FOR CONSOLE BOOT KEYPRESS |
|||
; |
|||
CALL CST |
|||
OR A |
|||
JP Z,DB_CONEND |
|||
CALL CINUC |
|||
CP 'M' ; MONITOR |
|||
JP Z,GOMON |
|||
CP 'C' ; CP/M BOOT FROM ROM |
|||
JP Z,GOCPM |
|||
CP 'Z' ; ZSYSTEM BOOT FROM ROM |
|||
JP Z,GOZSYS |
|||
CP 'L' ; LIST DRIVES |
|||
JP Z,GOLIST |
|||
CP '0' ; 0-9, DISK DEVICE |
|||
JP C,DB_INVALID |
|||
CP '9' + 1 |
|||
JP NC,DB_INVALID |
|||
SUB '0' |
|||
JP GOBOOTDISK |
|||
DB_CONEND: |
|||
; |
|||
; CHECK FOR DSKY BOOT KEYPRESS |
|||
; |
|||
#IF (DSKYENABLE) |
|||
CALL KY_STAT ; GET KEY FROM KB INTO A |
|||
OR A |
|||
JP Z,DB_DSKYEND |
|||
CALL KY_GET |
|||
CP KY_GO ; GO = MONITOR |
|||
JP Z,GOMONDSKY |
|||
CP KY_BO ; BO = BOOT ROM |
|||
JP Z,GOCPM |
|||
; CP 0AH ; A-F, DISK BOOT |
|||
; JP C,DB_INVALID |
|||
CP 0FH + 1 ; 0-F, DISK BOOT |
|||
; JP NC,DB_INVALID |
|||
; SUB 0AH |
|||
JP GOBOOTDISK |
|||
; LD HL,BOOT ; POINT TO BOOT MESSAGE |
|||
; LD A,00H ; BLANK OUT SELECTION,IT WAS INVALID |
|||
; LD (HL),A ; STORE IT IN DISPLAY BUFFER |
|||
; CALL SEGDISPLAY ; DISPLAY THE BUFFER |
|||
DB_DSKYEND: |
|||
#ENDIF |
|||
; |
|||
; IF CONFIGURED, CHECK FOR AUTOBOOT TIMEOUT |
|||
; |
|||
#IF (BOOTTYPE == BT_AUTO) |
|||
|
|||
; DELAY FOR 1MS TO MAKE TIMEOUT CALC EASY |
|||
LD DE,40 |
|||
CALL VDELAY |
|||
|
|||
; CHECK/INCREMENT TIMEOUT |
|||
LD BC,(BL_TIMEOUT) |
|||
DEC BC |
|||
LD (BL_TIMEOUT),BC |
|||
LD A,B |
|||
OR C |
|||
JP NZ,DB_BOOTLOOP |
|||
|
|||
; TIMEOUT EXPIRED, PERFORM DEFAULT BOOT ACTION |
|||
LD A,BOOT_DEFAULT |
|||
CP 'M' ; MONITOR |
|||
JP Z,GOMON |
|||
CP 'C' ; CP/M BOOT FROM ROM |
|||
JP Z,GOCPM |
|||
CP 'Z' ; ZSYSTEM BOOT FROM ROM |
|||
JP Z,GOZSYS |
|||
CP 'L' ; LIST DRIVES |
|||
JP Z,GOLIST |
|||
CP '0' ; 0-9, DISK DEVICE |
|||
JP C,DB_INVALID |
|||
CP '9' + 1 |
|||
JP NC,DB_INVALID |
|||
SUB '0' |
|||
JP GOBOOTDISK |
|||
#ENDIF |
|||
|
|||
JP DB_BOOTLOOP |
|||
; |
|||
; BOOT OPTION PROCESSING |
|||
; |
|||
DB_INVALID: |
|||
LD DE,STR_INVALID |
|||
CALL WRITESTR |
|||
JP DOBOOTMENU |
|||
; |
|||
GOMON: |
|||
CALL LDMON |
|||
JP MON_SERIAL |
|||
; |
|||
GOMONDSKY: |
|||
CALL LDMON |
|||
JP MON_DSKY |
|||
; |
|||
LDMON: |
|||
LD DE,STR_BOOTMON |
|||
CALL WRITESTR |
|||
LD HL,MONIMG |
|||
LD DE,MON_LOC |
|||
LD BC,MON_SIZ |
|||
LDIR |
|||
RET |
|||
; |
|||
GOCPM: |
|||
LD DE,STR_BOOTCPM |
|||
CALL WRITESTR |
|||
LD HL,CPMIMG |
|||
GOCPM2: |
|||
LD DE,CPM_LOC |
|||
LD BC,CPM_SIZ |
|||
LDIR |
|||
#IF (PLATFORM == PLT_UNA) |
|||
LD DE,-1 |
|||
LD L,1 |
|||
LD BC,$01FC ; UNA FUNC: SET BOOTSTRAP HISTORY |
|||
RST 08 ; CALL UNA |
|||
#ELSE |
|||
LD B,BF_SYSATTR |
|||
LD C,AID_BOOTVOL | $80 |
|||
LD DE,$0000 |
|||
RST 08 |
|||
#ENDIF |
|||
JP CPM_ENT |
|||
; |
|||
GOZSYS: |
|||
LD DE,STR_BOOTZSYS |
|||
CALL WRITESTR |
|||
LD HL,ZSYSIMG |
|||
JR GOCPM2 |
|||
; |
|||
GOLIST: |
|||
LD DE,STR_LIST |
|||
CALL WRITESTR |
|||
LD DE,STR_DRVLIST |
|||
CALL WRITESTR |
|||
CALL PRTALL |
|||
JP DOBOOTMENU |
|||
; |
|||
GOBOOTDISK: |
|||
LD (BL_BOOTID),A |
|||
LD DE,STR_BOOTDISK |
|||
CALL WRITESTR |
|||
JP BOOTDISK |
|||
; |
|||
; BOOT FROM DISK DRIVE |
|||
; |
|||
BOOTDISK: |
|||
#IF (PLATFORM == PLT_UNA) |
|||
; |
|||
; BOOT FROM UNA DISK DRIVE |
|||
; |
|||
LD A,(BL_BOOTID) ; GET BOOT DEVICE ID |
|||
LD B,A ; MOVE TO B |
|||
|
|||
; LOAD SECTOR 2 (BOOT INFO) |
|||
LD C,$41 ; UNA FUNC: SET LBA |
|||
LD DE,0 ; HI WORD OF LBA IS ALWAYS ZERO |
|||
LD HL,2 ; LOAD STARTING INFO SECTOR 2 |
|||
RST 08 ; SET LBA |
|||
JP NZ,DB_ERR ; HANDLE ERROR |
|||
CALL PC_PERIOD ; MARK PROGRESS |
|||
; |
|||
LD C,$42 ; UNA FUNC: READ SECTORS |
|||
LD DE,BL_INFOSEC ; DEST OF CPM IMAGE |
|||
LD L,1 ; SECTORS TO READ |
|||
RST 08 ; DO READ |
|||
JP NZ,DB_ERR ; HANDLE ERROR |
|||
CALL PC_PERIOD ; MARK PROGRESS |
|||
; |
|||
; CHECK SIGNATURE |
|||
CALL NEWLINE ; FORMATTING |
|||
LD DE,(BB_SIG) ; GET THE SIGNATURE |
|||
LD A,$A5 ; FIRST BYTE SHOULD BE $A5 |
|||
CP D ; COMPARE |
|||
JP NZ,DB_NOBOOT ; ERROR IF NOT EQUAL |
|||
LD A,$5A ; SECOND BYTE SHOULD BE $5A |
|||
CP E ; COMPARE |
|||
JP NZ,DB_NOBOOT ; ERROR IS NOT EQUAL |
|||
|
|||
; PRINT CPMLOC VALUE |
|||
CALL NEWLINE |
|||
LD DE,STR_CPMLOC |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMLOC) |
|||
CALL PRTHEXWORD |
|||
|
|||
; PRINT CPMEND VALUE |
|||
CALL PC_SPACE |
|||
LD DE,STR_CPMEND |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMEND) |
|||
CALL PRTHEXWORD |
|||
|
|||
; PRINT CPMENT VALUE |
|||
CALL PC_SPACE |
|||
LD DE,STR_CPMENT |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMENT) |
|||
CALL PRTHEXWORD |
|||
CALL PC_SPACE |
|||
|
|||
; PRINT DISK LABEL |
|||
LD DE,STR_LABEL |
|||
CALL WRITESTR |
|||
LD DE,BB_LABEL ; if it is there, then a printable |
|||
LD A,(BB_TERM) ; Display Disk Label if Present |
|||
CP '$' ; (dwg 2/7/2012) |
|||
CALL Z,WRITESTR ; label is there as well even if spaces. |
|||
; |
|||
LD DE,STR_LOADING ; LOADING MESSAGE |
|||
CALL WRITESTR ; PRINT IT |
|||
; |
|||
LD A,(BL_BOOTID) ; GET BOOT DEVICE ID |
|||
LD B,A ; MOVE TO B |
|||
; |
|||
LD C,$41 ; UNA FUNC: SET LBA |
|||
LD DE,0 ; HI WORD OF LBA IS ALWAYS ZERO |
|||
LD HL,3 ; LOAD STARTING AT SECTOR 3 |
|||
RST 08 ; SET LBA |
|||
JP NZ,DB_ERR ; HANDLE ERROR |
|||
CALL PC_PERIOD ; MARK PROGRESS |
|||
; |
|||
LD C,$42 ; UNA FUNC: READ SECTORS |
|||
LD HL,(BB_CPMEND) ; HL := END |
|||
LD DE,(BB_CPMLOC) ; DE := START |
|||
OR A ; CLEAR CARRY |
|||
SBC HL,DE ; HL := LENGTH TO LOAD |
|||
LD A,H ; DETERMINE 512 BYTE SECTOR COUNT |
|||
RRCA ; ... BY DIVIDING MSB BY TWO |
|||
LD L,A ; SECTORS TO READ |
|||
LD DE,(BB_CPMLOC) ; DEST OF CPM IMAGE |
|||
RST 08 ; DO READ |
|||
JP NZ,DB_ERR ; HANDLE ERROR |
|||
CALL PC_PERIOD ; MARK PROGRESS |
|||
; |
|||
; PASS BOOT DEVICE/UNIT/LU TO CBIOS COLD BOOT |
|||
LD DE,-1 |
|||
LD A,(BL_BOOTID) |
|||
LD L,A |
|||
LD BC,$01FC ; UNA FUNC: SET BOOTSTRAP HISTORY |
|||
RST 08 ; CALL UNA |
|||
; |
|||
; JUMP TO COLD BOOT ENTRY |
|||
CALL NEWLINE ; FORMATTING |
|||
LD HL,(BB_CPMENT) ; GET THE ENTRY POINT |
|||
JP (HL) ; ... AND GO |
|||
; |
|||
; PRINT LIST OF ALL DRIVES UNDER UNA |
|||
; |
|||
PRTALL: |
|||
LD B,0 ; START WITH UNIT 0 |
|||
; |
|||
UPRTALL1: ; LOOP THRU ALL UNITS AVAILABLE |
|||
LD C,$48 ; UNA FUNC: GET DISK TYPE |
|||
LD L,0 ; PRESET UNIT COUNT TO ZERO |
|||
RST 08 ; CALL UNA, B IS ASSUMED TO BE UNTOUCHED!!! |
|||
LD A,L ; UNIT COUNT TO A |
|||
OR A ; PAST END? |
|||
RET Z ; WE ARE DONE |
|||
PUSH BC ; SAVE UNIT |
|||
CALL UPRTDRV ; PROCESS THE UNIT |
|||
POP BC ; RESTORE UNIT |
|||
INC B ; NEXT UNIT |
|||
JR UPRTALL1 ; LOOP |
|||
; |
|||
; PRINT THE UNA UNIT INFO |
|||
; ON INPUT B HAS UNIT |
|||
; |
|||
UPRTDRV: |
|||
PUSH BC ; SAVE UNIT |
|||
PUSH DE ; SAVE DISK TYPE |
|||
LD DE,STR_PREFIX ; NEWLINE AND SPACING |
|||
CALL WRITESTR ; PRINT IT |
|||
LD A,B ; DRIVE LETTER TO A |
|||
ADD A,'0' ; MAKE IT DISPLAY NUMERIC |
|||
CALL COUT ; PRINT IT |
|||
LD A,')' ; DRIVE LETTER COLON |
|||
CALL COUT ; PRINT IT |
|||
CALL PC_SPACE |
|||
POP DE ; RECOVER DISK TYPE |
|||
LD A,D ; DISK TYPE TO A |
|||
CP $40 ; RAM/ROM? |
|||
JR Z,UPRTDRV1 ; HANDLE RAM/ROM |
|||
LD DE,UDEVIDE ; ASSUME IDE |
|||
CP $41 ; IDE? |
|||
JR Z,UPRTDRV2 ; PRINT IT |
|||
LD DE,UDEVPPIDE ; ASSUME PPIDE |
|||
CP $42 ; PPIDE? |
|||
JR Z,UPRTDRV2 ; PRINT IT |
|||
LD DE,UDEVSD ; ASSUME SD |
|||
CP $43 ; SD? |
|||
JR Z,UPRTDRV2 ; PRINT IT |
|||
LD DE,UDEVDSD ; ASSUME DSD |
|||
CP $44 ; DSD? |
|||
JR Z,UPRTDRV2 ; PRINT IT |
|||
LD DE,UDEVUNK ; OTHERWISE UNKNOWN |
|||
JR UPRTDRV2 |
|||
; |
|||
UPRTDRV1: ; HANDLE RAM/ROM |
|||
LD C,$45 ; UNA FUNC: GET DISK INFO |
|||
LD DE,$9000 ; 512 BYTE BUFFER *** FIX!!! *** |
|||
RST 08 ; CALL UNA |
|||
BIT 7,B ; TEST RAM DRIVE BIT |
|||
LD DE,UDEVROM ; ASSUME ROM |
|||
JR Z,UPRTDRV2 ; IF SO, PRINT IT |
|||
LD DE,UDEVRAM ; OTHERWISE RAM |
|||
JR UPRTDRV2 ; PRINT IT |
|||
; |
|||
UPRTDRV2: ; PRINT DEVICE |
|||
POP BC ; RECOVER UNIT |
|||
CALL WRITESTR ; PRINT DEVICE NAME |
|||
LD A,B ; UNIT TO A |
|||
ADD A,'0' ; MAKE IT PRINTABLE NUMERIC |
|||
CALL COUT ; PRINT IT |
|||
LD A,':' ; DEVICE NAME COLON |
|||
CALL COUT ; PRINT IT |
|||
RET ; DONE |
|||
; |
|||
UDEVRAM .DB "RAM$" |
|||
UDEVROM .DB "ROM$" |
|||
UDEVIDE .DB "IDE$" |
|||
UDEVPPIDE .DB "PPIDE$" |
|||
UDEVSD .DB "SD$" |
|||
UDEVDSD .DB "DSD$" |
|||
UDEVUNK .DB "UNK$" |
|||
; |
|||
#ELSE |
|||
; |
|||
LD DE,STR_BOOTDISK1 ; DISK BOOT MESSAGE |
|||
CALL WRITESTR ; PRINT IT |
|||
|
|||
; CHECK FOR VALID DRIVE LETTER |
|||
LD A,(BL_BOOTID) ; BOOT DEVICE TO A |
|||
PUSH AF ; SAVE BOOT DEVICE |
|||
LD B,BF_DIODEVCNT ; HBIOS FUNC: DEVICE COUNT |
|||
RST 08 ; CALL HBIOS, DEVICE COUNT TO B |
|||
POP AF ; RESTORE BOOT DEVICE |
|||
CP B ; CHECK MAX (INDEX - COUNT) |
|||
JP NC,DB_NODISK ; HANDLE INVALID SELECTION |
|||
|
|||
; GET DEVICE/UNIT, LU |
|||
LD B,BF_DIODEVINF ; HBIOS FUNC: DEVICE INFO |
|||
LD A,(BL_BOOTID) ; GET BOOT DEVICE ID |
|||
LD C,A ; PUT IN C |
|||
RST 08 ; CALL HBIOS, DEV INFO TO C |
|||
LD A,C ; DEVICE/UNIT TO A |
|||
LD (BL_DEVICE),A ; STORE IT |
|||
XOR A ; LU ALWAYS ZERO |
|||
LD (BL_LU),A ; STORE IT |
|||
|
|||
; SENSE MEDIA |
|||
LD A,(BL_DEVICE) ; GET DEVICE/UNIT |
|||
LD C,A ; STORE IN C |
|||
LD B,BF_DIOMED ; DRIVER FUNCTION = DISK MEDIA |
|||
RST 08 ; CALL HBIOS |
|||
OR A ; SET FLAGS |
|||
JP Z,DB_ERR ; HANDLE ERROR |
|||
|
|||
; SET SPT BASED ON MEDIA DETECTED |
|||
LD C,18 ; ASSUME 18 SPT |
|||
CP MID_FD144 ; 3.5" 1.44M FLOPPY? |
|||
JR Z,BOOTDISK1 ; YES, DONE |
|||
|
|||
LD C,15 ; ASSUME 15 SPT |
|||
CP MID_FD120 ; 5.25" 1.2M FLOPPY? |
|||
JR Z,BOOTDISK1 ; YES, DONE |
|||
CP MID_FD111 ; 8" 1.11M FLOPPY? |
|||
JR Z,BOOTDISK1 ; YES, DONE |
|||
|
|||
LD C,9 ; ASSUME 9 SPT |
|||
CP MID_FD720 ; 3.5" 720K FLOPPY? |
|||
JR Z,BOOTDISK1 ; YES, DONE |
|||
CP MID_FD360 ; 5.25" 360k FLOPPY? |
|||
JR Z,BOOTDISK1 ; YES, DONE |
|||
|
|||
LD C,16 ; EVERYTHING ELSE IS LBA (USE 16 SPT) |
|||
|
|||
BOOTDISK1: |
|||
LD A,C |
|||
LD (BL_SPT),A ; SAVE SPT |
|||
|
|||
; DETERMINE STARTING TRACK FOR LU |
|||
LD A,(BL_LU) ; GET LU SPECIFIED |
|||
LD E,A ; LU INDEX |
|||
LD H,65 ; 65 TRACKS PER LU |
|||
CALL MULT8 ; HL := H * E |
|||
LD (BL_LUTRK),HL ; SAVE IT |
|||
|
|||
; READ BOOT INFO SECTOR |
|||
LD HL,0 ; INITIAL TRACK (RELATIVE TO LU) |
|||
LD (BL_CURTRK),HL ; SAVE AS CURRENT TRACK |
|||
LD A,2 ; BOOT INFO IS IN SECTOR 2 |
|||
LD (BL_CURSEC),A ; SAVE AS CURRENT SECTOR |
|||
LD HL,BL_INFOSEC ; WHERE TO PUT INFO SECTOR |
|||
LD (BL_CURDMA),HL ; ... AND SAVE IT |
|||
CALL DB_READSEC ; READ CURRENT SECTOR |
|||
JP NZ,DB_ERR ; HANDLE ERROR |
|||
|
|||
; CHECK SIGNATURE |
|||
LD BC,(BB_SIG) |
|||
LD A,$A5 |
|||
CP B |
|||
JP NZ,DB_NOBOOT |
|||
LD A,$5A |
|||
CP C |
|||
JP NZ,DB_NOBOOT |
|||
|
|||
; PRINT CPMLOC VALUE |
|||
CALL NEWLINE |
|||
LD DE,STR_CPMLOC |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMLOC) |
|||
CALL PRTHEXWORD |
|||
|
|||
; PRINT CPMEND VALUE |
|||
CALL PC_SPACE |
|||
LD DE,STR_CPMEND |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMEND) |
|||
CALL PRTHEXWORD |
|||
|
|||
; PRINT CPMENT VALUE |
|||
CALL PC_SPACE |
|||
LD DE,STR_CPMENT |
|||
CALL WRITESTR |
|||
LD BC,(BB_CPMENT) |
|||
CALL PRTHEXWORD |
|||
CALL PC_SPACE |
|||
|
|||
; PRINT DISK LABEL |
|||
LD DE,STR_LABEL |
|||
CALL WRITESTR |
|||
LD DE,BB_LABEL ; if it is there, then a printable |
|||
LD A,(BB_TERM) ; Display Disk Label if Present |
|||
CP '$' ; (dwg 2/7/2012) |
|||
CALL Z,WRITESTR ; label is there as well even if spaces. |
|||
|
|||
; COMPUTE NUMBER OF SECTORS TO LOAD |
|||
LD HL,(BB_CPMEND) ; HL := END |
|||
LD DE,(BB_CPMLOC) ; DE := START |
|||
OR A ; CLEAR CARRY |
|||
SBC HL,DE ; HL := LENGTH TO LOAD |
|||
LD A,H ; DETERMINE 512 BYTE SECTOR COUNT |
|||
RRCA ; ... BY DIVIDING MSB BY TWO |
|||
LD (BL_COUNT),A ; ... AND SAVE IT |
|||
|
|||
; LOADING MESSAGE |
|||
CALL NEWLINE |
|||
LD DE,STR_LOADING |
|||
CALL WRITESTR |
|||
|
|||
; SETUP FOR DATA LOAD |
|||
LD HL,(BB_CPMLOC) ; GET TARGET LOAD LOCATION |
|||
LD (BL_CURDMA),HL ; ... AND SAVE IT |
|||
|
|||
DB_LOOP: |
|||
CALL DB_NXTSEC ; BUMP TO NEXT SECTOR |
|||
CALL DB_READSEC ; READ SECTOR |
|||
JP NZ,DB_ERR ; HANDLE ERRORS |
|||
CALL PC_PERIOD ; SHOW PROGRESS |
|||
LD HL,(BL_CURDMA) ; GET LOAD LOC |
|||
LD DE,512 ; 512 BYTES PER SECTOR |
|||
ADD HL,DE ; INCREMENT MEM POINTER |
|||
LD (BL_CURDMA),HL ; ... AND SAVE IT |
|||
LD HL,BL_COUNT ; POINT TO COUNTER |
|||
DEC (HL) ; ... AND DECREMENT IT |
|||
JR NZ,DB_LOOP ; LOOP IF NEEDED |
|||
CALL NEWLINE ; FORMATTING |
|||
|
|||
; PASS BOOT DEVICE/UNIT/LU TO CBIOS COLD BOOT |
|||
LD B,BF_SYSATTR |
|||
LD C,AID_BOOTVOL | $80 |
|||
LD A,(BL_DEVICE) ; LOAD BOOT DEVICE/UNIT |
|||
LD D,A ; SAVE IN D |
|||
LD A,(BL_LU) ; LOAD BOOT LU |
|||
LD E,A ; SAVE IN E |
|||
RST 08 |
|||
|
|||
; JUMP TO COLD BOOT ENTRY |
|||
LD HL,(BB_CPMENT) |
|||
JP (HL) |
|||
; |
|||
; INCREMENT TO NEXT SECTOR |
|||
; |
|||
DB_NXTSEC: |
|||
LD A,(BL_SPT) ; GET SECTORS PER TRACK |
|||
LD B,A ; ... AND SAVE IT IN B |
|||
LD HL,BL_CURSEC ; POINT TO CURRENT SECTOR |
|||
INC (HL) ; INCREMENT IT |
|||
LD A,(HL) ; GET CURRENT SECTOR TO A |
|||
CP B ; COMPARE TO SPT IN B |
|||
RET NZ ; IF WE HAVE NOT HIT SPT, DONE |
|||
XOR A ; PREPARE TO CLEAR CUR SECTOR |
|||
LD (HL),A ; ... AND DO IT |
|||
LD HL,(BL_CURTRK) ; LOAD CURRENT TRACK VALUE |
|||
INC HL ; ... AND INCREMENT IT |
|||
LD (BL_CURTRK),HL ; ... AND SAVE IT |
|||
RET |
|||
; |
|||
; READ CURRENT SECTOR TO LOAD LOCATION |
|||
; |
|||
DB_READSEC: |
|||
LD HL,(BL_CURDMA) ; GET THE SECTOR DMA ADDRESS |
|||
|
|||
#IF 0 |
|||
CALL NEWLINE |
|||
PUSH HL |
|||
POP BC |
|||
CALL PRTHEXWORD |
|||
#ENDIF |
|||
LD B,BF_DIOSETBUF ; HBIOS FUNC: SET BUF |
|||
RST 08 ; CALL HBIOS |
|||
|
|||
LD A,(BL_DEVICE) ; GET ACTIVE DEVICE/UNIT BYTE |
|||
AND $F0 ; ISOLATE DEVICE PORTION |
|||
CP DIODEV_FD ; FLOPPY? |
|||
JR NZ,DB_READSEC1 ; NO, USE LBA HANDLING |
|||
; SET HL=TRACK (ADD IN TRACK OFFSET) |
|||
LD DE,(BL_LUTRK) ; DE = TRACK OFFSET FOR LU SUPPORT |
|||
LD HL,(BL_CURTRK) ; HL = TRACK # |
|||
ADD HL,DE ; APPLY OFFSET FOR ACTIVE LU |
|||
; SET DE=SECTOR |
|||
LD A,(BL_CURSEC) ; GET THE SECTOR INTO A |
|||
LD E,A ; MOVE IT TO LSB |
|||
LD D,0 ; MSB IS ALWAYS ZERO |
|||
; SET C = DEVICE/UNIT |
|||
LD B,BF_DIORD ; FUNCTION IN B |
|||
LD A,(BL_DEVICE) ; LOAD DEVICE/UNIT VALUE |
|||
LD C,A ; SAVE IN C |
|||
JR DB_READSEC3 ; DISPATCH TO DRIVER |
|||
; |
|||
DB_READSEC1: |
|||
; |
|||
; LBA STYLE ACCESS |
|||
LD DE,(BL_CURTRK) ; GET TRACK INTO HL |
|||
LD B,4 ; PREPARE TO LEFT SHIFT BY 4 BITS |
|||
DB_READSEC2: |
|||
SLA E ; SHIFT DE LEFT BY 4 BITS |
|||
RL D |
|||
DJNZ DB_READSEC2 ; LOOP TILL ALL BITS DONE |
|||
LD A,(BL_CURSEC) ; GET THE SECTOR INTO A |
|||
AND $0F ; GET RID OF TOP NIBBLE |
|||
OR E ; COMBINE WITH E |
|||
LD E,A ; BACK IN E |
|||
LD HL,0 ; HL:DE NOW HAS LU RELATIVE LBA |
|||
; APPLY LU OFFSET NOW |
|||
; LU OFFSET IS EXPRESSED AS NUMBER OF BLOCKS * 256 TO LU OFFSET! |
|||
LD A,(BL_LUTRK) ; LSB OF LU TRACK TO A |
|||
ADD A,D ; ADD WITH D |
|||
LD D,A ; PUT IT BACK IN D |
|||
LD A,(BL_LUTRK+1) ; MSB OF LU TRACK TO A |
|||
CALL ADDHLA ; ADD LU OFFSET |
|||
LD B,BF_DIORD ; FUNCTION IN B |
|||
LD A,(BL_DEVICE) ; GET THE DEVICE/UNIT VALUE |
|||
LD C,A ; PUT IT IN C |
|||
; |
|||
DB_READSEC3: |
|||
; |
|||
; DISPATCH TO DRIVER |
|||
#IF 0 |
|||
PUSH AF |
|||
PUSH BC |
|||
PUSH DE |
|||
PUSH HL |
|||
|
|||
CALL PC_PERIOD |
|||
LD A,C |
|||
CALL PRTHEXBYTE |
|||
PUSH BC |
|||
PUSH HL |
|||
POP BC |
|||
CALL PC_PERIOD |
|||
CALL PRTHEXWORD |
|||
PUSH DE |
|||
POP BC |
|||
CALL PC_COLON |
|||
CALL PRTHEXWORD |
|||
CALL NEWLINE |
|||
POP BC |
|||
|
|||
POP HL |
|||
POP DE |
|||
POP BC |
|||
POP AF |
|||
#ENDIF |
|||
RST 08 |
|||
OR A ; SET FLAGS BASED ON RESULT |
|||
RET |
|||
; |
|||
; PRINT LIST OF ALL DRIVES |
|||
; |
|||
PRTALL: |
|||
; |
|||
LD B,BF_DIODEVCNT ; HBIOS FUNC: DEVICE COUNT |
|||
RST 08 ; CALL HBIOS |
|||
LD A,B ; COUNT TO A |
|||
OR A ; SET FLAGS |
|||
RET Z ; BAIL OUT IF ZERO |
|||
LD C,0 ; INIT DEVICE INDEX |
|||
; |
|||
PRTALL1: |
|||
LD DE,STR_PREFIX ; FORMATTING |
|||
CALL WRITESTR ; PRINT IT |
|||
LD A,C ; INDEX TO A |
|||
ADD A,'0' ; MAKE NUMERIC CHAR |
|||
CALL COUT ; PRINT IT |
|||
LD A,')' ; FORMATTING |
|||
CALL COUT ; PRINT IT |
|||
CALL PC_SPACE ; SPACING |
|||
PUSH BC ; SAVE LOOP CONTROL |
|||
LD B,BF_DIODEVINF ; HBIOS FUNC: DEVICE INFO |
|||
RST 08 ; CALL HBIOS |
|||
LD D,C ; DEVICE/UNIT TO D |
|||
LD E,0 ; LU IS ZERO |
|||
CALL PRTDRV ; PRINT IT |
|||
POP BC ; RESTORE LOOP CONTROL |
|||
INC C ; BUMP INDEX |
|||
DJNZ PRTALL1 ; LOOP AS NEEDED |
|||
RET ; DONE |
|||
; |
|||
; PRINT THE DEVICE/UNIT/LU INFO |
|||
; ON INPUT D HAS DEVICE/UNIT, E HAS LU |
|||
; DESTROY NO REGISTERS OTHER THAN A |
|||
; |
|||
PRTDRV: |
|||
PUSH DE ; PRESERVE DE |
|||
PUSH HL ; PRESERVE HL |
|||
LD A,D ; LOAD DEVICE/UNIT |
|||
RRCA ; ROTATE DEVICE |
|||
RRCA ; ... BITS |
|||
RRCA ; ... INTO |
|||
RRCA ; ... LOWEST 4 BITS |
|||
AND $0F ; ISOLATE DEVICE BITS |
|||
ADD A,A ; MULTIPLE BY TWO FOR WORD TABLE |
|||
LD HL,DEVTBL ; POINT TO START OF DEVICE NAME TABLE |
|||
CALL ADDHLA ; ADD A TO HL TO POINT TO TABLE ENTRY |
|||
LD A,(HL) ; DEREFERENCE HL TO LOC OF DEVICE NAME STRING |
|||
INC HL ; ... |
|||
LD D,(HL) ; ... |
|||
LD E,A ; ... |
|||
CALL WRITESTR ; PRINT THE DEVICE NMEMONIC |
|||
POP HL ; RECOVER HL |
|||
POP DE ; RECOVER DE |
|||
LD A,D ; LOAD DEVICE/UNIT |
|||
AND $0F ; ISOLATE UNIT |
|||
CALL PRTDECB ; PRINT IT |
|||
CALL PC_COLON ; FORMATTING |
|||
; LD A,E ; LOAD LU |
|||
; CALL PRTDECB ; PRINT IT |
|||
RET |
|||
; |
|||
DEVTBL: ; DEVICE TABLE |
|||
.DW DEV00, DEV01, DEV02, DEV03 |
|||
.DW DEV04, DEV05, DEV06, DEV07 |
|||
.DW DEV08, DEV09, DEV10, DEV11 |
|||
.DW DEV12, DEV13, DEV14, DEV15 |
|||
; |
|||
DEVUNK .DB "???$" |
|||
DEV00 .DB "MD$" |
|||
DEV01 .DB "FD$" |
|||
DEV02 .DB "RAMF$" |
|||
DEV03 .DB "IDE$" |
|||
DEV04 .DB "ATAPI$" |
|||
DEV05 .DB "PPIDE$" |
|||
DEV06 .DB "SD$" |
|||
DEV07 .DB "PRPSD$" |
|||
DEV08 .DB "PPPSD$" |
|||
DEV09 .DB "HDSK$" |
|||
DEV10 .EQU DEVUNK |
|||
DEV11 .EQU DEVUNK |
|||
DEV12 .EQU DEVUNK |
|||
DEV13 .EQU DEVUNK |
|||
DEV14 .EQU DEVUNK |
|||
DEV15 .EQU DEVUNK |
|||
; |
|||
#ENDIF |
|||
; |
|||
DB_NODISK: |
|||
; SELDSK DID NOT LIKE DRIVE SELECTION |
|||
LD DE,STR_NODISK |
|||
CALL WRITESTR |
|||
JP DOBOOTMENU |
|||
|
|||
DB_NOBOOT: |
|||
; DISK IS NOT BOOTABLE |
|||
LD DE,STR_NOBOOT |
|||
CALL WRITESTR |
|||
JP DOBOOTMENU |
|||
|
|||
DB_ERR: |
|||
; I/O ERROR DURING BOOT ATTEMPT |
|||
LD DE,STR_BOOTERR |
|||
CALL WRITESTR |
|||
JP DOBOOTMENU |
|||
; |
|||
#IF (DSKYENABLE) |
|||
; |
|||
; |
|||
;__SEGDISPLAY________________________________________________________________________________________ |
|||
; |
|||
; DISPLAY CONTENTS OF DISPLAYBUF IN DECODED HEX BITS 0-3 ARE DISPLAYED DIG, BIT 7 IS DP |
|||
;____________________________________________________________________________________________________ |
|||
; |
|||
SEGDISPLAY: |
|||
PUSH AF ; STORE AF |
|||
PUSH BC ; STORE BC |
|||
PUSH HL ; STORE HL |
|||
LD BC,0007H |
|||
ADD HL,BC |
|||
LD B,08H ; SET DIGIT COUNT |
|||
LD A,40H | 30H ; SET CONTROL PORT 7218 TO OFF |
|||
OUT (PPIC),A ; OUTPUT |
|||
CALL DELAY ; WAIT |
|||
LD A,0F0H ; SET CONTROL TO 1111 (DATA COMING, HEX DECODE,NO DECODE, NORMAL) |
|||
|
|||
SEGDISPLAY1: ; |
|||
OUT (PPIA),A ; OUTPUT TO PORT |
|||
LD A,80H | 30H ; STROBE WRITE PULSE WITH CONTROL=1 |
|||
OUT (PPIC),A ; OUTPUT TO PORT |
|||
CALL DELAY ; WAIT |
|||
LD A,40H | 30H ; SET CONTROL PORT 7218 TO OFF |
|||
OUT (PPIC),A ; OUTPUT |
|||
|
|||
SEGDISPLAY_LP: |
|||
LD A,(HL) ; GET DISPLAY DIGIT |
|||
OUT (PPIA),A ; OUT TO PPIA |
|||
LD A,00H | 30H ; SET WRITE STROBE |
|||
OUT (PPIC),A ; OUT TO PPIC |
|||
CALL DELAY ; DELAY |
|||
LD A,40H | 30H ; SET CONTROL PORT OFF |
|||
OUT (PPIC),A ; OUT TO PPIC |
|||
CALL DELAY ; WAIT |
|||
DEC HL ; INC POINTER |
|||
DJNZ SEGDISPLAY_LP ; LOOP FOR NEXT DIGIT |
|||
POP HL ; RESTORE HL |
|||
POP BC ; RESTORE BC |
|||
POP AF ; RESTORE AF |
|||
RET |
|||
#ENDIF |
|||
; |
|||
;__TEXT_STRINGS_________________________________________________________________________________________________________________ |
|||
; |
|||
; STRINGS |
|||
;_____________________________________________________________________________________________________________________________ |
|||
; |
|||
STR_BOOTDISK .DB "BOOT FROM DISK\r\n$" |
|||
STR_BOOTDISK1 .DB "\r\nReading disk information...$" |
|||
STR_BOOTMON .DB "START MONITOR\r\n$" |
|||
STR_BOOTCPM .DB "BOOT CPM FROM ROM\r\n$" |
|||
STR_BOOTZSYS .DB "BOOT ZSYSTEM FROM ROM\r\n$" |
|||
STR_LIST .DB "LIST DEVICES\r\n$" |
|||
STR_INVALID .DB "INVALID SELECTION\r\n$" |
|||
STR_SETUP .DB "SYSTEM SETUP\r\n$" |
|||
STR_SIG .DB "SIGNATURE=$" |
|||
STR_CPMLOC .DB "LOC=$" |
|||
STR_CPMEND .DB "END=$" |
|||
STR_CPMENT .DB "ENT=$" |
|||
STR_LABEL .DB "LABEL=$" |
|||
STR_DRVLIST .DB "\r\nDevices:\r\n$" |
|||
STR_PREFIX .DB "\r\n $" |
|||
STR_LOADING .DB "\r\nLoading$" |
|||
STR_NODISK .DB "\r\nNo disk!$" |
|||
STR_NOBOOT .DB "\r\nDisk not bootable!$" |
|||
STR_BOOTERR .DB "\r\nBoot failure!$" |
|||
; |
|||
STR_BANNER .DB "\r\n", PLATFORM_NAME, " Boot Loader$" |
|||
STR_BOOTMENU .DB "\r\nBoot: (C)PM, (Z)System, (M)onitor,\r\n" |
|||
.DB " (L)ist devices, or Device ID ===> $" |
|||
; |
|||
.IF DSKYENABLE |
|||
BOOT: |
|||
; . . t o o b |
|||
.DB 00H, 00H, 80H, 80H, 094H, 09DH, 09DH, 09FH |
|||
.ENDIF |
|||
; |
|||
#DEFINE CIOMODE_HBIOS |
|||
#DEFINE DSKY_KBD |
|||
#INCLUDE "util.asm" |
|||
; |
|||
; READ A CONSOLE CHARACTER AND CONVERT TO UPPER CASE |
|||
; |
|||
CINUC: |
|||
CALL CIN |
|||
AND 7FH ; STRIP HI BIT |
|||
CP 'A' ; KEEP NUMBERS, CONTROLS |
|||
RET C ; AND UPPER CASE |
|||
CP 7BH ; SEE IF NOT LOWER CASE |
|||
RET NC |
|||
AND 5FH ; MAKE UPPER CASE |
|||
RET |
|||
; |
|||
;================================================================================================== |
|||
; WORKING DATA STORAGE |
|||
;================================================================================================== |
|||
; |
|||
BL_STACKSIZ .EQU 40H |
|||
.FILL BL_STACKSIZ,0 |
|||
BL_STACK .EQU $ |
|||
; |
|||
BL_SPT .DB 16 ; SECTORS PER TRACK FOR LOAD DEVICE |
|||
BL_LUTRK .DW 0 ; STARTING TRACK FOR LU |
|||
BL_CURTRK .DW 0 ; CURRENT TRACK FOR LOAD |
|||
BL_CURSEC .DB 0 ; CURRENT SECTOR FOR LOAD |
|||
BL_CURDMA .DW 0 ; CURRENT MEM LOC BEING LOADED |
|||
BL_COUNT .DB 0 ; LOAD COUNTER |
|||
BL_TIMEOUT .DW 0 ; AUTOBOOT TIMEOUT COUNTDOWN COUNTER |
|||
BL_BOOTID .DB 0 ; BOOT DEVICE ID CHOSEN BY USER |
|||
BL_DEVICE .DB 0 ; DEVICE TO LOAD FROM |
|||
BL_LU .DB 0 ; LU TO LOAD FROM |
|||
; |
|||
; BOOT INFO SECTOR IS READ INTO AREA BELOW |
|||
; THE THIRD SECTOR OF A DISK DEVICE IS RESERVED FOR BOOT INFO |
|||
; |
|||
BL_INFOSEC .EQU $ |
|||
.FILL (512 - 128),0 |
|||
BB_METABUF .EQU $ |
|||
BB_SIG .DW 0 ; SIGNATURE (WILL BE 0A55AH IF SET) |
|||
BB_PLATFORM .DB 0 ; FORMATTING PLATFORM |
|||
BB_DEVICE .DB 0 ; FORMATTING DEVICE |
|||
BB_FORMATTER .FILL 8,0 ; FORMATTING PROGRAM |
|||
BB_DRIVE .DB 0 ; PHYSICAL DISK DRIVE # |
|||
BB_LU .DB 0 ; LOGICAL UNIT (LU) |
|||
.DB 0 ; MSB OF LU, NOW DEPRECATED |
|||
.FILL (BB_METABUF + 128) - $ - 32,0 |
|||
BB_PROTECT .DB 0 ; WRITE PROTECT BOOLEAN |
|||
BB_UPDATES .DW 0 ; UPDATE COUNTER |
|||
BB_RMJ .DB 0 ; RMJ MAJOR VERSION NUMBER |
|||
BB_RMN .DB 0 ; RMN MINOR VERSION NUMBER |
|||
BB_RUP .DB 0 ; RUP UPDATE NUMBER |
|||
BB_RTP .DB 0 ; RTP PATCH LEVEL |
|||
BB_LABEL .FILL 16,0 ; 16 CHARACTER DRIVE LABEL |
|||
BB_TERM .DB 0 ; LABEL TERMINATOR ('$') |
|||
BB_BILOC .DW 0 ; LOC TO PATCH BOOT DRIVE INFO TO (IF NOT ZERO) |
|||
BB_CPMLOC .DW 0 ; FINAL RAM DESTINATION FOR CPM/CBIOS |
|||
BB_CPMEND .DW 0 ; END ADDRESS FOR LOAD |
|||
BB_CPMENT .DW 0 ; CP/M ENTRY POINT (CBIOS COLD BOOT) |
|||
; |
|||
;================================================================================================== |
|||
; FILL REMAINDER OF BANK |
|||
;================================================================================================== |
|||
; |
|||
SLACK: .EQU ($9000 - $) |
|||
.FILL SLACK |
|||
; |
|||
.ECHO "LOADER space remaining: " |
|||
.ECHO SLACK |
|||
.ECHO " bytes.\n" |
|||
.END |
|||
@ -0,0 +1,211 @@ |
|||
; |
|||
;================================================================================================== |
|||
; SETUP |
|||
;================================================================================================== |
|||
; |
|||
; INCLUDE GENERIC STUFF |
|||
; |
|||
#INCLUDE "std.asm" |
|||
; |
|||
.ORG 0 |
|||
; |
|||
;================================================================================================== |
|||
; NORMAL PAGE ZERO SETUP, RET/RETI/RETN AS APPROPRIATE |
|||
;================================================================================================== |
|||
; |
|||
.FILL (000H - $),0FFH ; RST 0 |
|||
JP START ; JUMP TO BOOT CODE |
|||
.FILL (004H - $),0FFH ; FILL TO START OF SIG PTR |
|||
.DW ROM_SIG |
|||
.FILL (008H - $),0FFH ; RST 8 |
|||
RET |
|||
.FILL (010H - $),0FFH ; RST 10 |
|||
RET |
|||
.FILL (018H - $),0FFH ; RST 18 |
|||
RET |
|||
.FILL (020H - $),0FFH ; RST 20 |
|||
RET |
|||
.FILL (028H - $),0FFH ; RST 28 |
|||
RET |
|||
.FILL (030H - $),0FFH ; RST 30 |
|||
RET |
|||
.FILL (038H - $),0FFH ; INT |
|||
RETI |
|||
.FILL (066H - $),0FFH ; NMI |
|||
RETN |
|||
; |
|||
.FILL (070H - $),0FFH ; SIG STARTS AT $80 |
|||
; |
|||
ROM_SIG: |
|||
.DB $76, $B5 ; 2 SIGNATURE BYTES |
|||
.DB 1 ; STRUCTURE VERSION NUMBER |
|||
.DB 7 ; ROM SIZE (IN MULTIPLES OF 4KB, MINUS ONE) |
|||
.DW NAME ; POINTER TO HUMAN-READABLE ROM NAME |
|||
.DW AUTH ; POINTER TO AUTHOR INITIALS |
|||
.DW DESC ; POINTER TO LONGER DESCRIPTION OF ROM |
|||
.DB 0, 0, 0, 0, 0, 0 ; RESERVED FOR FUTURE USE; MUST BE ZERO |
|||
; |
|||
NAME .DB "ROMWBW v", BIOSVER, ", ", BIOSBLD, ", ", TIMESTAMP, 0 |
|||
AUTH .DB "WBW",0 |
|||
DESC .DB "ROMWBW v", BIOSVER, ", Copyright 2014, Wayne Warthen, GNU GPL v3", 0 |
|||
; |
|||
.FILL ($100 - $),$FF ; PAD REMAINDER OF PAGE ZERO |
|||
; |
|||
;================================================================================================== |
|||
; ROM COLD START |
|||
;================================================================================================== |
|||
; |
|||
START: |
|||
DI ; NO INTERRUPTS |
|||
IM 1 ; INTERRUPT MODE 1 |
|||
LD SP,HBX_LOC ; SETUP INITIAL STACK JUST BELOW HBIOS PROXY |
|||
; |
|||
; HARDWARE BOOTSTRAP FOR Z180 |
|||
; FOR N8, ACR & RMAP ARE ASSUMED TO BE ALREADY SET OR THIS CODE |
|||
; WOULD NOT BE EXECUTING |
|||
; |
|||
#IF ((PLATFORM == PLT_N8) | (PLATFORM == PLT_MK4)) |
|||
; SET BASE FOR CPU IO REGISTERS |
|||
LD A,CPU_BASE |
|||
OUT0 (CPU_ICR),A |
|||
|
|||
; SET DEFAULT CPU CLOCK MULTIPLIERS (XTAL / 2) |
|||
XOR A |
|||
OUT0 (CPU_CCR),A |
|||
OUT0 (CPU_CMR),A |
|||
|
|||
; SET DEFAULT WAIT STATES |
|||
LD A,$F0 |
|||
OUT0 (CPU_DCNTL),A |
|||
|
|||
#IF (Z180_CLKDIV >= 1) |
|||
; SET CLOCK DIVIDE TO 1 RESULTING IN FULL XTAL SPEED |
|||
LD A,$80 |
|||
OUT0 (CPU_CCR),A |
|||
#ENDIF |
|||
|
|||
#IF (Z180_CLKDIV >= 2) |
|||
; SET CPU MULTIPLIER TO 1 RESULTINT IN XTAL * 2 SPEED |
|||
LD A,$80 |
|||
OUT0 (CPU_CMR),A |
|||
#ENDIF |
|||
|
|||
; SET DESIRED WAIT STATES |
|||
LD A,0 + (Z180_MEMWAIT << 6) | (Z180_IOWAIT << 4) |
|||
OUT0 (CPU_DCNTL),A |
|||
|
|||
; MMU SETUP |
|||
LD A,$80 |
|||
OUT0 (CPU_CBAR),A ; SETUP FOR 32K/32K BANK CONFIG |
|||
XOR A |
|||
OUT0 (CPU_BBR),A ; BANK BASE = 0 |
|||
LD A,(RAMSIZE + RAMBIAS - 64) >> 2 |
|||
OUT0 (CPU_CBR),A ; COMMON BASE = LAST (TOP) BANK |
|||
#ENDIF |
|||
; |
|||
; HARDWARE BOOTSTRAP FOR ZETA 2 |
|||
; |
|||
#IF (PLATFORM == PLT_ZETA2) |
|||
; SET PAGING REGISTERS |
|||
XOR A |
|||
OUT (MPGSEL_0),A |
|||
INC A |
|||
OUT (MPGSEL_1),A |
|||
LD A,62 |
|||
OUT (MPGSEL_2),A |
|||
INC A |
|||
OUT (MPGSEL_3),A |
|||
; ENABLE PAGING |
|||
LD A,1 |
|||
OUT (MPGENA),A |
|||
#ENDIF |
|||
|
|||
; |
|||
; EMIT FIRST SIGN OF LIFE TO SERIAL PORT |
|||
; |
|||
CALL XIO_INIT ; INIT SERIAL PORT |
|||
LD HL,STR_BOOT ; POINT TO MESSAGE |
|||
CALL XIO_OUTS ; SAY HELLO |
|||
; |
|||
; COPY OURSELVES AND LOADER TO HI RAM FOR PHASE 2 |
|||
; |
|||
LD HL,0 ; COPY FROM START OF ROM IMAGE |
|||
LD DE,$8000 ; TO HIMEM $F000 |
|||
LD BC,$0800 ; COPY 2K |
|||
LDIR |
|||
; |
|||
CALL XIO_DOT ; MARK PROGRESS |
|||
; |
|||
JP PHASE2 ; JUMP TO PHASE 2 BOOT IN UPPER MEMORY |
|||
; |
|||
STR_BOOT .DB "RomWBW$" |
|||
; |
|||
; IMBED DIRECT SERIAL I/O ROUTINES |
|||
; |
|||
#INCLUDE "xio.asm" |
|||
; |
|||
;______________________________________________________________________________________________________________________ |
|||
; |
|||
; THIS IS THE PHASE 2 CODE THAT MUST EXECUTE IN UPPER MEMORY |
|||
; |
|||
.ORG $ + $8000 ; WE ARE NOW EXECUTING IN UPPER MEMORY |
|||
; |
|||
PHASE2: |
|||
CALL XIO_DOT ; MARK PROGRESS |
|||
; |
|||
; LAUNCH HBIOS |
|||
; |
|||
; INSTALL HBIOS PROXY |
|||
LD A,BID_BIOSIMG ; HBIOS IMAGE ROM BANK |
|||
CALL BNKSEL ; SELECT IT |
|||
LD HL,HBX_IMG ; HL := SOURCE OF HBIOS PROXY IMAGE |
|||
LD DE,HBX_LOC ; DE := DESTINATION TO INSTALL IT |
|||
LD BC,HBX_SIZ ; SIZE |
|||
LDIR ; DO THE COPY |
|||
LD A,BID_BOOT ; BOOT/SETUP BANK |
|||
LD (HB_CURBNK),A ; INIT CURRENT BANK |
|||
CALL BNKSEL ; SELECT IT |
|||
CALL XIO_DOT ; MARK PROGRESS |
|||
; |
|||
; INSTALL HBIOS CORE IN SHADOW RAM BANK |
|||
LD A,BID_BIOSIMG ; SOURCE BANK |
|||
LD (HB_SRCBNK),A ; SET IT |
|||
LD A,BID_BIOS ; DESTINATION BANK |
|||
LD (HB_DSTBNK),A ; SET IT |
|||
LD HL,0 ; SOURCE ADDRESS IS ZERO |
|||
LD DE,0 ; TARGET ADDRESS IS ZERO |
|||
LD BC,$8000 ; COPY ENTIRE BANK |
|||
CALL HB_BNKCPY ; DO IT |
|||
CALL XIO_DOT ; MARK PROGRESS |
|||
; |
|||
; INITIALIZE HBIOS |
|||
LD A,BID_BIOS ; HBIOS BANK |
|||
LD HL,0 ; ADDRESS 0 IS HBIOS INIT ENTRY ADDRESS |
|||
CALL HB_BNKCALL ; DO IT |
|||
|
|||
; |
|||
; CHAIN TO OS IMAGES BANK |
|||
; |
|||
LD A,BID_OSIMG ; CHAIN TO OS IMAGES BANK |
|||
LD HL,0 ; ENTER AT ADDRESS 0 |
|||
CALL HB_BNKCALL ; GO THERE |
|||
HALT ; WE SHOULD NEVER COME BACK! |
|||
; |
|||
;================================================================================================== |
|||
; MEMORY MANAGER |
|||
;================================================================================================== |
|||
; |
|||
#INCLUDE "memmgr.asm" |
|||
; |
|||
;================================================================================================== |
|||
; FILL REMAINDER OF SETUP BANK |
|||
;================================================================================================== |
|||
; |
|||
SLACK .EQU ($10000 - $) |
|||
.FILL SLACK,$FF |
|||
; |
|||
.ECHO "SETUP space remaining: " |
|||
.ECHO SLACK |
|||
.ECHO " bytes.\n" |
|||
; |
|||
.END |
|||
@ -1,7 +1,7 @@ |
|||
#DEFINE RMJ 2 |
|||
#DEFINE RMN 6 |
|||
#DEFINE RUP 5 |
|||
#DEFINE RTP 17 |
|||
#DEFINE BIOSVER "2.6.5" |
|||
#DEFINE BIOSBLD "Build 17" |
|||
#DEFINE RMN 7 |
|||
#DEFINE RUP 0 |
|||
#DEFINE RTP 0 |
|||
#DEFINE BIOSVER "2.7.0" |
|||
#DEFINE BIOSBLD "Build 0 Developmental" |
|||
#DEFINE REVISION 500 |
|||
|
|||
@ -0,0 +1,22 @@ |
|||
@echo off |
|||
setlocal |
|||
|
|||
set TOOLS=../../Tools |
|||
|
|||
set PATH=%TOOLS%\tasm32;%TOOLS%\zx;%PATH% |
|||
|
|||
set TASMTABS=%TOOLS%\tasm32 |
|||
|
|||
set ZXBINDIR=%TOOLS%/cpm/bin/ |
|||
set ZXLIBDIR=%TOOLS%/cpm/lib/ |
|||
set ZXINCDIR=%TOOLS%/cpm/include/ |
|||
|
|||
call :asm cbios || goto :eof |
|||
|
|||
goto :eof |
|||
|
|||
:asm |
|||
echo. |
|||
echo Building %1... |
|||
tasm -t80 -b -g3 -fFF %1.asm %1.bin %1.lst |
|||
goto :eof |
|||
@ -0,0 +1,5 @@ |
|||
@echo off |
|||
if exist *.bin del *.bin |
|||
if exist *.lst del *.lst |
|||
if exist *.prn del *.prn |
|||
if exist *.hex del *.hex |
|||
@ -0,0 +1,13 @@ |
|||
; RomWBW Configured for N8VEM simh, 2015-02-14T09:50:52 |
|||
; |
|||
#DEFINE TIMESTAMP "14-Feb-2015" |
|||
; |
|||
PLATFORM .EQU PLT_N8VEM ; HARDWARE PLATFORM |
|||
ROMSIZE .EQU 512 ; SIZE OF ROM IN KB |
|||
; |
|||
; INCLUDE PLATFORM SPECIFIC DEVICE DEFINITIONS |
|||
; |
|||
#INCLUDE "std-n8vem.inc" |
|||
; |
|||
#INCLUDE "config.asm" |
|||
; |
|||
File diff suppressed because it is too large
Binary file not shown.
File diff suppressed because it is too large
@ -0,0 +1,20 @@ |
|||
; |
|||
;================================================================================================== |
|||
; ROMWBW 2.X CONFIGURATION FOR SIMH EMULATOR |
|||
;================================================================================================== |
|||
; |
|||
; BUILD CONFIGURATION OPTIONS |
|||
; |
|||
DEFCON .EQU CIODEV_UART ; DEFAULT CONSOLE DEVICE (LOADER AND MONITOR): CIODEV_UART, CIODEV_CRT, CIODEV_PRPCON, CIODEV_PPPCON |
|||
; |
|||
RAMSIZE .EQU 512 ; SIZE OF RAM IN KB, MUST MATCH YOUR HARDWARE!!! |
|||
CLRRAMDISK .EQU CLR_ALWAYS ; CLR_ALWAYS, CLR_NEVER, CLR_AUTO (CLEAR IF INVALID DIR AREA) |
|||
; |
|||
;DSKYENABLE .EQU FALSE ; TRUE FOR DSKY SUPPORT (DO NOT COMBINE WITH PPIDE) |
|||
; |
|||
DEFIOBYTE .EQU $00 ; DEFAULT INITIAL VALUE FOR CP/M IOBYTE, $00=TTY, $01=CRT (MUST HAVE CRT HARDWARE) |
|||
ALTIOBYTE .EQU DEFIOBYTE ; ALT INITIAL VALUE (USED WHEN CONFIG JUMPER SHORTED) |
|||
WRTCACHE .EQU TRUE ; ENABLE WRITE CACHING IN CBIOS (DE)BLOCKING ALGORITHM |
|||
DSKTRACE .EQU FALSE ; ENABLE TRACING OF CBIOS DISK FUNCTION CALLS |
|||
; |
|||
#DEFINE AUTOCMD "" ; AUTO STARTUP COMMAND FOR CP/M |
|||
@ -0,0 +1,25 @@ |
|||
; |
|||
; N8VEM HARDWARE IO PORT ADDRESSES AND MEMORY LOCATIONS |
|||
; |
|||
RTC .EQU $70 ; ADDRESS OF RTC LATCH AND INPUT PORT |
|||
; |
|||
; MEMORY BANK CONFIGURATION |
|||
; |
|||
BID_ROM0 .EQU $00 |
|||
BID_ROMN .EQU (BID_ROM0 + ((ROMSIZE / 32) - 1)) |
|||
BID_RAM0 .EQU $80 |
|||
BID_RAMN .EQU (BID_RAM0 + ((RAMSIZE / 32) - 1)) |
|||
|
|||
BID_BOOT .EQU BID_ROM0 ; BOOT BANK |
|||
BID_BIOSIMG .EQU BID_ROM0 + 1 ; BIOS IMAGE BANK |
|||
BID_OSIMG .EQU BID_ROM0 + 2 ; ROM LOADER AND IMAGES BANK |
|||
BID_FSFAT .EQU BID_ROM0 + 3 ; FAT FILESYSTEM DRIVER BANK |
|||
BID_ROMD0 .EQU BID_ROM0 + 4 ; FIRST ROM DRIVE BANK |
|||
BID_ROMDN .EQU BID_ROMN ; LAST ROM DRIVE BANK |
|||
|
|||
BID_RAMD0 .EQU BID_RAM0 ; FIRST RAM DRIVE BANK |
|||
BID_RAMDN .EQU BID_RAMN - 4 ; LAST RAM DRIVE BANK |
|||
BID_AUX .EQU BID_RAMN - 3 ; AUX BANK (BPBIOS, ETC.) |
|||
BID_BIOS .EQU BID_RAMN - 2 ; BIOS BANK |
|||
BID_USR .EQU BID_RAMN - 1 ; USER BANK (CP/M TPA, ETC.) |
|||
BID_COM .EQU BID_RAMN ; COMMON BANK, UPPER 32K |
|||
@ -0,0 +1,36 @@ |
|||
; |
|||
; CHARACTER DEVICES |
|||
; |
|||
CIODEV_UART .EQU $00 |
|||
CIODEV_ASCI .EQU $10 |
|||
CIODEV_VDU .EQU $20 |
|||
CIODEV_CVDU .EQU $30 |
|||
CIODEV_UPD7220 .EQU $40 |
|||
CIODEV_N8V .EQU $50 |
|||
CIODEV_PRPCON .EQU $60 |
|||
CIODEV_PPPCON .EQU $70 |
|||
CIODEV_CONSOLE .EQU $C0 |
|||
CIODEV_CRT .EQU $D0 |
|||
CIODEV_BAT .EQU $E0 |
|||
CIODEV_NUL .EQU $F0 |
|||
; |
|||
; DISK DEVICES (ONLY FIRST NIBBLE RELEVANT, SECOND NIBBLE RESERVED FOR UNIT) |
|||
; |
|||
DIODEV_MD .EQU $00 |
|||
DIODEV_FD .EQU $10 |
|||
DIODEV_RF .EQU $20 |
|||
DIODEV_IDE .EQU $30 |
|||
DIODEV_ATAPI .EQU $40 |
|||
DIODEV_PPIDE .EQU $50 |
|||
DIODEV_SD .EQU $60 |
|||
DIODEV_PRPSD .EQU $70 |
|||
DIODEV_PPPSD .EQU $80 |
|||
DIODEV_HDSK .EQU $90 |
|||
; |
|||
; VDA DEVICES (VIDEO DISPLAY ADAPTER) |
|||
; |
|||
VDADEV_NONE .EQU $00 ; NO VDA DEVICE |
|||
VDADEV_VDU .EQU $10 ; ECB VDU - 6545 CHIP |
|||
VDADEV_CVDU .EQU $20 ; ECB COLOR VDU - 8563 CHIP (NOT IMP) |
|||
VDADEV_UPD7220 .EQU $30 ; ECB uP7220 (NOT IMPLEMENTED) |
|||
VDADEV_N8V .EQU $40 ; N8 ONBOARD VDA SUBSYSTEM |
|||
@ -0,0 +1,308 @@ |
|||
; ~/RomWBW/branches/s100/Source/std.asm 1/19/2013 dwg - |
|||
; |
|||
|
|||
; The purpose of this file is to define generic symbols and to include |
|||
; the appropriate std-*.inc file to bring in platform specifics. |
|||
|
|||
; There are four classes of systems supported by N8VEM. |
|||
; 1. N8VEM Platforms that include ECB interface |
|||
; 2. ZETA Genrally N8VEM-like, but no ECB |
|||
; 3. N8 Generally N8VEM-like bt 180 and extra embedded devices |
|||
; 4. S100 Assumes Z80 Master CPU Card |
|||
|
|||
; All the classes require certain generic definitions, and these are |
|||
; defined here prior to the inclusion of platform specific .inc files. |
|||
|
|||
; It is unfortunate, but all the possible config items must be defined |
|||
; here because the config gets read before the specific std-*.inc's |
|||
|
|||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|||
; |
|||
TRUE .EQU 1 |
|||
FALSE .EQU 0 |
|||
; |
|||
; PRIMARY HARDWARE PLATFORMS |
|||
; |
|||
PLT_N8VEM .EQU 1 ; N8VEM ECB Z80 SBC |
|||
PLT_ZETA .EQU 2 ; ZETA Z80 SBC |
|||
PLT_N8 .EQU 3 ; N8 (HOME COMPUTER) Z180 SBC |
|||
PLT_MK4 .EQU 4 |
|||
PLT_S2I .EQU 5 ; SCSI2IDE |
|||
PLT_S100 .EQU 6 ; S100COMPUTERS Z80 based system |
|||
PLT_UNA .EQU 7 ; UNA BIOS |
|||
; |
|||
; RAM DISK INITIALIZATION OPTIONS |
|||
; |
|||
CLR_NEVER .EQU 0 ; NEVER CLEAR RAM DISK |
|||
CLR_AUTO .EQU 1 ; CLEAR RAM DISK IF INVALID DIR ENTRIES |
|||
CLR_ALWAYS .EQU 2 ; ALWAYS CLEAR RAM DISK |
|||
; |
|||
; FLOPPY DISK MEDIA SELECTIONS (ID'S MUST BE INDEX OF ENTRY IN FCD_TBL) |
|||
; |
|||
FDM720 .EQU 0 ; 3.5" FLOPPY, 720KB, 2 SIDES, 80 TRKS, 9 SECTORS |
|||
FDM144 .EQU 1 ; 3.5" FLOPPY, 1.44MB, 2 SIDES, 80 TRKS, 18 SECTORS |
|||
FDM360 .EQU 2 ; 5.25" FLOPPY, 360KB, 2 SIDES, 40 TRKS, 9 SECTORS |
|||
FDM120 .EQU 3 ; 5.25" FLOPPY, 1.2MB, 2 SIDES, 80 TRKS, 15 SECTORS |
|||
FDM111 .EQU 4 ; 8" FLOPPY, 1.11MB, 2 SIDES, 74 TRKS, 15 SECTORS |
|||
; |
|||
; MEDIA ID VALUES |
|||
; |
|||
MID_NONE .EQU 0 |
|||
MID_MDROM .EQU 1 |
|||
MID_MDRAM .EQU 2 |
|||
MID_RF .EQU 3 |
|||
MID_HD .EQU 4 |
|||
MID_FD720 .EQU 5 |
|||
MID_FD144 .EQU 6 |
|||
MID_FD360 .EQU 7 |
|||
MID_FD120 .EQU 8 |
|||
MID_FD111 .EQU 9 |
|||
; |
|||
; CONSOLE TERMINAL TYPE CHOICES |
|||
; |
|||
TERM_TTY .EQU 0 |
|||
TERM_ANSI .EQU 1 |
|||
TERM_WYSE .EQU 2 |
|||
TERM_VT52 .EQU 3 |
|||
; |
|||
; EMULATION TYPES |
|||
; |
|||
EMUTYP_NONE .EQU 0 |
|||
EMUTYP_TTY .EQU 1 |
|||
EMUTYP_ANSI .EQU 2 |
|||
; |
|||
; SYSTEM GENERATION SETTINGS |
|||
; |
|||
SYS_CPM .EQU 1 ; CPM (IMPLIES BDOS + CCP) |
|||
SYS_ZSYS .EQU 2 ; ZSYSTEM OS (IMPLIES ZSDOS + ZCPR) |
|||
; |
|||
DOS_BDOS .EQU 1 ; BDOS |
|||
DOS_ZDDOS .EQU 2 ; ZDDOS VARIANT OF ZSDOS |
|||
DOS_ZSDOS .EQU 3 ; ZSDOS |
|||
; |
|||
CP_CCP .EQU 1 ; CCP COMMAND PROCESSOR |
|||
CP_ZCPR .EQU 2 ; ZCPR COMMAND PROCESSOR |
|||
; |
|||
; CONFIGURE DOS (DOS) AND COMMAND PROCESSOR (CP) BASED ON SYSTEM SETTING (SYS) |
|||
; |
|||
#IFNDEF BLD_SYS |
|||
SYS .EQU SYS_CPM |
|||
#ELSE |
|||
SYS .EQU BLD_SYS |
|||
#ENDIF |
|||
; |
|||
#IF (SYS == SYS_CPM) |
|||
DOS .EQU DOS_BDOS |
|||
CP .EQU CP_CCP |
|||
#DEFINE OSLBL "CP/M-80 2.2" |
|||
#ENDIF |
|||
; |
|||
#IF (SYS == SYS_ZSYS) |
|||
DOS .EQU DOS_ZSDOS |
|||
CP .EQU CP_ZCPR |
|||
#DEFINE OSLBL "ZSDOS 1.1" |
|||
#ENDIF |
|||
; |
|||
; INCLUDE VERSION AND BUILD SETTINGS |
|||
; |
|||
#INCLUDE "ver.inc" ; ADD BIOSVER |
|||
; |
|||
#INCLUDE "build.inc" ; INCLUDE USER CONFIG, ADD VARIANT, TIMESTAMP, & ROMSIZE |
|||
; |
|||
; INCLUDE PLATFORM SPECIFIC HARDWARE DEFINITIONS |
|||
; |
|||
#IF ((PLATFORM == PLT_N8VEM) | (PLATFORM == PLT_ZETA)) |
|||
#INCLUDE "n8vem.inc" |
|||
#ENDIF |
|||
; |
|||
#IF (PLATFORM == PLT_S2I) |
|||
#INCLUDE "s2i.inc" |
|||
#ENDIF |
|||
; |
|||
#IF (PLATFORM == PLT_N8) |
|||
#INCLUDE "n8.inc" |
|||
#ENDIF |
|||
; |
|||
#IF (PLATFORM == PLT_MK4) |
|||
#INCLUDE "mk4.inc" |
|||
#ENDIF |
|||
; |
|||
#IF (PLATFORM == PLT_UNA) |
|||
#INCLUDE "una.inc" |
|||
#ENDIF |
|||
; |
|||
; CHARACTER DEVICE FUNCTIONS |
|||
; |
|||
CF_INIT .EQU 0 |
|||
CF_IN .EQU 1 |
|||
CF_IST .EQU 2 |
|||
CF_OUT .EQU 3 |
|||
CF_OST .EQU 4 |
|||
; |
|||
; DISK OPERATIONS |
|||
; |
|||
DOP_READ .EQU 0 ; READ OPERATION |
|||
DOP_WRITE .EQU 1 ; WRITE OPERATION |
|||
DOP_FORMAT .EQU 2 ; FORMAT OPERATION |
|||
DOP_READID .EQU 3 ; READ ID OPERATION |
|||
; |
|||
; BIOS FUNCTIONS |
|||
; |
|||
#IF (PLATFORM == PLT_UNA) |
|||
BF_CIO .EQU $10 |
|||
BF_CIOIN .EQU BF_CIO + 1 ; CHARACTER INPUT |
|||
BF_CIOOUT .EQU BF_CIO + 2 ; CHARACTER OUTPUT |
|||
BF_CIOIST .EQU BF_CIO + 3 ; CHARACTER INPUT STATUS |
|||
BF_CIOOST .EQU BF_CIO + 4 ; CHARACTER OUTPUT STATUS |
|||
; |
|||
BF_DIO .EQU $40 |
|||
BF_DIORD .EQU BF_DIO + 2 ; DISK READ |
|||
BF_DIOWR .EQU BF_DIO + 3 ; DISK WRITE |
|||
#ELSE |
|||
BF_CIO .EQU $00 |
|||
BF_CIOIN .EQU BF_CIO + 0 ; CHARACTER INPUT |
|||
BF_CIOOUT .EQU BF_CIO + 1 ; CHARACTER OUTPUT |
|||
BF_CIOIST .EQU BF_CIO + 2 ; CHARACTER INPUT STATUS |
|||
BF_CIOOST .EQU BF_CIO + 3 ; CHARACTER OUTPUT STATUS |
|||
BF_CIOCFG .EQU BF_CIO + 4 ; CHARACTER I/O CONFIG |
|||
; |
|||
BF_DIO .EQU $10 |
|||
BF_DIORD .EQU BF_DIO + 0 ; DISK READ |
|||
BF_DIOWR .EQU BF_DIO + 1 ; DISK WRITE |
|||
BF_DIOST .EQU BF_DIO + 2 ; DISK STATUS |
|||
BF_DIOMED .EQU BF_DIO + 3 ; DISK MEDIA |
|||
BF_DIOID .EQU BF_DIO + 4 ; DISK IDENTIFY |
|||
BF_DIOGETBUF .EQU BF_DIO + 8 ; DISK GET BUFFER ADR |
|||
BF_DIOSETBUF .EQU BF_DIO + 9 ; DISK SET BUFFER ADR |
|||
BF_DIODEVCNT .EQU BF_DIO + 10 ; DISK DEVICE COUNT |
|||
BF_DIODEVINF .EQU BF_DIO + 11 ; DISK DEVICE INFO |
|||
; |
|||
BF_RTC .EQU $20 |
|||
BF_RTCGETTIM .EQU BF_RTC + 0 ; GET TIME |
|||
BF_RTCSETTIM .EQU BF_RTC + 1 ; SET TIME |
|||
BF_RTCGETBYT .EQU BF_RTC + 2 ; GET NVRAM BYTE BY INDEX |
|||
BF_RTCSETBYT .EQU BF_RTC + 3 ; SET NVRAM BYTE BY INDEX |
|||
BF_RTCGETBLK .EQU BF_RTC + 4 ; GET NVRAM DATA BLOCK |
|||
BF_RTCSETBLK .EQU BF_RTC + 5 ; SET NVRAM DATA BLOCK |
|||
; |
|||
BF_EMU .EQU $30 |
|||
BF_EMUIN .EQU BF_EMU + 0 ; EMULATOR CHARACTER INPUT |
|||
BF_EMUOUT .EQU BF_EMU + 1 ; EMULATOR CHARACTER OUTPUT |
|||
BF_EMUIST .EQU BF_EMU + 2 ; EMULATOR CHARACTER INPUT STATUS |
|||
BF_EMUOST .EQU BF_EMU + 3 ; EMULATOR CHARACTER OUTPUT STATUS |
|||
BF_EMUCFG .EQU BF_EMU + 4 ; EMULATOR CHARACTER I/O CONFIG |
|||
BF_EMUINI .EQU BF_EMU + 8 ; INITIALIZE EMULATION |
|||
BF_EMUQRY .EQU BF_EMU + 9 ; QUERY EMULATION STATUS |
|||
; |
|||
BF_VDA .EQU $40 |
|||
BF_VDAINI .EQU BF_VDA + 0 ; INITIALIZE VDU |
|||
BF_VDAQRY .EQU BF_VDA + 1 ; QUERY VDU STATUS |
|||
BF_VDARES .EQU BF_VDA + 2 ; SOFT RESET VDU |
|||
BF_VDASCS .EQU BF_VDA + 3 ; SET CURSOR STYLE |
|||
BF_VDASCP .EQU BF_VDA + 4 ; SET CURSOR POSITION |
|||
BF_VDASAT .EQU BF_VDA + 5 ; SET CHARACTER ATTRIBUTE |
|||
BF_VDASCO .EQU BF_VDA + 6 ; SET CHARACTER COLOR |
|||
BF_VDAWRC .EQU BF_VDA + 7 ; WRITE CHARACTER |
|||
BF_VDAFIL .EQU BF_VDA + 8 ; FILL |
|||
BF_VDACPY .EQU BF_VDA + 9 ; COPY |
|||
BF_VDASCR .EQU BF_VDA + 10 ; SCROLL |
|||
BF_VDAKST .EQU BF_VDA + 11 ; GET KEYBOARD STATUS |
|||
BF_VDAKFL .EQU BF_VDA + 12 ; FLUSH KEYBOARD BUFFER |
|||
BF_VDAKRD .EQU BF_VDA + 13 ; READ KEYBOARD |
|||
; |
|||
BF_SYS .EQU $F0 |
|||
BF_SYSSETBNK .EQU BF_SYS + 0 ; SET CURRENT BANK |
|||
BF_SYSGETBNK .EQU BF_SYS + 1 ; GET CURRENT BANK |
|||
BF_SYSCPY .EQU BF_SYS + 2 ; COPY TO/FROM RAM/ROM MEMORY BANK |
|||
BF_SYSXCPY .EQU BF_SYS + 3 ; EXTENDED COPY SETUP |
|||
BF_SYSATTR .EQU BF_SYS + 4 ; GET/SET SYSTEM ATTRIBUTE VALUE |
|||
;BF_SYSXXXX .EQU BF_SYS + 5 ; |
|||
BF_SYSGETVER .EQU BF_SYS + 6 ; GET VERSION OF HBIOS |
|||
#ENDIF |
|||
; |
|||
; SYSTEM ATTRIBUTE IDS |
|||
; |
|||
AID_BOOTVOL .EQU 0 ; BOOT VOLUME, MSB=DEV/UNIT, LSB=LU |
|||
AID_BOOTROM .EQU 0 ; BANK ID OF ROM PAGE BOOTED |
|||
; |
|||
; MEMORY LAYOUT |
|||
; |
|||
SYS_SIZ .EQU $3000 ; COMBINED SIZE OF SYSTEM AREA (OS + HBIOS PROXY) |
|||
HBBUF_SIZ .EQU 1024 ; INVARIANT HBIOS PHYSICAL DISK BUFFER, 1K |
|||
HBX_SIZ .EQU $200 ; HBIOS PROXY SIZE (SUBJECT TO CHANGE) |
|||
CPM_SIZ .EQU SYS_SIZ - HBX_SIZ ; NET SIZE OF ALL OS COMPONENTS (EXCLUDING HBIOS PROXY) |
|||
CCP_SIZ .EQU $800 ; INVARIANT SIZE OF CCP |
|||
BDOS_SIZ .EQU $E00 ; INVARIANT SIZE OF BDOS |
|||
CBIOS_SIZ .EQU CPM_SIZ - CCP_SIZ - BDOS_SIZ ; CBIOS IS THE REMAINDER |
|||
|
|||
MEMTOP .EQU $10000 ; INVARIANT TOP OF Z80 ADDRESSABLE MEMORY |
|||
BNKTOP .EQU $8000 ; BANK MEMORY BARRIER |
|||
|
|||
HBBUF_IMG .EQU BNKTOP - HBBUF_SIZ ; LOC OF DISK BUFFER IN HBIOS IMAGE BANK |
|||
HBX_IMG .EQU BNKTOP - HBX_SIZ ; LOC OF HBX IMAGE IN HBIOS IMAGE BANK |
|||
|
|||
HBBUF_END .EQU BNKTOP ; END OF PHYSICAL DISK BUFFER IN HBIOS |
|||
HBBUF_LOC .EQU HBBUF_END - HBBUF_SIZ ; START OF PHYSICAL DISK BUFFER |
|||
HBX_END .EQU MEMTOP ; END OF HBIOS PROXY |
|||
HBX_LOC .EQU HBX_END - HBX_SIZ ; START OF HBIOS PROXY |
|||
CPM_END .EQU HBX_LOC ; END OF CPM COMPONENTS (INCLUDING CBIOS) |
|||
CPM_LOC .EQU CPM_END - CPM_SIZ ; START OF CPM COMPONENTS |
|||
CBIOS_END .EQU HBX_LOC ; END OF CBIOS |
|||
CBIOS_LOC .EQU CBIOS_END - CBIOS_SIZ ; START OF CBIOS |
|||
BDOS_END .EQU CBIOS_LOC ; END OF BDOS |
|||
BDOS_LOC .EQU BDOS_END - BDOS_SIZ ; START OF BDOS |
|||
CCP_END .EQU BDOS_LOC ; END OF CCP |
|||
CCP_LOC .EQU CCP_END - CCP_SIZ ; START OF CCP |
|||
|
|||
CPM_ENT .EQU CBIOS_LOC ; CPM ENTRY POINT (IN CBIOS) |
|||
CCP_ENT .EQU CPM_LOC ; COMMAND PROCESSOR ENTRY POINT (IN CCP) |
|||
|
|||
MON_LOC .EQU $C000 ; LOCATION OF MONITOR FOR RUNNING SYSTEM |
|||
MON_SIZ .EQU $1000 ; SIZE OF MONITOR BINARY IMAGE |
|||
MON_END .EQU MON_LOC + MON_SIZ ; END OF MONITOR |
|||
|
|||
MON_DSKY .EQU MON_LOC + (0 * 3) ; MONITOR ENTRY (DSKY) |
|||
MON_SERIAL .EQU MON_LOC + (1 * 3) ; MONITOR ENTRY (SERIAL PORT) |
|||
|
|||
CBIOS_BOOT .EQU CBIOS_LOC + (0 * 3) |
|||
CBIOS_WBOOT .EQU CBIOS_LOC + (1 * 3) |
|||
CBIOS_CONST .EQU CBIOS_LOC + (2 * 3) |
|||
CBIOS_CONIN .EQU CBIOS_LOC + (3 * 3) |
|||
CBIOS_CONOUT .EQU CBIOS_LOC + (4 * 3) |
|||
CBIOS_LIST .EQU CBIOS_LOC + (5 * 3) |
|||
CBIOS_PUNCH .EQU CBIOS_LOC + (6 * 3) |
|||
CBIOS_READER .EQU CBIOS_LOC + (7 * 3) |
|||
CBIOS_HOME .EQU CBIOS_LOC + (8 * 3) |
|||
CBIOS_SELDSK .EQU CBIOS_LOC + (9 * 3) |
|||
CBIOS_SETTRK .EQU CBIOS_LOC + (10 * 3) |
|||
CBIOS_SETSEC .EQU CBIOS_LOC + (11 * 3) |
|||
CBIOS_SETDMA .EQU CBIOS_LOC + (12 * 3) |
|||
CBIOS_READ .EQU CBIOS_LOC + (13 * 3) |
|||
CBIOS_WRITE .EQU CBIOS_LOC + (14 * 3) |
|||
CBIOS_LISTST .EQU CBIOS_LOC + (15 * 3) |
|||
CBIOS_SECTRN .EQU CBIOS_LOC + (16 * 3) |
|||
; |
|||
CDISK: .EQU 4 ; LOC IN PAGE 0 OF CURRENT DISK NUMBER 0=A,...,15=P |
|||
IOBYTE: .EQU 3 ; LOC IN PAGE 0 OF I/O DEFINITION BYTE |
|||
; |
|||
; HBIOS PROXY COMMON DATA BLOCK |
|||
; EXACTLY 32 BYTES AT $FFE0-$FFFF |
|||
; |
|||
HBX_XFC .EQU $10000 - $20 ; HBIOS PROXY INTERFACE AREA, 32 BYTES FIXED |
|||
; |
|||
HBX_XFCDAT .EQU HBX_XFC ; DATA PORTION OF HBIOX PROXY INTERFACE AREA |
|||
HB_CURBNK .EQU HBX_XFCDAT + 0 ; CURRENTLY ACTIVE LOW MEMORY BANK ID |
|||
HB_PRVBNK .EQU HBX_XFCDAT + 1 ; PREVIOUS BANK (BANK SELECTED PRIOR TO CURRENT BANK) |
|||
HB_SRCADR .EQU HBX_XFCDAT + 2 ; BNKCPY: DESTINATION BANK ID |
|||
HB_SRCBNK .EQU HBX_XFCDAT + 4 ; BNKCPY: SOURCE BANK ID |
|||
HB_DSTADR .EQU HBX_XFCDAT + 5 ; BNKCPY: DESTINATION ADDRESS |
|||
HB_DSTBNK .EQU HBX_XFCDAT + 7 ; BNKCPY: SOURCE ADDRESS |
|||
HB_CNT .EQU HBX_XFCDAT + 8 ; BNKCPY: COUNT |
|||
; |
|||
HBX_XFCFNS .EQU HBX_XFC + $10 ; JUMP TABLE PORTION OF HBIOS PROXY INTERFACE AREA |
|||
HB_INVOKE .EQU HBX_XFCFNS + (0 * 3) ; INVOKE HBIOS FUNCTION |
|||
HB_BNKSEL .EQU HBX_XFCFNS + (1 * 3) ; SELECT LOW MEMORY BANK ID |
|||
HB_BNKCPY .EQU HBX_XFCFNS + (2 * 3) ; INTERBANK MEMORY COPY |
|||
HB_BNKCALL .EQU HBX_XFCFNS + (3 * 3) ; INTERBANK FUNCTION CALL |
|||
HB_LOC .EQU HBX_XFCFNS + 12 ; ADDRESS OF HBIOS PROXY START |
|||
HB_IDENT .EQU HBX_XFCFNS + 14 ; POINTER TO HBIOS IDENT DATA BLOCK |
|||
@ -0,0 +1,394 @@ |
|||
; |
|||
;================================================================================================== |
|||
; UTILITY FUNCTIONS |
|||
;================================================================================================== |
|||
; |
|||
; |
|||
CHR_CR .EQU 0DH |
|||
CHR_LF .EQU 0AH |
|||
CHR_BS .EQU 08H |
|||
CHR_ESC .EQU 1BH |
|||
; |
|||
;__________________________________________________________________________________________________ |
|||
; |
|||
; UTILITY PROCS TO PRINT SINGLE CHARACTERS WITHOUT TRASHING ANY REGISTERS |
|||
; |
|||
PC_SPACE: |
|||
PUSH AF |
|||
LD A,' ' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_PERIOD: |
|||
PUSH AF |
|||
LD A,'.' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_COLON: |
|||
PUSH AF |
|||
LD A,':' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_COMMA: |
|||
PUSH AF |
|||
LD A,',' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_LBKT: |
|||
PUSH AF |
|||
LD A,'[' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_RBKT: |
|||
PUSH AF |
|||
LD A,']' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_LT: |
|||
PUSH AF |
|||
LD A,'<' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_GT: |
|||
PUSH AF |
|||
LD A,'>' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_LPAREN: |
|||
PUSH AF |
|||
LD A,'(' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_RPAREN: |
|||
PUSH AF |
|||
LD A,')' |
|||
JR PC_PRTCHR |
|||
|
|||
PC_ASTERISK: |
|||
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 |
|||
|
|||
NEWLINE: |
|||
CALL PC_CR |
|||
CALL PC_LF |
|||
RET |
|||
; |
|||
; PRINT THE HEX BYTE VALUE IN A |
|||
; |
|||
PRTHEXBYTE: |
|||
PUSH AF |
|||
PUSH DE |
|||
CALL HEXASCII |
|||
LD A,D |
|||
CALL COUT |
|||
LD A,E |
|||
CALL COUT |
|||
POP DE |
|||
POP AF |
|||
RET |
|||
; |
|||
; PRINT THE HEX WORD VALUE IN BC |
|||
; |
|||
PRTHEXWORD: |
|||
PUSH AF |
|||
LD A,B |
|||
CALL PRTHEXBYTE |
|||
LD A,C |
|||
CALL PRTHEXBYTE |
|||
POP AF |
|||
RET |
|||
; |
|||
; CONVERT BINARY VALUE IN A TO ASCII HEX CHARACTERS IN DE |
|||
; |
|||
HEXASCII: |
|||
LD D,A |
|||
CALL HEXCONV |
|||
LD E,A |
|||
LD A,D |
|||
RLCA |
|||
RLCA |
|||
RLCA |
|||
RLCA |
|||
CALL HEXCONV |
|||
LD D,A |
|||
RET |
|||
; |
|||
; CONVERT LOW NIBBLE OF A TO ASCII HEX |
|||
; |
|||
HEXCONV: |
|||
AND 0FH ;LOW NIBBLE ONLY |
|||
ADD A,90H |
|||
DAA |
|||
ADC A,40H |
|||
DAA |
|||
RET |
|||
; |
|||
; OUTPUT A '$' TERMINATED STRING |
|||
; |
|||
WRITESTR: |
|||
PUSH AF |
|||
WRITESTR1: |
|||
LD A,(DE) |
|||
CP '$' ; TEST FOR STRING TERMINATOR |
|||
JP Z,WRITESTR2 |
|||
CALL COUT |
|||
INC DE |
|||
JP WRITESTR1 |
|||
WRITESTR2: |
|||
POP AF |
|||
RET |
|||
; |
|||
; PANIC: TRY TO DUMP MACHINE STATE AND HALT |
|||
; |
|||
PANIC: |
|||
PUSH HL |
|||
PUSH DE |
|||
PUSH BC |
|||
PUSH AF |
|||
LD DE,STR_PANIC |
|||
CALL WRITESTR |
|||
LD DE,STR_AF |
|||
CALL WRITESTR |
|||
POP BC ; AF |
|||
CALL PRTHEXWORD |
|||
LD DE,STR_BC |
|||
CALL WRITESTR |
|||
POP BC ; BC |
|||
CALL PRTHEXWORD |
|||
LD DE,STR_DE |
|||
CALL WRITESTR |
|||
POP BC ; DE |
|||
CALL PRTHEXWORD |
|||
LD DE,STR_HL |
|||
CALL WRITESTR |
|||
POP BC ; HL |
|||
CALL PRTHEXWORD |
|||
LD DE,STR_PC |
|||
CALL WRITESTR |
|||
POP BC ; PC |
|||
CALL PRTHEXWORD |
|||
LD DE,STR_SP |
|||
CALL WRITESTR |
|||
LD HL,0 |
|||
ADD HL,SP ; SP |
|||
LD B,H |
|||
LD C,L |
|||
CALL PRTHEXWORD |
|||
|
|||
RST 38 |
|||
|
|||
HALT |
|||
|
|||
JP 0 |
|||
; |
|||
;================================================================================================== |
|||
; CONSOLE CHARACTER I/O HELPER ROUTINES (REGISTERS PRESERVED) |
|||
;================================================================================================== |
|||
; |
|||
; OUTPUT CHARACTER FROM A |
|||
COUT: |
|||
PUSH AF |
|||
PUSH BC |
|||
PUSH DE |
|||
PUSH HL |
|||
LD C,A |
|||
CALL CBIOS_CONOUT |
|||
POP HL |
|||
POP DE |
|||
POP BC |
|||
POP AF |
|||
RET |
|||
; |
|||
; INPUT CHARACTER TO A |
|||
; |
|||
CIN: |
|||
PUSH BC |
|||
PUSH DE |
|||
PUSH HL |
|||
CALL CBIOS_CONIN |
|||
POP HL |
|||
POP DE |
|||
POP BC |
|||
RET |
|||
; |
|||
; RETURN INPUT STATUS IN A (0 = NO CHAR, !=0 CHAR WAITING) |
|||
; |
|||
CST: |
|||
PUSH BC |
|||
PUSH DE |
|||
PUSH HL |
|||
CALL CBIOS_CONST |
|||
POP HL |
|||
POP DE |
|||
POP BC |
|||
RET |
|||
; |
|||
STR_PANIC .DB "\r\n\r\n>>> FATAL ERROR:$" |
|||
STR_AF .DB " AF=$" |
|||
STR_BC .DB " BC=$" |
|||
STR_DE .DB " DE=$" |
|||
STR_HL .DB " HL=$" |
|||
STR_PC .DB " PC=$" |
|||
STR_SP .DB " SP=$" |
|||
; |
|||
; INDIRECT JUMP TO ADDRESS IN HL |
|||
; |
|||
; MOSTLY USEFUL TO PERFORM AN INDIRECT CALL LIKE: |
|||
; LD HL,xxxx |
|||
; CALL JPHL |
|||
; |
|||
JPHL: JP (HL) |
|||
; |
|||
; ADD HL,A |
|||
; |
|||
; A REGISTER IS DESTROYED! |
|||
; |
|||
|
|||
ADDHLA: |
|||
ADD A,L |
|||
LD L,A |
|||
RET NC |
|||
INC H |
|||
RET |
|||
; |
|||
; MULTIPLY 8-BIT VALUES |
|||
; IN: MULTIPLY H BY E |
|||
; OUT: HL = RESULT, E = 0, B = 0 |
|||
; |
|||
MULT8: |
|||
LD D,0 |
|||
LD L,D |
|||
LD B,8 |
|||
MULT8_LOOP: |
|||
ADD HL,HL |
|||
JR NC,MULT8_NOADD |
|||
ADD HL,DE |
|||
MULT8_NOADD: |
|||
DJNZ MULT8_LOOP |
|||
RET |
|||
; |
|||
; FILL MEMORY AT HL WITH VALUE A, LENGTH IN BC, ALL REGS USED |
|||
; LENGTH *MSUT* BE GREATER THAN 1 FOR PROPER OPERATION!!! |
|||
; |
|||
FILL: |
|||
LD D,H ; SET DE TO HL |
|||
LD E,L ; SO DESTINATION EQUALS SOURCE |
|||
LD (HL),A ; FILL THE FIRST BYTE WITH DESIRED VALUE |
|||
INC DE ; INCREMENT DESTINATION |
|||
DEC BC ; DECREMENT THE COUNT |
|||
LDIR ; DO THE REST |
|||
RET ; RETURN |
|||
; |
|||
; SET A BIT IN BYTE ARRAY AT HL, INDEX IN A |
|||
; |
|||
BITSET: |
|||
CALL BITLOC ; LOCATE THE BIT |
|||
OR (HL) ; SET THE SPECIFIED BIT |
|||
LD (HL),A ; SAVE IT |
|||
RET ; RETURN |
|||
; |
|||
; CLEAR A BIT IN BYTE ARRAY AT HL, INDEX IN A |
|||
; |
|||
BITCLR: |
|||
CALL BITLOC ; LOCATE THE BIT |
|||
CPL ; INVERT ALL BITS |
|||
AND (HL) ; CLEAR SPECIFIED BIT |
|||
LD (HL),A ; SAVE IT |
|||
RET ; RETURN |
|||
; |
|||
; GET VALUE OF A BIT IN BYTE ARRAY AT HL, INDEX IN A |
|||
; |
|||
BITTST: |
|||
CALL BITLOC ; LOCATE THE BIT |
|||
AND (HL) ; SET Z FLAG BASED ON BIT |
|||
RET ; RETURN |
|||
; |
|||
; LOCATE A BIT IN BYTE ARRAY AT HL, INDEX IN A |
|||
; RETURN WITH HL POINTING TO BYTE AND A WITH MASK FOR SPECIFIC BIT |
|||
; |
|||
BITLOC: |
|||
PUSH AF ; SAVE BIT INDEX |
|||
SRL A ; DIVIDE BY 8 TO GET BYTE INDEX |
|||
SRL A ; " |
|||
SRL A ; " |
|||
LD C,A ; MOVE TO BC |
|||
LD B,0 ; " |
|||
ADD HL,BC ; HL NOW POINTS TO BYTE CONTAINING BIT |
|||
POP AF ; RECOVER A (INDEX) |
|||
AND $07 ; ISOLATE REMAINDER, Z SET IF ZERO |
|||
LD B,A ; SETUP SHIFT COUNTER |
|||
LD A,1 ; SETUP A WITH MASK |
|||
RET Z ; DONE IF ZERO |
|||
BITLOC1: |
|||
SLA A ; SHIFT |
|||
DJNZ BITLOC1 ; LOOP AS NEEDED |
|||
RET ; DONE |
|||
; |
|||
; PRINT VALUE OF A IN DECIMAL WITH LEADING ZERO SUPPRESSION |
|||
; |
|||
PRTDECB: |
|||
PUSH HL |
|||
PUSH AF |
|||
LD L,A |
|||
LD H,0 |
|||
CALL PRTDEC |
|||
POP AF |
|||
POP HL |
|||
RET |
|||
; |
|||
; PRINT VALUE OF HL IN DECIMAL WITH LEADING ZERO SUPPRESSION |
|||
; |
|||
PRTDEC: |
|||
PUSH BC |
|||
PUSH DE |
|||
PUSH HL |
|||
LD E,'0' |
|||
LD BC,-10000 |
|||
CALL PRTDEC1 |
|||
LD BC,-1000 |
|||
CALL PRTDEC1 |
|||
LD BC,-100 |
|||
CALL PRTDEC1 |
|||
LD C,-10 |
|||
CALL PRTDEC1 |
|||
LD E,0 |
|||
LD C,-1 |
|||
CALL PRTDEC1 |
|||
POP HL |
|||
POP DE |
|||
POP BC |
|||
RET |
|||
PRTDEC1: |
|||
LD A,'0' - 1 |
|||
PRTDEC2: |
|||
INC A |
|||
ADD HL,BC |
|||
JR C,PRTDEC2 |
|||
SBC HL,BC |
|||
CP E |
|||
JR Z,PRTDEC3 |
|||
LD E,0 |
|||
CALL COUT |
|||
PRTDEC3: |
|||
RET |
|||
; |
|||
;================================================================================================== |
|||
; DATA |
|||
;================================================================================================== |
|||
; |
|||
STR_EMPTY .TEXT "<EMPTY>$" |
|||
@ -0,0 +1,7 @@ |
|||
#DEFINE RMJ 2 |
|||
#DEFINE RMN 7 |
|||
#DEFINE RUP 0 |
|||
#DEFINE RTP 0 |
|||
#DEFINE BIOSVER "2.7.0" |
|||
#DEFINE BIOSBLD "Build 0 Developmental" |
|||
#DEFINE REVISION 500 |
|||
Binary file not shown.
Binary file not shown.
@ -1,880 +0,0 @@ |
|||
--THE README FILE-- |
|||
------------------------ |
|||
|
|||
README contains late-breaking news and tips about WordStar, |
|||
and information about printers. |
|||
|
|||
|
|||
THE DISKS THAT CAME IN YOUR PACKAGE |
|||
----------------------------------- |
|||
|
|||
The file HOMONYMS.TXT is included on the Speller disk |
|||
contrary to what is listed in Appendix D. |
|||
|
|||
|
|||
INSTALLATION |
|||
------------ |
|||
|
|||
WINSTALL and WSCHANGE |
|||
|
|||
WordStar has two installation programs: |
|||
|
|||
o WINSTALL contains the basic choices to install WordStar. |
|||
It is recommended for all users. |
|||
|
|||
Be sure and install your valid disk drives since WordStar |
|||
running under CP/M cannot recover from attempts to access non- |
|||
existent disk drives. |
|||
|
|||
o WSCHANGE contains every installation and customization |
|||
choice. It is designed for advanced users and users who |
|||
want to customize WordStar after they're familiar with it. |
|||
Use the menu listing below for a directory of the menus |
|||
in WSCHANGE. |
|||
|
|||
Directory of WSCHANGE Menus |
|||
|
|||
The chart below shows the organization of menus in WSCHANGE. |
|||
Print it out and refer to it as you customize WordStar. |
|||
|
|||
Main Installation Menu |
|||
|
|||
A Console |
|||
A Monitor |
|||
A Monitor selection |
|||
B Monitor name |
|||
C Screen sizing |
|||
B Function keys |
|||
C Monitor patches |
|||
A Special characters |
|||
B Cursor control |
|||
C Screen control |
|||
D Keyboard patches |
|||
A Function keys |
|||
B Save function keys |
|||
E Interface patches |
|||
A Console busy handshaking |
|||
B Special I/O subroutines |
|||
B Printer |
|||
A Printer choices |
|||
A Printer selection |
|||
B Printer name |
|||
C Default printer driver |
|||
B Printer driver library |
|||
A Select library file |
|||
B Create smaller library |
|||
C Add new printer driver |
|||
D Change printer driver data |
|||
C WS printer patches |
|||
A Custom print controls, printer initialization |
|||
|
|||
NOTE: Disregard the "CUSTOM & SIMPLE Controls Save CUSTOM/SIMPLE |
|||
Controls" option shown. This is not available from this menu. |
|||
|
|||
D Printing defaults |
|||
E Printer interface |
|||
A Printer port selection |
|||
B Printer busy handshaking |
|||
C Printer subroutines |
|||
C Computer |
|||
A Disk drives |
|||
A Valid disk drives |
|||
B Maximum valid user number |
|||
C Delay disk access if typing |
|||
B Operating system |
|||
A Single-user system |
|||
B Multi-user MP/M |
|||
C Multi-user Turbo DOS |
|||
D ZCPR3 |
|||
C Memory usage |
|||
D WordStar files |
|||
E Directory display |
|||
F Computer patches |
|||
D WordStar |
|||
A Page layout |
|||
A Page sizing & margins |
|||
B Headers & footers |
|||
C Tabs |
|||
B Editing settings |
|||
A Edit screen & help level |
|||
B Typing |
|||
C Paragraph alignment |
|||
D Blocks |
|||
E Erase & unerase |
|||
F Lines & characters |
|||
G Find & replace |
|||
H WordStar 3.3 compatibility |
|||
I Printing defaults |
|||
C Other features |
|||
A Spelling checks |
|||
B Nondocument mode |
|||
C Indexing |
|||
D Shorthand (key macros) |
|||
E Merge printing |
|||
F Miscellaneous |
|||
E Patching |
|||
A Auto patcher |
|||
B Save settings |
|||
C Reset all settings |
|||
|
|||
MEMORY USAGE |
|||
------------ |
|||
|
|||
WordStar requires a minimum TPA size of 50 kbytes to run |
|||
using the factory defaults. The TPA is the amount of memory |
|||
available in your computer for use by programs that have a |
|||
file type of COM. To see how big the TPA is in your computer, |
|||
press the question mark key (?) at the Opening Menu. |
|||
|
|||
The amount of memory required by WordStar can be reduced by |
|||
approximately 3 kbytes if necessary. Use the WSCHANGE program |
|||
to select the minimum memory configuration option. The menu |
|||
will show you what capabilities are being reduced. |
|||
|
|||
WordStar uses a general-purpose buffer for a variety of |
|||
tasks. WordStar allocates memory to this buffer for editing, |
|||
for merge printing, and at the Opening Menu (see BFSIZE in |
|||
PATCH.LST). The buffer used for editing is usually the most |
|||
sensitive to a reduced TPA size. (You may be able to use the |
|||
Opening Menu and print, but there may be insufficient memory |
|||
for editing.) |
|||
|
|||
The merge print buffer is used only to hold merge print |
|||
variable names and data. Increase it if you run out of memory |
|||
while merge printing. |
|||
|
|||
The Opening Menu buffer is used primarily to hold the file |
|||
directory, and for miscellaneous tasks. |
|||
|
|||
|
|||
LOW-MEMORY INDICATOR IN STATUS LINE |
|||
----------------------------------- |
|||
|
|||
If the Low-Memory indicator appears in the status line, it |
|||
means that WordStar was unable to complete some function. |
|||
The most common symptoms are: the line number in the |
|||
status line is wrong, or a paragraph alignment could not be |
|||
completed. You may correct the line counter by saving your |
|||
file, exiting WordStar, and re-loading your file. To correct |
|||
the paragraph alignment, move your cursor to the point where |
|||
paragraph alignment stopped, and then press ^B again. |
|||
|
|||
The reason this comes up is that WordStar was not able to fit |
|||
a big enough chunk of text into memory at one time. |
|||
|
|||
When you first begin editing, WordStar uses the value from |
|||
EDSIZE in the user area to determine the minimum amount |
|||
of memory required for a page of text. The default |
|||
is set for approximately a 55 line by 66 column page. If |
|||
your page size is routinely larger than this, you may want |
|||
to increase EDSIZE. Multiply the number of lines by the |
|||
number of columns, and divide by 128. |
|||
|
|||
If the Low-Memory indicator comes on while printing, it is due |
|||
to either the same reasons as for editing, or there is |
|||
insufficient memory to print the text proportionally spaced. |
|||
The amount of memory required depends on which printer |
|||
driver you are using. If you aren't using the .PS ON dot |
|||
command to turn proportional spacing on in your document, |
|||
low memory won't be a problem. Also, WordStar uses more |
|||
memory for merge printing than it does for regular printing |
|||
(around 2.5 kbytes more). |
|||
|
|||
The Low-Memory indicator will also appear when a full disk error |
|||
is encountered during editing. Treat the disk-full error as you |
|||
would normally. |
|||
|
|||
|
|||
RAM-RESIDENT PROGRAMS |
|||
--------------------- |
|||
|
|||
RAM-resident programs, such as SmartKey, reduce the amount of |
|||
working memory (TPA) that WordStar can use. The new features in |
|||
WordStar, such as shorthand, may reduce the need for these |
|||
RAM-resident programs, thus freeing memory for WordStar. |
|||
|
|||
|
|||
ZCPR3 SUPPORT |
|||
------------- |
|||
|
|||
In order to enable the ZCPR facilities within WordStar, the user |
|||
must use the Z3INS utility provided with ZCPR to install the |
|||
address of the ZCPR "environment" into WordStar. The environment |
|||
contains information that WordStar uses to support ZCPR-specific |
|||
functions. |
|||
|
|||
Generally, the user should log onto the drive containing the file |
|||
WS.COM, and issue the command: |
|||
|
|||
Z3INS SYS.ENV WS.COM |
|||
|
|||
The user should also run either WINSTALL or WSCHANGE to further |
|||
install WordStar for ZCPR. However, this is not mandatory because |
|||
the only thing that happens is that the WordStar sign-on says |
|||
"ZCPR3," and the LGLUSR location in the user area is changed for a |
|||
maximum user number of 31. (The normal default for LGLUSR is 15.) |
|||
|
|||
Once the user has installed WordStar for use with ZCPR, the user |
|||
will be able to use the following ZCPR features: |
|||
|
|||
- A named directory may be used when logging onto a new drive/user. |
|||
|
|||
- A named directory may be used instead of a drive/user as part |
|||
of any file name. |
|||
|
|||
- The drive/user always appears above file directories. (For CP/M |
|||
only the drive letter is shown if the user number is zero.) |
|||
|
|||
- The directory name also appears above the directory if one has |
|||
been defined for the currently logged drive/user. |
|||
|
|||
- If WordStar does not find its OVR files on the current drive and |
|||
user, it will search the drives and user numbers in the ZCPR |
|||
search path rather than using its standard search pattern. |
|||
|
|||
- WordStar installs itself as a ZCPR "shell" process which lets the |
|||
user enter any legal ZCPR command when running a program. (CP/M |
|||
can only run programs that are COM files.) |
|||
|
|||
|
|||
OSBORNE USERS |
|||
------------- |
|||
|
|||
The command to change a hard carriage return to a soft carriage |
|||
return (document mode) or to turn Auto-indent ON (nondocument |
|||
mode) does not function on the Osborne because of a limitation |
|||
in its BIOS. The following patch can be applied to change the |
|||
command from ^^ to ^- (Ctrl-Hyphen): |
|||
|
|||
Using DDT or SID in the file WSMSGS.OVR: |
|||
|
|||
At 02DA replace 1E with a 1D |
|||
At 02EF replace 1E with a 1D |
|||
At 0359 replace 1E with a 1D |
|||
At 06B2 replace 1E with a 1D |
|||
At 06C9 replace 1E with a 1D |
|||
|
|||
At the system prompt type SAVE 53 WSMSGS.OVR |
|||
|
|||
For more information on how to use SID or DDT, see your CP/M |
|||
reference guide. As always, be sure and apply the patch to a |
|||
COPY of the file. |
|||
|
|||
|
|||
INSTRUCTIONS FOR TWO FLOPPY DISK COMPUTERS |
|||
------------------------------------------ |
|||
|
|||
Do not remove the Program disk while you are using WordStar. |
|||
|
|||
The Printer Driver Library file (WSPRINT.OVR) on the WordStar |
|||
program disk is much smaller than the Printer Driver Library |
|||
file contained on the disk labeled PRINTER. Be sure to read the |
|||
section in "Starting" that discusses the printer library file. |
|||
|
|||
|
|||
RUN A PROGRAM |
|||
------------- |
|||
|
|||
Once you press R you can type the drive and user number for the |
|||
program you want to run. You may run only .COM files. CCP commands, |
|||
such as DIR cannot be used. |
|||
|
|||
|
|||
INDEXING |
|||
-------- |
|||
|
|||
Using StarIndex |
|||
|
|||
StarIndex 1.01 works with files created with this release of |
|||
WordStar. |
|||
|
|||
"Can't Use That Printer" Message |
|||
|
|||
When WordStar creates an index or table of contents, it uses |
|||
the printer drivers $INDEX and $TOC. If you created a smaller |
|||
WSPRINT.OVR file, you may have left these drivers out. To |
|||
return them to the file, copy the original WSPRINT.OVR file |
|||
onto your disk. When you create a smaller file again, be sure |
|||
to save these drivers. See Appendix C in the WordStar manual |
|||
for a list of other drivers to save. |
|||
|
|||
|
|||
SPELL CHECKING |
|||
-------------- |
|||
|
|||
Dual floppy disk users: |
|||
|
|||
Unless you have sufficient room on your working WordStar program |
|||
disk for the files TW.COM, SPELL.COM, MARKFIX.COM, REVIEW.COM and |
|||
MAINDICT.CMP you will not be able to run a spell check from the |
|||
Opening Menu. You will need to exit WordStar and replace the |
|||
working WordStar program disk with the dictionary disk you created |
|||
during installation. This disk should contain the files listed |
|||
above. Make sure the disk in drive B has the file you want to |
|||
spell-check. |
|||
|
|||
Follow the directions for running a spell check in The WORD Plus |
|||
manual. |
|||
|
|||
|
|||
UPGRADING FROM A PREVIOUS RELEASE |
|||
--------------------------------- |
|||
|
|||
This release of WordStar contains many new features and commands. |
|||
See the "What's New" booklet for a complete list. The following |
|||
changes came in too late to be included in the documentation. |
|||
|
|||
Printer Patches |
|||
|
|||
Previous versions of WordStar treat most dot matrix printers |
|||
and other non-daisy wheel printers as a DRAFT printer with a |
|||
few patchable items. Because of this, many users have used |
|||
these patches to be able to use certain features of their |
|||
printers. Sometimes the patches have been quite extensive, and |
|||
some users have many files that count on them. |
|||
|
|||
The printer drivers of WordStar Release 4, on the other hand, |
|||
are very powerful. Almost every driver recognizes all the print |
|||
controls and all the dot commands. In fact, if a document is |
|||
written to be printed on one kind of printer, it is likely that |
|||
it will also print fine on some other printer. |
|||
|
|||
However, if you want to use your existing files with WordStar |
|||
4, and those files rely on the user area being patched in a |
|||
special way, you can probably do so by moving the patches into |
|||
WordStar 4, and using the CUSTOM or SIMPLE printer driver. |
|||
|
|||
On the INSTALL disk is a program called MOVEPRN.COM that |
|||
copies the printer driver portion of the previous release's |
|||
user area into files that can be installed into Release 4 with |
|||
the "auto patcher" feature. |
|||
|
|||
Copy the program MOVEPRN.COM onto the disk containing the |
|||
WS.COM file for the previous version. Type |
|||
|
|||
MOVEPRN WS.COM FILE1.PAT FILE2.PAT |
|||
|
|||
MOVEPRN extracts the proper portions of the user area and |
|||
writes them into two files that may then be used with the "auto |
|||
patcher" feature of WSCHANGE. |
|||
|
|||
FILE1.PAT is to be used with the general patching menu |
|||
(Choose E "Patching" on the WSCHANGE Main Menu, then A "Auto |
|||
Patcher"). FILE2.PAT should be used to install strings first |
|||
into the SIMPLE driver, and then into the CUSTOM driver (choose |
|||
B "Printer" on the WSCHANGE Main Menu, then B "Printer driver |
|||
library", D "Change printer driver data" and D "Driver auto |
|||
patcher"). |
|||
|
|||
Test print your document first with the SIMPLE driver, and then |
|||
with the CUSTOM driver to see which one produces the most |
|||
satisfactory results. |
|||
|
|||
Also read Appendix C for more information on using the Auto |
|||
Patcher. |
|||
|
|||
|
|||
Hanging Indents |
|||
|
|||
For WordStar Professional Release 4, MailMerge reformats indented |
|||
text created with ^OG to the current margins. If you want the text |
|||
to remain indented, use embedded ruler lines or the .RM, .LM, |
|||
and .PM commands. See the "Reference Guide" for more information. |
|||
|
|||
Pressing ^OG to wrap back to the first tab on the ruler line after |
|||
having reached the last tab works the same way it did in previous |
|||
versions of WordStar, contrary to what is stated in the manual. |
|||
|
|||
|
|||
TERMINALS |
|||
--------- |
|||
|
|||
WordStar comes installed for an "idealized" special terminal. |
|||
WINSTALL and WSCHANGE allow you to install many terminals by |
|||
name, thus allowing WordStar to take advantage of the special |
|||
features that the terminal might support, such as underlining |
|||
or the function keys. |
|||
|
|||
Use either WINSTALL or WSCHANGE to pick your specific terminal |
|||
or computer screen from the Monitor menu. If your terminal |
|||
isn't on the menu, it probably emulates one of those that is |
|||
there. Look in your terminal documentation to find out. |
|||
|
|||
After you install WordStar for the proper terminal, run |
|||
WordStar and open the file PRINT.TST to see which attributes |
|||
(such as bold and underline) work on your screen. |
|||
WordStar will highlight the following in some way... |
|||
|
|||
Bold (^PB) |
|||
Underline (^PS) |
|||
Strike-out (^PX) |
|||
Subscript (^PV) |
|||
Superscript (^PT) |
|||
Doublestrike (^PD) |
|||
Italics (^PY) |
|||
Blocks (^KB, ^KK) |
|||
Error messages |
|||
|
|||
Most of the time, normal text will be shown in dim intensity, |
|||
and highlighted text will be shown in bright intensity. You |
|||
may have to use a brightness and/or contrast knob to adjust |
|||
your screen the first time you use WordStar this way. |
|||
|
|||
If your dim intensity is too dim to see well, and you can't |
|||
adjust it, you can change the BRITE flag to ON using WSCHANGE. |
|||
This will invert bright and dim in your text, so that regular |
|||
text is displayed bright, and highlighted text will be |
|||
displayed as dim. However, text in the menus is not affected. |
|||
|
|||
|
|||
DISPLAY PROBLEMS WITH TERMINALS |
|||
------------------------------- |
|||
|
|||
Once you have installed WordStar for the proper terminal, you |
|||
may still experience display problems. |
|||
|
|||
If text from the previous screen remains after WordStar |
|||
displays a new screenful of text, the most likely cause is |
|||
cursor wrap. Basically, WordStar must know what happens to the |
|||
cursor when a character is displayed at the rightmost position |
|||
of the screen. It can either remain at the right edge, or it |
|||
can wrap to the beginning of the next line. The WRAP flag in |
|||
WordStar must be set either on or off to correspond to the |
|||
way the terminal works. (It is generally set for the |
|||
terminal's factory default, but the default can usually be |
|||
changed using the terminal's setup mode.) |
|||
|
|||
Another possible cause for display problems is your terminal's |
|||
incomplete emulation of some other terminal. The most |
|||
common differences are... |
|||
|
|||
Line insert (LININS), line delete (LINDEL), |
|||
Erase to end of screen (ERAEOS), |
|||
Erase to end of line (ERAEOL), |
|||
And, erase screen (ERASCR). |
|||
|
|||
Look in the manual for your terminal and use WSCHANGE to see |
|||
if the control sequences match. |
|||
|
|||
|
|||
PRINTERS |
|||
-------- |
|||
|
|||
WHAT'S IN THIS SECTION |
|||
|
|||
This section contains the following information: |
|||
|
|||
Choosing a Printer |
|||
Setting Up Your Printer |
|||
Printer Drivers |
|||
Proportional Printing |
|||
Laser Printers |
|||
Information on Specific Printers |
|||
|
|||
CHOOSING A PRINTER |
|||
|
|||
WordStar is ready to work with over 100 printers. The printer you |
|||
choose during installation becomes your default printer. However, |
|||
when you print a document, you can choose any other printer. To |
|||
choose a default printer, follow these steps: |
|||
|
|||
1. Look at the Printer Information brochure that came in your |
|||
package. The first chart shows the printers listed on the |
|||
Printer Selection Menus. If your printer is on the menu, |
|||
simply choose it during installation. |
|||
|
|||
2. If your printer isn't listed on the menu, it may work like a |
|||
printer that is. Refer to the second chart in the Printer |
|||
Information brochure for a list of printers that work like |
|||
printers on the menu. When WordStar asks you to choose a |
|||
printer, choose the printer that works like yours. |
|||
|
|||
3. If neither chart lists your printer, choose Typewriter Printer |
|||
(if your printer can backspace) or Draft Printer (if it can't). |
|||
These choices may not take advantage of all your printer's |
|||
features, but they will work with almost any printer. |
|||
|
|||
Note: If you choose Draft or Typewriter, you can modify custom |
|||
print controls and printer initialization. |
|||
|
|||
If you want to make more modifications to take advantage of your |
|||
printer's feature, choose the Custom or Simple drivers, then use |
|||
the WS Printer Patches section of WSCHANGE to tell WordStar the |
|||
codes for your printer. Refer to your printer manual for these |
|||
codes. Some printers work better with the Custom driver and some |
|||
with the Simple driver. Try using both and see which works better |
|||
with your printer. See the "Reference Guide" for more information. |
|||
|
|||
SETTING UP YOUR PRINTER |
|||
|
|||
Choosing a Printer Port |
|||
|
|||
Each printer is connected to a printer port at the back of |
|||
the computer. WordStar looks for printers on the LST: port. |
|||
If your printer is connected to a different port, use |
|||
WSCHANGE to tell WordStar the correct port. |
|||
|
|||
Testing Your Printer Connection |
|||
|
|||
At the operating system prompt, type "PIP LST:=READ.ME." This |
|||
file should be printed by your printer. If it is not, your printer |
|||
may be connected to a different port. See your computer reference |
|||
manual, and the section on the STAT command in your CP/M |
|||
reference manual for more information. |
|||
|
|||
|
|||
PRINTER DRIVERS |
|||
|
|||
The WSPRINT.OVR file on the Printers disk contains a printer |
|||
driver for each printer on the Printer Selection Menu. The printer |
|||
driver for a printer contains all the codes WordStar needs to work |
|||
with that printer. |
|||
|
|||
Each printer driver has a short name. If you choose a printer when |
|||
you print a document, you see the names of the printer drivers, not |
|||
the names of the printers. |
|||
|
|||
PROPORTIONAL PRINTING |
|||
|
|||
WordStar supports proportional printing on a number of printers. |
|||
To turn on proportional printing, either install WordStar to |
|||
default to proportional printing, or place a ".PS on" command |
|||
in your document. At print time, WordStar selects the |
|||
appropriate proportional font based on the character width |
|||
(.CW) currently in effect. |
|||
|
|||
The specific printer descriptions later in this section show |
|||
recommended character widths for proportional typefaces. |
|||
These widths are for a normal mix of upper- and lowercase |
|||
letters. If you have many words or phrases all in uppercase |
|||
or if you want your text less densely printed, choose a larger |
|||
character width. |
|||
|
|||
While WordStar mostly sets character widths based on the |
|||
proportional-width table in the driver, on the more advanced |
|||
daisy wheel printers, WordStar uses the printer's proportional- |
|||
spacing mode. WordStar determines how much white space is needed |
|||
to right-justify the line based on its own proportional width |
|||
tables. If the table values don't match the wheel installed, |
|||
WordStar won't be able to justify the line correctly. |
|||
|
|||
WordStar sends standard ASCII characters; if a proportional wheel |
|||
uses a different spoke mapping, set up the printer to handle this. |
|||
|
|||
LASER PRINTERS |
|||
|
|||
WordStar supports laser printer features such as font changes |
|||
and proportional spacing. |
|||
|
|||
WordStar supports several laser printers: the Canon LPB-8 A1 & A2; |
|||
the Hewlett-Packard LaserJet, LaserJet+, and LaserJet 500+; |
|||
and the Ricoh LP4080. Refer to the "Specific Printer |
|||
Information" section of this file for information on these |
|||
printers. General notes about using laser printers are given below. |
|||
|
|||
Paper Size and Margins |
|||
|
|||
Laser printers come with preset page margins. You need to |
|||
compensate for these margins by changing page length in your |
|||
WordStar documents. The chart below shows the recommended |
|||
settings for 8 1/2 X 11 inch paper for both portrait and landscape |
|||
orientations. These settings allow 55 lines of text for portrait |
|||
orientation and 40 lines of text for landscape orientation (at 6 |
|||
lines per inch). They also allow for a footer of up to 3 lines |
|||
and a one-line header. If you use multiple-line headers, adjust |
|||
the top margin accordingly. |
|||
|
|||
Dot Default Portrait Landscape |
|||
Setting Command Value Orientation Orientation |
|||
------- ------- ------- ----------- ----------- |
|||
page length .PL 66 62 47 |
|||
top margin .MT 3 2 2 |
|||
bottom margin .MB 8 5 5 |
|||
header margin .HM 2 1 1 |
|||
footer margin .FM 2 2 2 |
|||
|
|||
If the laser printer is your primary printer, you can use WSCHANGE |
|||
to make these settings the defaults. |
|||
|
|||
Because laser printers leave small margins at the left and right |
|||
sides of the page, you may want to use a smaller page offset |
|||
setting (the default is .PO 8). |
|||
|
|||
Form Feeds |
|||
|
|||
When you print with a laser printer, answer Y for yes to the "Use |
|||
form feeds (Y/N)?" prompt at print time. (The default is NO.) If |
|||
the laser printer is your primary printer, you can use WSCHANGE to |
|||
change the default to yes. |
|||
|
|||
WordStar Commands for Font Selection |
|||
|
|||
The WordStar dot commands and print control commands listed below |
|||
determine the fonts used for printing a document. |
|||
|
|||
.PR .PR OR=L selects landscape orientation; .PR OR=P (or just |
|||
.PR OR) selects portrait orientation (the default). If |
|||
either of these commands appears after the first printing |
|||
line on a page, the orientation will not change until the |
|||
following page. |
|||
|
|||
.PS .PS ON selects proportionally spaced characters; .PS OFF |
|||
(the default) selects fixed-spaced characters. |
|||
|
|||
.CW The character-width setting (.CW followed by the width in |
|||
120ths of an inch) determines the character pitch and font |
|||
selected for fixed-width printing. For proportional fonts, it |
|||
determines the point size and proportional-width table |
|||
selected. |
|||
|
|||
.LQ .LQ ON selects near letter quality print (if supported by |
|||
your printer). LQ OFF selects draft quality print. Default |
|||
is ON. |
|||
|
|||
^PY The italic print control toggles between normal and italic |
|||
characters when the appropriate italic font is available. |
|||
|
|||
^PB The boldface print control toggles between normal and bold |
|||
characters when the appropriate bold font is available. |
|||
|
|||
^PD The double strike print control used with the laser printers |
|||
toggles overprinting with a horizontal offset of 1/120" |
|||
between the two character images. This allows a bold effect |
|||
where no bold font is available. |
|||
|
|||
^PA ^PA turns alternate pitch on. Use .CW to assign different |
|||
character widths to normal pitch (see ^PN below) and alternate |
|||
pitch so that each pitch accesses a different font. You can |
|||
then change fonts by switching between the two pitches. This |
|||
is the only way to use two fonts on the same line. |
|||
(See "Character width" and "Pitch" in the "Reference Guide.") |
|||
|
|||
^PN ^PN turns normal pitch on. You can use it with ^PA as |
|||
described above. |
|||
|
|||
^P@ When working with columns, if you use alternate and normal |
|||
pitch for two fonts, or if you use proportional spacing, you |
|||
may need to use ^P@ to make sure the columns line up. |
|||
Remember that the column position set with ^P@ is determined |
|||
by the normal pitch character width. (See "Columns" and |
|||
"Proportional spacing" in the "Reference Guide." |
|||
|
|||
INFORMATION ON SPECIFIC PRINTERS |
|||
|
|||
This section describes the capabilities of each printer listed on |
|||
the Printer Selection Menu. The printers are listed in alphabetical |
|||
order (except for the generic printers such as "Draft," |
|||
"Typewriter," "Custom," "Simple," and the various print-to-disk |
|||
options, which are listed first). |
|||
|
|||
There is a chart for each printer explaining how features work and |
|||
listing any special notes about the printer. Each printer is |
|||
described in the following format: |
|||
|
|||
PRINTER NAME ----- Driver: (short name) |
|||
|
|||
^PY Effect of italics/ribbon color print control |
|||
^PT/V Subscript/superscript information |
|||
.CW Information on available character widths and fonts. The |
|||
chart shows the .CW, .LQ, and .PS settings required to use |
|||
different fonts. |
|||
|
|||
.LQ OFF .LQ ON .PS ON Font Name |
|||
------- ------ ------ --------- |
|||
.cw val .cw val recommended value (range) font 1 |
|||
.cw val .cw val recommended value (range) font 2 |
|||
|
|||
.UL Continuous-underline information (if restrictions) |
|||
.UJ Microspace-justification information (if restrictions) |
|||
|
|||
N/A means a command has no effect on this printer. |
|||
|
|||
NOTES Switch settings, special features, anomalies. |
|||
|
|||
DRAFT PRINTER (nonbackspacing) ----- Driver: DRAFT |
|||
|
|||
^PD Overprints the line twice |
|||
^PB Overprints the line three times |
|||
^PS Overprints the underscore character in a separate pass |
|||
^PT/V Prints super/subscripts with a full line between |
|||
super/subscript and text |
|||
.LH Sets line height only in multiples of full lines |
|||
.CW N/A |
|||
.PS N/A |
|||
.LQ N/A |
|||
.UJ N/A |
|||
|
|||
NOTES This driver works with any printer that doesn't automatically |
|||
perform a line feed when it receives a carriage return command. All |
|||
overprinting is done by returning the carriage and passing over the |
|||
line again. |
|||
|
|||
TYPEWRITER PRINTER (backspacing) ----- Driver: TYPEWR |
|||
|
|||
^PD Backspaces and overprints each character twice |
|||
^PB Backspaces and overprints each character three times |
|||
^PS Backspaces and overprints the underscore character |
|||
^PT/V Prints super/subscripts with a full line between |
|||
super/subscript and text |
|||
.LH Sets line height only in multiples of full lines |
|||
.CW N/A |
|||
.PS N/A |
|||
.LQ N/A |
|||
.UJ N/A |
|||
|
|||
NOTES This driver works with any printer that doesn't automatically |
|||
perform a line feed when a it receives a carriage return command, |
|||
and responds to a backspace character. Overprinting is done by |
|||
backspacing. |
|||
|
|||
AUTO LINE FEED PRINTER (backspacing) ----- Driver: AUTOLF |
|||
|
|||
^PD Backspaces and overprints each character twice |
|||
^PB Backspaces and overprints each character three times |
|||
^PS Backspaces and overprints the underscore character |
|||
^PT/V Prints super/subscripts with a full line between |
|||
super/subscript and text |
|||
.LH Sets line height only in multiples of full lines |
|||
.CW N/A |
|||
.PS N/A |
|||
.LQ N/A |
|||
.UJ N/A |
|||
|
|||
NOTES This driver works with any printer that automatically |
|||
performs a line feed when it receives a carriage return character, |
|||
and responds to a backspace command. Overprinting is done by |
|||
backspacing. |
|||
|
|||
SIMPLE CUSTOMIZABLE PRINTERS ----- Driver: SIMPLE |
|||
|
|||
All print controls cause control strings (on and off) in |
|||
the user area to be sent to the printer. These strings |
|||
are used by both the SIMPLE and CUSTOM drivers. They can |
|||
be installed with the WSCHANGE program. |
|||
|
|||
.LQ Controlled by user area strings |
|||
.PS Controlled by user area strings |
|||
.CW N/A |
|||
.UJ N/A |
|||
.LH N/A |
|||
|
|||
NOTES This printer driver prints the line in one pass, sending |
|||
control strings from the user area to select print enhancements. |
|||
|
|||
CUSTOMIZABLE PRINTERS ----- Driver: CUSTOM |
|||
|
|||
All print controls cause control strings (on and off) in |
|||
the user area to be sent to the printer. These strings |
|||
are used by both the SIMPLE and CUSTOM drivers. They can |
|||
be installed with the WSCHANGE program. |
|||
|
|||
.LQ ON/OFF controlled by user area strings |
|||
.PS ON/OFF controlled by user area strings |
|||
.LH Sets line height only in multiples of full lines |
|||
.UJ N/A |
|||
.CW N/A |
|||
|
|||
NOTES This driver prints the line in multiple passes, sending |
|||
control strings from the user area to select print enhancements. |
|||
|
|||
PREVIEW TO DISK ----- Driver: PRVIEW |
|||
|
|||
This driver prints documents to the PREVIEW.WS file to allow |
|||
you to preview the format and appearance of a document before |
|||
printing. Headers, footers, and pagination are shown correctly |
|||
and print controls remain in the file to display onscreen |
|||
attributes. Dot commands are not printed. |
|||
|
|||
PRINT TO DISK WITHOUT PRINT CONTROLS ----- Driver: ASCII |
|||
|
|||
This driver prints to the ASCII.WS file, stripping headers and |
|||
footers, high bits, and print controls. |
|||
|
|||
PRINT TO DISK WITHOUT HEADERS AND FOOTERS ----- Driver: XTRACT |
|||
|
|||
This driver prints to the XTRACT.WS disk file, stripping headers |
|||
and footers, but preserving high bits and print controls. |
|||
|
|||
ANADEX 9500A, 9500B ----- Driver: 9500 |
|||
|
|||
^PY N/A |
|||
^PT/V Even superscript roll |
|||
|
|||
.CW .CW Font name |
|||
--- --------- |
|||
9 13.3 cpi |
|||
10 12 cpi |
|||
12 10 cpi |
|||
18 6.7 cpi |
|||
20 6 cpi |
|||
24 5 cpi |
|||
|
|||
.LH 1/24" resolution, use even values |
|||
.UJ This printer has no incremental horizontal positioning |
|||
.PS N/A |
|||
.LQ N/A |
|||
|
|||
ANADEX 9501B, INTEQ 5100B ----- Driver: 9501B |
|||
|
|||
^PY N/A |
|||
^PT/V Even superscript roll |
|||
|
|||
.CW .CW Font name |
|||
--- --------- |
|||
7 16.7 cpi |
|||
8 15 cpi |
|||
10 12.5 cpi |
|||
12 10 cpi |
|||
14 8.3 cpi |
|||
16 7.5 cpi |
|||
20 6.2 cpi |
|||
24 5 cpi |
|||
|
|||
.LH 1/24" resolution, use even values |
|||
.UJ This printer has no incremental horizontal positioning |
|||
.PS N/A |
|||
.LQ N/A |
|||
|
|||
C. ITOH STARWRITER 1550 AND 8510 ----- Driver: C1550 |
|||
|
|||
^PY N/A |
|||
^PT/V Prints full-size characters with roll |
|||
|
|||
.CW .CW Font Name |
|||
--- --------- |
|||
7 compressed |
|||
10 elite |
|||
12 pica |
|||
14 expanded compressed |
|||
20 expanded elite |
|||
24 expanded pica |
|||
|
|||
.LQ N/A |
|||
.PS N/A |
|||
.UL Continuous underlining suppresses microspace justification |
|||
|
|||
C. ITOH F10 STARWRITER ----- Driver: QUME |
|||
|
|||
See Diablo 630, 1610, 1620 Daisy Wheel. |
|||
|
|||
Note: Proportional printing was tested with a Theme 10 wheel. |
|||
|
|||
CANON LBP-8A1 AND LBP-8A2 LASER PRINTER ----- Driver: LBP8 |
|||
|
|||
^PY Selects italics if appropriate font installed |
|||
^PT/V Prints full-size characters with roll |
|||
.PS .PS |
|||
.CW OFF ON Font Name |
|||
--- -- --------- |
|||
6 - 20 cpi |
|||
8 - 15 cpi |
|||
9 - 13.3 cpi |
|||
10 - 12 cpi (elite) |
|||
12 - 10 cpi |
|||
20 - 6 cpi |
|||
24 - 5 cpi |
|||
16 - 7.5 cpi |
|||
- 7 (0-8) Garland 8 point |
|||
- 10 (9-11) Garland 12 point |
|||
- 14 (12-17) Expanded 8 point |
|||
- 20 (18-30) Expand |
|||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files changed in this diff
Loading…
Reference in new issue