From 57c26c59b231d3c35d5c39f640911a94f347d337 Mon Sep 17 00:00:00 2001 From: tomcw Date: Tue, 7 Mar 2023 18:06:06 +0000 Subject: [PATCH] Update History.txt & some Phasor-related comments --- bin/History.txt | 4 ++-- source/Mockingboard.cpp | 9 ++++++--- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/bin/History.txt b/bin/History.txt index 7ca1335c..177425fc 100644 --- a/bin/History.txt +++ b/bin/History.txt @@ -18,7 +18,7 @@ Tom Charlesworth - At start-up, use the Registry's saved "Window x/y position" to position the AppleWin window correctly for multiple monitors. - [Change #1033] New command line support for hard disk controller in slots 5 and 7. - Use '-s5 hdc' or '-s7 hdc' to start up with a hard disk controller (hdc) in slots 5 and 7 respectively. - - Use '-s5h1 ' and '-s5h2 ' to connect to hard disk image. + - Use '-s5h1 ' and '-s5h2 ' to connect hard disk images. - NB. There's no GUI configuration support for the hdc in slot 5. - NB. An hdc in slot 5 allows these 3.5" titles to work: "Perplexing Puzzles" and "Dark Heart of Uukrul". - [Bug #1193] Phasor: now can't read AY regs (via 6522 PortA) after AY set to INACTIVE function. (Mockingboard still can.) @@ -31,7 +31,7 @@ Tom Charlesworth - [PR #1171] Refactor the Mockingboard & Phasor code. - Can now put any sound card (Mockingboard, Phasor or SAM) into either or both slots 4 and 5. - NB. Allows Mouse card in slot 4 and Mockingboard (or Phasor) in slot 5. -- Change: Command line '-s empty' now works for slots 1-7 (just not slot 0). +- Change: Command line '-s empty' now works for slots 1-7 (so only slot 0 isn't supported). - Debugger: Improve mini-memory views for AY8913 chip registers: show reg. latch address in white. - Debugger: Fix 'zpc' command, which wasn't working. diff --git a/source/Mockingboard.cpp b/source/Mockingboard.cpp index 796b6a7b..1bf1e0bc 100644 --- a/source/Mockingboard.cpp +++ b/source/Mockingboard.cpp @@ -185,7 +185,7 @@ void MockingboardCard::Get6522IrqDescription(std::string& desc) // // AFAICT, inputs to the Phasor GAL are: // . ORB.b4:3 = Chip Select (CS) for AY1 & AY2 (active low) -// . ORB.b2:0 = PSG Function (RESET, INACTIVE, READ, WRITE, LATCH) +// . ORB.b2:0 = PSG Function (RESET, INACTIVE, READ, WRITE, LATCH) [Or since LATCH=%111, then maybe a 3-input AND: b2.b1.b0 -> GAL?] // . Phasor mode (Mockingboard, Echo+, Phasor-native) // . Slot inputs (address, reset, etc) // And outputs from the GAL are: @@ -195,8 +195,9 @@ void MockingboardCard::Get6522IrqDescription(std::string& desc) // In Phasor-native mode, GAL logic: // . AY2 LATCH func selects AY2 and AY1; sets latch addr for AY2 and AY1 // . AY1 LATCH func selects AY1; deselects AY2; sets latch addr for AY1 -// . AY2 WRITE func writes AY2 if it's selected -// . AY1 WRITE func writes AY1; writes AY2 if it's selected +// . AY2 & AY1 LATCH func selects AY2 and AY1; sets latch addr for AY2 and AY1 +// . AY2 WRITE(READ) func writes(reads) AY2 if it's selected +// . AY1 WRITE(READ) func writes(reads) AY1; writes(reads) AY2 if it's selected. NB. If both chips, then the READ is the OR-sum. // // EG, to do a "AY1 LATCH", then write 6522 ORB with b4:3=%01, b2:0=%111 // @@ -231,6 +232,8 @@ void MockingboardCard::WriteToORB(BYTE subunit) if (m_phasorMode == PH_EchoPlus) subunit = SY6522_DEVICE_B; + // NB. For PH_Phasor, when selecting *both* AYs, then order matters: first do AY8913_DEVICE_A then AY8913_DEVICE_B + // Reason: from GAL logic: 'AY1 LATCH func' deselects AY2, then 'AY2 LATCH func' selects AY2 and AY1. (And we want both selected) if (nAY_CS & kAY0) AY8910_Write(subunit, AY8913_DEVICE_A, value);