- Debugger Function keys F4 / F5 / F6 / F7 / F8

- Debugger Memory View adjusted
- Continue / Pause
This commit is contained in:
tudnai 2022-10-30 05:42:15 -07:00
parent c8c74b02b4
commit 2decf2abdc
7 changed files with 176 additions and 218 deletions

View File

@ -48,7 +48,7 @@
value = "default_MHz_6502 * 1000 * 1000 / spkr_sample_rate">
</PersistentString>
<PersistentString
value = "( (spkr_clk + m6502.clkfrm) / ( default_MHz_6502 * 1000 * 1000 / spkr_sample_rate)) * 2">
value = "( (spkr_clk + m6502.clkfrm) / ( 1024000 / spkr_sample_rate ) ) * 2">
</PersistentString>
<PersistentString
value = "(int16_t)28000 + (int16_t)-32768">
@ -66,7 +66,7 @@
value = "(spkr_clk + m6502.clkfrm)">
</PersistentString>
<PersistentString
value = "( (spkr_clk + m6502.clkfrm) / ( 1024000 / spkr_sample_rate ) ) * 2">
value = "( (spkr_clk + m6502.clkfrm) / ( default_MHz_6502 * 1000 * 1000 / spkr_sample_rate)) * 2">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -104,6 +104,14 @@
<ContextState
contextName = "set_flags_N:6502.c">
</ContextState>
<ContextState
contextName = "ViewController.keyDown(with:):ViewController.swift">
<PersistentStrings>
<PersistentString
value = "event.charactersIgnoringModifiers">
</PersistentString>
</PersistentStrings>
</ContextState>
<ContextState
contextName = "rel_addr:Apple2_mmio.h">
</ContextState>
@ -158,7 +166,7 @@
contextName = "closure #1 in ViewController.Update():ViewController.swift">
<PersistentStrings>
<PersistentString
value = "MEMcfg.is_80STORE">
value = "txtArr">
</PersistentString>
<PersistentString
value = "self.shadowTxt">
@ -167,10 +175,10 @@
value = "txt">
</PersistentString>
<PersistentString
value = "MEMcfg.txt_page_2">
value = "MEMcfg.is_80STORE">
</PersistentString>
<PersistentString
value = "txtArr">
value = "MEMcfg.txt_page_2">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -299,7 +307,7 @@
contextName = "LoRes.Update():LoRes.swift">
<PersistentStrings>
<PersistentString
value = "UInt8( (block &gt;&gt; 4) &amp; 0x0F )">
value = "blockChanged[ screenIdx ]">
</PersistentString>
<PersistentString
value = "UInt8(block)">
@ -308,7 +316,7 @@
value = "UInt8(block &amp; 4)">
</PersistentString>
<PersistentString
value = "blockChanged[ screenIdx ]">
value = "UInt8( (block &gt;&gt; 4) &amp; 0x0F )">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -561,10 +569,10 @@
contextName = "ToolBarController.GamePort(_:):ToolBarController.swift">
<PersistentStrings>
<PersistentString
value = "ViewController.current?.mouseCursorHidden">
value = "ViewController.current?.mouseCursorJoystickEmulation">
</PersistentString>
<PersistentString
value = "ViewController.current?.mouseCursorJoystickEmulation">
value = "ViewController.current?.mouseCursorHidden">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -603,13 +611,13 @@
contextName = "HiRes.compute():HiRes.swift">
<PersistentStrings>
<PersistentString
value = "UnsafeRawBufferPointer(result)">
value = "computePipelineState.maxTotalThreadsPerThreadgroup">
</PersistentString>
<PersistentString
value = "result[2]">
</PersistentString>
<PersistentString
value = "computePipelineState.maxTotalThreadsPerThreadgroup">
value = "UnsafeRawBufferPointer(result)">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -676,7 +684,7 @@
value = "new">
</PersistentString>
<PersistentString
value = "WOZtmp.shift16">
value = "WOZwrite.shift16">
</PersistentString>
<PersistentString
value = "WOZwrite.shift">
@ -688,7 +696,7 @@
value = "(1 &lt;&lt; i) - 1">
</PersistentString>
<PersistentString
value = "WOZwrite.shift16">
value = "WOZtmp.shift16">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -776,6 +784,9 @@
</PersistentString>
</PersistentStrings>
</ContextState>
<ContextState
contextName = "disassemblyLine:disassembler.c">
</ContextState>
<ContextState
contextName = "PUSH:6502_instr_stack.h">
<PersistentStrings>
@ -784,9 +795,6 @@
</PersistentString>
</PersistentStrings>
</ContextState>
<ContextState
contextName = "disassemblyLine:disassembler.c">
</ContextState>
<ContextState
contextName = "POP:6502_instr_stack.h">
</ContextState>
@ -840,10 +848,10 @@
contextName = "set_flags_NZC:common.h">
<PersistentStrings>
<PersistentString
value = "(unsigned)0xFF">
value = "(unsigned)test ">
</PersistentString>
<PersistentString
value = "(unsigned)test ">
value = "(unsigned)0xFF">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -877,17 +885,14 @@
contextName = "HiRes.draw(_:):HiRes.swift">
<PersistentStrings>
<PersistentString
value = "shadowScreen">
value = "linAddr">
</PersistentString>
<PersistentString
value = "ctx?.data">
value = "ctx?.bitsPerComponent">
</PersistentString>
<PersistentString
value = "ctx?.width">
</PersistentString>
<PersistentString
value = "ctx?.bitmapInfo">
</PersistentString>
<PersistentString
value = "ctx?.bytesPerRow">
</PersistentString>
@ -897,6 +902,12 @@
<PersistentString
value = "HiResLineAddrTbl">
</PersistentString>
<PersistentString
value = "ctx?.bitmapInfo">
</PersistentString>
<PersistentString
value = "shadowScreen">
</PersistentString>
<PersistentString
value = "(blockH7 | ( block &amp; bitMask ))">
</PersistentString>
@ -907,10 +918,7 @@
value = "ctx?.height">
</PersistentString>
<PersistentString
value = "linAddr">
</PersistentString>
<PersistentString
value = "ctx?.bitsPerComponent">
value = "ctx?.data">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -946,22 +954,22 @@
value = "m6502">
</PersistentString>
<PersistentString
value = "m6502.PC">
value = "(void*)Apple2_64K_RAM">
</PersistentString>
<PersistentString
value = "m6502.clkfrm">
value = "Apple2_64K_RAM + 0x3600">
</PersistentString>
<PersistentString
value = "m6502.ecoSpindown">
</PersistentString>
<PersistentString
value = "m6502.PC">
</PersistentString>
<PersistentString
value = "Apple2_64K_AUX + 0x3600">
</PersistentString>
<PersistentString
value = "(void*)Apple2_64K_RAM">
</PersistentString>
<PersistentString
value = "Apple2_64K_RAM + 0x3600">
value = "m6502.clkfrm">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -980,7 +988,7 @@
value = "textDisplay_height_diff">
</PersistentString>
<PersistentString
value = "textDisplay_width_diff">
value = "textDisplay.frame">
</PersistentString>
<PersistentString
value = "MonitorView.textViewBounds">
@ -989,10 +997,10 @@
value = "frame.size">
</PersistentString>
<PersistentString
value = "textDisplay.bounds">
value = "textDisplay_width_diff">
</PersistentString>
<PersistentString
value = "textDisplay.frame">
value = "textDisplay.bounds">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -1091,7 +1099,7 @@
value = "pdl_value[pdl]">
</PersistentString>
<PersistentString
value = "normalized_time">
value = "normalized_time &gt;= pdl_value[pdl] ? 255 : 0">
</PersistentString>
<PersistentString
value = "(3300 * 255/3300)">
@ -1103,7 +1111,7 @@
value = "1 * 512 * (1 - ( 3300 / 3300.0 ))">
</PersistentString>
<PersistentString
value = "normalized_time &gt;= pdl_value[pdl] ? 255 : 0">
value = "normalized_time">
</PersistentString>
</PersistentStrings>
</ContextState>
@ -1174,10 +1182,10 @@
value = "Apple2_64K_AUX + 0xC600">
</PersistentString>
<PersistentString
value = "Apple2_64K_RAM + 0xC600">
value = "(void*)rom">
</PersistentString>
<PersistentString
value = "(void*)rom">
value = "Apple2_64K_RAM + 0xC600">
</PersistentString>
<PersistentString
value = "strlen(fullPath)">

