denise: OCS DENISEID ($07C) floats the undriven bus high to 0xFFFF#122
Merged
Conversation
The 8362 OCS Denise has no DENISEID register, so a CPU read of $DFF07C reads the undriven custom data bus. That bus floats high, so the read returns 0xFFFF -- and because the low byte (0xFF) is not the 0xFC that the 8373 ECS Denise drives, software still correctly detects OCS. Copperline returned the deterministic-zero undriven-bus fallback instead, so the ID read back as 0x0000 on OCS. Read $07C as the Denise revision id when it drives one (ECS 0xFFFC) and as the float-high 0xFFFF otherwise, and list it as a readable register. vAmigaTS Denise/Misc/Id/deniseid on OCS drops from 39.9% to 0.0% differing pixels against the vAmiga 4.4 reference; ECS is unchanged and the standard demo screenshots stay byte-identical (the change only affects an OCS read of $07C).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The 8362 OCS Denise has no DENISEID register, so a CPU read of
$DFF07Creadsthe undriven custom data bus. That bus floats high, so the read returns 0xFFFF
-- and because the low byte (0xFF) is not the 0xFC that the 8373 ECS Denise
drives, software still correctly detects OCS. Copperline returned its
deterministic-zero undriven-bus fallback, so the ID read back as 0x0000 on OCS.
Fix
Read
$07Cas the Denise revision id when it drives one (ECS = 0xFFFC) and asthe float-high 0xFFFF otherwise, and list it as a readable register.
Validation
the vAmiga 4.4 reference (verified with
tools/adf-compare.sh).byte-identical at 5s and 9s (the change only affects an OCS read of
$07C).clippy and fmt clean.