Merge branch 'open-simh:master' into rp11
This commit is contained in:
commit
14ac68f741
65 changed files with 651 additions and 667 deletions
172
.github/workflows/cmake-builds.yml
vendored
172
.github/workflows/cmake-builds.yml
vendored
|
@ -34,8 +34,8 @@ jobs:
|
||||||
- name: Upload DEB
|
- name: Upload DEB
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-x86_64-${{matrix.os}}.deb
|
name: simh-4.1.0-x86_64-${{matrix.os}}.deb
|
||||||
path: cmake/build-ninja/simh-4.0.0-x86_64-${{matrix.os}}.deb
|
path: cmake/build-ninja/simh-4.1.0-x86_64-${{matrix.os}}.deb
|
||||||
|
|
||||||
|
|
||||||
cmake-macOS:
|
cmake-macOS:
|
||||||
|
@ -68,13 +68,13 @@ jobs:
|
||||||
- name: Upload ZIP
|
- name: Upload ZIP
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-x86_64.${{matrix.os}}.zip
|
name: simh-4.1.0-x86_64.${{matrix.os}}.zip
|
||||||
path: cmake/build-xcode/simh-4.0.0-x86_64.${{matrix.os}}.zip
|
path: cmake/build-xcode/simh-4.1.0-x86_64.${{matrix.os}}.zip
|
||||||
- name: Upload DMG
|
- name: Upload DMG
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-x86_64.${{matrix.os}}.dmg
|
name: simh-4.1.0-x86_64.${{matrix.os}}.dmg
|
||||||
path: cmake/build-xcode/simh-4.0.0-x86_64.${{matrix.os}}.dmg
|
path: cmake/build-xcode/simh-4.1.0-x86_64.${{matrix.os}}.dmg
|
||||||
|
|
||||||
|
|
||||||
## This looks like it's doing the right thing on the Github CI/CD pipeline because
|
## This looks like it's doing the right thing on the Github CI/CD pipeline because
|
||||||
|
@ -108,46 +108,128 @@ jobs:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
##+
|
- name: Install v141_xp (XP toolkit) and build SIMH
|
||||||
## NOTE: This will have to change when Github updates the windows-latest
|
|
||||||
## image AND when Microsoft bumps the Visual Studio year.
|
|
||||||
##
|
|
||||||
## Things that need updating:
|
|
||||||
## - Product ID (maybe: MS seems to be very consistent with the component
|
|
||||||
## name, hasn't changed since VS 2019.)
|
|
||||||
## - Channel ID
|
|
||||||
##-
|
|
||||||
- name: Install v141_xp (XP toolkit)
|
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: |
|
run: |
|
||||||
$ErrorActionPreference="Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
$WarningPreference="Continue"
|
$WarningPreference = "Continue"
|
||||||
$packageParams = @( "--productId", "Microsoft.VisualStudio.Product.Enterprise",
|
$DebugPreference = "Continue"
|
||||||
"--channelId", "VisualStudio.17.Release",
|
|
||||||
"--add", "Microsoft.VisualStudio.Component.VC.v141.x86.x64",
|
|
||||||
"--add", "Microsoft.VisualStudio.Component.WinXP",
|
|
||||||
"--no-includeRecommended",
|
|
||||||
"--includeOptional",
|
|
||||||
"--quiet",
|
|
||||||
"--locale en-US" ) -join " "
|
|
||||||
choco install visualstudio2022-workload-nativedesktop --package-parameters $packageParams
|
|
||||||
|
|
||||||
- name: vs2022-xp build
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
$ErrorActionPreference="Stop"
|
|
||||||
$WarningPreference="Continue"
|
|
||||||
$env:ChocolateyInstall = Convert-Path "$((Get-Command choco).Path)\..\.."
|
|
||||||
Import-Module "$env:ChocolateyInstall\helpers\chocolateyProfile.psm1"
|
|
||||||
Update-SessionEnvironment
|
|
||||||
# Fix PATH so that "C:\Strawberry" (Strawberry Perl) doesn't mess with the build
|
# Fix PATH so that "C:\Strawberry" (Strawberry Perl) doesn't mess with the build
|
||||||
# CMake WILL find incompatible libraries within Strawberry.
|
# CMake WILL find incompatible libraries within Strawberry.
|
||||||
$fixPATH = (${env:PATH}.Split(';') | `
|
$fixPATH = (${env:PATH}.Split(';') | `
|
||||||
Where-Object { $_ -notlike "*\Strawberry\*" -and $_ -notlike "*/Strawberry/*" }) -join ';'
|
Where-Object { $_ -notlike "*\Strawberry\*" -and $_ -notlike "*/Strawberry/*" }) -join ';'
|
||||||
$env:Path = $fixPATH
|
$env:Path = $fixPATH
|
||||||
|
|
||||||
|
#+
|
||||||
|
# Update the existing Github Visual Studio installation in-place. `vswhere` may find multiple
|
||||||
|
# VS installations, so iterate through them all.
|
||||||
|
#
|
||||||
|
# This is Grey Magic. `vs_installer` exits almost immediately if you run it from the command
|
||||||
|
# line. However, `vs_installer`'s subprocesses are well known and we look for them and wait
|
||||||
|
# for them to terminate.
|
||||||
|
#
|
||||||
|
# GH Actions does something strange with stdout and stderr, so you won't get any
|
||||||
|
# indication of failure or output that shows you that something is happening.
|
||||||
|
#
|
||||||
|
# The waiting code was adapted from the Chocolatey VS installer scripts.
|
||||||
|
#-
|
||||||
|
$vswhere = "${env:ProgramFiles} (x86)\Microsoft Visual Studio\Installer\vswhere"
|
||||||
|
$vsinstaller = "${env:ProgramFiles} (x86)\Microsoft Visual Studio\Installer\vs_installer.exe"
|
||||||
|
$vsInstallOut = "$env:TEMP\vsinstall-out.txt"
|
||||||
|
$vsInstallErr = "$env:TEMP\vsinstall-err.txt"
|
||||||
|
|
||||||
|
& ${vswhere} -property installationPath | `
|
||||||
|
Foreach-Object -process {
|
||||||
|
## --quiet: Don't open/show UI
|
||||||
|
## --force: Terminate any VS instances forcibly
|
||||||
|
## --norestart: Delay reboot after install, if needed
|
||||||
|
## --installWhileDownloading: Self-explanitory.
|
||||||
|
$Params = @(
|
||||||
|
"modify",
|
||||||
|
"--installPath", "$_",
|
||||||
|
"--add", "Microsoft.VisualStudio.Component.VC.v141.x86.x64",
|
||||||
|
"--add", "Microsoft.VisualStudio.Component.WinXP",
|
||||||
|
"--quiet", "--force", "--norestart", "--installWhileDownloading"
|
||||||
|
)
|
||||||
|
|
||||||
|
& $vsInstaller $Params 2> $vsInstallErr > $vsInstallOut
|
||||||
|
|
||||||
|
$vsinstallerProcesses = @('vs_installer', 'vs_installershell', 'vs_installerservice')
|
||||||
|
$vsInstallerStartup = $true
|
||||||
|
$vsInstallerStartCount = 10
|
||||||
|
|
||||||
|
do
|
||||||
|
{
|
||||||
|
Write-Debug ('Looking for running VS installer processes')
|
||||||
|
$vsInstallerRemaining = Get-Process -Name $vsinstallerProcesses -ErrorAction SilentlyContinue | Where-Object { $null -ne $_ -and -not $_.HasExited }
|
||||||
|
$vsInstallerProcessCount = ($vsInstallerRemaining | Measure-Object).Count
|
||||||
|
if ($vsInstallerProcessCount -gt 0)
|
||||||
|
{
|
||||||
|
## Installer processes are present, so obviously not starting up.
|
||||||
|
$vsInstallerStartup = $false
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Write-Debug "Found $vsInstallerProcessCount running Visual Studio installer processes which are known to exit asynchronously:"
|
||||||
|
$vsInstallerRemaining | Sort-Object -Property Name, Id | ForEach-Object { '[{0}] {1}' -f $_.Id, $_.Name } | Write-Debug
|
||||||
|
Write-Debug ('Giving the processes some time to exit')
|
||||||
|
$vsInstallerRemaining | Wait-Process -Timeout 45 -ErrorAction SilentlyContinue
|
||||||
|
}
|
||||||
|
finally
|
||||||
|
{
|
||||||
|
$vsInstallerRemaining | ForEach-Object { $_.Dispose() }
|
||||||
|
$vsInstallerRemaining = $null
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($vsInstallerStartup) {
|
||||||
|
if ($vsInstallerStartCount -gt 0) {
|
||||||
|
Write-Debug "No VS installer processes detected; sleeping with $vsInstallerStartCount tries remaining."
|
||||||
|
Start-Sleep -Seconds 10.0
|
||||||
|
$vsInstallerStartCount -= 1
|
||||||
|
} else {
|
||||||
|
$vsInstallerStartup = $false
|
||||||
|
Write-Debug "VS installer never started? Exiting."
|
||||||
|
Exit 99
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
while (($vsInstallerStartup -and $vsInstallerStartCount -gt 0) -or $vsInstallerProcessCount -gt 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((Test-Path $vsInstallOut -PathType Leaf) -and (Get-Item $vsInstallOut).length -gt 0kb)
|
||||||
|
{
|
||||||
|
Write-Output "-- vsinstaller output:"
|
||||||
|
Get-Content $vsInstallOut
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Write-Debug "-- No vsinstaller output."
|
||||||
|
}
|
||||||
|
|
||||||
|
if ((Test-Path $vsInstallErr -PathType Leaf) -and (Get-Item $vsInstallErr).length -gt 0kb)
|
||||||
|
{
|
||||||
|
Write-Output "-- vsinstaller error output:"
|
||||||
|
Get-Content $vsInstallErr
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Write-Debug "-- No vsinstaller error/diag output."
|
||||||
|
}
|
||||||
|
|
||||||
|
#+
|
||||||
|
# The GH Windows runner image documentation says that the VSSetup module is installed, from
|
||||||
|
# whence Get-VSSetupInstance and Select-VSSetupInstance are imported. This step is pure
|
||||||
|
# paranoia, ensuring that we really, truly and honestly have WinXP support.
|
||||||
|
#-
|
||||||
|
Write-Debug "Get-VSSetupInstance/Select-VSSetupInstance"
|
||||||
|
Get-VSSetupInstance -All | Select-VSSetupInstance -Require 'Microsoft.VisualStudio.Component.WinXP' -Latest
|
||||||
|
|
||||||
## Don't use LTO for XP. XP compatibility comes from VS2017 -- MS is
|
## Don't use LTO for XP. XP compatibility comes from VS2017 -- MS is
|
||||||
## at VS2022. There are likely legacy bugs that have been fixed.
|
## at VS2022. There are likely legacy bugs that have been fixed.
|
||||||
./cmake/cmake-builder.ps1 -flavor vs2022-xp -config Release -clean -verbose -notest -cpack_suffix win32-xp
|
./cmake/cmake-builder.ps1 -flavor vs2022-xp -config Release -clean -verbose -notest -cpack_suffix win32-xp
|
||||||
|
|
||||||
|
|
||||||
- name: SIMH simulator suite test
|
- name: SIMH simulator suite test
|
||||||
shell: pwsh
|
shell: pwsh
|
||||||
run: |
|
run: |
|
||||||
|
@ -166,13 +248,13 @@ jobs:
|
||||||
- name: Upload ZIP
|
- name: Upload ZIP
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-win32-vs2022xp.zip
|
name: simh-4.1.0-win32-vs2022xp.zip
|
||||||
path: cmake/build-vs2022-xp/simh-4.0.0-win32-xp.zip
|
path: cmake/build-vs2022-xp/simh-4.1.0-win32-xp.zip
|
||||||
- name: Upload MSI
|
- name: Upload MSI
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-win32-vs2022xp.zip
|
name: simh-4.1.0-win32-vs2022xp.zip
|
||||||
path: cmake/build-vs2022-xp/simh-4.0.0-win32-xp.msi
|
path: cmake/build-vs2022-xp/simh-4.1.0-win32-xp.msi
|
||||||
|
|
||||||
cmake-vs2022:
|
cmake-vs2022:
|
||||||
name: VS 2022 Win10 native VCPKG
|
name: VS 2022 Win10 native VCPKG
|
||||||
|
@ -213,15 +295,15 @@ jobs:
|
||||||
- name: Upload ZIP
|
- name: Upload ZIP
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-win32-vs2022.zip
|
name: simh-4.1.0-win32-vs2022.zip
|
||||||
path: cmake/build-vs2022/simh-4.0.0-win32-native.zip
|
path: cmake/build-vs2022/simh-4.1.0-win32-native.zip
|
||||||
- name: Upload EXE installer
|
- name: Upload EXE installer
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-win32-vs2022.exe
|
name: simh-4.1.0-win32-vs2022.exe
|
||||||
path: cmake/build-vs2022/simh-4.0.0-win32-native.exe
|
path: cmake/build-vs2022/simh-4.1.0-win32-native.exe
|
||||||
- name: Upload MSI installer
|
- name: Upload MSI installer
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: simh-4.0.0-win32-vs2022.msi
|
name: simh-4.1.0-win32-vs2022.msi
|
||||||
path: cmake/build-vs2022/simh-4.0.0-win32-native.msi
|
path: cmake/build-vs2022/simh-4.1.0-win32-native.msi
|
||||||
|
|
59
.github/workflows/coverity-scan.yml
vendored
Normal file
59
.github/workflows/coverity-scan.yml
vendored
Normal file
|
@ -0,0 +1,59 @@
|
||||||
|
name: Coverity Scan
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: '0 18 * * 2,4' # Bi-weekly at 18:00 UTC on Tuesday and Thursday
|
||||||
|
|
||||||
|
# Automatically cancel any previous workflow on new push.
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
latest:
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
steps:
|
||||||
|
- name: Determine current repository
|
||||||
|
id: "determine-repo"
|
||||||
|
run: echo "repo=${GITHUB_REPOSITORY}" >> $GITHUB_OUTPUT
|
||||||
|
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Download Coverity Build Tool
|
||||||
|
run: |
|
||||||
|
wget -q https://scan.coverity.com/download/cxx/linux64 --post-data "token=$TOKEN&project=open-simh%2Fsimh" -O cov-analysis-linux64.tar.gz
|
||||||
|
mkdir cov-analysis-linux64
|
||||||
|
tar xzf cov-analysis-linux64.tar.gz --strip 1 -C cov-analysis-linux64
|
||||||
|
env:
|
||||||
|
TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
||||||
|
if: steps.determine-repo.outputs.repo == 'open-simh/simh'
|
||||||
|
|
||||||
|
- name: Fixed world writable dirs
|
||||||
|
run: |
|
||||||
|
chmod go-w $HOME
|
||||||
|
sudo chmod -R go-w /usr/share
|
||||||
|
if: steps.determine-repo.outputs.repo == 'open-simh/simh'
|
||||||
|
|
||||||
|
- name: Installing build dependencies
|
||||||
|
run: |
|
||||||
|
sh -ex .travis/deps.sh linux
|
||||||
|
sudo apt --assume-yes install -ym ninja-build
|
||||||
|
if: steps.determine-repo.outputs.repo == 'open-simh/simh'
|
||||||
|
|
||||||
|
- name: Build with cov-build
|
||||||
|
run: |
|
||||||
|
export PATH=`pwd`/cov-analysis-linux64/bin:$PATH
|
||||||
|
cov-build --dir cov-int cmake/cmake-builder.sh --config Release --flavor ninja --lto --notest --parallel --verbose --cpack_suffix x86_64-${{matrix.os}}
|
||||||
|
if: steps.determine-repo.outputs.repo == 'open-simh/simh'
|
||||||
|
|
||||||
|
- name: Submit the result to Coverity Scan
|
||||||
|
run: |
|
||||||
|
tar czvf simh.tgz cov-int
|
||||||
|
curl \
|
||||||
|
--form token=$TOKEN \
|
||||||
|
--form email=noreply@opensimh.org \
|
||||||
|
--form file=@simh.tgz \
|
||||||
|
--form version=trunk \
|
||||||
|
--form description="opensimh" \
|
||||||
|
https://scan.coverity.com/builds?project=open-simh%2Fsimh
|
||||||
|
env:
|
||||||
|
TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }}
|
||||||
|
if: steps.determine-repo.outputs.repo == 'open-simh/simh'
|
197
.github/workflows/windows_build.yml
vendored
197
.github/workflows/windows_build.yml
vendored
|
@ -1,197 +0,0 @@
|
||||||
name: Windows_Build
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
inputs:
|
|
||||||
ref:
|
|
||||||
description: 'Ref/hash/tag - blank for head'
|
|
||||||
required: false
|
|
||||||
type: string
|
|
||||||
configuration:
|
|
||||||
description: 'Configuration'
|
|
||||||
required: true
|
|
||||||
default: 'Release'
|
|
||||||
type: choice
|
|
||||||
options:
|
|
||||||
- Release
|
|
||||||
- Debug
|
|
||||||
platform:
|
|
||||||
description: 'Platform'
|
|
||||||
required: true
|
|
||||||
default: 'Win32'
|
|
||||||
type: choice
|
|
||||||
options:
|
|
||||||
- Win32
|
|
||||||
# - ARM
|
|
||||||
architecture:
|
|
||||||
description: 'Architecture'
|
|
||||||
required: true
|
|
||||||
default: x64
|
|
||||||
type: choice
|
|
||||||
options:
|
|
||||||
- x64
|
|
||||||
- x86
|
|
||||||
- arm64
|
|
||||||
dispose:
|
|
||||||
description: 'Disposition'
|
|
||||||
required: true
|
|
||||||
default: 'Discard'
|
|
||||||
type: choice
|
|
||||||
options:
|
|
||||||
- 'Discard'
|
|
||||||
- 'Snapshot'
|
|
||||||
- 'Release'
|
|
||||||
|
|
||||||
pull_request:
|
|
||||||
types: closed
|
|
||||||
branches: [ 'master', 'Supnik-Current' ]
|
|
||||||
|
|
||||||
push:
|
|
||||||
branches: [ 'master', 'Supnik-Current' ]
|
|
||||||
|
|
||||||
# min hr mday mon dow UTC
|
|
||||||
schedule:
|
|
||||||
- cron: '23 8 * * 1,3,5' # x64 snapshots
|
|
||||||
- cron: '13 16 * * 2,4,6' # x86 snapshots
|
|
||||||
# - cron: '46 20 * * 1,4,7' # Arm snapshots
|
|
||||||
|
|
||||||
# GITHUB_SHA last commit GITHUB_REF refs/tags/name
|
|
||||||
release:
|
|
||||||
types: published
|
|
||||||
|
|
||||||
env:
|
|
||||||
SOLUTION_FILE: 'Visual Studio Projects\Simh.ci.sln'
|
|
||||||
REF: ${{ inputs.ref || github.sha }}
|
|
||||||
BUILD_CONFIGURATION: ${{ inputs.configuration || 'Release' }}
|
|
||||||
BUILD_PLATFORM: ${{ inputs.platform || 'Win32' }}
|
|
||||||
BUILD_ARCH: ${{ inputs.architecture || ( github.event_name == 'schedule' && ( ( contains(github.event.schedule, '16') && 'x86' ) || ( contains(github.event.schedule, '20') && 'arm64' ) ) ) || 'x64' }}
|
|
||||||
DISPOSE: ${{ inputs.dispose || ( github.event_name == 'schedule' && 'Snapshot' ) || ( github.event_name == 'release' && 'Release' ) || 'Discard' }}
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: read
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build-on-windows:
|
|
||||||
environment: open-simh-ci
|
|
||||||
runs-on: windows-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: 'Verify configuration'
|
|
||||||
if: ( env.BUILD_PLATFORM == 'Win32' && env.BUILD_ARCH != 'x86' && env.BUILD_ARCH != 'x64' ) || ( env.BUILD_PLATFORM == 'ARM' && env.BUILD_ARCH != 'arm64' )
|
|
||||||
shell: cmd
|
|
||||||
run: |
|
|
||||||
echo ::error file=windows_build.yml,title=Invalid configuration::Platform ${{ env.BUILD_PLATFORM }} does not support Architecture ${{ env.BUILD_ARCH }}
|
|
||||||
exit 1
|
|
||||||
- name: 'Deal with CRLF files in repo'
|
|
||||||
run: git config --global core.autocrlf input
|
|
||||||
- name: 'Checkout branch'
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
with:
|
|
||||||
ref: ${{ env.REF }}
|
|
||||||
- name: Identify branch
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
$br="${{ github.ref_name || github.head_ref }}"
|
|
||||||
if ( $null -eq $br ) {
|
|
||||||
"DISPOSE=Discard" >>$env:GITHUB_ENV
|
|
||||||
"BRANCH=null" >>$env:GITHUB_ENV
|
|
||||||
} else {
|
|
||||||
$br=$br.Trim()
|
|
||||||
if( $br -eq '' ) {
|
|
||||||
"DISPOSE=Discard" >>$env:GITHUB_ENV
|
|
||||||
"BRANCH=empty" >>$env:GITHUB_ENV
|
|
||||||
} elseif ( $br -match '[Ss]upnik' ) {
|
|
||||||
"BRANCH=V3" >>$env:GITHUB_ENV
|
|
||||||
} else {
|
|
||||||
"BRANCH=V4" >>$env:GITHUB_ENV
|
|
||||||
}}
|
|
||||||
- name: Get external libraries
|
|
||||||
#(Required for V3, V4 will see and skip)
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
Invoke-WebRequest -Uri "https://github.com/simh/windows-build/archive/windows-build.zip" -UseBasicParsing -OutFile windows-build.zip
|
|
||||||
Expand-Archive -Path .\windows-build.zip -DestinationPath .\windows-build.tmp
|
|
||||||
move .\windows-build.tmp\windows-build-windows-build ..\windows-build
|
|
||||||
del windows-build.tmp
|
|
||||||
del windows-build.zip
|
|
||||||
- name: Add MSBuild to PATH for Visual Studio
|
|
||||||
uses: microsoft/setup-msbuild@v1.1
|
|
||||||
with:
|
|
||||||
msbuild-architecture: ${{ env.BUILD_ARCH }}
|
|
||||||
- name: Install PuTTY
|
|
||||||
run: |
|
|
||||||
choco install --no-progress putty
|
|
||||||
- name: Build Simulators with Visual Studio
|
|
||||||
shell: cmd
|
|
||||||
working-directory: ${{env.GITHUB_WORKSPACE}}
|
|
||||||
run: |
|
|
||||||
msbuild "${{env.SOLUTION_FILE}}" -property:Configuration=${{env.BUILD_CONFIGURATION}} -property:Platform=${{env.BUILD_PLATFORM}}
|
|
||||||
- name: Compute zipfile name step 1
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
git log -1 --pretty="COMMIT=%H" >>$env:GITHUB_ENV
|
|
||||||
$(git log -1 --pretty="#=%aI").Replace("T","-").Replace("#","CDATE").Replace(":","-") >>$env:GITHUB_ENV
|
|
||||||
echo PACNAME=${{env.BUILD_PLATFORM}}-${{env.BUILD_ARCH}}-${{env.BUILD_CONFIGURATION}} >>$env:GITHUB_ENV
|
|
||||||
- name: Compute zipfile name step 2
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
"ZIPNAME=${{env.CDATE}}-${{env.COMMIT}}-${{env.PACNAME}}.zip" >>$env:GITHUB_ENV
|
|
||||||
- name: Collect results for deployment
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
shell: cmd
|
|
||||||
working-directory: ${{env.GITHUB_WORKSPACE}}
|
|
||||||
run: |
|
|
||||||
mkdir "${{env.PACNAME}}"
|
|
||||||
copy "LICENSE.txt" "${{env.PACNAME}}\"
|
|
||||||
echo This software was created by the Open SIMH Project>"${{env.PACNAME}}\README.txt"
|
|
||||||
echo For more information, see https://opensimh.org>>"${{env.PACNAME}}\README.txt"
|
|
||||||
move "BIN\NT\${{env.BUILD_PLATFORM}}-${{env.BUILD_CONFIGURATION}}\*.exe" "${{env.PACNAME}}"
|
|
||||||
echo Built in ${{ github.repository }} by ${{ github.actor }} (${{ github.event_name }}) from ${{ github.ref_type }}/${{ github.ref_name }}>${{ env.ZIPNAME }}-contents.txt
|
|
||||||
echo In the zip file, the files reside in ${{env.PACNAME}}\*>>${{ env.ZIPNAME }}-contents.txt
|
|
||||||
echo Dates/times are UTC>>${{ env.ZIPNAME }}-contents.txt
|
|
||||||
echo .>>${{ env.ZIPNAME }}-contents.txt
|
|
||||||
dir "${{env.PACNAME}}" >>${{ env.ZIPNAME }}-contents.txt
|
|
||||||
- name: Import signing key
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
uses: crazy-max/ghaction-import-gpg@v5
|
|
||||||
with:
|
|
||||||
gpg_private_key: ${{ secrets.GPG_KIT_SIGNING_KEY }}
|
|
||||||
- name: Create and sign zip file
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
shell: pwsh
|
|
||||||
working-directory: ${{env.GITHUB_WORKSPACE}}
|
|
||||||
run: |
|
|
||||||
Compress-Archive -Path "${{ env.PACNAME }}" -DestinationPath "${{ env.ZIPNAME }}"
|
|
||||||
gpg --output "${{ env.ZIPNAME }}.sig" --detach-sig "${{ env.ZIPNAME }}"
|
|
||||||
- name: Deploy new executables to kits server
|
|
||||||
id: scp-ppk
|
|
||||||
if: env.DISPOSE != 'Discard'
|
|
||||||
shell: pwsh
|
|
||||||
working-directory: ${{env.GITHUB_WORKSPACE}}
|
|
||||||
env:
|
|
||||||
SCP_DEPLOY_KEY: '${{ secrets.SCP_DEPLOY_KEY }}'
|
|
||||||
run: |
|
|
||||||
$fn = Join-Path -Path $env:RUNNER_TEMP -ChildPath "sdk.ppk";
|
|
||||||
$eb = [System.Convert]::FromBase64String($env:SCP_DEPLOY_KEY);
|
|
||||||
Set-Content $fn -Value $eb -AsByteStream;
|
|
||||||
"SDK=$fn" >>$env:GITHUB_OUTPUT
|
|
||||||
"KITS_HOST_KEY=" + "${{ vars.KITS_HOST_KEY }}".Trim() + "`n" >>$env:GITHUB_ENV
|
|
||||||
- name: Save as snapshot
|
|
||||||
if: ${{ env.DISPOSE == 'Snapshot' }}
|
|
||||||
shell: cmd
|
|
||||||
run: |
|
|
||||||
pscp -p -r -q -batch -noagent -i ${{ steps.scp-ppk.outputs.SDK }} -hostkey "${{ env.KITS_HOST_KEY }}" ${{ env.ZIPNAME }} ${{ env.ZIPNAME }}.sig ${{ env.ZIPNAME }}-contents.txt simh-deploy@kits.opensimh.org:/var/www/kits/html/${{ env.BRANCH }}/Windows/Snapshots/${{ env.BUILD_ARCH }}/
|
|
||||||
- name: Save as release
|
|
||||||
if: env.DISPOSE == 'Release'
|
|
||||||
shell: cmd
|
|
||||||
run: |
|
|
||||||
pscp -p -r -q -batch -noagent -i ${{ steps.scp-ppk.outputs.SDK }} -hostkey "${{ env.KITS_HOST_KEY }}" ${{ env.ZIPNAME }} ${{ env.ZIPNAME }}.sig ${{ env.ZIPNAME }}-contents.txt simh-deploy@kits.opensimh.org:/var/www/kits/html/${{ env.BRANCH }}/Windows/Releases/${{ env.BUILD_ARCH }}/
|
|
||||||
- name: cleanup ppk
|
|
||||||
env:
|
|
||||||
FN: ${{ steps.scp-ppk.outputs.SDK }}
|
|
||||||
shell: pwsh
|
|
||||||
if: always() && ( env.FN != '' )
|
|
||||||
run: |
|
|
||||||
Remove-Item -Path $env:FN;
|
|
|
@ -233,7 +233,8 @@ MTAB contty_mod[] = {
|
||||||
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, 1, "CONNECTIONS", NULL,
|
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, 1, "CONNECTIONS", NULL,
|
||||||
NULL, &tmxr_show_cstat, (void *)&contty_desc, "Display current connection" },
|
NULL, &tmxr_show_cstat, (void *)&contty_desc, "Display current connection" },
|
||||||
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, 0, "STATISTICS", NULL,
|
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, 0, "STATISTICS", NULL,
|
||||||
NULL, &tmxr_show_cstat, (void *)&contty_desc, "Display CONTTY statistics" }
|
NULL, &tmxr_show_cstat, (void *)&contty_desc, "Display CONTTY statistics" },
|
||||||
|
{ 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
CONST char *brg_rates[IU_SPEED_REGS][IU_SPEEDS] = {
|
CONST char *brg_rates[IU_SPEED_REGS][IU_SPEEDS] = {
|
||||||
|
@ -276,7 +277,8 @@ DEVICE contty_dev = {
|
||||||
|
|
||||||
MTAB iu_timer_mod[] = {
|
MTAB iu_timer_mod[] = {
|
||||||
{ MTAB_XTD|MTAB_VDV|MTAB_VALR, 0, "MULT", "MULT={1|2|3|4}",
|
{ MTAB_XTD|MTAB_VDV|MTAB_VALR, 0, "MULT", "MULT={1|2|3|4}",
|
||||||
&iu_timer_set_mult, &iu_timer_show_mult, NULL, "Timer Multiplier" }
|
&iu_timer_set_mult, &iu_timer_show_mult, NULL, "Timer Multiplier" },
|
||||||
|
{ 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
REG iu_timer_reg[] = {
|
REG iu_timer_reg[] = {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_cpu.c: MITS Altair CPU (8080 and Z80)
|
/* altairz80_cpu.c: MITS Altair CPU (8080 and Z80)
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
@ -451,7 +451,7 @@ REG cpu_reg[] = {
|
||||||
}, /* 65 M68K, PREF_ADDR */
|
}, /* 65 M68K, PREF_ADDR */
|
||||||
{ HRDATAD (M68K_PREF_DATA, m68k_registers[M68K_REG_PREF_DATA], 32, "M68K Last Prefetch Data register"),
|
{ HRDATAD (M68K_PREF_DATA, m68k_registers[M68K_REG_PREF_DATA], 32, "M68K Last Prefetch Data register"),
|
||||||
}, /* 66 M68K, PREF_DATA */
|
}, /* 66 M68K, PREF_DATA */
|
||||||
{ HRDATAD (M68K_PPC, m68k_registers[M68K_REG_PPC], 32, "M68K Previous Proram Counter register"),
|
{ HRDATAD (M68K_PPC, m68k_registers[M68K_REG_PPC], 32, "M68K Previous Program Counter register"),
|
||||||
}, /* 67 M68K, PPC */
|
}, /* 67 M68K, PPC */
|
||||||
{ HRDATAD (M68K_IR, m68k_registers[M68K_REG_IR], 32, "M68K Instruction Register"),
|
{ HRDATAD (M68K_IR, m68k_registers[M68K_REG_IR], 32, "M68K Instruction Register"),
|
||||||
}, /* 68 M68K, IR */
|
}, /* 68 M68K, IR */
|
||||||
|
@ -6384,7 +6384,7 @@ static t_stat sim_instr_mmu (void) {
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This sequence of instructions is a mix that mimics
|
* This sequence of instructions is a mix that mimics
|
||||||
* a resonable instruction set that is a close estimate
|
* a reasonable instruction set that is a close estimate
|
||||||
* to the calibrated result.
|
* to the calibrated result.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_cpu_opt.c: MITS Altair CPU (8080 and Z80)
|
/* altairz80_cpu_opt.c: MITS Altair CPU (8080 and Z80)
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_defs.h: MITS Altair simulator definitions
|
/* altairz80_defs.h: MITS Altair simulator definitions
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_dsk.c: MITS Altair 88-DISK Simulator
|
/* altairz80_dsk.c: MITS Altair 88-DISK Simulator
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_hdsk.c: simulated hard disk device to increase capacity
|
/* altairz80_hdsk.c: simulated hard disk device to increase capacity
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
@ -419,7 +419,7 @@ static DISK_INFO* hdsk_imd[HDSK_NUMBER];
|
||||||
static REG hdsk_reg[] = {
|
static REG hdsk_reg[] = {
|
||||||
{ DRDATAD (HDCMD, hdskLastCommand, 32, "Last command"),
|
{ DRDATAD (HDCMD, hdskLastCommand, 32, "Last command"),
|
||||||
REG_RO },
|
REG_RO },
|
||||||
{ DRDATAD (HDPOS, hdskCommandPosition, 32, "Commmand position"),
|
{ DRDATAD (HDPOS, hdskCommandPosition, 32, "Command position"),
|
||||||
REG_RO },
|
REG_RO },
|
||||||
{ DRDATAD (HDDSK, selectedDisk, 32, "Selected disk"),
|
{ DRDATAD (HDDSK, selectedDisk, 32, "Selected disk"),
|
||||||
REG_RO },
|
REG_RO },
|
||||||
|
@ -605,7 +605,7 @@ static t_stat hdsk_attach(UNIT *uptr, CONST char *cptr) {
|
||||||
}
|
}
|
||||||
ASSURE((uptr -> HDSK_SECTORS_PER_TRACK) && (uptr -> HDSK_SECTOR_SIZE) && (uptr -> HDSK_FORMAT_TYPE >= 0));
|
ASSURE((uptr -> HDSK_SECTORS_PER_TRACK) && (uptr -> HDSK_SECTOR_SIZE) && (uptr -> HDSK_FORMAT_TYPE >= 0));
|
||||||
|
|
||||||
/* Step 4: Number of tracks is smallest number to accomodate capacity */
|
/* Step 4: Number of tracks is smallest number to accommodate capacity */
|
||||||
uptr -> HDSK_NUMBER_OF_TRACKS = (uptr -> capac + uptr -> HDSK_SECTORS_PER_TRACK *
|
uptr -> HDSK_NUMBER_OF_TRACKS = (uptr -> capac + uptr -> HDSK_SECTORS_PER_TRACK *
|
||||||
uptr -> HDSK_SECTOR_SIZE - 1) / (uptr -> HDSK_SECTORS_PER_TRACK * uptr -> HDSK_SECTOR_SIZE);
|
uptr -> HDSK_SECTOR_SIZE - 1) / (uptr -> HDSK_SECTORS_PER_TRACK * uptr -> HDSK_SECTOR_SIZE);
|
||||||
ASSURE( ( (t_addr) ((uptr -> HDSK_NUMBER_OF_TRACKS - 1) * uptr -> HDSK_SECTORS_PER_TRACK *
|
ASSURE( ( (t_addr) ((uptr -> HDSK_NUMBER_OF_TRACKS - 1) * uptr -> HDSK_SECTORS_PER_TRACK *
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_mhdsk.c: MITS 88-HDSK Hard Disk simulator
|
/* altairz80_mhdsk.c: MITS 88-HDSK Hard Disk simulator
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_net.c: networking capability
|
/* altairz80_net.c: networking capability
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_sio.c: MITS Altair serial I/O card
|
/* altairz80_sio.c: MITS Altair serial I/O card
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* altairz80_sys.c: MITS Altair system interface
|
/* altairz80_sys.c: MITS Altair system interface
|
||||||
|
|
||||||
Copyright (c) 2002-2014, Peter Schorn
|
Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -35,7 +35,7 @@
|
||||||
EAX & 0xff === AL
|
EAX & 0xff === AL
|
||||||
EAX & 0xffff == AX
|
EAX & 0xffff == AX
|
||||||
|
|
||||||
etc. The result is that alot of the calculations can then be
|
etc. The result is that a lot of the calculations can then be
|
||||||
done using the native instruction set fully.
|
done using the native instruction set fully.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -196,7 +196,7 @@ struct pc_env
|
||||||
struct i386_general_regs Gn_regs;
|
struct i386_general_regs Gn_regs;
|
||||||
struct i386_special_regs Sp_regs;
|
struct i386_special_regs Sp_regs;
|
||||||
struct i386_segment_regs Sg_regs;
|
struct i386_segment_regs Sg_regs;
|
||||||
/* our flags structrure. This contains information on
|
/* our flags structure. This contains information on
|
||||||
REPE prefix 2 bits repe,repne
|
REPE prefix 2 bits repe,repne
|
||||||
SEGMENT overrides 5 bits normal,DS,SS,CS,ES
|
SEGMENT overrides 5 bits normal,DS,SS,CS,ES
|
||||||
Delayed flag set 3 bits (zero, signed, parity)
|
Delayed flag set 3 bits (zero, signed, parity)
|
||||||
|
|
|
@ -77,7 +77,7 @@ void cpu8086_intr(uint8 intrnum);
|
||||||
|
|
||||||
/* this file includes subroutines which do:
|
/* this file includes subroutines which do:
|
||||||
stuff involving decoding instruction formats.
|
stuff involving decoding instruction formats.
|
||||||
stuff involving accessess of immediate data via IP.
|
stuff involving accesses of immediate data via IP.
|
||||||
etc.
|
etc.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -675,7 +675,7 @@ uint8 fetch_data_byte(PC_ENV *m, uint16 offset)
|
||||||
refer to addresses relative to the SS. So, at the minimum,
|
refer to addresses relative to the SS. So, at the minimum,
|
||||||
all decodings of addressing modes would have to set/clear
|
all decodings of addressing modes would have to set/clear
|
||||||
a bit describing whether the access is relative to DS or SS.
|
a bit describing whether the access is relative to DS or SS.
|
||||||
That is the function of the cpu-state-varible m->sysmode.
|
That is the function of the cpu-state-variable m->sysmode.
|
||||||
There are several potential states:
|
There are several potential states:
|
||||||
repe prefix seen (handled elsewhere)
|
repe prefix seen (handled elsewhere)
|
||||||
repne prefix seen (ditto)
|
repne prefix seen (ditto)
|
||||||
|
@ -683,7 +683,7 @@ uint8 fetch_data_byte(PC_ENV *m, uint16 offset)
|
||||||
ds segment override
|
ds segment override
|
||||||
es segment override
|
es segment override
|
||||||
ss segment override
|
ss segment override
|
||||||
ds/ss select (in absense of override)
|
ds/ss select (in absence of override)
|
||||||
Each of the above 7 items are handled with a bit in the sysmode
|
Each of the above 7 items are handled with a bit in the sysmode
|
||||||
field.
|
field.
|
||||||
The latter 5 can be implemented as a simple state machine:
|
The latter 5 can be implemented as a simple state machine:
|
||||||
|
|
|
@ -78,7 +78,7 @@ extern uint32 in(const uint32 Port);
|
||||||
to the 256 byte-"opcodes" found on the 8086. The table which
|
to the 256 byte-"opcodes" found on the 8086. The table which
|
||||||
dispatches this is found in the files optab.[ch].
|
dispatches this is found in the files optab.[ch].
|
||||||
|
|
||||||
Each opcode proc has a comment preceeding it which gives it's table
|
Each opcode proc has a comment preceding it which gives it's table
|
||||||
address. Several opcodes are missing (undefined) in the table.
|
address. Several opcodes are missing (undefined) in the table.
|
||||||
|
|
||||||
Each proc includes information for decoding (DECODE_PRINTF and
|
Each proc includes information for decoding (DECODE_PRINTF and
|
||||||
|
@ -3100,7 +3100,7 @@ static void i86op_movs_byte(PC_ENV *m)
|
||||||
inc = 1;
|
inc = 1;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
@ -3133,7 +3133,7 @@ static void i86op_movs_word(PC_ENV *m)
|
||||||
inc = 2;
|
inc = 2;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
@ -3291,7 +3291,7 @@ static void i86op_stos_byte(PC_ENV *m)
|
||||||
inc = 1;
|
inc = 1;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
@ -3319,7 +3319,7 @@ static void i86op_stos_word(PC_ENV *m)
|
||||||
inc = 2;
|
inc = 2;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
@ -3347,7 +3347,7 @@ static void i86op_lods_byte(PC_ENV *m)
|
||||||
inc = 1;
|
inc = 1;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
@ -3375,7 +3375,7 @@ static void i86op_lods_word(PC_ENV *m)
|
||||||
inc = 2;
|
inc = 2;
|
||||||
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
if (m->sysmode & (SYSMODE_PREFIX_REPE | SYSMODE_PREFIX_REPNE))
|
||||||
{
|
{
|
||||||
/* dont care whether REPE or REPNE */
|
/* don't care whether REPE or REPNE */
|
||||||
/* move them until CX is ZERO. */
|
/* move them until CX is ZERO. */
|
||||||
while (m->R_CX != 0)
|
while (m->R_CX != 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -186,7 +186,7 @@ uint8 xor_0x3_tab[] = { 0, 1, 1, 0 };
|
||||||
|
|
||||||
By inspection, one gets: cc = ab + r'(a + b)
|
By inspection, one gets: cc = ab + r'(a + b)
|
||||||
|
|
||||||
That represents alot of operations, but NO CHOICE....
|
That represents a lot of operations, but NO CHOICE....
|
||||||
|
|
||||||
BORROW CHAIN CALCULATION.
|
BORROW CHAIN CALCULATION.
|
||||||
The following table represents the
|
The following table represents the
|
||||||
|
@ -498,7 +498,7 @@ uint8 neg_byte(PC_ENV *m, uint8 s)
|
||||||
CONDITIONAL_SET_FLAG(res & 0x80, m, F_SF);
|
CONDITIONAL_SET_FLAG(res & 0x80, m, F_SF);
|
||||||
CONDITIONAL_SET_FLAG(parity_tab[res], m, F_PF);
|
CONDITIONAL_SET_FLAG(parity_tab[res], m, F_PF);
|
||||||
/* calculate the borrow chain --- modified such that d=0.
|
/* calculate the borrow chain --- modified such that d=0.
|
||||||
substitutiing d=0 into bc= res&(~d|s)|(~d&s);
|
substituting d=0 into bc= res&(~d|s)|(~d&s);
|
||||||
(the one used for sub) and simplifying, since ~d=0xff...,
|
(the one used for sub) and simplifying, since ~d=0xff...,
|
||||||
~d|s == 0xffff..., and res&0xfff... == res. Similarly
|
~d|s == 0xffff..., and res&0xfff... == res. Similarly
|
||||||
~d&s == s. So the simplified result is:*/
|
~d&s == s. So the simplified result is:*/
|
||||||
|
@ -518,7 +518,7 @@ uint16 neg_word(PC_ENV *m, uint16 s)
|
||||||
CONDITIONAL_SET_FLAG(res & 0x8000, m, F_SF);
|
CONDITIONAL_SET_FLAG(res & 0x8000, m, F_SF);
|
||||||
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
||||||
/* calculate the borrow chain --- modified such that d=0.
|
/* calculate the borrow chain --- modified such that d=0.
|
||||||
substitutiing d=0 into bc= res&(~d|s)|(~d&s);
|
substituting d=0 into bc= res&(~d|s)|(~d&s);
|
||||||
(the one used for sub) and simplifying, since ~d=0xff...,
|
(the one used for sub) and simplifying, since ~d=0xff...,
|
||||||
~d|s == 0xffff..., and res&0xfff... == res. Similarly
|
~d|s == 0xffff..., and res&0xfff... == res. Similarly
|
||||||
~d&s == s. So the simplified result is:*/
|
~d&s == s. So the simplified result is:*/
|
||||||
|
@ -793,7 +793,7 @@ uint16 rcr_word(PC_ENV *m, uint16 d, uint16 s)
|
||||||
if (cnt==1)
|
if (cnt==1)
|
||||||
{
|
{
|
||||||
cf = d & 0x1;
|
cf = d & 0x1;
|
||||||
/* see note above on teh byte version */
|
/* see note above on the byte version */
|
||||||
ocf = ACCESS_FLAG(m,F_CF) != 0;
|
ocf = ACCESS_FLAG(m,F_CF) != 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -1310,7 +1310,7 @@ void test_byte(PC_ENV *m, uint8 d, uint8 s)
|
||||||
CONDITIONAL_SET_FLAG(res&0x80, m, F_SF);
|
CONDITIONAL_SET_FLAG(res&0x80, m, F_SF);
|
||||||
CONDITIONAL_SET_FLAG(res==0, m, F_ZF);
|
CONDITIONAL_SET_FLAG(res==0, m, F_ZF);
|
||||||
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
||||||
/* AF == dont care*/
|
/* AF == don't care*/
|
||||||
CLEAR_FLAG(m, F_CF);
|
CLEAR_FLAG(m, F_CF);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1322,7 +1322,7 @@ void test_word(PC_ENV *m, uint16 d, uint16 s)
|
||||||
CONDITIONAL_SET_FLAG(res&0x8000, m, F_SF);
|
CONDITIONAL_SET_FLAG(res&0x8000, m, F_SF);
|
||||||
CONDITIONAL_SET_FLAG(res==0, m, F_ZF);
|
CONDITIONAL_SET_FLAG(res==0, m, F_ZF);
|
||||||
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
CONDITIONAL_SET_FLAG(parity_tab[res&0xff], m, F_PF);
|
||||||
/* AF == dont care*/
|
/* AF == don't care*/
|
||||||
CLEAR_FLAG(m, F_CF);
|
CLEAR_FLAG(m, F_CF);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -142,10 +142,10 @@ static const char* ibc_description(DEVICE *dptr);
|
||||||
|
|
||||||
/* IBC Middi Cadet I/O Ports */
|
/* IBC Middi Cadet I/O Ports */
|
||||||
#define IBC_SIO 0x04 /* 0x04-0x13: UARTs (using AltairZ80 SIO.) UARTS 0x00-0x03 are using 2sio. */
|
#define IBC_SIO 0x04 /* 0x04-0x13: UARTs (using AltairZ80 SIO.) UARTS 0x00-0x03 are using 2sio. */
|
||||||
#define IBC_FDC_DATA 0x28 /* FDC Data Regster */
|
#define IBC_FDC_DATA 0x28 /* FDC Data Register */
|
||||||
#define IBC_PARAM 0x2a /* FDC PARAM register */
|
#define IBC_PARAM 0x2a /* FDC PARAM Register */
|
||||||
#define IBC_DIPSWE 0x3c /* CPU Board DIP Switch E */
|
#define IBC_DIPSWE 0x3c /* CPU Board DIP Switch E */
|
||||||
#define IBC_BANKSEL 0x38 /* Bank Select register */
|
#define IBC_BANKSEL 0x38 /* Bank Select Register */
|
||||||
#define IBC_FIFO_CTRL 0x3e /* FDC FIFO Control */
|
#define IBC_FIFO_CTRL 0x3e /* FDC FIFO Control */
|
||||||
#define IBC_ROM_CTRL 0x3f /* ROM Control Register */
|
#define IBC_ROM_CTRL 0x3f /* ROM Control Register */
|
||||||
#define IBC_SCC_BANKSEL 0x58 /* Bank Select register */
|
#define IBC_SCC_BANKSEL 0x58 /* Bank Select register */
|
||||||
|
@ -252,7 +252,7 @@ static DEBTAB ibc_dt[] = {
|
||||||
{ "SBD", SBD_MSG, "System Board messages" },
|
{ "SBD", SBD_MSG, "System Board messages" },
|
||||||
{ "UART", UART_MSG, "UART messages" },
|
{ "UART", UART_MSG, "UART messages" },
|
||||||
{ "CACHE", CACHE_MSG, "CACHE messages" },
|
{ "CACHE", CACHE_MSG, "CACHE messages" },
|
||||||
{ "UIO", UNHANDLED_IO_MSG, "Unsuported I/O Ports" },
|
{ "UIO", UNHANDLED_IO_MSG, "Unsupported I/O Ports" },
|
||||||
{ "FIFO", FIFO_MSG, "FDC FIFO messages" },
|
{ "FIFO", FIFO_MSG, "FDC FIFO messages" },
|
||||||
{ "DIPSW", DIPSW_MSG, "DIP Switch messages" },
|
{ "DIPSW", DIPSW_MSG, "DIP Switch messages" },
|
||||||
{ NULL, 0, NULL }
|
{ NULL, 0, NULL }
|
||||||
|
@ -1817,7 +1817,7 @@ static int32 ibc_banksel(const int32 port, const int32 io, const int32 data)
|
||||||
* 0xff: Boot from floppy (All off.)
|
* 0xff: Boot from floppy (All off.)
|
||||||
* Switch 1 - 0xfe: Boot into ROM monitor (Switch 1 on.)
|
* Switch 1 - 0xfe: Boot into ROM monitor (Switch 1 on.)
|
||||||
* Switch 2 - 0xfd: Boot from hard disk (Switch 2 on.)
|
* Switch 2 - 0xfd: Boot from hard disk (Switch 2 on.)
|
||||||
* Switch 7 - 0xbe: OFF = Use FDC Interupts, ON = Poll FDC instead.
|
* Switch 7 - 0xbe: OFF = Use FDC Interrupts, ON = Poll FDC instead.
|
||||||
*/
|
*/
|
||||||
result = ibc_info->dipsw_E;
|
result = ibc_info->dipsw_E;
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,8 @@
|
||||||
#define IBC_HDC_MAX_DRIVES 4 /* Maximum number of drives supported */
|
#define IBC_HDC_MAX_DRIVES 4 /* Maximum number of drives supported */
|
||||||
#define IBC_HDC_MAX_SECLEN 256 /* Maximum of 256 bytes per sector */
|
#define IBC_HDC_MAX_SECLEN 256 /* Maximum of 256 bytes per sector */
|
||||||
#define IBC_HDC_FORMAT_FILL_BYTE 0xe5 /* Real controller uses 0, but we
|
#define IBC_HDC_FORMAT_FILL_BYTE 0xe5 /* Real controller uses 0, but we
|
||||||
choose 0xe5 so the disk shows up as blank under CP/M. */
|
choose 0xe5 so the disk shows
|
||||||
|
up as blank under CP/M. */
|
||||||
#define IBC_HDC_MAX_CYLS 1024
|
#define IBC_HDC_MAX_CYLS 1024
|
||||||
#define IBC_HDC_MAX_HEADS 16
|
#define IBC_HDC_MAX_HEADS 16
|
||||||
#define IBC_HDC_MAX_SPT 256
|
#define IBC_HDC_MAX_SPT 256
|
||||||
|
@ -67,6 +68,7 @@
|
||||||
#define TF_TRKH 7
|
#define TF_TRKH 7
|
||||||
#define TF_FIFO 8
|
#define TF_FIFO 8
|
||||||
|
|
||||||
|
#define IBC_HDC_STATUS_BUSY (1 << 4)
|
||||||
#define IBC_HDC_STATUS_ERROR (1 << 0)
|
#define IBC_HDC_STATUS_ERROR (1 << 0)
|
||||||
|
|
||||||
#define IBC_HDC_ERROR_ID_NOT_FOUND (1 << 4)
|
#define IBC_HDC_ERROR_ID_NOT_FOUND (1 << 4)
|
||||||
|
@ -238,7 +240,7 @@ static t_stat ibc_hdc_attach(UNIT *uptr, CONST char *cptr)
|
||||||
/* Defaults for the Quantum 2020 Drive */
|
/* Defaults for the Quantum 2020 Drive */
|
||||||
pDrive->ready = 0;
|
pDrive->ready = 0;
|
||||||
if (pDrive->ncyls == 0) {
|
if (pDrive->ncyls == 0) {
|
||||||
/* If geometry was not specified, default to Quantun 2020 */
|
/* If geometry was not specified, default to Quantum 2020 */
|
||||||
pDrive->ncyls = 512;
|
pDrive->ncyls = 512;
|
||||||
pDrive->nheads = 4;
|
pDrive->nheads = 4;
|
||||||
pDrive->nsectors = 32;
|
pDrive->nsectors = 32;
|
||||||
|
@ -536,7 +538,7 @@ static t_stat IBC_HDC_doCommand(void)
|
||||||
IBC_HDC_DRIVE_INFO* pDrive = &ibc_hdc_info->drive[ibc_hdc_info->sel_drive];
|
IBC_HDC_DRIVE_INFO* pDrive = &ibc_hdc_info->drive[ibc_hdc_info->sel_drive];
|
||||||
uint8 cmd = ibc_hdc_info->taskfile[TF_CMD] & IBC_HDC_CMD_MASK;
|
uint8 cmd = ibc_hdc_info->taskfile[TF_CMD] & IBC_HDC_CMD_MASK;
|
||||||
|
|
||||||
pDrive->cur_cyl = ibc_hdc_info->taskfile[TF_TRKH] << 8;
|
pDrive->cur_cyl = (uint16)ibc_hdc_info->taskfile[TF_TRKH] << 8;
|
||||||
pDrive->cur_cyl |= ibc_hdc_info->taskfile[TF_TRKL];
|
pDrive->cur_cyl |= ibc_hdc_info->taskfile[TF_TRKL];
|
||||||
pDrive->xfr_nsects = ibc_hdc_info->taskfile[TF_NSEC];
|
pDrive->xfr_nsects = ibc_hdc_info->taskfile[TF_NSEC];
|
||||||
pDrive->cur_head = ibc_hdc_info->taskfile[TF_HEAD];
|
pDrive->cur_head = ibc_hdc_info->taskfile[TF_HEAD];
|
||||||
|
|
|
@ -232,7 +232,7 @@ static t_stat ibc_smd_attach(UNIT *uptr, CONST char *cptr)
|
||||||
/* Defaults for the Quantum 2020 Drive */
|
/* Defaults for the Quantum 2020 Drive */
|
||||||
pDrive->ready = 0;
|
pDrive->ready = 0;
|
||||||
if (pDrive->ncyls == 0) {
|
if (pDrive->ncyls == 0) {
|
||||||
/* If geometry was not specified, default to Quantun 2020 */
|
/* If geometry was not specified, default to Quantum 2020 */
|
||||||
pDrive->ncyls = 512;
|
pDrive->ncyls = 512;
|
||||||
pDrive->nheads = 4;
|
pDrive->nheads = 4;
|
||||||
pDrive->nsectors = 16;
|
pDrive->nsectors = 16;
|
||||||
|
|
|
@ -379,7 +379,7 @@ void m68k_set_reg(m68k_register_t reg, unsigned int value);
|
||||||
/* Check if an instruction is valid for the specified CPU type */
|
/* Check if an instruction is valid for the specified CPU type */
|
||||||
unsigned int m68k_is_valid_instruction(unsigned int instruction, unsigned int cpu_type);
|
unsigned int m68k_is_valid_instruction(unsigned int instruction, unsigned int cpu_type);
|
||||||
|
|
||||||
/* Disassemble 1 instruction using the epecified CPU type at pc. Stores
|
/* Disassemble 1 instruction using the specified CPU type at pc. Stores
|
||||||
* disassembly in str_buff and returns the size of the instruction in bytes.
|
* disassembly in str_buff and returns the size of the instruction in bytes.
|
||||||
*/
|
*/
|
||||||
unsigned int m68k_disassemble(char* str_buff, unsigned int pc, unsigned int cpu_type);
|
unsigned int m68k_disassemble(char* str_buff, unsigned int pc, unsigned int cpu_type);
|
||||||
|
|
|
@ -140,7 +140,7 @@
|
||||||
* the exception occurs normally.
|
* the exception occurs normally.
|
||||||
* The callback looks like int callback(int opcode)
|
* The callback looks like int callback(int opcode)
|
||||||
* You should put OPT_SPECIFY_HANDLER here if you cant to use it, otherwise it will
|
* You should put OPT_SPECIFY_HANDLER here if you cant to use it, otherwise it will
|
||||||
* use a dummy default handler and you'll have to call m68k_set_illg_instr_callback explicitely
|
* use a dummy default handler and you'll have to call m68k_set_illg_instr_callback explicitly
|
||||||
*/
|
*/
|
||||||
#define M68K_ILLG_HAS_CALLBACK OPT_OFF
|
#define M68K_ILLG_HAS_CALLBACK OPT_OFF
|
||||||
#define M68K_ILLG_CALLBACK(opcode) op_illg(opcode)
|
#define M68K_ILLG_CALLBACK(opcode) op_illg(opcode)
|
||||||
|
@ -199,7 +199,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
/* If ON, the enulation core will use 64-bit integers to speed up some
|
/* If ON, the emulation core will use 64-bit integers to speed up some
|
||||||
* operations.
|
* operations.
|
||||||
*/
|
*/
|
||||||
#define M68K_USE_64_BIT OPT_ON
|
#define M68K_USE_64_BIT OPT_ON
|
||||||
|
|
|
@ -973,7 +973,7 @@ int m68k_execute(int num_cycles)
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
/* Set tracing accodring to T1. (T0 is done inside instruction) */
|
/* Set tracing according to T1. (T0 is done inside instruction) */
|
||||||
m68ki_trace_t1(); /* auto-disable (see m68kcpu.h) */
|
m68ki_trace_t1(); /* auto-disable (see m68kcpu.h) */
|
||||||
|
|
||||||
/* Set the address space for reads */
|
/* Set the address space for reads */
|
||||||
|
@ -1037,7 +1037,7 @@ void m68k_end_timeslice(void)
|
||||||
|
|
||||||
/* ASG: rewrote so that the int_level is a mask of the IPL0/IPL1/IPL2 bits */
|
/* ASG: rewrote so that the int_level is a mask of the IPL0/IPL1/IPL2 bits */
|
||||||
/* KS: Modified so that IPL* bits match with mask positions in the SR
|
/* KS: Modified so that IPL* bits match with mask positions in the SR
|
||||||
* and cleaned out remenants of the interrupt controller.
|
* and cleaned out remnants of the interrupt controller.
|
||||||
*/
|
*/
|
||||||
void m68k_set_irq(unsigned int int_level)
|
void m68k_set_irq(unsigned int int_level)
|
||||||
{
|
{
|
||||||
|
|
|
@ -398,7 +398,7 @@ typedef uint32 uint64;
|
||||||
|
|
||||||
/* ----------------------------- Configuration ---------------------------- */
|
/* ----------------------------- Configuration ---------------------------- */
|
||||||
|
|
||||||
/* These defines are dependant on the configuration defines in m68kconf.h */
|
/* These defines are dependent on the configuration defines in m68kconf.h */
|
||||||
|
|
||||||
/* Disable certain comparisons if we're not using all CPU types */
|
/* Disable certain comparisons if we're not using all CPU types */
|
||||||
#if M68K_EMULATE_040
|
#if M68K_EMULATE_040
|
||||||
|
@ -2015,7 +2015,7 @@ static inline void m68ki_exception_illegal(void)
|
||||||
USE_CYCLES(CYC_EXCEPTION[EXCEPTION_ILLEGAL_INSTRUCTION_M68K] - CYC_INSTRUCTION[REG_IR]);
|
USE_CYCLES(CYC_EXCEPTION[EXCEPTION_ILLEGAL_INSTRUCTION_M68K] - CYC_INSTRUCTION[REG_IR]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Exception for format errror in RTE */
|
/* Exception for format error in RTE */
|
||||||
static inline void m68ki_exception_format_error(void)
|
static inline void m68ki_exception_format_error(void)
|
||||||
{
|
{
|
||||||
uint sr = m68ki_init_exception();
|
uint sr = m68ki_init_exception();
|
||||||
|
@ -2052,7 +2052,7 @@ static inline void m68ki_exception_address_error(void)
|
||||||
|
|
||||||
/* Use up some clock cycles. Note that we don't need to undo the
|
/* Use up some clock cycles. Note that we don't need to undo the
|
||||||
instruction's cycles here as we've longjmp:ed directly from the
|
instruction's cycles here as we've longjmp:ed directly from the
|
||||||
instruction handler without passing the part of the excecute loop
|
instruction handler without passing the part of the execute loop
|
||||||
that deducts instruction cycles */
|
that deducts instruction cycles */
|
||||||
USE_CYCLES(CYC_EXCEPTION[EXCEPTION_ADDRESS_ERROR]);
|
USE_CYCLES(CYC_EXCEPTION[EXCEPTION_ADDRESS_ERROR]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -156,7 +156,7 @@ uint read_imm_8(void);
|
||||||
uint read_imm_16(void);
|
uint read_imm_16(void);
|
||||||
uint read_imm_32(void);
|
uint read_imm_32(void);
|
||||||
|
|
||||||
/* Read data at the PC but don't imcrement the PC */
|
/* Read data at the PC but don't increment the PC */
|
||||||
uint peek_imm_8(void);
|
uint peek_imm_8(void);
|
||||||
uint peek_imm_16(void);
|
uint peek_imm_16(void);
|
||||||
uint peek_imm_32(void);
|
uint peek_imm_32(void);
|
||||||
|
@ -3721,7 +3721,7 @@ static void build_opcode_table(void)
|
||||||
/* ================================= API ================================== */
|
/* ================================= API ================================== */
|
||||||
/* ======================================================================== */
|
/* ======================================================================== */
|
||||||
|
|
||||||
/* Disasemble one instruction at pc and store in str_buff */
|
/* Disassemble one instruction at pc and store in str_buff */
|
||||||
unsigned int m68k_disassemble(char* str_buff, unsigned int pc, unsigned int cpu_type)
|
unsigned int m68k_disassemble(char* str_buff, unsigned int pc, unsigned int cpu_type)
|
||||||
{
|
{
|
||||||
if(!g_initialized)
|
if(!g_initialized)
|
||||||
|
@ -3773,7 +3773,7 @@ unsigned int m68k_disassemble(char* str_buff, unsigned int pc, unsigned int cpu_
|
||||||
|
|
||||||
char* m68ki_disassemble_quick(unsigned int pc, unsigned int cpu_type)
|
char* m68ki_disassemble_quick(unsigned int pc, unsigned int cpu_type)
|
||||||
{
|
{
|
||||||
static char buff[100];
|
static char buff[200];
|
||||||
buff[0] = 0;
|
buff[0] = 0;
|
||||||
m68k_disassemble(buff, pc, cpu_type);
|
m68k_disassemble(buff, pc, cpu_type);
|
||||||
return buff;
|
return buff;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* m68kcpmsim.c: CP/M for Motorola 68000 definitions
|
/* m68kcpmsim.c: CP/M for Motorola 68000 definitions
|
||||||
|
|
||||||
Copyright (c) 2014, Peter Schorn
|
Copyright (c) 2014 - 2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
@ -48,7 +48,7 @@
|
||||||
sector number to the sector register. This write triggers the requested
|
sector number to the sector register. This write triggers the requested
|
||||||
operation. The status of the operation can be determined by reading the
|
operation. The status of the operation can be determined by reading the
|
||||||
status register.
|
status register.
|
||||||
A zero indicates that no error occured.
|
A zero indicates that no error occurred.
|
||||||
|
|
||||||
Note that these operations invoke read() and write() system calls directly
|
Note that these operations invoke read() and write() system calls directly
|
||||||
so that they will alter the image on the hard disk. KEEP BACKUPS!
|
so that they will alter the image on the hard disk. KEEP BACKUPS!
|
||||||
|
@ -98,7 +98,7 @@
|
||||||
|
|
||||||
/* Memory-mapped IO ports */
|
/* Memory-mapped IO ports */
|
||||||
|
|
||||||
/* 6850 serial port like thing. Implements a reduced set of functionallity. */
|
/* 6850 serial port like thing. Implements a reduced set of functionality. */
|
||||||
#define MC6850_STAT 0xff1000L // command/status register
|
#define MC6850_STAT 0xff1000L // command/status register
|
||||||
#define MC6850_DATA 0xff1002L // receive/transmit data register
|
#define MC6850_DATA 0xff1002L // receive/transmit data register
|
||||||
|
|
||||||
|
@ -335,7 +335,7 @@ static int MC6850_device_ack(void) {
|
||||||
|
|
||||||
static void MC6850_data_write(uint32 value) {
|
static void MC6850_data_write(uint32 value) {
|
||||||
sim_putchar(value);
|
sim_putchar(value);
|
||||||
if ((m68k_MC6850_control & 0x60) == 0x20) { // transmit interupt enabled?
|
if ((m68k_MC6850_control & 0x60) == 0x20) { // transmit interrupt enabled?
|
||||||
int_controller_clear(IRQ_MC6850);
|
int_controller_clear(IRQ_MC6850);
|
||||||
int_controller_set(IRQ_MC6850);
|
int_controller_set(IRQ_MC6850);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
/* m68kcpmsim.h: CP/M for Motorola 68000 definitions
|
/* m68kcpmsim.h: CP/M for Motorola 68000 definitions
|
||||||
|
|
||||||
Copyright (c) 2014, Peter Schorn
|
Copyright (c) 2014 - 2023, Peter Schorn
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a
|
Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
copy of this software and associated documentation files (the "Software"),
|
copy of this software and associated documentation files (the "Software"),
|
||||||
|
|
|
@ -11,8 +11,6 @@
|
||||||
#ifndef NASM_NASM_H
|
#ifndef NASM_NASM_H
|
||||||
#define NASM_NASM_H
|
#define NASM_NASM_H
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#ifndef NULL
|
#ifndef NULL
|
||||||
#define NULL 0
|
#define NULL 0
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -65,7 +65,7 @@
|
||||||
We get many calls on how to interface terminals to the 2SIO. The
|
We get many calls on how to interface terminals to the 2SIO. The
|
||||||
problem is that the Asynchronous Communications Interface Adapter's
|
problem is that the Asynchronous Communications Interface Adapter's
|
||||||
(ACIA) handshaking signals make interfacing with the 2SIO a
|
(ACIA) handshaking signals make interfacing with the 2SIO a
|
||||||
somewhat complicated matter. An explaination of the signals and
|
somewhat complicated matter. An explanation of the signals and
|
||||||
their function should make the job easier. The three handshaking
|
their function should make the job easier. The three handshaking
|
||||||
signals--Data Carrier Detect (DCD), Request to Send (RTS) and
|
signals--Data Carrier Detect (DCD), Request to Send (RTS) and
|
||||||
Clear to Send (CTS)--permit limited control of a modem or
|
Clear to Send (CTS)--permit limited control of a modem or
|
||||||
|
@ -79,8 +79,8 @@
|
||||||
section is inhibited and no data can be received by the ACIA.
|
section is inhibited and no data can be received by the ACIA.
|
||||||
|
|
||||||
Information from the two input signals, CTS and DCD, is present in
|
Information from the two input signals, CTS and DCD, is present in
|
||||||
the ACIA status register. Bit 2 represents *DCD, and bit 3 repre-
|
the ACIA status register. Bit 2 represents *DCD, and bit 3
|
||||||
sents *CTS. When bit 2 is high, DCD is inactive. When bit 3 is high,
|
represents *CTS. When bit 2 is high, DCD is inactive. When bit 3 is high,
|
||||||
CTS is inactive. When bit 2 goes low, valid data is sent to the ACIA.
|
CTS is inactive. When bit 2 goes low, valid data is sent to the ACIA.
|
||||||
When bit 3 goes low, data can be transmitted.
|
When bit 3 goes low, data can be transmitted.
|
||||||
|
|
||||||
|
@ -230,6 +230,8 @@ static TMXR m2sio1_tmxr = { /* multiplexer descriptor */
|
||||||
#define UNIT_M2SIO_DTR (1 << UNIT_V_M2SIO_DTR)
|
#define UNIT_M2SIO_DTR (1 << UNIT_V_M2SIO_DTR)
|
||||||
#define UNIT_V_M2SIO_DCD (UNIT_V_UF + 2) /* Force DCD active low */
|
#define UNIT_V_M2SIO_DCD (UNIT_V_UF + 2) /* Force DCD active low */
|
||||||
#define UNIT_M2SIO_DCD (1 << UNIT_V_M2SIO_DCD)
|
#define UNIT_M2SIO_DCD (1 << UNIT_V_M2SIO_DCD)
|
||||||
|
#define UNIT_V_M2SIO_CTS (UNIT_V_UF + 3) /* Force CTS active low */
|
||||||
|
#define UNIT_M2SIO_CTS (1 << UNIT_V_M2SIO_CTS)
|
||||||
|
|
||||||
static MTAB m2sio_mod[] = {
|
static MTAB m2sio_mod[] = {
|
||||||
{ MTAB_XTD|MTAB_VDV, 0, "IOBASE", "IOBASE",
|
{ MTAB_XTD|MTAB_VDV, 0, "IOBASE", "IOBASE",
|
||||||
|
@ -246,6 +248,10 @@ static MTAB m2sio_mod[] = {
|
||||||
"Force DCD active low" },
|
"Force DCD active low" },
|
||||||
{ UNIT_M2SIO_DCD, 0, "NODCD", "NODCD", NULL, NULL, NULL,
|
{ UNIT_M2SIO_DCD, 0, "NODCD", "NODCD", NULL, NULL, NULL,
|
||||||
"DCD follows status line (default)" },
|
"DCD follows status line (default)" },
|
||||||
|
{ UNIT_M2SIO_CTS, UNIT_M2SIO_CTS, "CTS", "CTS", NULL, NULL, NULL,
|
||||||
|
"Force CTS active low" },
|
||||||
|
{ UNIT_M2SIO_CTS, 0, "NOCTS", "NOCTS", NULL, NULL, NULL,
|
||||||
|
"CTS follows status line (default)" },
|
||||||
{ MTAB_XTD|MTAB_VDV|MTAB_VALR, 0, "BAUD", "BAUD", &m2sio_set_baud, &m2sio_show_baud,
|
{ MTAB_XTD|MTAB_VDV|MTAB_VALR, 0, "BAUD", "BAUD", &m2sio_set_baud, &m2sio_show_baud,
|
||||||
NULL, "Set baud rate (default=9600)" },
|
NULL, "Set baud rate (default=9600)" },
|
||||||
{ 0 }
|
{ 0 }
|
||||||
|
@ -395,7 +401,7 @@ static t_stat m2sio_reset(DEVICE *dptr, int32 (*routine)(const int32, const int3
|
||||||
c = getClockFrequency() / 5;
|
c = getClockFrequency() / 5;
|
||||||
dptr->units[0].wait = (c && c < 1000) ? c : 1000;
|
dptr->units[0].wait = (c && c < 1000) ? c : 1000;
|
||||||
|
|
||||||
/* Enable TMXR modem control passthru */
|
/* Enable TMXR modem control passthrough */
|
||||||
tmxr_set_modem_control_passthru(xptr->tmxr);
|
tmxr_set_modem_control_passthru(xptr->tmxr);
|
||||||
|
|
||||||
/* Reset status registers */
|
/* Reset status registers */
|
||||||
|
@ -440,7 +446,7 @@ static t_stat m2sio_svc(UNIT *uptr)
|
||||||
tmxr_set_get_modem_bits(xptr->tmln, 0, 0, &s);
|
tmxr_set_get_modem_bits(xptr->tmln, 0, 0, &s);
|
||||||
stb = xptr->stb;
|
stb = xptr->stb;
|
||||||
xptr->stb &= ~M2SIO_CTS;
|
xptr->stb &= ~M2SIO_CTS;
|
||||||
xptr->stb |= (s & TMXR_MDM_CTS) ? 0 : M2SIO_CTS; /* Active Low */
|
xptr->stb |= ((s & TMXR_MDM_CTS) || (uptr->flags & UNIT_M2SIO_CTS)) ? 0 : M2SIO_CTS; /* Active Low */
|
||||||
if ((stb ^ xptr->stb) & M2SIO_CTS) {
|
if ((stb ^ xptr->stb) & M2SIO_CTS) {
|
||||||
sim_debug(STATUS_MSG, uptr->dptr, "CTS state changed to %s.\n", (xptr->stb & M2SIO_CTS) ? "LOW" : "HIGH");
|
sim_debug(STATUS_MSG, uptr->dptr, "CTS state changed to %s.\n", (xptr->stb & M2SIO_CTS) ? "LOW" : "HIGH");
|
||||||
}
|
}
|
||||||
|
@ -665,7 +671,7 @@ static t_stat m2sio_config_line(UNIT *uptr)
|
||||||
** to run irrelevant, old software, that use TMXR and
|
** to run irrelevant, old software, that use TMXR and
|
||||||
** rely on some semblance of timing (Remote CP/M, BYE,
|
** rely on some semblance of timing (Remote CP/M, BYE,
|
||||||
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
||||||
** other communications software), on contemprary
|
** other communications software), on contemporary
|
||||||
** hardware.
|
** hardware.
|
||||||
**
|
**
|
||||||
** Serial ports are self-limiting and sockets will run
|
** Serial ports are self-limiting and sockets will run
|
||||||
|
|
|
@ -258,7 +258,7 @@ DEVICE cromfdc_dev = {
|
||||||
};
|
};
|
||||||
|
|
||||||
/* This is the CROMFDC RDOS-II ROM.
|
/* This is the CROMFDC RDOS-II ROM.
|
||||||
* The CROMFDC has a single 8K ROM; however ths simulation includes
|
* The CROMFDC has a single 8K ROM; however this simulation includes
|
||||||
* two different versions of RDOS:
|
* two different versions of RDOS:
|
||||||
* RDOS 2.52 and RDOS 3.12
|
* RDOS 2.52 and RDOS 3.12
|
||||||
* RDOS 2.52 is the default, but RDOS 3.12 can be
|
* RDOS 2.52 is the default, but RDOS 3.12 can be
|
||||||
|
|
|
@ -313,7 +313,7 @@ static uint8 adcs6_rom[2][ADCS6_ROM_SIZE] = {
|
||||||
*
|
*
|
||||||
* MONITOR COMMANDS :
|
* MONITOR COMMANDS :
|
||||||
* B = Load disk boot loader
|
* B = Load disk boot loader
|
||||||
* C = Load disk boot loader from cartriage
|
* C = Load disk boot loader from cartridge
|
||||||
* DSSSS,QQQQ = Dump memory in hex from S to Q
|
* DSSSS,QQQQ = Dump memory in hex from S to Q
|
||||||
* FSSSS,QQQQ,BB = Fill memory from S to Q with B
|
* FSSSS,QQQQ,BB = Fill memory from S to Q with B
|
||||||
* GAAAA = Go to address A
|
* GAAAA = Go to address A
|
||||||
|
|
|
@ -78,8 +78,8 @@ typedef struct {
|
||||||
uint8 sel_drive; /* Currently selected drive */
|
uint8 sel_drive; /* Currently selected drive */
|
||||||
uint8 head_sel; /* Head select (signals to drive itself) */
|
uint8 head_sel; /* Head select (signals to drive itself) */
|
||||||
uint8 head; /* Head set by write to the HEAD register */
|
uint8 head; /* Head set by write to the HEAD register */
|
||||||
uint8 cyl; /* Cyl that the current operation is targetting */
|
uint8 cyl; /* Cyl that the current operation is targeting */
|
||||||
uint8 sector; /* Sector the current READ/WRITE operation is targetting */
|
uint8 sector; /* Sector the current READ/WRITE operation is targeting */
|
||||||
uint8 hdr_sector; /* Current sector for WRITE_HEADER */
|
uint8 hdr_sector; /* Current sector for WRITE_HEADER */
|
||||||
uint8 ctl_attn;
|
uint8 ctl_attn;
|
||||||
uint8 ctl_run;
|
uint8 ctl_run;
|
||||||
|
@ -152,11 +152,11 @@ static REG disk2_reg[] = {
|
||||||
{ HRDATAD (SEL_DRIVE, disk2_info_data.sel_drive, 3,
|
{ HRDATAD (SEL_DRIVE, disk2_info_data.sel_drive, 3,
|
||||||
"Currently selected drive"), },
|
"Currently selected drive"), },
|
||||||
{ HRDATAD (CYL, disk2_info_data.cyl, 8,
|
{ HRDATAD (CYL, disk2_info_data.cyl, 8,
|
||||||
"Cylinder that the current operation is targetting"), },
|
"Cylinder that the current operation is targeting"), },
|
||||||
{ HRDATAD (HEAD, disk2_info_data.head, 8,
|
{ HRDATAD (HEAD, disk2_info_data.head, 8,
|
||||||
"Head that the current operation is targetting"), },
|
"Head that the current operation is targeting"), },
|
||||||
{ HRDATAD (SECTOR, disk2_info_data.sector, 8,
|
{ HRDATAD (SECTOR, disk2_info_data.sector, 8,
|
||||||
"Sector that the current operation is targetting"), },
|
"Sector that the current operation is targeting"), },
|
||||||
|
|
||||||
{ NULL }
|
{ NULL }
|
||||||
};
|
};
|
||||||
|
|
|
@ -973,7 +973,7 @@ static DEBTAB dj2d_dt[] = {
|
||||||
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ "VERBOSE", VERBOSE_MSG, "Verbose messages" },
|
{ "VERBOSE", VERBOSE_MSG, "Verbose messages" },
|
||||||
{ "DEBUG", DEBUG_MSG, "Debug messages" },
|
{ "DEBUG", DEBUG_MSG, "Debug messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
|
|
|
@ -529,7 +529,7 @@ static uint8 DJHDC_Write(const uint32 Addr, uint8 cData)
|
||||||
/* Point IOPB to new link */
|
/* Point IOPB to new link */
|
||||||
djhdc_info->link_addr = next_link;
|
djhdc_info->link_addr = next_link;
|
||||||
|
|
||||||
/* Read remaineder of IOPB */
|
/* Read remainder of IOPB */
|
||||||
for(i = 0; i < DJHDC_IOPB_LEN-3; i++) {
|
for(i = 0; i < DJHDC_IOPB_LEN-3; i++) {
|
||||||
djhdc_info->iopb[i] = GetByteDMA((djhdc_info->link_addr) + i);
|
djhdc_info->iopb[i] = GetByteDMA((djhdc_info->link_addr) + i);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
IMSAI FIF Disk Controller by Ernie Price
|
IMSAI FIF Disk Controller by Ernie Price
|
||||||
|
|
||||||
Based on altairz80_dsk.c, Copyright (c) 2002-2014, Peter Schorn
|
Based on altairz80_dsk.c, Copyright (c) 2002-2023, Peter Schorn
|
||||||
|
|
||||||
Plug-n-Play added by Howard M. Harte
|
Plug-n-Play added by Howard M. Harte
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
This device emulates D.C. Hayes 80-103A and Micromodem 100 communications
|
This device emulates D.C. Hayes 80-103A and Micromodem 100 communications
|
||||||
adapters.
|
adapters.
|
||||||
|
|
||||||
To provide any useful funcationality, this device need to be attached to
|
To provide any useful functionality, this device need to be attached to
|
||||||
a socket or serial port. Enter "HELP HAYES" at the "simh>" prompt for
|
a socket or serial port. Enter "HELP HAYES" at the "simh>" prompt for
|
||||||
additional information.
|
additional information.
|
||||||
*/
|
*/
|
||||||
|
@ -243,7 +243,7 @@ static t_stat hayes_reset(DEVICE *dptr)
|
||||||
/* Set DEVICE for this UNIT */
|
/* Set DEVICE for this UNIT */
|
||||||
dptr->units[0].dptr = dptr;
|
dptr->units[0].dptr = dptr;
|
||||||
|
|
||||||
/* Enable TMXR modem control passthru */
|
/* Enable TMXR modem control passthrough */
|
||||||
tmxr_set_modem_control_passthru(hayes_ctx.tmxr);
|
tmxr_set_modem_control_passthru(hayes_ctx.tmxr);
|
||||||
|
|
||||||
/* Reset status registers */
|
/* Reset status registers */
|
||||||
|
@ -505,7 +505,7 @@ static t_stat hayes_config_line(UNIT *uptr)
|
||||||
** to run irrelevant, old software, that use TMXR and
|
** to run irrelevant, old software, that use TMXR and
|
||||||
** rely on some semblance of timing (Remote CP/M, BYE,
|
** rely on some semblance of timing (Remote CP/M, BYE,
|
||||||
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
||||||
** other communications software), on contemprary
|
** other communications software), on contemporary
|
||||||
** hardware.
|
** hardware.
|
||||||
**
|
**
|
||||||
** Serial ports are self-limiting and sockets will run
|
** Serial ports are self-limiting and sockets will run
|
||||||
|
|
|
@ -261,7 +261,7 @@ static t_stat hdc1001_attach(UNIT *uptr, CONST char *cptr)
|
||||||
/* Defaults for the Quantum 2020 Drive */
|
/* Defaults for the Quantum 2020 Drive */
|
||||||
pDrive->ready = 0;
|
pDrive->ready = 0;
|
||||||
if (pDrive->ncyls == 0) {
|
if (pDrive->ncyls == 0) {
|
||||||
/* If geometry was not specified, default to Quantun 2020 */
|
/* If geometry was not specified, default to Quantum 2020 */
|
||||||
pDrive->ncyls = 512;
|
pDrive->ncyls = 512;
|
||||||
pDrive->nheads = 4;
|
pDrive->nheads = 4;
|
||||||
pDrive->nsectors = 16;
|
pDrive->nsectors = 16;
|
||||||
|
@ -448,7 +448,7 @@ static uint8 HDC1001_Write(const uint32 Addr, uint8 cData)
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
sim_debug(ERROR_MSG, &hdc1001_dev,DEV_NAME "%d: " ADDRESS_FORMAT
|
sim_debug(ERROR_MSG, &hdc1001_dev,DEV_NAME "%d: " ADDRESS_FORMAT
|
||||||
" Invalid sector size specified in SDH registrer.\n", hdc1001_info->sel_drive, PCX);
|
" Invalid sector size specified in SDH register.\n", hdc1001_info->sel_drive, PCX);
|
||||||
pDrive->cur_sectsize = 512;
|
pDrive->cur_sectsize = 512;
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
|
@ -458,7 +458,7 @@ static uint8 HDC1001_Write(const uint32 Addr, uint8 cData)
|
||||||
|
|
||||||
if (pDrive->sectsize != pDrive->cur_sectsize) {
|
if (pDrive->sectsize != pDrive->cur_sectsize) {
|
||||||
sim_debug(ERROR_MSG, &hdc1001_dev,DEV_NAME "%d: " ADDRESS_FORMAT
|
sim_debug(ERROR_MSG, &hdc1001_dev,DEV_NAME "%d: " ADDRESS_FORMAT
|
||||||
" Sector size specified in SDH registrer (0x%x) does not match disk geometry (0x%x.)\n",
|
" Sector size specified in SDH register (0x%x) does not match disk geometry (0x%x.)\n",
|
||||||
hdc1001_info->sel_drive, PCX, pDrive->cur_sectsize, pDrive->sectsize);
|
hdc1001_info->sel_drive, PCX, pDrive->cur_sectsize, pDrive->sectsize);
|
||||||
}
|
}
|
||||||
/* fall through */
|
/* fall through */
|
||||||
|
|
|
@ -655,7 +655,7 @@ static DEBTAB icom_dt[] = {
|
||||||
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
and memory address space.
|
and memory address space.
|
||||||
|
|
||||||
While the Double D is capable to loading many different operating systems,
|
While the Double D is capable to loading many different operating systems,
|
||||||
this emulator is centered around Digital Reasearch's CP/M 2 operating
|
this emulator is centered around Digital Research's CP/M 2 operating
|
||||||
system as it was released by Jade.
|
system as it was released by Jade.
|
||||||
|
|
||||||
The process of booting CP/M with the DD is a bit more complicated than
|
The process of booting CP/M with the DD is a bit more complicated than
|
||||||
|
@ -312,7 +312,7 @@ static uint8 jade_prom[JADE_PROM_SIZE] = {
|
||||||
#define CMD_MD0 0x01 /* Select DD bank 0 */
|
#define CMD_MD0 0x01 /* Select DD bank 0 */
|
||||||
#define CMD_MD1 0x03 /* Select DD bank 1 */
|
#define CMD_MD1 0x03 /* Select DD bank 1 */
|
||||||
#define CMD_SOT 0x00 /* Switch DD mem out of system */
|
#define CMD_SOT 0x00 /* Switch DD mem out of system */
|
||||||
#define CMD_INT 0x02 /* Isssue DD Z80A interrupt */
|
#define CMD_INT 0x02 /* Issue DD Z80A interrupt */
|
||||||
#define CMD_BGN 0x80 /* Reset Z80 and execute */
|
#define CMD_BGN 0x80 /* Reset Z80 and execute */
|
||||||
|
|
||||||
#define DC_LOG 0x00 /* Log on diskette */
|
#define DC_LOG 0x00 /* Log on diskette */
|
||||||
|
@ -494,7 +494,7 @@ static DEBTAB jade_dt[] = {
|
||||||
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -190,7 +190,7 @@ static DEBTAB mdsa_dt[] = {
|
||||||
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -111,7 +111,7 @@ typedef struct {
|
||||||
typedef struct {
|
typedef struct {
|
||||||
uint8 dd; /* Controls density on write DD=1 for double density and DD=0 for single density. */
|
uint8 dd; /* Controls density on write DD=1 for double density and DD=0 for single density. */
|
||||||
uint8 ss; /* Specifies the side of a double-sided diskette. The bottom side (and only side of a single-sided diskette) is selected when SS=0. The second (top) side is selected when SS=1. */
|
uint8 ss; /* Specifies the side of a double-sided diskette. The bottom side (and only side of a single-sided diskette) is selected when SS=0. The second (top) side is selected when SS=1. */
|
||||||
uint8 dp; /* has shared use. During stepping operations, DP=O specifies a step out and DP=1 specifies a step in. During write operations, write procompensation is invoked if and only if DP=1. */
|
uint8 dp; /* has shared use. During stepping operations, DP=O specifies a step out and DP=1 specifies a step in. During write operations, write precompensation is invoked if and only if DP=1. */
|
||||||
uint8 st; /* controls the level of the head step signal to the disk drives. */
|
uint8 st; /* controls the level of the head step signal to the disk drives. */
|
||||||
uint8 pst; /* value of step signal (st) on previous order */
|
uint8 pst; /* value of step signal (st) on previous order */
|
||||||
uint8 ds; /* is the drive select field, encoded as follows: */
|
uint8 ds; /* is the drive select field, encoded as follows: */
|
||||||
|
@ -270,7 +270,7 @@ static DEBTAB mdsad_dt[] = {
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "ORDERS", ORDERS_MSG, "Orders messages" },
|
{ "ORDERS", ORDERS_MSG, "Orders messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -33,11 +33,11 @@
|
||||||
The MM-103 uses the Motorola MC6860L digital modem chip. This device does
|
The MM-103 uses the Motorola MC6860L digital modem chip. This device does
|
||||||
not have the ability to emulate the modulation and demodulation functions
|
not have the ability to emulate the modulation and demodulation functions
|
||||||
or the ability to connect to a phone line. All modem features, such as
|
or the ability to connect to a phone line. All modem features, such as
|
||||||
switch hook, dialtone detection, and dialing, are emulated in such a way
|
switch hook, dial tone detection, and dialing, are emulated in such a way
|
||||||
that most software written for the MM-103 should function in some useful
|
that most software written for the MM-103 should function in some useful
|
||||||
fashion.
|
fashion.
|
||||||
|
|
||||||
To provide any useful funcationality, this device need to be attached to
|
To provide any useful functionality, this device need to be attached to
|
||||||
a socket or serial port. Enter "HELP PMMI" at the "simh>" prompt for
|
a socket or serial port. Enter "HELP PMMI" at the "simh>" prompt for
|
||||||
additional information.
|
additional information.
|
||||||
*/
|
*/
|
||||||
|
@ -266,7 +266,7 @@ static t_stat pmmi_reset(DEVICE *dptr)
|
||||||
/* Set DEVICE for this UNIT */
|
/* Set DEVICE for this UNIT */
|
||||||
dptr->units[0].dptr = dptr;
|
dptr->units[0].dptr = dptr;
|
||||||
|
|
||||||
/* Enable TMXR modem control passthru */
|
/* Enable TMXR modem control passthrough */
|
||||||
tmxr_set_modem_control_passthru(pmmi_ctx.tmxr);
|
tmxr_set_modem_control_passthru(pmmi_ctx.tmxr);
|
||||||
|
|
||||||
/* Reset status registers */
|
/* Reset status registers */
|
||||||
|
@ -571,7 +571,7 @@ static t_stat pmmi_config_line(UNIT *uptr)
|
||||||
** to run irrelevant, old software, that use TMXR and
|
** to run irrelevant, old software, that use TMXR and
|
||||||
** rely on some semblance of timing (Remote CP/M, BYE,
|
** rely on some semblance of timing (Remote CP/M, BYE,
|
||||||
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
** RBBS, PCGET/PUT, Xmodem, MEX, Modem7, or most
|
||||||
** other communications software), on contemprary
|
** other communications software), on contemporary
|
||||||
** hardware.
|
** hardware.
|
||||||
**
|
**
|
||||||
** Serial ports are self-limiting and sockets will run
|
** Serial ports are self-limiting and sockets will run
|
||||||
|
@ -626,8 +626,8 @@ static int32 pmmi_reg0(int32 io, int32 data)
|
||||||
} else { pmmi_ctx.oreg0 = data; /* Set UART configuration */
|
} else { pmmi_ctx.oreg0 = data; /* Set UART configuration */
|
||||||
pmmi_config_line(&pmmi_dev.units[0]);
|
pmmi_config_line(&pmmi_dev.units[0]);
|
||||||
|
|
||||||
if (data & PMMI_SH) { /* If off-hook, clear dialtone bit (active low) */
|
if (data & PMMI_SH) { /* If off-hook, clear dial tone bit (active low) */
|
||||||
pmmi_ctx.dtimer = sim_os_msec() + 500; /* Dialtone in 500ms */
|
pmmi_ctx.dtimer = sim_os_msec() + 500; /* Dial tone in 500ms */
|
||||||
if (pmmi_ctx.oreg0 & PMMI_SH) {
|
if (pmmi_ctx.oreg0 & PMMI_SH) {
|
||||||
pmmi_ctx.ireg2 &= ~PMMI_AP; /* Answer Phone Bit (active low) */
|
pmmi_ctx.ireg2 &= ~PMMI_AP; /* Answer Phone Bit (active low) */
|
||||||
}
|
}
|
||||||
|
|
|
@ -190,7 +190,7 @@ static REG scp300f_reg[] = {
|
||||||
{ HRDATAD(SPIC_OCW2, scp300f_pic[SLAVE_PIC].OCW2, 8, "Slave OCW2 register"), },
|
{ HRDATAD(SPIC_OCW2, scp300f_pic[SLAVE_PIC].OCW2, 8, "Slave OCW2 register"), },
|
||||||
{ HRDATAD(SPIC_OCW3, scp300f_pic[SLAVE_PIC].OCW3, 8, "Slave OCW3 register"), },
|
{ HRDATAD(SPIC_OCW3, scp300f_pic[SLAVE_PIC].OCW3, 8, "Slave OCW3 register"), },
|
||||||
|
|
||||||
{ HRDATAD(9513_HUND, data9513[0], 8, "9513 Hundreths"), },
|
{ HRDATAD(9513_HUND, data9513[0], 8, "9513 Hundredths"), },
|
||||||
{ HRDATAD(9513_SS, data9513[1], 8, "9513 Seconds"), },
|
{ HRDATAD(9513_SS, data9513[1], 8, "9513 Seconds"), },
|
||||||
{ HRDATAD(9513_MM, data9513[2], 8, "9513 Minutes"), },
|
{ HRDATAD(9513_MM, data9513[2], 8, "9513 Minutes"), },
|
||||||
{ HRDATAD(9513_HH, data9513[3], 8, "9513 Hours"), },
|
{ HRDATAD(9513_HH, data9513[3], 8, "9513 Hours"), },
|
||||||
|
@ -709,7 +709,7 @@ static uint8 SCP300F_Write(const uint32 Addr, uint8 cData)
|
||||||
|
|
||||||
switch(Addr & SCP300F_IO_MASK) {
|
switch(Addr & SCP300F_IO_MASK) {
|
||||||
case SCP300F_SPIC_0:
|
case SCP300F_SPIC_0:
|
||||||
sel_pic = SLAVE_PIC; /* intentional falltrough */
|
sel_pic = SLAVE_PIC; /* intentional fallthrough */
|
||||||
case SCP300F_MPIC_0:
|
case SCP300F_MPIC_0:
|
||||||
if (cData & 0x10) {
|
if (cData & 0x10) {
|
||||||
sim_debug(PIC_MSG, &scp300f_dev, "SCP300F: " ADDRESS_FORMAT
|
sim_debug(PIC_MSG, &scp300f_dev, "SCP300F: " ADDRESS_FORMAT
|
||||||
|
|
|
@ -483,7 +483,7 @@ static uint8 SS1_Write(const uint32 Addr, uint8 cData)
|
||||||
|
|
||||||
switch(Addr & 0x0F) {
|
switch(Addr & 0x0F) {
|
||||||
case SS1_S8259_L:
|
case SS1_S8259_L:
|
||||||
sel_pic = SLAVE_PIC; /* intentional falltrough */
|
sel_pic = SLAVE_PIC; /* intentional fallthrough */
|
||||||
case SS1_M8259_L:
|
case SS1_M8259_L:
|
||||||
if(cData & 0x10) {
|
if(cData & 0x10) {
|
||||||
sim_debug(PIC_MSG, &ss1_dev, "SS1: " ADDRESS_FORMAT
|
sim_debug(PIC_MSG, &ss1_dev, "SS1: " ADDRESS_FORMAT
|
||||||
|
|
|
@ -332,7 +332,7 @@ static DEBTAB tarbell_dt[] = {
|
||||||
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
{ "WRITE", WR_DATA_MSG, "Write messages" },
|
||||||
{ "STATUS", STATUS_MSG, "Status messages" },
|
{ "STATUS", STATUS_MSG, "Status messages" },
|
||||||
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
{ "RDDETAIL", RD_DATA_DETAIL_MSG, "Read detail messages" },
|
||||||
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messags" },
|
{ "WRDETAIL", WR_DATA_DETAIL_MSG, "Write detail messages" },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1091,7 +1091,7 @@ static uint8 Do1793Command(uint8 cCommand)
|
||||||
sdata.raw[wd179x_info->fdc_dataindex] = wd179x_info->fdc_data;
|
sdata.raw[wd179x_info->fdc_dataindex] = wd179x_info->fdc_data;
|
||||||
|
|
||||||
if (wd179x_info->external_fifo_len) {
|
if (wd179x_info->external_fifo_len) {
|
||||||
/* For external FIFO, write the sector immediately, as the sofware pre-fills a FIFO, which is then read out into the FDC using DRQ */
|
/* For external FIFO, write the sector immediately, as the software pre-fills a FIFO, which is then read out into the FDC using DRQ */
|
||||||
wd179x_info->fdc_status &= ~(WD179X_STAT_DRQ | WD179X_STAT_BUSY); /* Clear DRQ, BUSY */
|
wd179x_info->fdc_status &= ~(WD179X_STAT_DRQ | WD179X_STAT_BUSY); /* Clear DRQ, BUSY */
|
||||||
wd179x_info->drq = 0;
|
wd179x_info->drq = 0;
|
||||||
wd179x_info->intrq = 1;
|
wd179x_info->intrq = 1;
|
||||||
|
|
|
@ -75,7 +75,7 @@ endif()
|
||||||
|
|
||||||
## SIMH Version variables:
|
## SIMH Version variables:
|
||||||
set(SIMH_VERSION_MAJOR 4)
|
set(SIMH_VERSION_MAJOR 4)
|
||||||
set(SIMH_VERSION_MINOR 0)
|
set(SIMH_VERSION_MINOR 1)
|
||||||
set(SIMH_VERSION_PATCH 0)
|
set(SIMH_VERSION_PATCH 0)
|
||||||
set(SIMH_VERSION "${SIMH_VERSION_MAJOR}.${SIMH_VERSION_MINOR}.${SIMH_VERSION_PATCH}")
|
set(SIMH_VERSION "${SIMH_VERSION_MAJOR}.${SIMH_VERSION_MINOR}.${SIMH_VERSION_PATCH}")
|
||||||
|
|
||||||
|
|
|
@ -105,9 +105,9 @@
|
||||||
#define RK_NUMTR (RK_NUMCY * RK_NUMSF) /* tracks/drive */
|
#define RK_NUMTR (RK_NUMCY * RK_NUMSF) /* tracks/drive */
|
||||||
#define RK_NUMDR 8 /* drives/controller */
|
#define RK_NUMDR 8 /* drives/controller */
|
||||||
#define RK_M_NUMDR 07
|
#define RK_M_NUMDR 07
|
||||||
#define RK_SIZE (RK_NUMCY * RK_NUMSF * RK_NUMSC * RK_NUMWD)
|
#define RK_NUMBL (RK_NUMTR * RK_NUMSC)
|
||||||
|
#define RK_SIZE (RK_NUMBL * RK_NUMWD) /* words/drive */
|
||||||
#define RK_RSRVSEC (3 * RK_NUMSF * RK_NUMSC) /* reserved (unused) disk area */
|
#define RK_RSRVSEC (3 * RK_NUMSF * RK_NUMSC) /* reserved (unused) disk area */
|
||||||
/* words/drive */
|
|
||||||
#define RK_CTLI 1 /* controller int */
|
#define RK_CTLI 1 /* controller int */
|
||||||
#define RK_SCPI(x) (2u << (x)) /* drive int */
|
#define RK_SCPI(x) (2u << (x)) /* drive int */
|
||||||
#define RK_MAXFR (1 << 16) /* max transfer */
|
#define RK_MAXFR (1 << 16) /* max transfer */
|
||||||
|
@ -122,7 +122,7 @@ struct drvtyp {
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct drvtyp drv_tab[] = {
|
static struct drvtyp drv_tab[] = {
|
||||||
{ RK_NUMSC, RK_NUMSF, RK_NUMCY, RK_SIZE, "RK05" },
|
{ RK_NUMSC, RK_NUMSF, RK_NUMCY, RK_NUMBL, "RK05" },
|
||||||
{ 0 }
|
{ 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -294,7 +294,7 @@ BITFIELD *rk_reg_bits[] = {
|
||||||
rk_ba_bits,
|
rk_ba_bits,
|
||||||
rk_da_bits,
|
rk_da_bits,
|
||||||
NULL,
|
NULL,
|
||||||
NULL,
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Debug detail levels */
|
/* Debug detail levels */
|
||||||
|
@ -324,6 +324,7 @@ int32 last_drv = 0; /* last r/w drive */
|
||||||
int32 rk_stopioe = 1; /* stop on error */
|
int32 rk_stopioe = 1; /* stop on error */
|
||||||
int32 rk_swait = 10; /* seek time */
|
int32 rk_swait = 10; /* seek time */
|
||||||
int32 rk_rwait = 10; /* rotate time */
|
int32 rk_rwait = 10; /* rotate time */
|
||||||
|
static int32 not_impl = 0; /* placeholder for unused regs */
|
||||||
|
|
||||||
const char *rk_regnames[] = {
|
const char *rk_regnames[] = {
|
||||||
"RKDS",
|
"RKDS",
|
||||||
|
@ -333,7 +334,7 @@ const char *rk_regnames[] = {
|
||||||
"RKBA",
|
"RKBA",
|
||||||
"RKDA",
|
"RKDA",
|
||||||
"unused",
|
"unused",
|
||||||
"RKDB",
|
"RKDB"
|
||||||
};
|
};
|
||||||
|
|
||||||
int32 *rk_regs[] = {
|
int32 *rk_regs[] = {
|
||||||
|
@ -343,6 +344,8 @@ int32 *rk_regs[] = {
|
||||||
&rkwc,
|
&rkwc,
|
||||||
&rkba,
|
&rkba,
|
||||||
&rkda,
|
&rkda,
|
||||||
|
¬_impl,
|
||||||
|
¬_impl
|
||||||
};
|
};
|
||||||
|
|
||||||
t_stat rk_rd (int32 *data, int32 PA, int32 access);
|
t_stat rk_rd (int32 *data, int32 PA, int32 access);
|
||||||
|
@ -607,7 +610,7 @@ if (func == RKCS_CTLRESET) { /* control reset? */
|
||||||
rker = rker & ~RKER_SOFT; /* clear soft errors */
|
rker = rker & ~RKER_SOFT; /* clear soft errors */
|
||||||
if (rker == 0) /* redo summary */
|
if (rker == 0) /* redo summary */
|
||||||
rkcs = rkcs & ~RKCS_ERR;
|
rkcs = rkcs & ~RKCS_ERR;
|
||||||
rkcs = rkcs & ~RKCS_SCP; /* clear sch compl*/
|
rkcs = rkcs & ~RKCS_SCP; /* clear sch compl */
|
||||||
rk_clr_done (); /* clear done */
|
rk_clr_done (); /* clear done */
|
||||||
last_drv = GET_DRIVE (rkda); /* get drive no */
|
last_drv = GET_DRIVE (rkda); /* get drive no */
|
||||||
uptr = rk_dev.units + last_drv; /* select unit */
|
uptr = rk_dev.units + last_drv; /* select unit */
|
||||||
|
@ -750,7 +753,7 @@ if (wc && (err == 0)) { /* seek ok? */
|
||||||
else { /* normal store */
|
else { /* normal store */
|
||||||
if ((t = MAP_WRW (ma, wc << 1, rkxb))) { /* store buf */
|
if ((t = MAP_WRW (ma, wc << 1, rkxb))) { /* store buf */
|
||||||
rker = rker | RKER_NXM; /* NXM? set flag */
|
rker = rker | RKER_NXM; /* NXM? set flag */
|
||||||
wc = wc - t; /* adj wd cnt */
|
wc = wc - (t >> 1); /* adj wd cnt */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break; /* end read */
|
break; /* end read */
|
||||||
|
@ -767,14 +770,14 @@ if (wc && (err == 0)) { /* seek ok? */
|
||||||
else { /* normal fetch */
|
else { /* normal fetch */
|
||||||
if ((t = MAP_RDW (ma, wc << 1, rkxb))) { /* get buf */
|
if ((t = MAP_RDW (ma, wc << 1, rkxb))) { /* get buf */
|
||||||
rker = rker | RKER_NXM; /* NXM? set flg */
|
rker = rker | RKER_NXM; /* NXM? set flg */
|
||||||
wc = wc - t; /* adj wd cnt */
|
wc = wc - (t >> 1); /* adj wd cnt */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (wc) { /* any xfer? */
|
if (wc) { /* any xfer? */
|
||||||
awc = (wc + (RK_NUMWD - 1)) & ~(RK_NUMWD - 1); /* clr to */
|
awc = (wc + (RK_NUMWD - 1)) & ~(RK_NUMWD - 1); /* clr to */
|
||||||
for (i = wc; i < awc; i++) /* end of blk */
|
for (i = wc; i < awc; i++) /* end of blk */
|
||||||
rkxb[i] = 0;
|
rkxb[i] = 0;
|
||||||
sim_disk_data_trace (uptr, (uint8 *)rkxb, da/RK_NUMWD, awc, "sim_disk_wrsect", RKDEB_DAT & dptr->dctrl, RKDEB_OPS);
|
sim_disk_data_trace (uptr, (uint8 *)rkxb, da/RK_NUMWD, awc*sizeof(*rkxb), "sim_disk_wrsect", RKDEB_DAT & dptr->dctrl, RKDEB_OPS);
|
||||||
err = sim_disk_wrsect (uptr, da/RK_NUMWD, (uint8 *)rkxb, NULL, awc/RK_NUMWD);
|
err = sim_disk_wrsect (uptr, da/RK_NUMWD, (uint8 *)rkxb, NULL, awc/RK_NUMWD);
|
||||||
}
|
}
|
||||||
break; /* end write */
|
break; /* end write */
|
||||||
|
@ -817,7 +820,7 @@ if ((uptr->FUNC == RKCS_READ) && (rkcs & RKCS_FMT)) /* read format? */
|
||||||
else da = da + wc + (RK_NUMWD - 1); /* count by words */
|
else da = da + wc + (RK_NUMWD - 1); /* count by words */
|
||||||
track = (da / RK_NUMWD) / RK_NUMSC;
|
track = (da / RK_NUMWD) / RK_NUMSC;
|
||||||
sect = (da / RK_NUMWD) % RK_NUMSC;
|
sect = (da / RK_NUMWD) % RK_NUMSC;
|
||||||
uptr->CYL = track / RK_NUMSF; /* update position */
|
uptr->CYL = track / RK_NUMSF;
|
||||||
rkda = (rkda & RKDA_DRIVE) | (track << RKDA_V_TRACK) | (sect << RKDA_V_SECT);
|
rkda = (rkda & RKDA_DRIVE) | (track << RKDA_V_TRACK) | (sect << RKDA_V_SECT);
|
||||||
rk_set_done (0);
|
rk_set_done (0);
|
||||||
|
|
||||||
|
@ -919,13 +922,9 @@ return auto_config (0, 0);
|
||||||
t_stat rk_attach (UNIT *uptr, CONST char *cptr)
|
t_stat rk_attach (UNIT *uptr, CONST char *cptr)
|
||||||
{
|
{
|
||||||
t_stat r;
|
t_stat r;
|
||||||
static const char *drives[] = {"RK05", NULL};
|
|
||||||
|
|
||||||
r = sim_disk_attach_ex2 (uptr, cptr, RK_NUMWD * sizeof (uint16),
|
r = sim_disk_attach_ex2 (uptr, cptr, RK_NUMWD * sizeof (uint16),
|
||||||
sizeof (uint16), TRUE, 0,
|
sizeof (uint16), TRUE, 0,
|
||||||
"RK05", 0, 0,
|
"RK05", 0, 0, NULL, RK_RSRVSEC);
|
||||||
(uptr->flags & UNIT_NOAUTO) ? NULL: drives,
|
|
||||||
RK_RSRVSEC);
|
|
||||||
if (r != SCPE_OK) /* error? */
|
if (r != SCPE_OK) /* error? */
|
||||||
return r;
|
return r;
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
|
|
|
@ -122,6 +122,12 @@ extern int32 MMR2;
|
||||||
#error "Assertion failure: RQ_NUMCT exceeds 4"
|
#error "Assertion failure: RQ_NUMCT exceeds 4"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined (VAX_610)
|
||||||
|
#define MICROVAX1 1
|
||||||
|
#else
|
||||||
|
#define MICROVAX1 0
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "pdp11_uqssp.h"
|
#include "pdp11_uqssp.h"
|
||||||
#include "pdp11_mscp.h"
|
#include "pdp11_mscp.h"
|
||||||
#include "sim_disk.h"
|
#include "sim_disk.h"
|
||||||
|
@ -137,13 +143,7 @@ extern int32 MMR2;
|
||||||
#define RQ_SH_UN 010 /* show unit q's */
|
#define RQ_SH_UN 010 /* show unit q's */
|
||||||
#define RQ_SH_ALL 017 /* show all */
|
#define RQ_SH_ALL 017 /* show all */
|
||||||
|
|
||||||
#define RQ_CLASS 1 /* RQ class */
|
#define RQ_CLASS 1 /* RQ class: Mass storage controllers */
|
||||||
#define RQU_UQPM 6 /* UB port model */
|
|
||||||
#define RQQ_UQPM 19 /* QB port model */
|
|
||||||
#define RQ_UQPM (UNIBUS? RQU_UQPM: RQQ_UQPM)
|
|
||||||
#define RQU_MODEL 6 /* UB MSCP ctrl model (UDA50A) */
|
|
||||||
#define RQQ_MODEL 19 /* QB MSCP ctrl model (RQDX3) */
|
|
||||||
#define RQ_MODEL (UNIBUS? RQU_MODEL: RQQ_MODEL)
|
|
||||||
#define RQ_HVER 1 /* hardware version */
|
#define RQ_HVER 1 /* hardware version */
|
||||||
#define RQ_SVER 3 /* software version */
|
#define RQ_SVER 3 /* software version */
|
||||||
#define RQ_DHTMO 60 /* def host timeout */
|
#define RQ_DHTMO 60 /* def host timeout */
|
||||||
|
@ -172,6 +172,7 @@ extern int32 MMR2;
|
||||||
#define unit_plug u4 /* drive unit plug value */
|
#define unit_plug u4 /* drive unit plug value */
|
||||||
#define io_status u5 /* io status from callback */
|
#define io_status u5 /* io status from callback */
|
||||||
#define io_complete u6 /* io completion flag */
|
#define io_complete u6 /* io completion flag */
|
||||||
|
/* we can re-use filebuf because we don't set UNIT_BUFABLE in flags */
|
||||||
#define rqxb filebuf /* xfer buffer */
|
#define rqxb filebuf /* xfer buffer */
|
||||||
#define RQ_RMV(u) ((drv_tab[GET_DTYPE (u->flags)].flgs & RQDF_RMV)? \
|
#define RQ_RMV(u) ((drv_tab[GET_DTYPE (u->flags)].flgs & RQDF_RMV)? \
|
||||||
UF_RMV: 0)
|
UF_RMV: 0)
|
||||||
|
@ -752,31 +753,35 @@ x RA73 70(+1) 21 2667+ 21 1 ? 3920490
|
||||||
|
|
||||||
// AFAIK the UNIBUS KLESI and QBUS KLESI used the same controller type ...
|
// AFAIK the UNIBUS KLESI and QBUS KLESI used the same controller type ...
|
||||||
#define KLESI_CTYPE 1 // RC25 controller (UNIBUS and QBUS both)
|
#define KLESI_CTYPE 1 // RC25 controller (UNIBUS and QBUS both)
|
||||||
#define KLESI_UQPM 1
|
#define KLESI_UQPM 3
|
||||||
#define KLESI_MODEL 1
|
#define KLESI_MODEL 3
|
||||||
|
|
||||||
#define RUX50_CTYPE 2 // UNIBUS RX50-only controller
|
#define RUX50_CTYPE 2 // UNIBUS RX50-only controller
|
||||||
#define RUX50_UQPM 2
|
#define RUX50_UQPM 10 // this should be 10 according to the MSCP spec
|
||||||
#define RUX50_MODEL 2
|
#define RUX50_MODEL 10
|
||||||
|
|
||||||
#define UDA50_CTYPE 3 // UNIBUS SDI (RAxx) controller
|
#define UDA50_CTYPE 3 // UNIBUS SDI (RAxx) controller
|
||||||
#define UDA50_UQPM 6
|
#define UDA50_UQPM 6 // really type of UDA50A; UDA50 is 2
|
||||||
#define UDA50_MODEL 6
|
#define UDA50_MODEL 6
|
||||||
|
|
||||||
#define RQDX3_CTYPE 4 // QBUS RX50/RDxx controller
|
#define RQDX1_CTYPE 4 // QBUS RX50/RDxx controller,
|
||||||
|
#define RQDX1_UQPM 7 // first version; RQDX2 has the same id
|
||||||
|
#define RQDX1_MODEL 7
|
||||||
|
|
||||||
|
#define RQDX3_CTYPE 5 // QBUS RX50/RDxx controller
|
||||||
#define RQDX3_UQPM 19
|
#define RQDX3_UQPM 19
|
||||||
#define RQDX3_MODEL 19
|
#define RQDX3_MODEL 19
|
||||||
|
|
||||||
#define KDA50_CTYPE 5 // QBUS SDI (RAxx) controller
|
#define KDA50_CTYPE 6 // QBUS SDI (RAxx) controller
|
||||||
#define KDA50_UQPM 13
|
#define KDA50_UQPM 13 // KDA50-Q
|
||||||
#define KDA50_MODEL 13
|
#define KDA50_MODEL 13
|
||||||
|
|
||||||
#define KRQ50_CTYPE 6 // QBUS RRD40/50 CDROM controller
|
#define KRQ50_CTYPE 7 // QBUS RRD40/50 CDROM controller
|
||||||
#define KRQ50_UQPM 16
|
#define KRQ50_UQPM 16
|
||||||
#define KRQ50_MODEL 16
|
#define KRQ50_MODEL 16
|
||||||
|
|
||||||
#define KRU50_CTYPE 7 // UNIBUS RRD40/50 CDROM controller
|
#define KRU50_CTYPE 8 // UNIBUS RRD40/50 CDROM controller
|
||||||
#define KRU50_UQPM 26
|
#define KRU50_UQPM 26 // unassigned in appendix C
|
||||||
#define KRU50_MODEL 26
|
#define KRU50_MODEL 26
|
||||||
|
|
||||||
struct drvtyp {
|
struct drvtyp {
|
||||||
|
@ -883,6 +888,7 @@ static struct ctlrtyp ctlr_tab[] = {
|
||||||
RQ_CTLR (KLESI),
|
RQ_CTLR (KLESI),
|
||||||
RQ_CTLR (RUX50),
|
RQ_CTLR (RUX50),
|
||||||
RQ_CTLR (UDA50),
|
RQ_CTLR (UDA50),
|
||||||
|
RQ_CTLR (RQDX1),
|
||||||
RQ_CTLR (RQDX3),
|
RQ_CTLR (RQDX3),
|
||||||
RQ_CTLR (KDA50),
|
RQ_CTLR (KDA50),
|
||||||
RQ_CTLR (KRQ50),
|
RQ_CTLR (KRQ50),
|
||||||
|
@ -1119,10 +1125,12 @@ MTAB rq_mod[] = {
|
||||||
NULL, &rq_show_ctrl, NULL, "Display all unit queues" },
|
NULL, &rq_show_ctrl, NULL, "Display all unit queues" },
|
||||||
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, RQ_SH_ALL, "ALL", NULL,
|
{ MTAB_XTD|MTAB_VDV|MTAB_NMO, RQ_SH_ALL, "ALL", NULL,
|
||||||
NULL, &rq_show_ctrl, NULL, "Display complete controller state" },
|
NULL, &rq_show_ctrl, NULL, "Display complete controller state" },
|
||||||
|
{ MTAB_XTD|MTAB_VDV, RQDX1_CTYPE, NULL, "RQDX1",
|
||||||
|
&rq_set_ctype, NULL, NULL, "Set RQDX1/2 (QBUS RX50/RDnn) Controller Type" },
|
||||||
{ MTAB_XTD|MTAB_VDV, RQDX3_CTYPE, NULL, "RQDX3",
|
{ MTAB_XTD|MTAB_VDV, RQDX3_CTYPE, NULL, "RQDX3",
|
||||||
&rq_set_ctype, NULL, NULL, "Set RQDX3 (QBUS RX50/RDnn) Controller Type" },
|
&rq_set_ctype, NULL, NULL, "Set RQDX3 (QBUS RX50/RDnn) Controller Type" },
|
||||||
{ MTAB_XTD|MTAB_VDV, UDA50_CTYPE, NULL, "UDA50",
|
{ MTAB_XTD|MTAB_VDV, UDA50_CTYPE, NULL, "UDA50",
|
||||||
&rq_set_ctype, NULL, NULL, "Set UDA50 (UNIBUS SDI RAnn) Controller Type" },
|
&rq_set_ctype, NULL, NULL, "Set UDA50A (UNIBUS SDI RAnn) Controller Type" },
|
||||||
{ MTAB_XTD|MTAB_VDV, KDA50_CTYPE, NULL, "KDA50",
|
{ MTAB_XTD|MTAB_VDV, KDA50_CTYPE, NULL, "KDA50",
|
||||||
&rq_set_ctype, NULL, NULL, "Set KDA50 (QBUS SDI RAnn) Controller Type" },
|
&rq_set_ctype, NULL, NULL, "Set KDA50 (QBUS SDI RAnn) Controller Type" },
|
||||||
{ MTAB_XTD|MTAB_VDV, KRQ50_CTYPE, NULL, "KRQ50",
|
{ MTAB_XTD|MTAB_VDV, KRQ50_CTYPE, NULL, "KRQ50",
|
||||||
|
@ -3099,7 +3107,8 @@ if (cidx < 0) /* not found??? */
|
||||||
cp = rq_ctxmap[cidx]; /* get context */
|
cp = rq_ctxmap[cidx]; /* get context */
|
||||||
cp->cnum = cidx; /* init index */
|
cp->cnum = cidx; /* init index */
|
||||||
if (cp->ctype == DEFAULT_CTYPE)
|
if (cp->ctype == DEFAULT_CTYPE)
|
||||||
cp->ctype = (UNIBUS? UDA50_CTYPE : RQDX3_CTYPE);
|
cp->ctype = (UNIBUS ? UDA50_CTYPE :
|
||||||
|
MICROVAX1 ? RQDX1_CTYPE : RQDX3_CTYPE);
|
||||||
|
|
||||||
if (!plugs_inited ) {
|
if (!plugs_inited ) {
|
||||||
#if !defined (VM_VAX)
|
#if !defined (VM_VAX)
|
||||||
|
@ -3418,9 +3427,9 @@ fprintf (st, "UDA50 MSCP Disk Controller (%s)\n\n", dptr->name);
|
||||||
fprintf (st, "The simulator implements four MSCP disk controllers, RQ, RQB, RQC, RQD.\n");
|
fprintf (st, "The simulator implements four MSCP disk controllers, RQ, RQB, RQC, RQD.\n");
|
||||||
fprintf (st, "Initially, RQB, RQC, and RQD are disabled. Each RQ controller simulates\n");
|
fprintf (st, "Initially, RQB, RQC, and RQD are disabled. Each RQ controller simulates\n");
|
||||||
fprintf (st, "an MSCP disk controller with four drives. The MSCP controller type can be\n");
|
fprintf (st, "an MSCP disk controller with four drives. The MSCP controller type can be\n");
|
||||||
fprintf (st, "specified as one of RQDX3, UDA50, KDA50, KRQ50, KLESI or RUX50. RQ options\n");
|
fprintf (st, "specified as one of RQDX1, RQDX3, UDA50, KDA50, KRQ50, KLESI or RUX50.\n");
|
||||||
fprintf (st, "include the ability to set units write enabled or write locked, and to set\n");
|
fprintf (st, "RQ options include the ability to set units write enabled or write locked,\n");
|
||||||
fprintf (st, "the drive type to one of many disk types:\n");
|
fprintf (st, "and to set the drive type to one of many disk types:\n");
|
||||||
fprint_set_help (st, dptr);
|
fprint_set_help (st, dptr);
|
||||||
fprintf (st, "set RQn RAUSER{=n} Set disk type to RA82 with n MB's\n");
|
fprintf (st, "set RQn RAUSER{=n} Set disk type to RA82 with n MB's\n");
|
||||||
fprintf (st, " (1MB is 1000000 bytes)\n");
|
fprintf (st, " (1MB is 1000000 bytes)\n");
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
- [Why CMake?](#why-cmake)
|
- [Why CMake?](#why-cmake)
|
||||||
- [Before You Begin Building...](#before-you-begin-building)
|
- [Before You Begin Building...](#before-you-begin-building)
|
||||||
- [Toolchains and Tools](#toolchains-and-tools)
|
- [Toolchains and Tools](#toolchains-and-tools)
|
||||||
- [Ninja: "file recompation: Permission denied"](#ninja-file-recompation-permission-denied)
|
- [Ninja: "failed recompaction: Permission denied"](#ninja-file-recompation-permission-denied)
|
||||||
- [Windows XP-compatible/Server 2003 binaries](#windows-xp-compatibleserver-2003-binaries)
|
- [Windows XP-compatible/Server 2003 binaries](#windows-xp-compatibleserver-2003-binaries)
|
||||||
- [Feature Libraries](#feature-libraries)
|
- [Feature Libraries](#feature-libraries)
|
||||||
- [Linux, macOS and MinGW-w64](#linux-macos-and-mingw-w64)
|
- [Linux, macOS and MinGW-w64](#linux-macos-and-mingw-w64)
|
||||||
|
@ -160,7 +160,7 @@ Before you begin building the simulators, you need the following:
|
||||||
Unix Makefiles and Visual Studio's `msbuild`.
|
Unix Makefiles and Visual Studio's `msbuild`.
|
||||||
|
|
||||||
|
|
||||||
#### Ninja: "file recompation: Permission denied"
|
#### Ninja: "failed recompaction: Permission denied"
|
||||||
|
|
||||||
This is a long-standing issue with [Ninja][ninja] on Windows when `ninja` is
|
This is a long-standing issue with [Ninja][ninja] on Windows when `ninja` is
|
||||||
recursively invoked. You are very likely to encounter this error message when
|
recursively invoked. You are very likely to encounter this error message when
|
||||||
|
@ -547,7 +547,7 @@ or video support.
|
||||||
--cppcheck Enable cppcheck static code analysis rules
|
--cppcheck Enable cppcheck static code analysis rules
|
||||||
|
|
||||||
--cpack_suffix Specify CPack's packaging suffix, e.g., "ubuntu-22.04"
|
--cpack_suffix Specify CPack's packaging suffix, e.g., "ubuntu-22.04"
|
||||||
to produce the "simh-4.0.0-ubuntu-22.04.deb" Debian
|
to produce the "simh-4.1.0-ubuntu-22.04.deb" Debian
|
||||||
package.
|
package.
|
||||||
|
|
||||||
--verbose Turn on verbose build output
|
--verbose Turn on verbose build output
|
||||||
|
@ -1035,7 +1035,7 @@ within the IDE. The walkthrough provides directions for VS 2022 and VS 2019.
|
||||||
on the keyboard, to start the dependecy feature library superbuild.
|
on the keyboard, to start the dependecy feature library superbuild.
|
||||||
|
|
||||||
- When all dependency feature libraries have been built, the build process
|
- When all dependency feature libraries have been built, the build process
|
||||||
__will__ unexpectedly terminate with a _"file recompation: Permission
|
__will__ unexpectedly terminate with a _"failed recompaction: Permission
|
||||||
denied"_ error (see [this `ninja` note](#ninja-file-recompation-permission-denied).)
|
denied"_ error (see [this `ninja` note](#ninja-file-recompation-permission-denied).)
|
||||||
|
|
||||||
Choose `Delete Cache and Reconfigure` from the `Project` menu. This will
|
Choose `Delete Cache and Reconfigure` from the `Project` menu. This will
|
||||||
|
|
|
@ -29,7 +29,7 @@ rem
|
||||||
rem Everything implicitly requires BUILD to also be set to have
|
rem Everything implicitly requires BUILD to also be set to have
|
||||||
rem any meaning, it always gets set.
|
rem any meaning, it always gets set.
|
||||||
set _X_BUILD=BUILD
|
set _X_BUILD=BUILD
|
||||||
set _X_REQUIRED_WINDOWS_BUILD=20220119
|
set _X_REQUIRED_WINDOWS_BUILD=20230621
|
||||||
call :FindVCVersion _VC_VER
|
call :FindVCVersion _VC_VER
|
||||||
|
|
||||||
set _PDB=%~dpn1.pdb
|
set _PDB=%~dpn1.pdb
|
||||||
|
|
82
appveyor.yml
82
appveyor.yml
|
@ -13,14 +13,15 @@ environment:
|
||||||
## The matrix is ordered by relative popularity/priority:
|
## The matrix is ordered by relative popularity/priority:
|
||||||
##-
|
##-
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu
|
|
||||||
SIMH_BUILD_FLAVOR: ninja
|
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
||||||
SIMH_BUILD_FLAVOR: vs2022
|
SIMH_BUILD_FLAVOR: vs2022
|
||||||
|
## Static library support available in this vcpkg install.
|
||||||
|
VCPKG_ROOT: C:\Tools\vcpkg
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
|
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
|
||||||
SIMH_BUILD_FLAVOR: vs2019
|
SIMH_BUILD_FLAVOR: vs2019
|
||||||
|
## Static library support available in this vcpkg install.
|
||||||
|
VCPKG_ROOT: C:\Tools\vcpkg
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
|
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
|
||||||
SIMH_BUILD_FLAVOR: vs2017
|
SIMH_BUILD_FLAVOR: vs2017
|
||||||
|
@ -28,32 +29,39 @@ environment:
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
||||||
SIMH_BUILD_FLAVOR: vs2022-xp
|
SIMH_BUILD_FLAVOR: vs2022-xp
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
|
## These Appveyor VM images exist, aren't strictly needed to build XP-compatible
|
||||||
SIMH_BUILD_FLAVOR: vs2019-xp
|
## executables.
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
|
||||||
SIMH_BUILD_FLAVOR: vs2017-xp
|
# SIMH_BUILD_FLAVOR: vs2019-xp
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
|
||||||
SIMH_BUILD_FLAVOR: vs2015
|
# SIMH_BUILD_FLAVOR: vs2017-xp
|
||||||
|
|
||||||
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
|
||||||
|
# SIMH_BUILD_FLAVOR: vs2015
|
||||||
|
|
||||||
|
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu
|
||||||
|
SIMH_BUILD_FLAVOR: ninja
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2004
|
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2004
|
||||||
SIMH_BUILD_FLAVOR: unix
|
SIMH_BUILD_FLAVOR: unix
|
||||||
|
|
||||||
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu1604
|
## Older image -- still needed?
|
||||||
SIMH_BUILD_FLAVOR: unix
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu1604
|
||||||
|
# SIMH_BUILD_FLAVOR: unix
|
||||||
|
|
||||||
## These images have cmake 3.12, which is too old. Could build if
|
## These images have cmake 3.12, which is too old. Could build if
|
||||||
## cmake were upgraded in the image in the before_build stanza, but
|
## cmake were upgraded in the image in the before_build stanza, but
|
||||||
## that subverts the purpose of the image.
|
## that subverts the image's purpose.
|
||||||
|
|
||||||
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013
|
||||||
# SIMH_BUILD_FLAVOR: vs2013
|
# SIMH_BUILD_FLAVOR: vs2013
|
||||||
#
|
#
|
||||||
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2012
|
||||||
# SIMH_BUILD_FLAVOR: vs2012
|
# SIMH_BUILD_FLAVOR: vs2012
|
||||||
#
|
#
|
||||||
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013
|
# - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2008
|
||||||
# SIMH_BUILD_FLAVOR: vs2008
|
# SIMH_BUILD_FLAVOR: vs2008
|
||||||
|
|
||||||
## - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
## - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
|
||||||
|
@ -89,11 +97,10 @@ build:
|
||||||
verbosity: minimal
|
verbosity: minimal
|
||||||
|
|
||||||
before_build:
|
before_build:
|
||||||
- ps: |
|
- cmd: |
|
||||||
if ($isWindows) {
|
if "%SIMH_BUILD_FLAVOR%"=="ninja" ( choco install ninja )
|
||||||
if (${env:SIMH_BUILD_FLAVOR} -eq "ninja") { choco install ninja; }
|
if not exist "cmake\dependencies" ( mkdir "cmake\dependencies" )
|
||||||
if (!(Test-Path -Path cmake\dependencies)) { New-Item -ItemType Directory -Path cmake\dependencies }
|
|
||||||
}
|
|
||||||
- sh: |
|
- sh: |
|
||||||
case "${APPVEYOR_BUILD_WORKER_IMAGE}" in
|
case "${APPVEYOR_BUILD_WORKER_IMAGE}" in
|
||||||
Ubuntu*)
|
Ubuntu*)
|
||||||
|
@ -112,17 +119,18 @@ before_build:
|
||||||
esac
|
esac
|
||||||
|
|
||||||
build_script:
|
build_script:
|
||||||
# Run the cmake-builder script all the way through: generate, build, test.
|
## Need to use cmd, per Appveyor support. PowerShell has issues with output.
|
||||||
- ps: |
|
## Specifically, when CMake prints the "old CMake version, won't CPack" warning,
|
||||||
if ($isWindows) {
|
## Appveyor terminates the build injudiciously. The workaround is cmd.
|
||||||
$ErrorActionPreference="Stop"
|
##
|
||||||
$WarningPreference="Continue"
|
## LTO works reliably on VS 2022 and 2019. Hangs while building SEL32 on VS 2017.
|
||||||
if (!([string]::IsNullOrEmpty($env:MINGW))) { $env:PATH=$(@(${env:MINGW}, ${env:PATH}) -join ";"); };
|
- cmd: |
|
||||||
cmake\cmake-builder.ps1 `
|
SETLOCAL EnableExtensions
|
||||||
-flavor ${env:SIMH_BUILD_FLAVOR} `
|
if not "%MINGW%"=="" ( set "PATH=%MINGW%;%PATH%" )
|
||||||
-config ${env:CONFIGURATION} `
|
if "%SIMH_BUILD_FLAVOR%"=="vs2022" set LTO=-lto
|
||||||
-lto -parallel -clean -notest -noinstall -verbose
|
if "%SIMH_BUILD_FLAVOR%"=="vs2019" set LTO=-lto
|
||||||
}
|
powershell -File .\cmake\cmake-builder.ps1 -flavor %SIMH_BUILD_FLAVOR% -config %CONFIGURATION% %LTO% -parallel -clean -notest -noinstall -verbose
|
||||||
|
|
||||||
- sh: |
|
- sh: |
|
||||||
case "${APPVEYOR_BUILD_WORKER_IMAGE}" in
|
case "${APPVEYOR_BUILD_WORKER_IMAGE}" in
|
||||||
Ubuntu1604)
|
Ubuntu1604)
|
||||||
|
@ -137,11 +145,15 @@ build_script:
|
||||||
--verbose --parallel --clean --notest --noinstall
|
--verbose --parallel --clean --notest --noinstall
|
||||||
|
|
||||||
test_script:
|
test_script:
|
||||||
- ps: |
|
# - ps: |
|
||||||
if ($isWindows) {
|
# if ($isWindows) {
|
||||||
Write-Output "cmake\cmake-builder.ps1 -testonly -config ${env:CONFIGURATION} -flavor ${env:SIMH_BUILD_FLAVOR}"
|
# Write-Output "cmake\cmake-builder.ps1 -testonly -config ${env:CONFIGURATION} -flavor ${env:SIMH_BUILD_FLAVOR}"
|
||||||
cmake\cmake-builder.ps1 -testonly -config ${env:CONFIGURATION} -flavor ${env:SIMH_BUILD_FLAVOR}
|
# cmake\cmake-builder.ps1 -testonly -config ${env:CONFIGURATION} -flavor ${env:SIMH_BUILD_FLAVOR}
|
||||||
}
|
# }
|
||||||
|
|
||||||
|
- cmd: |
|
||||||
|
powershell -File .\cmake\cmake-builder.ps1 -flavor %SIMH_BUILD_FLAVOR% -config %CONFIGURATION% -testonly
|
||||||
|
|
||||||
- sh: |
|
- sh: |
|
||||||
cmake/cmake-builder.sh --testonly --config ${CONFIGURATION} --flavor ${SIMH_BUILD_FLAVOR}
|
cmake/cmake-builder.sh --testonly --config ${CONFIGURATION} --flavor ${SIMH_BUILD_FLAVOR}
|
||||||
|
|
||||||
|
|
|
@ -18,14 +18,14 @@ Welcome to SIMH's pre-built binaries!
|
||||||
TO INSTALL. If you do, you are likely to get a Windows Defender popup box that
|
TO INSTALL. If you do, you are likely to get a Windows Defender popup box that
|
||||||
will prevent you from installing SIMH. Instead, use a CMD or PowerShell
|
will prevent you from installing SIMH. Instead, use a CMD or PowerShell
|
||||||
command window and execute the `.exe` from the command line prompt. For
|
command window and execute the `.exe` from the command line prompt. For
|
||||||
example, to install `simh-4.0.0-win32-native.exe`:
|
example, to install `simh-4.1.0-win32-native.exe`:
|
||||||
|
|
||||||
```
|
```
|
||||||
## PowerShell:
|
## PowerShell:
|
||||||
PS> .\simh-4.0.0-win32-native
|
PS> .\simh-4.1.0-win32-native
|
||||||
|
|
||||||
## CMD:
|
## CMD:
|
||||||
> .\simh-4.0.0-win32-native
|
> .\simh-4.1.0-win32-native
|
||||||
```
|
```
|
||||||
|
|
||||||
- `.msi`: WiX toolkit-created Windows MSI installer.
|
- `.msi`: WiX toolkit-created Windows MSI installer.
|
||||||
|
@ -37,5 +37,5 @@ Welcome to SIMH's pre-built binaries!
|
||||||
or CMD command window:
|
or CMD command window:
|
||||||
|
|
||||||
```
|
```
|
||||||
> msiexec /qf /i simh-4.0.0-win32-native.msi
|
> msiexec /qf /i simh-4.1.0-win32-native.msi
|
||||||
```
|
```
|
||||||
|
|
|
@ -41,7 +41,7 @@ Options:
|
||||||
--cppcheck Enable cppcheck static code analysis rules
|
--cppcheck Enable cppcheck static code analysis rules
|
||||||
|
|
||||||
--cpack_suffix Specify CPack's packaging suffix, e.g., "ubuntu-22.04"
|
--cpack_suffix Specify CPack's packaging suffix, e.g., "ubuntu-22.04"
|
||||||
to produce the "simh-4.0.0-ubuntu-22.04.deb" Debian
|
to produce the "simh-4.1.0-ubuntu-22.04.deb" Debian
|
||||||
package.
|
package.
|
||||||
|
|
||||||
--verbose Turn on verbose build output
|
--verbose Turn on verbose build output
|
||||||
|
|
|
@ -122,21 +122,21 @@ list(APPEND PCRE_SOURCE_URL
|
||||||
"https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-8.45.zip/download?use_mirror=freefr"
|
"https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-8.45.zip/download?use_mirror=freefr"
|
||||||
"https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-8.45.zip/download?use_mirror=master"
|
"https://sourceforge.net/projects/pcre/files/pcre/8.45/pcre-8.45.zip/download?use_mirror=master"
|
||||||
)
|
)
|
||||||
set(PNG_SOURCE_URL "https://github.com/glennrp/libpng/archive/refs/tags/v1.6.39.tar.gz")
|
set(PNG_SOURCE_URL "https://github.com/glennrp/libpng/archive/refs/tags/v1.6.40.tar.gz")
|
||||||
## Freetype also needs multiple URLs to chase a working mirror:
|
## Freetype also needs multiple URLs to chase a working mirror:
|
||||||
list(APPEND FREETYPE_SOURCE_URL
|
list(APPEND FREETYPE_SOURCE_URL
|
||||||
"https://github.com/freetype/freetype/archive/refs/tags/VER-2-12-1.zip"
|
"https://github.com/freetype/freetype/archive/refs/tags/VER-2-13-0.zip"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=cytranet"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=cytranet"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=phoenixnap"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=phoenixnap"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=versaweb"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=versaweb"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=netactuate"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=netactuate"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=cfhcable"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=cfhcable"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=freefr"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=freefr"
|
||||||
"https://sourceforge.net/projects/freetype/files/freetype2/2.12.1/ft2121.zip/download?use_mirror=master"
|
"https://sourceforge.net/projects/freetype/files/freetype2/2.13.1/ft2131.zip/download?use_mirror=master"
|
||||||
"https://download.savannah.gnu.org/releases/freetype/freetype-2.12.1.tar.xz"
|
"https://download.savannah.gnu.org/releases/freetype/freetype-2.13.1.tar.xz"
|
||||||
"https://gitlab.freedesktop.org/freetype/freetype/-/archive/VER-2-12-1/freetype-VER-2-12-1.zip"
|
"https://gitlab.freedesktop.org/freetype/freetype/-/archive/VER-2-13-0/freetype-VER-2-13-0.zip"
|
||||||
)
|
)
|
||||||
set(SDL2_SOURCE_URL "https://github.com/libsdl-org/SDL/archive/refs/tags/release-2.26.3.zip")
|
set(SDL2_SOURCE_URL "https://github.com/libsdl-org/SDL/archive/refs/tags/release-2.28.1.zip")
|
||||||
set(SDL2_TTF_SOURCE_URL "https://github.com/libsdl-org/SDL_ttf/archive/refs/tags/release-2.20.2.zip")
|
set(SDL2_TTF_SOURCE_URL "https://github.com/libsdl-org/SDL_ttf/archive/refs/tags/release-2.20.2.zip")
|
||||||
|
|
||||||
## Need to build ZLIB for both PCRE and libpng16:
|
## Need to build ZLIB for both PCRE and libpng16:
|
||||||
|
|
BIN
doc/altairz80_doc.docx
Normal file
BIN
doc/altairz80_doc.docx
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
22
makefile
22
makefile
|
@ -697,11 +697,11 @@ ifeq (${WIN32},) #*nix Environments (&& cygwin)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
ifneq (,$(VIDEO_USEFUL))
|
|
||||||
ifeq (cygwin,$(OSTYPE))
|
ifeq (cygwin,$(OSTYPE))
|
||||||
LIBEXTSAVE := ${LIBEXT}
|
LIBEXTSAVE := ${LIBEXT}
|
||||||
LIBEXT = dll.a
|
LIBEXT = dll.a
|
||||||
endif
|
endif
|
||||||
|
ifneq (,$(VIDEO_USEFUL))
|
||||||
ifneq (,$(call find_include,SDL2/SDL))
|
ifneq (,$(call find_include,SDL2/SDL))
|
||||||
ifneq (,$(call find_lib,SDL2))
|
ifneq (,$(call find_lib,SDL2))
|
||||||
ifneq (,$(shell which sdl2-config))
|
ifneq (,$(shell which sdl2-config))
|
||||||
|
@ -782,14 +782,6 @@ ifeq (${WIN32},) #*nix Environments (&& cygwin)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
ifeq (cygwin,$(OSTYPE))
|
|
||||||
LIBEXT = $(LIBEXTSAVE)
|
|
||||||
LIBPATH += /usr/lib/w32api
|
|
||||||
ifneq (,$(call find_lib,winmm))
|
|
||||||
OS_CCDEFS += -DHAVE_WINMM
|
|
||||||
OS_LDFLAGS += -lwinmm
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
ifeq (,$(findstring HAVE_LIBSDL,$(VIDEO_CCDEFS)))
|
ifeq (,$(findstring HAVE_LIBSDL,$(VIDEO_CCDEFS)))
|
||||||
$(info *** Info ***)
|
$(info *** Info ***)
|
||||||
$(info *** Info *** The simulator$(BUILD_MULTIPLE) you are building could provide more functionality)
|
$(info *** Info *** The simulator$(BUILD_MULTIPLE) you are building could provide more functionality)
|
||||||
|
@ -831,6 +823,14 @@ ifeq (${WIN32},) #*nix Environments (&& cygwin)
|
||||||
$(info *** Info ***)
|
$(info *** Info ***)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
ifeq (cygwin,$(OSTYPE))
|
||||||
|
LIBEXT = $(LIBEXTSAVE)
|
||||||
|
LIBPATH += /usr/lib/w32api
|
||||||
|
ifneq (,$(call find_lib,winmm))
|
||||||
|
OS_CCDEFS += -DHAVE_WINMM
|
||||||
|
OS_LDFLAGS += -lwinmm
|
||||||
|
endif
|
||||||
|
endif
|
||||||
ifneq (,$(NETWORK_USEFUL))
|
ifneq (,$(NETWORK_USEFUL))
|
||||||
ifneq (,$(call find_include,pcap))
|
ifneq (,$(call find_include,pcap))
|
||||||
ifneq (,$(shell grep 'pcap/pcap.h' $(call find_include,pcap) | grep include))
|
ifneq (,$(shell grep 'pcap/pcap.h' $(call find_include,pcap) | grep include))
|
||||||
|
@ -1312,9 +1312,9 @@ endif
|
||||||
ifneq (,$(UNSUPPORTED_BUILD))
|
ifneq (,$(UNSUPPORTED_BUILD))
|
||||||
CFLAGS_GIT += -DSIM_BUILD=Unsupported=$(UNSUPPORTED_BUILD)
|
CFLAGS_GIT += -DSIM_BUILD=Unsupported=$(UNSUPPORTED_BUILD)
|
||||||
endif
|
endif
|
||||||
OPTIMIZE ?= -O2
|
OPTIMIZE ?= -O2 -DNDEBUG=1
|
||||||
ifneq ($(DEBUG),)
|
ifneq ($(DEBUG),)
|
||||||
CFLAGS_G = -g -ggdb -g3
|
CFLAGS_G = -g -ggdb -g3 -D_DEBUG=1
|
||||||
CFLAGS_O = -O0
|
CFLAGS_O = -O0
|
||||||
BUILD_FEATURES = - debugging support
|
BUILD_FEATURES = - debugging support
|
||||||
LTO =
|
LTO =
|
||||||
|
|
22
scp.c
22
scp.c
|
@ -13119,8 +13119,6 @@ else {
|
||||||
ep->match = match_buf;
|
ep->match = match_buf;
|
||||||
ep->size = match_size;
|
ep->size = match_size;
|
||||||
}
|
}
|
||||||
ep->match_pattern = (char *)malloc (strlen (match) + 1);
|
|
||||||
strcpy (ep->match_pattern, match);
|
|
||||||
if (ep->act) { /* replace old action? */
|
if (ep->act) { /* replace old action? */
|
||||||
free (ep->act); /* deallocate */
|
free (ep->act); /* deallocate */
|
||||||
ep->act = NULL; /* now no action */
|
ep->act = NULL; /* now no action */
|
||||||
|
@ -13243,6 +13241,7 @@ for (i=0; i < exp->size; i++) {
|
||||||
if (ep->switches & EXP_TYP_REGEX) {
|
if (ep->switches & EXP_TYP_REGEX) {
|
||||||
#if defined (USE_REGEX)
|
#if defined (USE_REGEX)
|
||||||
int *ovector = NULL;
|
int *ovector = NULL;
|
||||||
|
int ovector_elts;
|
||||||
int rc;
|
int rc;
|
||||||
char *cbuf = (char *)exp->buf;
|
char *cbuf = (char *)exp->buf;
|
||||||
static size_t sim_exp_match_sub_count = 0;
|
static size_t sim_exp_match_sub_count = 0;
|
||||||
|
@ -13261,27 +13260,38 @@ for (i=0; i < exp->size; i++) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
++regex_checks;
|
++regex_checks;
|
||||||
ovector = (int *)malloc (3 * (ep->re_nsub + 1) * sizeof (*ovector));
|
ovector_elts = 3 * (ep->re_nsub + 1);
|
||||||
|
ovector = (int *)calloc ((size_t) ovector_elts, sizeof(*ovector));
|
||||||
if (sim_deb && exp->dptr && (exp->dptr->dctrl & exp->dbit)) {
|
if (sim_deb && exp->dptr && (exp->dptr->dctrl & exp->dbit)) {
|
||||||
char *estr = sim_encode_quoted_string (exp->buf, exp->buf_ins);
|
char *estr = sim_encode_quoted_string (exp->buf, exp->buf_ins);
|
||||||
sim_debug (exp->dbit, exp->dptr, "Checking String: %s\n", estr);
|
sim_debug (exp->dbit, exp->dptr, "Checking String: %s\n", estr);
|
||||||
sim_debug (exp->dbit, exp->dptr, "Against RegEx Match Rule: %s\n", ep->match_pattern);
|
sim_debug (exp->dbit, exp->dptr, "Against RegEx Match Rule: %s\n", ep->match_pattern);
|
||||||
free (estr);
|
free (estr);
|
||||||
}
|
}
|
||||||
rc = pcre_exec (ep->regex, NULL, cbuf, exp->buf_ins, 0, PCRE_NOTBOL, ovector, 3 * (ep->re_nsub + 1));
|
rc = pcre_exec (ep->regex, NULL, cbuf, exp->buf_ins, 0, PCRE_NOTBOL, ovector, ovector_elts);
|
||||||
if (rc >= 0) {
|
if (rc >= 0) {
|
||||||
size_t j;
|
size_t j;
|
||||||
char *buf = (char *)malloc (1 + exp->buf_ins);
|
char *buf = (char *)malloc (1 + exp->buf_ins);
|
||||||
|
|
||||||
for (j=0; j < (size_t)rc; j++) {
|
for (j=0; j < (size_t)rc; j++) {
|
||||||
char env_name[32];
|
char env_name[32];
|
||||||
|
int end_offs = ovector[2 * j + 1], start_offs = ovector[2 * j];
|
||||||
|
|
||||||
sprintf (env_name, "_EXPECT_MATCH_GROUP_%d", (int)j);
|
sprintf (env_name, "_EXPECT_MATCH_GROUP_%d", (int)j);
|
||||||
memcpy (buf, &cbuf[ovector[2 * j]], ovector[2 * j + 1] - ovector[2 * j]);
|
if (start_offs >= 0 && end_offs >= start_offs) {
|
||||||
buf[ovector[2 * j + 1] - ovector[2 * j]] = '\0';
|
memcpy (buf, &cbuf[start_offs], end_offs - start_offs);
|
||||||
|
buf[end_offs - start_offs] = '\0';
|
||||||
setenv (env_name, buf, 1); /* Make the match and substrings available as environment variables */
|
setenv (env_name, buf, 1); /* Make the match and substrings available as environment variables */
|
||||||
sim_debug (exp->dbit, exp->dptr, "%s=%s\n", env_name, buf);
|
sim_debug (exp->dbit, exp->dptr, "%s=%s\n", env_name, buf);
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
/* Substring was not captured by regexp: remove from the environment
|
||||||
|
* (unsetenv is local static -- doesn't actually remove the variable from
|
||||||
|
* the environment, sets it to an empty string.) */
|
||||||
|
sim_debug (exp->dbit, exp->dptr, "unsetenv %s\n", env_name);
|
||||||
|
unsetenv(env_name);
|
||||||
|
}
|
||||||
|
}
|
||||||
for (; j<sim_exp_match_sub_count; j++) {
|
for (; j<sim_exp_match_sub_count; j++) {
|
||||||
char env_name[32];
|
char env_name[32];
|
||||||
|
|
||||||
|
|
|
@ -780,7 +780,7 @@ switch (uptr->UCMD) {
|
||||||
if (CHS_IFERR (st)) /* channel error? */
|
if (CHS_IFERR (st)) /* channel error? */
|
||||||
return dp_chan_err (dva, st);
|
return dp_chan_err (dva, st);
|
||||||
}
|
}
|
||||||
if ((i != DPS_NBY) || (st != CHS_ZBC)) { /* length error? */
|
if (!DP_Q10B (ctx->dp_ctype) && (st != CHS_ZBC)) { /* 16B only: length error? */
|
||||||
ctx->dp_flags |= DPF_PGE; /* set prog err */
|
ctx->dp_flags |= DPF_PGE; /* set prog err */
|
||||||
if (chan_set_chf (dva, CHF_LNTE)) /* do we care? */
|
if (chan_set_chf (dva, CHF_LNTE)) /* do we care? */
|
||||||
return SCPE_OK;
|
return SCPE_OK;
|
||||||
|
|
12
sim_disk.c
12
sim_disk.c
|
@ -3380,12 +3380,14 @@ if ((uptr->flags & UNIT_BUF) && (uptr->filebuf)) {
|
||||||
sim_messagef (SCPE_OK, "%s: writing buffer to file: %s\n", sim_uname (uptr), uptr->filename);
|
sim_messagef (SCPE_OK, "%s: writing buffer to file: %s\n", sim_uname (uptr), uptr->filename);
|
||||||
sim_disk_wrsect (uptr, 0, (uint8 *)uptr->filebuf, NULL, (cap + ctx->sector_size - 1) / ctx->sector_size);
|
sim_disk_wrsect (uptr, 0, (uint8 *)uptr->filebuf, NULL, (cap + ctx->sector_size - 1) / ctx->sector_size);
|
||||||
}
|
}
|
||||||
|
if (uptr->flags & UNIT_MUSTBUF) { /* dyn alloc? */
|
||||||
|
free (uptr->filebuf); /* free buffers */
|
||||||
|
uptr->filebuf = NULL;
|
||||||
|
free (uptr->filebuf2);
|
||||||
|
uptr->filebuf2 = NULL;
|
||||||
|
}
|
||||||
uptr->flags = uptr->flags & ~UNIT_BUF;
|
uptr->flags = uptr->flags & ~UNIT_BUF;
|
||||||
}
|
}
|
||||||
free (uptr->filebuf); /* free buffers */
|
|
||||||
uptr->filebuf = NULL;
|
|
||||||
free (uptr->filebuf2);
|
|
||||||
uptr->filebuf2 = NULL;
|
|
||||||
|
|
||||||
update_disk_footer (uptr); /* Update meta data if highwater has changed */
|
update_disk_footer (uptr); /* Update meta data if highwater has changed */
|
||||||
|
|
||||||
|
@ -5756,7 +5758,7 @@ if (1) { /* CHS Calculation */
|
||||||
cylinderTimesHeads = totalSectors / sectorsPerTrack;
|
cylinderTimesHeads = totalSectors / sectorsPerTrack;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
cylinders = cylinderTimesHeads / heads;
|
cylinders = (totalSectors + sectorsPerTrack * heads - 1) / (sectorsPerTrack * heads);
|
||||||
Footer.DiskGeometry = NtoHl ((cylinders<<16)|(heads<<8)|sectorsPerTrack);
|
Footer.DiskGeometry = NtoHl ((cylinders<<16)|(heads<<8)|sectorsPerTrack);
|
||||||
}
|
}
|
||||||
Footer.Checksum = NtoHl (CalculateVhdFooterChecksum(&Footer, sizeof(Footer)));
|
Footer.Checksum = NtoHl (CalculateVhdFooterChecksum(&Footer, sizeof(Footer)));
|
||||||
|
|
|
@ -1083,7 +1083,7 @@ do {
|
||||||
sim_os_clock_resoluton_ms = clock_diff;
|
sim_os_clock_resoluton_ms = clock_diff;
|
||||||
clock_last = clock_now;
|
clock_last = clock_now;
|
||||||
} while (clock_now < clock_start + 100);
|
} while (clock_now < clock_start + 100);
|
||||||
if ((sim_idle_rate_ms != 0) && (sim_os_clock_resoluton_ms != 0))
|
if ((sim_os_clock_resoluton_ms != 0) && (sim_idle_rate_ms >= sim_os_clock_resoluton_ms))
|
||||||
sim_os_tick_hz = 1000/(sim_os_clock_resoluton_ms * (sim_idle_rate_ms/sim_os_clock_resoluton_ms));
|
sim_os_tick_hz = 1000/(sim_os_clock_resoluton_ms * (sim_idle_rate_ms/sim_os_clock_resoluton_ms));
|
||||||
else {
|
else {
|
||||||
fprintf (stderr, "Can't properly determine host system clock capabilities.\n");
|
fprintf (stderr, "Can't properly determine host system clock capabilities.\n");
|
||||||
|
|
|
@ -2235,7 +2235,7 @@ return 0;
|
||||||
const char *vid_version(void)
|
const char *vid_version(void)
|
||||||
{
|
{
|
||||||
static char SDLVersion[160];
|
static char SDLVersion[160];
|
||||||
SDL_version compiled, running;
|
SDL_version compiled = { 0, }, running = { 0, };
|
||||||
|
|
||||||
SDL_GetVersion(&running);
|
SDL_GetVersion(&running);
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "simh",
|
"name": "simh",
|
||||||
"version-string": "4.0.0",
|
"version-string": "4.1.0",
|
||||||
"description": [
|
"description": [
|
||||||
"SIMH: The historical computer architecture simulation suite."
|
"SIMH: The historical computer architecture simulation suite."
|
||||||
],
|
],
|
||||||
|
|
Loading…
Add table
Reference in a new issue