View File

@ -150,7 +150,7 @@ class AppDelegate: NSObject, NSApplicationDelegate {
}
@IBAction func DebugContinue(_ sender: Any) {
DebuggerWindowController.current?.Continue(sender)
DebuggerWindowController.current?.ContinuePauseButton(sender)
}
@IBAction func DebugStepOver(_ sender: Any) {

View File

@ -34,7 +34,7 @@
</buttonCell>
</button>
<connections>
<action selector="Continue:" target="g5o-m8-tZm" id="ggd-Cv-fuR"/>
<action selector="ContinuePauseButton:" target="g5o-m8-tZm" id="ggd-Cv-fuR"/>
</connections>
</toolbarItem>
<toolbarItem implicitItemIdentifier="34201AE0-6358-4CC1-A7D5-BEB45E6353C8" label="Step Over" paletteLabel="Step Over" image="NSTouchBarGoForwardTemplate" id="GHM-FG-JZe" userLabel="Step Over Toolbar Item">
@ -222,7 +222,7 @@
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textView editable="NO" selectable="NO" drawsBackground="NO" importsGraphics="NO" richText="NO" horizontallyResizable="YES" verticallyResizable="YES" baseWritingDirection="leftToRight" findStyle="bar" allowsCharacterPickerTouchBarItem="NO" textCompletion="NO" id="Hwx-Gd-XW1" userLabel="Display" customClass="DisplayView" customModule="A2MacTests" customModuleProvider="target">
<rect key="frame" x="0.0" y="53" width="288" height="1271"/>
<rect key="frame" x="0.0" y="33" width="288" height="1271"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" widthSizable="YES" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" red="0.12549019610000001" green="0.12549019610000001" blue="0.12549019610000001" alpha="0.0" colorSpace="custom" customColorSpace="sRGB"/>
@ -354,13 +354,13 @@ C20D: 4C C5 FE JMP $FEC5
</customSpacing>
</stackView>
<customView identifier="Side Panel" focusRingType="none" translatesAutoresizingMaskIntoConstraints="NO" id="JUf-qx-iuW" userLabel="Side Panel">
<rect key="frame" x="306" y="12" width="710" height="598"/>
<rect key="frame" x="306" y="10" width="710" height="600"/>
<subviews>
<stackView focusRingType="none" distribution="fill" orientation="vertical" alignment="leading" spacing="20" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="0fW-4Y-eIm" userLabel="Views">
<rect key="frame" x="0.0" y="72" width="710" height="526"/>
<rect key="frame" x="0.0" y="0.0" width="710" height="600"/>
<subviews>
<stackView distribution="fill" orientation="horizontal" alignment="top" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Cvo-4B-v1R" userLabel="CPU Stack View">
<rect key="frame" x="0.0" y="342" width="710" height="184"/>
<rect key="frame" x="0.0" y="416" width="710" height="184"/>
<subviews>
<stackView distribution="fill" orientation="vertical" alignment="leading" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="Crh-BM-MCy" userLabel="CPU View">
<rect key="frame" x="0.0" y="0.0" width="351" height="184"/>
@ -404,6 +404,7 @@ C20D: 4C C5 FE JMP $FEC5
<color key="backgroundColor" red="0.11372549019607843" green="0.11372549019607843" blue="0.11372549019607843" alpha="1" colorSpace="calibratedRGB"/>
</clipView>
<constraints>
<constraint firstAttribute="height" relation="greaterThanOrEqual" constant="160" id="1ff-p2-gpA"/>
<constraint firstAttribute="height" constant="160" id="SX5-Sa-JJZ"/>
</constraints>
<scroller key="horizontalScroller" hidden="YES" verticalHuggingPriority="750" horizontal="YES" id="ZRA-0X-qL7">
@ -453,11 +454,11 @@ C20D: 4C C5 FE JMP $FEC5
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textView editable="NO" selectable="NO" drawsBackground="NO" importsGraphics="NO" richText="NO" horizontallyResizable="YES" verticallyResizable="YES" baseWritingDirection="leftToRight" findStyle="bar" allowsCharacterPickerTouchBarItem="NO" textCompletion="NO" id="BHr-Q4-rBI" userLabel="Display" customClass="DisplayView" customModule="A2MacTests" customModuleProvider="target">
<rect key="frame" x="0.0" y="-113" width="334" height="182"/>
<rect key="frame" x="0.0" y="0.0" width="334" height="182"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" widthSizable="YES" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="windowBackgroundColor" catalog="System" colorSpace="catalog"/>
<size key="minSize" width="334" height="158"/>
<size key="minSize" width="181" height="158"/>
<size key="maxSize" width="3840" height="58101"/>
<attributedString key="textStorage">
<fragment content="1FF: FA1FE: 841FD: 011FC: 011FB: 001FA: 1F1F9: C11F7: D443 JSR1F5: D532 JSR1F3: FD77 JSR1f1: FD37 JSR">
@ -477,10 +478,10 @@ C20D: 4C C5 FE JMP $FEC5
<constraint firstAttribute="height" constant="160" id="wPj-Ga-QuT"/>
</constraints>
<scroller key="horizontalScroller" hidden="YES" verticalHuggingPriority="750" horizontal="YES" id="uYL-9G-QAi">
<rect key="frame" x="-100" y="-100" width="225" height="15"/>
<rect key="frame" x="-100" y="-100" width="349" height="15"/>
<autoresizingMask key="autoresizingMask"/>
</scroller>
<scroller key="verticalScroller" verticalHuggingPriority="750" horizontal="NO" id="dcm-z5-VNG">
<scroller key="verticalScroller" verticalHuggingPriority="750" doubleValue="1" horizontal="NO" id="dcm-z5-VNG">
<rect key="frame" x="335" y="1" width="15" height="158"/>
<autoresizingMask key="autoresizingMask"/>
</scroller>
@ -505,12 +506,14 @@ C20D: 4C C5 FE JMP $FEC5
<constraints>
<constraint firstAttribute="bottom" secondItem="tkP-fH-zDU" secondAttribute="bottom" id="1s4-KL-DYI"/>
<constraint firstAttribute="bottom" secondItem="Crh-BM-MCy" secondAttribute="bottom" id="2Uh-ZC-DIS"/>
<constraint firstItem="YLL-6E-LGQ" firstAttribute="height" secondItem="9Z1-95-RLw" secondAttribute="height" id="CoB-8r-Kke"/>
<constraint firstItem="tkP-fH-zDU" firstAttribute="leading" secondItem="Cvo-4B-v1R" secondAttribute="centerX" constant="4" id="IsL-Uw-GQd"/>
<constraint firstAttribute="trailing" secondItem="tkP-fH-zDU" secondAttribute="trailing" id="K1G-vH-FMD"/>
<constraint firstItem="Crh-BM-MCy" firstAttribute="leading" secondItem="Cvo-4B-v1R" secondAttribute="leading" id="UyY-hW-CCt"/>
<constraint firstAttribute="centerX" secondItem="Crh-BM-MCy" secondAttribute="trailing" constant="4" id="bbL-4L-Mdt"/>
<constraint firstItem="tkP-fH-zDU" firstAttribute="top" secondItem="Cvo-4B-v1R" secondAttribute="top" id="dA3-wJ-Ymz"/>
<constraint firstItem="Crh-BM-MCy" firstAttribute="top" secondItem="Cvo-4B-v1R" secondAttribute="top" id="nLr-7e-4fF"/>
<constraint firstAttribute="height" constant="184" id="x8r-57-qsI"/>
</constraints>
<visibilityPriorities>
<integer value="1000"/>
@ -522,21 +525,10 @@ C20D: 4C C5 FE JMP $FEC5
</customSpacing>
</stackView>
<stackView distribution="fill" orientation="vertical" alignment="leading" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="ZWI-gS-oPs" userLabel="Memory View">
<rect key="frame" x="0.0" y="0.0" width="710" height="322"/>
<rect key="frame" x="0.0" y="100" width="710" height="300"/>
<subviews>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="08L-qW-l2D" userLabel="Memory1">
<rect key="frame" x="4" y="306" width="44" height="16"/>
<constraints>
<constraint firstAttribute="height" constant="16" id="gj1-T9-yAz"/>
</constraints>
<textFieldCell key="cell" lineBreakMode="clipping" title="Mem 1" id="3Un-jU-O0b">
<font key="font" usesAppearanceFont="YES"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="p3x-F3-IOa">
<rect key="frame" x="10" y="282" width="50" height="16"/>
<rect key="frame" x="10" y="280" width="50" height="20"/>
<constraints>
<constraint firstAttribute="height" constant="20" id="bS5-Xb-qDz"/>
</constraints>
@ -547,7 +539,7 @@ C20D: 4C C5 FE JMP $FEC5
</textFieldCell>
</textField>
<textField horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="DiM-zp-wCg" userLabel="Low Nibble Label">
<rect key="frame" x="78" y="282" width="634" height="16"/>
<rect key="frame" x="78" y="280" width="634" height="16"/>
<constraints>
<constraint firstAttribute="height" constant="16" id="cbC-f3-JsA"/>
</constraints>
@ -585,9 +577,6 @@ C20D: 4C C5 FE JMP $FEC5
</subviews>
<color key="backgroundColor" red="0.1137254902" green="0.1137254902" blue="0.1137254902" alpha="1" colorSpace="calibratedRGB"/>
</clipView>
<constraints>
<constraint firstAttribute="height" constant="274" id="6Ya-GA-z0A"/>
</constraints>
<scroller key="horizontalScroller" hidden="YES" verticalHuggingPriority="750" horizontal="YES" id="5vz-OF-VRE">
<rect key="frame" x="-100" y="-100" width="225" height="15"/>
<autoresizingMask key="autoresizingMask"/>
@ -599,30 +588,32 @@ C20D: 4C C5 FE JMP $FEC5
</scrollView>
</subviews>
<constraints>
<constraint firstItem="p3x-F3-IOa" firstAttribute="centerY" secondItem="DiM-zp-wCg" secondAttribute="centerY" id="1jB-6a-Kd7"/>
<constraint firstItem="p3x-F3-IOa" firstAttribute="centerY" secondItem="DiM-zp-wCg" secondAttribute="centerY" constant="-2" id="1jB-6a-Kd7"/>
<constraint firstAttribute="height" constant="300" id="1q4-G0-gXU"/>
<constraint firstAttribute="trailing" secondItem="DiM-zp-wCg" secondAttribute="trailing" id="7b8-T1-ViL"/>
<constraint firstItem="DiM-zp-wCg" firstAttribute="top" secondItem="ZWI-gS-oPs" secondAttribute="top" constant="4" id="C0D-5y-lzy"/>
<constraint firstAttribute="trailing" secondItem="dzC-sA-aHa" secondAttribute="trailing" id="CnA-zf-PRO"/>
<constraint firstItem="p3x-F3-IOa" firstAttribute="leading" secondItem="ZWI-gS-oPs" secondAttribute="leading" constant="10" id="PZX-dV-eeZ"/>
<constraint firstItem="dzC-sA-aHa" firstAttribute="top" secondItem="ZWI-gS-oPs" secondAttribute="top" constant="26" id="T4S-i9-19K"/>
<constraint firstItem="DiM-zp-wCg" firstAttribute="leading" secondItem="ZWI-gS-oPs" secondAttribute="leading" constant="80" id="Vk4-MB-VHG"/>
<constraint firstItem="p3x-F3-IOa" firstAttribute="trailing" secondItem="DiM-zp-wCg" secondAttribute="leading" constant="-20" id="W4a-Ms-nKK"/>
<constraint firstItem="dzC-sA-aHa" firstAttribute="leading" secondItem="ZWI-gS-oPs" secondAttribute="leading" id="Ze8-Ir-2gQ"/>
<constraint firstItem="08L-qW-l2D" firstAttribute="leading" secondItem="ZWI-gS-oPs" secondAttribute="leading" constant="6" id="kxm-zh-cum"/>
<constraint firstAttribute="bottom" secondItem="dzC-sA-aHa" secondAttribute="bottom" id="m9p-3C-szs"/>
</constraints>
<visibilityPriorities>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
</visibilityPriorities>
<customSpacing>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
</customSpacing>
</stackView>
</subviews>
<constraints>
<constraint firstItem="ZWI-gS-oPs" firstAttribute="top" secondItem="Cvo-4B-v1R" secondAttribute="bottom" constant="16" id="Fz5-5q-jZv"/>
<constraint firstItem="Cvo-4B-v1R" firstAttribute="leading" secondItem="0fW-4Y-eIm" secondAttribute="leading" id="GTz-4R-DZt"/>
<constraint firstItem="Cvo-4B-v1R" firstAttribute="top" secondItem="0fW-4Y-eIm" secondAttribute="top" id="azH-14-O3q"/>
<constraint firstAttribute="trailing" secondItem="Cvo-4B-v1R" secondAttribute="trailing" id="cxB-Rw-f6s"/>
@ -639,89 +630,11 @@ C20D: 4C C5 FE JMP $FEC5
</customSpacing>
</stackView>
<stackView focusRingType="none" distribution="fill" orientation="vertical" alignment="leading" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="jQ2-04-lPn" userLabel="Bottom Selection">
<rect key="frame" x="8" y="8" width="694" height="57"/>
<rect key="frame" x="8" y="8" width="694" height="10"/>
<subviews>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="HN2-Eb-6Ht">
<rect key="frame" x="-2" y="41" width="56" height="18"/>
<buttonCell key="cell" type="check" title="Trace" bezelStyle="regularSquare" imagePosition="left" inset="2" id="Kdm-bM-hb0">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
</button>
<box focusRingType="none" verticalHuggingPriority="750" boxType="separator" translatesAutoresizingMaskIntoConstraints="NO" id="oa2-bF-OPT">
<rect key="frame" x="0.0" y="32" width="68" height="5"/>
<rect key="frame" x="0.0" y="7" width="68" height="5"/>
</box>
<textField hidden="YES" focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="jDi-tM-QQZ">
<rect key="frame" x="-2" y="41" width="47" height="16"/>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="right" title="ILE: 0.1" id="f2w-FD-OOD">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<slider hidden="YES" focusRingType="none" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="BhN-WM-tjw">
<rect key="frame" x="-2" y="40" width="92" height="19"/>
<sliderCell key="cell" continuous="YES" refusesFirstResponder="YES" state="on" focusRingType="none" alignment="left" maxValue="1" doubleValue="0.10000000000000001" tickMarkPosition="above" sliderType="linear" id="9wv-cN-nvE"/>
</slider>
<textField hidden="YES" focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="7E5-pO-ycS">
<rect key="frame" x="-2" y="41" width="44" height="16"/>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="right" title="LE: 0.1" id="5ol-5S-WKc">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<slider hidden="YES" focusRingType="none" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="OMo-Kb-QeD">
<rect key="frame" x="-2" y="40" width="92" height="19"/>
<sliderCell key="cell" continuous="YES" refusesFirstResponder="YES" state="on" focusRingType="none" alignment="left" maxValue="0.99990000000000001" doubleValue="0.10000000000000001" tickMarkPosition="above" sliderType="linear" id="sQN-qq-kna"/>
</slider>
<textField hidden="YES" focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="eLg-K3-PjQ">
<rect key="frame" x="-2" y="41" width="48" height="16"/>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="right" title="ITE: 0.1" id="1EB-3r-dYk">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<slider hidden="YES" focusRingType="none" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="NkU-cs-aFb">
<rect key="frame" x="-2" y="40" width="92" height="19"/>
<sliderCell key="cell" continuous="YES" refusesFirstResponder="YES" state="on" focusRingType="none" alignment="left" maxValue="1" doubleValue="0.10000000000000001" tickMarkPosition="above" sliderType="linear" id="zBO-yu-dme"/>
</slider>
<textField hidden="YES" focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="n5c-EX-l5m">
<rect key="frame" x="-2" y="41" width="45" height="16"/>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="right" title="TE: 0.1" id="FVR-Lz-j3N">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<slider hidden="YES" focusRingType="none" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Co1-Pf-vj7">
<rect key="frame" x="-2" y="40" width="92" height="19"/>
<sliderCell key="cell" continuous="YES" refusesFirstResponder="YES" state="on" focusRingType="none" alignment="left" maxValue="0.99990000000000001" doubleValue="0.10000000000000001" tickMarkPosition="above" sliderType="linear" id="QUR-Gu-VdD"/>
</slider>
<textField hidden="YES" focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Mh9-7g-Aso">
<rect key="frame" x="-2" y="41" width="40" height="16"/>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="right" title="WE: 4" id="eqc-tk-tvn">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<slider hidden="YES" focusRingType="none" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Ph5-Bw-bE9">
<rect key="frame" x="-2" y="33" width="92" height="24"/>
<sliderCell key="cell" continuous="YES" refusesFirstResponder="YES" state="on" focusRingType="none" alignment="left" maxValue="40" doubleValue="4.1025641025641022" tickMarkPosition="above" numberOfTickMarks="40" allowsTickMarkValuesOnly="YES" sliderType="linear" id="YOJ-Bu-pgj"/>
</slider>
<textField focusRingType="none" horizontalHuggingPriority="251" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="3bk-Vi-4BD">
<rect key="frame" x="-2" y="9" width="75" height="17"/>
<constraints>
<constraint firstAttribute="height" constant="17" id="Jzf-c8-kfw"/>
</constraints>
<textFieldCell key="cell" lineBreakMode="clipping" refusesFirstResponder="YES" focusRingType="none" alignment="center" title="0.000 MHz" id="Bvh-6f-3DM">
<font key="font" metaFont="system"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
</textFieldCell>
</textField>
<box focusRingType="none" verticalHuggingPriority="750" boxType="separator" translatesAutoresizingMaskIntoConstraints="NO" id="VUT-jD-TzS">
<rect key="frame" x="0.0" y="-2" width="68" height="5"/>
</box>
@ -729,34 +642,10 @@ C20D: 4C C5 FE JMP $FEC5
<visibilityPriorities>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
</visibilityPriorities>
<customSpacing>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
</customSpacing>
</stackView>
</subviews>
@ -767,6 +656,7 @@ C20D: 4C C5 FE JMP $FEC5
<constraint firstAttribute="trailing" secondItem="jQ2-04-lPn" secondAttribute="trailing" constant="8" id="IgJ-iQ-fya"/>
<constraint firstAttribute="trailing" secondItem="0fW-4Y-eIm" secondAttribute="trailing" id="QYl-GI-RBo"/>
<constraint firstItem="jQ2-04-lPn" firstAttribute="leading" secondItem="JUf-qx-iuW" secondAttribute="leading" constant="8" id="S6T-Kb-26z"/>
<constraint firstAttribute="bottom" secondItem="0fW-4Y-eIm" secondAttribute="bottom" id="i6Q-OP-9m0"/>
<constraint firstItem="0fW-4Y-eIm" firstAttribute="leading" secondItem="JUf-qx-iuW" secondAttribute="leading" id="oiu-yH-cRR"/>
</constraints>
</customView>
@ -775,7 +665,7 @@ C20D: 4C C5 FE JMP $FEC5
<constraint firstAttribute="bottom" secondItem="jY7-ZU-I4z" secondAttribute="bottom" constant="10" id="8jC-7G-Ofh"/>
<constraint firstItem="JUf-qx-iuW" firstAttribute="leading" secondItem="jY7-ZU-I4z" secondAttribute="trailing" constant="8" id="ARC-gJ-JMB"/>
<constraint firstItem="JUf-qx-iuW" firstAttribute="top" secondItem="Myj-W6-YvY" secondAttribute="top" constant="6" id="OaJ-lc-b0j"/>
<constraint firstAttribute="bottom" secondItem="JUf-qx-iuW" secondAttribute="bottom" constant="12" id="Y4T-sR-Hag"/>
<constraint firstAttribute="bottom" secondItem="JUf-qx-iuW" secondAttribute="bottom" constant="10" id="Y4T-sR-Hag"/>
<constraint firstItem="jY7-ZU-I4z" firstAttribute="top" secondItem="Myj-W6-YvY" secondAttribute="top" constant="6" id="cCh-QQ-pyz"/>
<constraint firstItem="jY7-ZU-I4z" firstAttribute="leading" secondItem="Myj-W6-YvY" secondAttribute="leading" constant="8" id="gka-CA-9WG"/>
<constraint firstAttribute="trailing" secondItem="JUf-qx-iuW" secondAttribute="trailing" constant="8" id="kwa-ri-Rtq"/>

View File

@ -856,30 +856,33 @@ Gw
</connections>
</menuItem>
<menuItem isSeparatorItem="YES" id="cie-yN-x37"/>
<menuItem title=" Continue" image="NSTouchBarSkipToEndTemplate" id="4XT-55-ZIi">
<menuItem title=" Continue" image="NSTouchBarSkipToEndTemplate" keyEquivalent="" id="4XT-55-ZIi">
<attributedString key="attributedTitle"/>
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="DebugContinue:" target="Voe-Tx-rLC" id="8VJ-SA-88F"/>
</connections>
</menuItem>
<menuItem title=" Pause" image="NSTouchBarPauseTemplate" id="CGs-2r-GUf">
<menuItem title=" Pause" image="NSTouchBarPauseTemplate" keyEquivalent="" id="CGs-2r-GUf">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="Pause:" target="Voe-Tx-rLC" id="ZHS-S4-fpJ"/>
</connections>
</menuItem>
<menuItem title=" Step Over" image="NSTouchBarGoForwardTemplate" keyEquivalent="6" id="sJB-Vb-4l9">
<menuItem title=" Step Over" image="NSTouchBarGoForwardTemplate" keyEquivalent="" id="sJB-Vb-4l9">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="DebugStepOver:" target="Voe-Tx-rLC" id="j9J-b7-Qc7"/>
</connections>
</menuItem>
<menuItem title="Step In" image="NSTouchBarGoDownTemplate" keyEquivalent="7" id="8Ex-Dj-aTQ">
<menuItem title="Step In" image="NSTouchBarGoDownTemplate" keyEquivalent="" id="8Ex-Dj-aTQ">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="DebugStepIn:" target="Voe-Tx-rLC" id="VS2-dJ-ej6"/>
</connections>
</menuItem>
<menuItem title="Step Out" image="NSTouchBarGoUpTemplate" keyEquivalent="8" id="nJ4-nf-edr">
<menuItem title="Step Out" image="NSTouchBarGoUpTemplate" keyEquivalent="" id="nJ4-nf-edr">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="DebugStepOut:" target="Voe-Tx-rLC" id="yLP-2Q-Aj3"/>
</connections>
@ -1522,7 +1525,7 @@ Gw
<popUpButton key="view" id="rfS-6q-EKe">
<rect key="frame" x="0.0" y="14" width="43" height="30"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="Quick Disk" imagePosition="only" alignment="right" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" id="8bV-Aa-zHf">
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="popUpButtonCell:8bV-Aa-zHf:image" imagePosition="only" alignment="right" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" id="8bV-Aa-zHf">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="menu"/>
<menu key="menu" id="7Vp-Rc-UbT">
@ -1809,7 +1812,7 @@ Gw
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textView editable="NO" selectable="NO" drawsBackground="NO" importsGraphics="NO" richText="NO" horizontallyResizable="YES" verticallyResizable="YES" baseWritingDirection="leftToRight" findStyle="bar" allowsCharacterPickerTouchBarItem="NO" textCompletion="NO" id="ccC-Wu-3za" userLabel="Display" customClass="DisplayView" customModule="Steve___" customModuleProvider="target">
<rect key="frame" x="0.0" y="-384" width="1152" height="768"/>
<rect key="frame" x="0.0" y="-416" width="1152" height="768"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" widthSizable="YES" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" red="0.0" green="0.99143940210000003" blue="1" alpha="0.76658818490000002" colorSpace="custom" customColorSpace="sRGB"/>
@ -1945,7 +1948,7 @@ Gw
<subviews>
<popUpButton translatesAutoresizingMaskIntoConstraints="NO" id="49f-8R-QCc" userLabel="Disk1 Button">
<rect key="frame" x="0.0" y="75" width="104" height="99"/>
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="popUpButtonCell:CNs-lh-urM:image" imagePosition="only" alignment="left" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" altersStateOfSelectedItem="NO" id="CNs-lh-urM">
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="popUpButtonCell:8bV-Aa-zHf:image" imagePosition="only" alignment="left" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" altersStateOfSelectedItem="NO" id="CNs-lh-urM">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="menu"/>
<menu key="menu" id="N33-K0-nba">
@ -1997,7 +2000,7 @@ Gw
</popUpButton>
<popUpButton translatesAutoresizingMaskIntoConstraints="NO" id="QDr-Cp-9QQ" userLabel="Disk2 Button">
<rect key="frame" x="0.0" y="0.0" width="104" height="99"/>
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="popUpButtonCell:CNs-lh-urM:image" imagePosition="only" alignment="left" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" altersStateOfSelectedItem="NO" selectedItem="28N-X8-n7Q" id="8FA-1D-k8p">
<popUpButtonCell key="cell" type="bevel" bezelStyle="regularSquare" image="popUpButtonCell:8bV-Aa-zHf:image" imagePosition="only" alignment="left" lineBreakMode="truncatingTail" refusesFirstResponder="YES" imageScaling="proportionallyUpOrDown" inset="2" pullsDown="YES" arrowPosition="noArrow" altersStateOfSelectedItem="NO" selectedItem="28N-X8-n7Q" id="8FA-1D-k8p">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="menu"/>
<menu key="menu" id="8He-mk-LVI">
@ -139128,7 +139131,7 @@ BQB9EQcAfREJAH0RCwB9ERQAfREZAH0RHwB9EScAfREpAH0RKwB9ES0AfREvAH0imwB9IqAAfSKtAH0i
sAB9Ir0AfSLCAH0iygB9Is0AfSLSAH0i2gAAAAAAAAQBAAAAAAAAAFAAAAAAAAAAAAAAAAAAfSLdA
</mutableData>
</image>
<image name="popUpButtonCell:CNs-lh-urM:image" width="1" height="1">
<image name="popUpButtonCell:8bV-Aa-zHf:image" width="1" height="1">
<mutableData key="keyedArchiveRepresentation">
YnBsaXN0MDDUAQIDBAUGBwpYJHZlcnNpb25ZJGFyY2hpdmVyVCR0b3BYJG9iamVjdHMSAAGGoF8QD05T
S2V5ZWRBcmNoaXZlctEICVRyb290gAGvEBcLDBkaIRQmKisyNTo9PkNGR0pUXF1hZFUkbnVsbNYNDg8Q

View File

@ -148,7 +148,7 @@ N V - B D I Z C
func DisplayMemory() {
var memory = ""
for i : UInt16 in stride(from: 0x400, to: 0x4FF, by: 16) {
memory += hexLine16(addr: i) + textLine16(addr: i) + "\n"
memory += hexLine16(addr: i) + " " + textLine16(addr: i) + "\n"
}
DispatchQueue.main.async {

View File

@ -100,16 +100,29 @@ class DebuggerWindowController: NSWindowController, NSWindowDelegate {
}
@IBAction func Continue(_ sender: Any) {
func Continue() {
ContinuePauseButtonState()
ToolBarController.current?.PauseButtonUpdate()
ViewController.current?.Pause(0)
}
func Pause() {
ContinuePauseButtonState()
ToolBarController.current?.PauseButtonUpdate()
ViewController.current?.Pause(0)
}
@IBAction func ContinuePauseButton(_ sender: Any) {
switch cpuState {
case cpuState_halted:
ViewController.current?.Pause(sender)
Continue()
case cpuState_running:
ViewController.current?.Pause(sender)
Pause()
default:
break

View File

@ -333,29 +333,47 @@ class ViewController: NSViewController {
//------------------------------------------------------------
}
func Resume() {
#if SCHEDULER_CVDISPLAYLINK
CVDisplayLinkStart(displayLink!)
#else
upd.resume()
#endif
cpuState = cpuState_running
if let debugger = DebuggerWindowController.current {
debugger.ContinuePauseButtonState()
}
}
func Pause() {
#if SCHEDULER_CVDISPLAYLINK
CVDisplayLinkStop(displayLink!)
#else
upd.suspend()
#endif
cpuState = cpuState_halted
if let debugger = DebuggerWindowController.current {
debugger.ContinuePauseButtonState()
}
}
@IBAction func Pause(_ sender: Any) {
switch ( cpuState ) {
case cpuState_halted:
#if SCHEDULER_CVDISPLAYLINK
CVDisplayLinkStart(displayLink!)
#else
upd.resume()
#endif
cpuState = cpuState_running
Resume()
break
case cpuState_running:
#if SCHEDULER_CVDISPLAYLINK
CVDisplayLinkStop(displayLink!)
#else
upd.suspend()
#endif
cpuState = cpuState_halted
Pause()
break
default:
@ -450,7 +468,13 @@ class ViewController: NSViewController {
let rightArrowKey = 124
let upArrowKey = 126
let downArrowKey = 125
let F4FunctionKey = 118
let F5FunctionKey = 96
let F6FunctionKey = 97
let F7FunctionKey = 98
let F8FunctionKey = 99
var ddd = 9;
override var acceptsFirstResponder: Bool {
@ -506,7 +530,8 @@ class ViewController: NSViewController {
if hide {
if mouseCursorHidden {
// NSCursor.hide() is working weird, better to set a 1px transparent cursor
mouseCursorHiddenJoystickEmulation.set()
// mouseCursorHiddenJoystickEmulation.set()
mouseCursorJoystickEmulation.set()
}
else {
mouseCursorJoystickEmulation.set()
@ -690,7 +715,36 @@ class ViewController: NSViewController {
else {
kbdInput(0x8B)
}
case F4FunctionKey:
// if let debugger = DebuggerWindowController.current {
// debugger.Continue()
// }
Resume()
case F5FunctionKey:
// if let debugger = DebuggerWindowController.current {
// debugger.Pause()
// }
Pause()
case F6FunctionKey:
if let debugger = DebuggerWindowController.current {
debugger.Step_Over(event)
}
case F7FunctionKey:
if let debugger = DebuggerWindowController.current {
debugger.Step_In(event)
}
case F8FunctionKey:
if let debugger = DebuggerWindowController.current {
debugger.Step_Out(event)
}
default:
// print("keycode: %d", keyCode)
if let chars = event.characters {
@ -1426,21 +1480,11 @@ class ViewController: NSViewController {
// NSEvent.removeMonitor(NSEvent.EventType.keyDown)
NSEvent.addLocalMonitorForEvents(matching: .keyDown) {
// print("keyDown event")
if DebuggerWindowController.current?.isKey ?? false {
return $0
}
self.keyDown(with: $0)
return nil
}
NSEvent.addLocalMonitorForEvents(matching: .keyUp) {
// print("keyUp event")
if DebuggerWindowController.current?.isKey ?? false {
return $0
}
self.keyUp(with: $0)
return nil
}