Merge remote-tracking branch 'upstream/master'
# Conflicts: # source/Disk.cpp
This commit is contained in:
commit
c1631a1abf
45 changed files with 1066 additions and 569 deletions
|
@ -17,7 +17,7 @@ To compile from source see:
|
|||
|
||||
Next Version
|
||||
============
|
||||
Experimental build [1.26.3.1](https://github.com/AppleWin/AppleWin/releases/tag/v1.26.3.1)
|
||||
Experimental build [1.26.3.6](https://github.com/AppleWin/AppleWin/releases/tag/v1.26.3.6)
|
||||
|
||||
Please report [new issues](https://github.com/AppleWin/AppleWin/issues/new)
|
||||
|
||||
|
@ -27,5 +27,5 @@ Previous Versions
|
|||
|
||||
Last pre-NTSC change:
|
||||
|
||||
* [AppleWin v1.25.0.3](https://github.com/AppleWin/AppleWin/releases/download/v1.25.0.3/AppleWin1.25.0.3.zip)
|
||||
* [AppleWin v1.25.0.4](https://github.com/AppleWin/AppleWin/releases/download/v1.25.0.4/AppleWin1.25.0.4.zip)
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ https://github.com/AppleWin/AppleWin/issues/new
|
|||
Tom Charlesworth
|
||||
|
||||
|
||||
1.26.3.4 (Experimental) - 12 Nov 2017
|
||||
1.26.3.6 (Experimental) - 20 Dec 2017
|
||||
-------------------------------------
|
||||
Changes:
|
||||
. [Bug #504] Full-screen: hide mouse pointer after 2 seconds of inactivity (and show again if mouse is moved)
|
||||
|
@ -19,18 +19,27 @@ Changes:
|
|||
- nnnn: select a specific resolution with height=nnnn pixels
|
||||
Use to select a better resolution for full-screen mode.
|
||||
NB. This changes the display resolution (and restores on exit).
|
||||
. [Bug #477] Help doc: Document behaviour full-speed mode
|
||||
. [Bug #428] Input option to use PC Joystick 1 Thumbstick 2 for emulated Joystick 2
|
||||
. Swapping disks while a drive is on now warns and prompts if you still wish to do this instead of silently failing with no feedback.
|
||||
. [Bug #323] Skip hard disk boot by holding down the Open-Apple key during an Apple II restart
|
||||
. [Bug #224] Added Config checkbox for 'Full-Screen: Show drive/keyboard status'
|
||||
. [PR #441] Update zlib to latest version 1.2.11
|
||||
. [PR #275] Attenuate speaker (and 8-bit DAC) output sample after 0.25s of inactivity
|
||||
. [Bug #483] Debugger: Shift+Left mouse button to toggle 6502 Status flag bits
|
||||
. [Bug #479, #476, #473] Debugger: Various UI and other fixes
|
||||
. [Bug #462] Debugger: Changed Left mouse button (LMB) to Shift+LMB to toggle display items
|
||||
. [Bug #406] Debugger: Support LC and MMU status & updated Help doc
|
||||
|
||||
Fixes:
|
||||
. [Bug #516] Internal video-mode was having PAGE2 permanently cleared (instead of just masked) when 80STORE was set.
|
||||
. [Bug #514] Emulator restart (or reset) wasn't clearing any pending Mousecard interrupt
|
||||
. [Bug #499] Flush current track (if dirty) before 'Send to CiderPress'
|
||||
. [Bug #496] Support polling of Mockingboard's & Phasor's 6522 IFR.Timer1
|
||||
. [Bug #492] UI fixes for full-screen & 2x windowed-mode
|
||||
. [Bug #486] Peripheral card's expansion ROM ($C800-CFFF, eg. SSC) wasn't being correctly restored from a save-state
|
||||
- Resulting in regression: Mousecard crash to monitor (#495).
|
||||
. [Bug #484] Debugger: Some corrections to APPLE2E.SYM
|
||||
. [Bug #464] Fix for full-screen: bottom line missing when vertical resolution is 768
|
||||
. [Bug #460] Debugger: F2 whilst debugger active will immediately stop the drive spinning (allowing disk swap)
|
||||
. [Bug #456] Fix strange speaker clicks when changing configuration - DirectSound wasn't being uninitialised on a restart
|
||||
|
@ -56,6 +65,7 @@ Fixes:
|
|||
- Experimental support for 6551's status bits: DCD and DSR via -dcd and -dsr switches
|
||||
. [Bug #383] "Enhanced disk speed" is very slow when debugger is active
|
||||
. [Bug #320] Mockingboard/Phasor: support 'inactive' function like real hardware
|
||||
. [Bug #308] SSC ACIA Status register's interrupt bit not set when IRQ enabled and using TCP Port 1977
|
||||
. [Bug #269] When stepping, ESC no longer exits back to debugger (use F7, Pause keys or Debugger button instead).
|
||||
. [Bug #250] Debugger: When MODE_STEPPING, fix issue with disk LEDs staying on
|
||||
. [Bug #217] Debugger G(o) command should use normal speed
|
||||
|
|
|
@ -1,4 +1,14 @@
|
|||
/*
|
||||
.12 GH-PR#480:
|
||||
GH#462: Default to Shift+Left Click to toggle diasm columns
|
||||
Use 'disasm click <n>' to reconfigure this
|
||||
GH#473: Fixed bug caused by Util_MemoryTextFile, Line 51 not zero-terminating buffer by invalidating it.
|
||||
GH#476: Fixed off-by-one bug wrapping in debugger console
|
||||
GH#483: Shift+Left mouse button to toggle 6502 Status flag bits
|
||||
GH#484: Some corrections to APPLE2E.SYM
|
||||
.11 Added:"Warning" for long symbols when symbol table is loaded
|
||||
.10 Changed: "Warning" of symbols that alias to "Info."
|
||||
.9 Continuation of 2.8.0.8: Fix overflowing disassembly pane for long symbols
|
||||
.8 Fixed: Inactive Language Card bank now grayed out, main memory no longer double inverse.
|
||||
.7 Fixed: Memory softswitches are now in chronological order, and their background is a dark grey
|
||||
.6 Added: Read/Write for Main/Aux memory now shown
|
||||
|
|
136
docs/VICE Knowledge Base - Article 13-005.htm
Normal file
136
docs/VICE Knowledge Base - Article 13-005.htm
Normal file
|
@ -0,0 +1,136 @@
|
|||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||
<html><head>
|
||||
|
||||
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
|
||||
<meta name="author" content="Spiro Trikaliotis">
|
||||
<meta name="copyright" content="© 2003-2007 Spiro Trikaliotis and the VICE team">
|
||||
<link rel="stylesheet" href="VICE%20Knowledge%20Base%20-%20Article%2013-005_files/vicekb.css" title="My own stylesheet">
|
||||
<meta name="keywords" content="vice knowledge base,vkb,x64,x128,xplus4,xcbm,xvic">
|
||||
<title>VICE Knowledge Base - Article 13-005</title>
|
||||
</head>
|
||||
<body>
|
||||
<!--#config timefmt="%d.%b.%Y %H:%M" -->
|
||||
<div class="top">
|
||||
<div class="title">
|
||||
<h1>
|
||||
<a href="http://web.archive.org/web/20130517193701/http://www.viceteam.org/">
|
||||
<img alt="VICE home" src="VICE%20Knowledge%20Base%20-%20Article%2013-005_files/vice-logo.png" width="120" height="45" border="0"></a>
|
||||
Knowledge Base - Article 13-005</h1>
|
||||
</div> <!-- title -->
|
||||
<hr>
|
||||
</div> <!-- top -->
|
||||
<div class="main">
|
||||
<div class="sidebar">
|
||||
<p>Article ID: 13-005</p>
|
||||
<p><b>Last Reviewed:</b><br>August 25, 2004</p>
|
||||
<p><a title="Send this article to a friend" href="http://web.archive.org/web/20130517193701/mailto:/?subject=VICE%20Knowledge%20Base%20Article%20-%2013-005&body=This%20article%20pointer%20was%20forwarded%20to%20you%20from%20the%20VICE%20Knowledge%20Base%20site.%20http://vicekb.trikaliotis.net/13-005">
|
||||
<img src="VICE%20Knowledge%20Base%20-%20Article%2013-005_files/icoEmail.gif" width="18" height="10" border="0" align="absMiddle">Send to a friend</a></p>
|
||||
<p>Provided by<br><a target="_top" href="http://web.archive.org/web/20130517193701/http://www.viceteam.org/">The VICE team</a></p>
|
||||
<p>If you want to bookmark this page or refer to it, use the following URL only, please:<br>
|
||||
<a href="http://web.archive.org/web/20130517193701/http://vicekb.trikaliotis.net/13-005">http://vicekb.trikaliotis.net/13-005</a>
|
||||
</p><hr>
|
||||
</div> <!-- sidebar -->
|
||||
<div class="content">
|
||||
<h1>[Howto] Enable networking with WinVICE</h1>
|
||||
<hr>
|
||||
The information in this article applies to the following versions of VICE: <ul><li>all Windows versions starting from 1.13</li></ul>
|
||||
<hr><h2>PROBLEMEXPOSITION</h2>
|
||||
<p>Starting with WinVICE 1.13, there is support for two ethernet cartridges allowing network access: The "<a href="http://web.archive.org/web/20130517193701/http://www.dunkels.com/adam/tfe/">The Final
|
||||
Ethernet</a>" (TFE) and the "Retroreplay-Net" (RR-Net) cartridges. If you
|
||||
want to enable support for these, you have to follow the instructions below.</p><h2>!WARNING!</h2>
|
||||
<p>Installing support for networking with VICE requires you to install
|
||||
3rd party products on your machine. The VICE team cannot be
|
||||
made responsible for any problems
|
||||
and/or damage which arises from this! The rejection of any
|
||||
warranty for VICE
|
||||
applies, too.<br>
|
||||
The product which has to be installed, <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/">WinPCAP</a>,
|
||||
is a capture library. That is, it captures <b>every</b> packet which is available
|
||||
on the network, regardless if it was destined for your machine or not. From this, it
|
||||
follows that it is a real security flaw using WinPCAP in a network. Using WinPCAP
|
||||
can result in disclosure of any information that is available on your network which is
|
||||
not secured by other means! Installing WinPCAP, you acknowledge that you're well aware
|
||||
of this security flaw and that the VICE team cannot be made responsible for any problems
|
||||
and/or damage which may arise from the use of WinPCAP!</p><h2>PREREQUISITES</h2>
|
||||
<p>At that moment, The ethernet emulation for WinVICE only works if you
|
||||
have a real ethernet card on your machine and you are
|
||||
connected to the net via it, that is, you must have
|
||||
direct access to any station you want to access. Ethernet
|
||||
is emulated as if the VICE emulator was
|
||||
connected to your ethernet card via a hub. Every protocol,
|
||||
in particular PPPOE or other protocols,
|
||||
are only supported if the corresponding emulated program
|
||||
supports these!</p><h2>SOLUTION</h2>
|
||||
<p></p><p>For networking support, you need administrative rights
|
||||
(administrator account or similar) on your windows machine.
|
||||
Without this, there's no chance to have networking work!</p>
|
||||
<p>If you have administrative rights, follow the following instructions to install networking
|
||||
with VICE:</p>
|
||||
<ul><li>First, read the above warning!</li><li>Get <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/">WinPCAP</a>
|
||||
from their site. There's only need for the WinPCAP auto-installer in order to let VICE run.</li>
|
||||
<li>Install the WinPCAP package you just downloaded. For this, you need to have the right to install
|
||||
new drivers to your system. In general, the administrator account does have this right.</li>
|
||||
<li>Now, start WinVICE as you do always. Do this with the user account you have used in the previous
|
||||
step to install WinPCAP! Choosing the VICE menu entry Settings/Ethernet, a dialog box
|
||||
shows up, allowing you to select Ethernet as NONE, TFE ("The final ethernet") or RR-Net. If this
|
||||
is possible, WinPCAP has be installed successfully to your system. If not, check the <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm">WinPCAP FAQ</a> to find a solution.</li>
|
||||
<li>The only program using ethernet we know to date is <a href="http://web.archive.org/web/20130517193701/http://dunkels.com/adam/contiki/index.html">Contiki</a>. To use Contiki, get a version of it
|
||||
from <a href="http://web.archive.org/web/20130517193701/http://dunkels.com/adam/contiki/index.html">the website</a>. Make sure that it is
|
||||
a version which is enabled for ethernet (TFE or RR-Net)!</li>
|
||||
<li>Run this version of Contiki inside x64. Now, enable ethernet with TFE or RR-Net settings, depending
|
||||
on which type you want to use. Since these two are almost identical, only some addresses are changed,
|
||||
it's more of a matter of taste which one to use. Select the ethernet device you want to use with
|
||||
ethernet if you have more than one.
|
||||
</li><li>You need an IP address in order to let Contiki run on your network. The virtual ethernet device
|
||||
of VICE runs as if it were connected to your host computer's device with a hub. No network address
|
||||
translation (NAT) or the like is performed! Get an IP from your network administrator as if you had
|
||||
a new machine to connect to your network. In fact, you have one, although it is only emulated.</li>
|
||||
<li> Now, run Contiki, enter your IP configuration using the IP from above, and everything should
|
||||
work.</li></ul>
|
||||
<p>Enjoy the new surfing experience.</p>
|
||||
<p>It's not necessary to log on as administrator in order to run the ethernet emulation. Anyway,
|
||||
this <b>is</b> necessary the first time you start VICE after you've booted. After you've done
|
||||
this, you can log off and log in with another account to run VICE. To circumvent this, see
|
||||
the FAQ section below.</p><h2>FAQ</h2>
|
||||
<p></p><ul><li><p><b>Why do I have to log in as administrator in order to start VICE with network support?</b></p><p>This is because the WinPCAP driver is not loaded at system startup, but rather
|
||||
on-demand when someone like VICE needs it. Not every user is allowed to start services, thus, you
|
||||
have to log in as a user with these rights in order to start it. The administrator is a person having
|
||||
this right. On many machines, an account belonging to the "main user" group is allowed,
|
||||
too. On these machines, you don't need administrator rights in order to start VICE with networking
|
||||
support.</p><p>If you don't like this solution, you have another option. See <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm#Q-18">Q-18</a> at the WinPCAP FAQ.</p></li>
|
||||
<li><p><b>I have problems with networking support; furthermore, there's a firewall on my machine</b></p>
|
||||
<p>This is a know problem with WinPCAP, it does not work well with all firewalls, see <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm#Q-10">Q-10</a> at the WinPCAP FAQ. Unfortunately, we don't
|
||||
have a solution for this. Disabling the firewall, as suggested in Q-10, might not be an option for
|
||||
you, but we cannot do anything about it.</p></li>
|
||||
<li><p><b>I have another problem not covered here.</b></p><p>Have a look at the <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm">WinPCAP FAQ</a>, there might be a solution for your problem.
|
||||
</p></li></ul><p></p><h2>STATUS</h2>
|
||||
<p>This document is for information purpose only. The behaviour reported
|
||||
is intentional in the VICE versions listed at the beginning
|
||||
of this article.</p><h2>LINKS</h2>
|
||||
<p></p><ul><li><a href="http://web.archive.org/web/20130517193701/http://vicekb.trikaliotis.net/11-002">11-002 [Howto] Enable networking on VICE/Unix</a>.</li> <li>The Final Ethernet Homepage: <a href="http://web.archive.org/web/20130517193701/http://www.dunkels.com/adam/tfe/">http://www.dunkels.com/adam/tfe/</a>.</li><li>
|
||||
Contiki Homepage:
|
||||
<a href="http://web.archive.org/web/20130517193701/http://dunkels.com/adam/contiki/index.html">http://dunkels.com/adam/contiki/index.html</a>.
|
||||
</li><li>WinPCAP: <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/">http://winpcap.polito.it/</a>.
|
||||
</li><li><a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm">WinPCAP FAQ</a>, especially
|
||||
<a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm#Q-10">Q-10</a> and <a href="http://web.archive.org/web/20130517193701/http://winpcap.polito.it/misc/faq.htm#Q-18">Q-18</a>.</li></ul><p></p><h2>REVISION</h2>
|
||||
<p></p><ul><li>August 25,2004: Added reference to the same information for Unix based systems</li> <li>October 14, 2003: Before, it was mistakenly said that you find ethernet on
|
||||
Options/Ethernet. This is not true, it is Settings/Ethernet.</li>
|
||||
<li>October 8, 2003: Added section PREREQUISITES.</li>
|
||||
<li>September 15, 2003: Original release of this document</li></ul><p></p> </div> <!-- content -->
|
||||
<div class="review">
|
||||
<p>Last Reviewed: August 25, 2004</p>
|
||||
</div> <!-- review -->
|
||||
</div> <!-- main -->
|
||||
<div class="footer">
|
||||
<hr>
|
||||
<div class="copyright"> © 2003-2007 <a href="http://web.archive.org/web/20130517193701/mailto:www@@trikaliotis.net">Spiro Trikaliotis</a> and <a href="http://web.archive.org/web/20130517193701/http://www.viceteam.org/">The VICE team</a><br>
|
||||
<a href="http://web.archive.org/web/20130517193701/http://vicekb.trikaliotis.net/13-005">http://vicekb.trikaliotis.net/13-005</a>
|
||||
Last modified: August 25, 2004
|
||||
</div> <!-- copyright -->
|
||||
<div class="fileinfo">
|
||||
<a href="http://web.archive.org/web/20130517193701/http://www.anybrowser.org/campaign/"><img src="VICE%20Knowledge%20Base%20-%20Article%2013-005_files/ab-ms-star-en.gif" alt="Viewable With Any Browser" width="88" height="31"></a><a href="http://web.archive.org/web/20130517193701/http://jigsaw.w3.org/css-validator/validator?uri=http://www.trikaliotis.net/vicekb/common/vicekb.css">
|
||||
<img style="border:0;width:88px;height:31px" src="VICE%20Knowledge%20Base%20-%20Article%2013-005_files/vcss.gif" alt="Valid CSS!"></a>
|
||||
</div> <!-- fileinfo -->
|
||||
</div> <!-- footer -->
|
||||
|
||||
</body></html>
|
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
BIN
docs/VICE Knowledge Base - Article 13-005_files/icoEmail.gif
Normal file
BIN
docs/VICE Knowledge Base - Article 13-005_files/icoEmail.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 106 B |
BIN
docs/VICE Knowledge Base - Article 13-005_files/vcss.gif
Normal file
BIN
docs/VICE Knowledge Base - Article 13-005_files/vcss.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
BIN
docs/VICE Knowledge Base - Article 13-005_files/vice-logo.png
Normal file
BIN
docs/VICE Knowledge Base - Article 13-005_files/vice-logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
78
docs/VICE Knowledge Base - Article 13-005_files/vicekb.css
Normal file
78
docs/VICE Knowledge Base - Article 13-005_files/vicekb.css
Normal file
|
@ -0,0 +1,78 @@
|
|||
BODY {
|
||||
FONT-FAMILY: Helvetica, Arial, Tahoma, sans-serif
|
||||
}
|
||||
DIV.top {
|
||||
MARGIN-TOP: 0pt; MARGIN-BOTTOM: 6pt
|
||||
}
|
||||
DIV.top.title {
|
||||
center; FLOAT: right; MARGIN-LEFT: 20%
|
||||
}
|
||||
DIV.top.title P {
|
||||
text-align: center; color: red
|
||||
}
|
||||
DIV.top.logo {
|
||||
FLOAT: left; WIDTH: 20%; MARGIN-RIGHT: 80%
|
||||
}
|
||||
|
||||
DIV.main {
|
||||
}
|
||||
|
||||
DIV.sidebar {
|
||||
MARGIN-TOP: 0pt; FLOAT: right; MARGIN-BOTTOM: 6pt; WIDTH: 30%
|
||||
}
|
||||
|
||||
DIV.sidebar P {
|
||||
FONT-SIZE: 8pt; MARGIN: 0pt 2pt 6pt 36pt
|
||||
}
|
||||
|
||||
DIV.main.content {
|
||||
MARGIN-RIGHT: 30%
|
||||
PADDING-RIGHT: 2pt; PADDING-LEFT: 2pt; PADDING-BOTTOM: 2pt; PADDING-TOP: 2pt
|
||||
}
|
||||
DIV.main.content P {
|
||||
FONT-SIZE: 12pt; MARGIN: 0pt 2pt 6pt 36pt
|
||||
}
|
||||
DIV.main.content P.centered {
|
||||
FONT-SIZE: 12pt; MARGIN: 0pt 2pt 6pt; TEXT-ALIGN: center
|
||||
}
|
||||
DIV.main.content ui {
|
||||
MARGIN: 0pt 0pt 6pt
|
||||
}
|
||||
DIV.main.content li {
|
||||
FONT-SIZE: 12pt
|
||||
}
|
||||
DIV.main.content h1 {
|
||||
FONT-SIZE: 20pt
|
||||
}
|
||||
DIV.content h2 {
|
||||
FONT-SIZE: 15pt
|
||||
}
|
||||
DIV.content hr {
|
||||
MARGIN-RIGHT: 30%; HEIGHT: 3pt
|
||||
}
|
||||
|
||||
DIV.main.content P {
|
||||
}
|
||||
|
||||
DIV.footer {
|
||||
PADDING-RIGHT: 2pt; MARGIN-TOP: 6pt; PADDING-LEFT: 2pt; FLOAT: left; MARGIN-BOTTOM: 0pt; PADDING-BOTTOM: 2pt; VERTICAL-ALIGN: baseline; WIDTH: 100%; PADDING-TOP: 2pt
|
||||
}
|
||||
|
||||
DIV.copyright {
|
||||
FONT-SIZE: 60%; FLOAT: left
|
||||
}
|
||||
DIV.review {
|
||||
text-align: center; FONT-SIZE: 8pt
|
||||
}
|
||||
DIV.fileinfo {
|
||||
FONT-SIZE: 60%; FLOAT: right
|
||||
}
|
||||
|
||||
/*
|
||||
FILE ARCHIVED ON 03:57:53 Jul 19, 2013 AND RETRIEVED FROM THE
|
||||
INTERNET ARCHIVE ON 21:23:25 Dec 18, 2017.
|
||||
JAVASCRIPT APPENDED BY WAYBACK MACHINE, COPYRIGHT INTERNET ARCHIVE.
|
||||
|
||||
ALL OTHER CONTENT MAY ALSO BE PROTECTED BY COPYRIGHT (17 U.S.C.
|
||||
SECTION 108(a)(3)).
|
||||
*/
|
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>Save-State Files</title>
|
||||
<title>Command line</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="FONT-FAMILY: verdana; BACKGROUND-COLOR: rgb(255,255,255)" alink="#008000"
|
||||
|
@ -55,7 +55,9 @@
|
|||
-load-state <savestate><br>
|
||||
Load a save-state file<br><br>
|
||||
-modem<br>
|
||||
Shorthand for passing -dtr -dcd -dsr<br><br>
|
||||
Shorthand for passing -dtr -dcd -dsr<br>
|
||||
Use with GBBS Pro (or any other BBS package). See the <a href="http://www.callapple.org/documentation/books/gbbs-pro-2-2/">GBBS Pro 2.2</a> book from Call-A.P.P.L.E.
|
||||
<br><br>
|
||||
-dtr<br>
|
||||
Support SSC's DTR (Data Terminal Ready) control bit<br><br>
|
||||
-dcd<br>
|
||||
|
|
|
@ -89,7 +89,14 @@
|
|||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Uthernet network card">
|
||||
<param name="Local" value="uthernet.html">
|
||||
<param name="ImageNumber" value="2">
|
||||
</OBJECT>
|
||||
<UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="WiFi workaround">
|
||||
<param name="Local" value="uthernet-wifi-workaround.html">
|
||||
</OBJECT>
|
||||
</UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Command line">
|
||||
<param name="Local" value="CommandLine.html">
|
||||
|
@ -141,9 +148,13 @@
|
|||
</OBJECT>
|
||||
<UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Entering the debugger">
|
||||
<param name="Name" value="Entering & exiting the debugger">
|
||||
<param name="Local" value="dbg-entering-debugger.html">
|
||||
</OBJECT>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Debugger Screen Layout">
|
||||
<param name="Local" value="dbg-screen-layout.html">
|
||||
</OBJECT>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Scrolling">
|
||||
<param name="Local" value="dbg-scrolling.html">
|
||||
|
@ -185,10 +196,6 @@
|
|||
<param name="Local" value="dbg-configuration.html">
|
||||
</OBJECT>
|
||||
</UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Troubleshooting">
|
||||
<param name="Local" value="Troubleshooting.html">
|
||||
</OBJECT>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Resources">
|
||||
<param name="Local" value="resources.html">
|
||||
|
@ -208,6 +215,21 @@
|
|||
<param name="Local" value="contact.html">
|
||||
</OBJECT>
|
||||
</UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Appendix">
|
||||
<param name="Local" value="appendix.html">
|
||||
<param name="ImageNumber" value="2">
|
||||
</OBJECT>
|
||||
<UL>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Full-speed mode">
|
||||
<param name="Local" value="fullspeed.html">
|
||||
</OBJECT>
|
||||
<LI> <OBJECT type="text/sitemap">
|
||||
<param name="Name" value="Troubleshooting">
|
||||
<param name="Local" value="Troubleshooting.html">
|
||||
</OBJECT>
|
||||
</UL>
|
||||
</UL>
|
||||
</UL>
|
||||
</BODY></HTML>
|
||||
|
|
|
@ -13,13 +13,13 @@
|
|||
<p style="MARGIN-LEFT: 40px">Thomas Stahl: TV emulation mode (up to v1.25.0.4)</p>
|
||||
<p style="MARGIN-LEFT: 40px">Chris Foxwell: SSI263 phoneme samples</p>
|
||||
<p style="MARGIN-LEFT: 40px">Robert Hoem: Hard disk card (source module & f/w)</p>
|
||||
<p style="MARGIN-LEFT: 40px">VICE team: TFE, Z80, MC6821 PIA emulation modules (<a href="http://www.viceteam.org">http://www.viceteam.org</a>)<br>
|
||||
<p style="MARGIN-LEFT: 40px">VICE team: TFE, Z80, MC6821 PIA emulation modules (<a href="http://vice-emu.sourceforge.net/index.html#developers">http://vice-emu.sourceforge.net/index.html#developers</a>)<br>
|
||||
- In particular, Spiro Trikaliotis for TFE, whose code Glenn Jones adapted for Uthernet support</p>
|
||||
<p style="MARGIN-LEFT: 40px">FUSE team: AY-3-8910 module (<a href="http://fuse-emulator.sourceforge.net">http://fuse-emulator.sourceforge.net</a>)</p>
|
||||
<p style="MARGIN-LEFT: 40px">Kyle Kim: Mouse card support based on code from Apple in PC</p>
|
||||
<p style="MARGIN-LEFT: 40px">Fábio Belavenuto: TK3000 Brazilian //e clone (originally responsible for integrating Z80Em)</p>
|
||||
<p style="MARGIN-LEFT: 40px">Bob Sander-Cederlof: Applesoft Symbols (<a href="http://www.txbobsc.com/scsc/scdocumentor/index.html">http://www.txbobsc.com/scsc/scdocumentor/</a> S-C DocuMentor: Applesoft)</p>
|
||||
<p style="MARGIN-LEFT: 40px">David Schmidt: Updates to this help file</p>
|
||||
<p style="MARGIN-LEFT: 40px">Mike Harvey, Founder & Editor of Nibble Magazine: For providing us Apple fans the pleasure of eagerly awaiting each next month's issue to learn about the Apple! (<a href="http://www.nibblemagazine.net/">http://www.nibblemagazine.net/</a>)</p>
|
||||
<p style="MARGIN-LEFT: 40px">Mike Harvey, Founder & Editor of Nibble Magazine: For providing us Apple fans the pleasure of eagerly awaiting each next month's issue to learn about the Apple! (<a href="http://www.nibblemagazine.com/">http://www.nibblemagazine.com/</a>)</p>
|
||||
</body>
|
||||
</html>
|
||||
|
|
24
help/appendix.html
Normal file
24
help/appendix.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
||||
<title>Appendix</title>
|
||||
|
||||
|
||||
</head>
|
||||
|
||||
|
||||
<body style="background-color: rgb(255, 255, 255); font-family: verdana;" alink="#008000" link="#008000" vlink="#008000">
|
||||
|
||||
<h2 style="color: rgb(0, 128, 0);">Appendix</h2>
|
||||
|
||||
<hr size="4">
|
||||
|
||||
<ul>
|
||||
<li><a href="fullspeed.html">Full-speed mode</a></li>
|
||||
<li><a href="Troubleshooting.html">Troubleshooting</a></li>
|
||||
</ul>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -5,12 +5,12 @@
|
|||
<meta http-equiv="CONTENT-TYPE" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="DIRECTION: ltr" lang="en-US">
|
||||
<h2><a name="Debugger"></a>Entering the Debugger</h2>
|
||||
<h2><a name="Entering-Debugger"></a>Entering the Debugger</h2>
|
||||
<p>Start AppleWin, and press <b><font face="Courier, monospace">F7</font></b> to
|
||||
enter the debugger.</p>
|
||||
<p>The first thing you'll probably notice is the new syntax coloring in the
|
||||
disassembly view, and info panel. All the colors can be customized to
|
||||
your liking. See the <a href="#Colors">Colors</a> section for details.</p>
|
||||
your liking. See the <a href="dbg-configuration.html#Colors">Colors</a> section for details.</p>
|
||||
<p>Since the mini-console isn't the full width of the screen, you can toggle
|
||||
between the full-screen console with the tilde '~' key. This style of table
|
||||
will be used to designate which keys the debugger will recognize.</p>
|
||||
|
@ -122,7 +122,7 @@
|
|||
<br>
|
||||
</p>
|
||||
|
||||
<h2><a name="Debugger"></a>Exiting the Debugger</h2>
|
||||
<h2><a name="Exiting-Debugger"></a>Exiting the Debugger</h2>
|
||||
<p>In general, press <b><font face="Courier, monospace">F7</font></b> to exit the debugger.<br>
|
||||
NB. If you have breakpoints set then you will exit the debugger in 'stepping' mode.<br><br>
|
||||
Other ways to exit the debugger and force 'stepping' mode are:
|
||||
|
@ -152,7 +152,7 @@
|
|||
</tr>
|
||||
<tr>
|
||||
<td width="14%">
|
||||
<p>g</p>
|
||||
<p>G</p>
|
||||
</td>
|
||||
<td width="25%">
|
||||
<p>yes</p>
|
||||
|
@ -169,7 +169,7 @@
|
|||
</tr>
|
||||
<tr>
|
||||
<td width="14%">
|
||||
<p>gg</p>
|
||||
<p>GG</p>
|
||||
</td>
|
||||
<td width="25%">
|
||||
<p>no</p>
|
||||
|
|
|
@ -202,8 +202,8 @@
|
|||
</tr>
|
||||
<tr bgcolor="#cccccc">
|
||||
<td width="35%">
|
||||
<p>G [StopAddress]
|
||||
</p>
|
||||
<p>G [StopAddress]<br>
|
||||
GG [StopAddress]</p>
|
||||
</td>
|
||||
<td width="65%">
|
||||
<p><i>Resume execution until PC = StopAddress.</i></p>
|
||||
|
@ -211,7 +211,8 @@
|
|||
</tr>
|
||||
<tr bgcolor="#999999">
|
||||
<td width="35%">
|
||||
<p>G [StopAddress] [SkipAddress,Length]</p>
|
||||
<p>G [StopAddress] [SkipAddress,Length]<br>
|
||||
GG [StopAddress] [SkipAddress,Length]</p>
|
||||
</td>
|
||||
<td width="65%">
|
||||
<p><i>Resume execution until PC = StopAddress.<br>
|
||||
|
@ -224,11 +225,13 @@
|
|||
<p>####G</p>
|
||||
</td>
|
||||
<td width="65%">
|
||||
<p><i>Alias for: R PC [=] address.</i></p>
|
||||
<p><i>Alias for: R PC [=] address and then G.</i></p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p><br>NB. The GG command resumes execution in full-speed. See <a href="dbg-entering-debugger.html#Exiting-Debugger">Exiting the Debugger</a>.
|
||||
</p>
|
||||
<p><br>
|
||||
<br>
|
||||
</p>
|
||||
|
|
|
@ -6,13 +6,14 @@
|
|||
</head>
|
||||
<body style="DIRECTION: ltr" lang="en-US">
|
||||
<h1>Flags</h1>
|
||||
<p>Each flag can individually be set or cleared on the Processor Status Register ('<b>P</b>').
|
||||
<p>Each flag can individually be set or cleared in the Processor Status Register ('<b>P</b>').
|
||||
Cleared flags will show up with a normal background. Set flags will show
|
||||
with an inverse background.
|
||||
</p>
|
||||
<br>
|
||||
<p><font size="4"><b>Notes</b>:</font></p>
|
||||
<ul>
|
||||
<li> Shift+Left mouse button can be used to toggle the state of individual flags.</li>
|
||||
<li>
|
||||
<p style="MARGIN-BOTTOM: 0in"><i>The legacy commands <b>R</b>? and <b>S</b>?, where? is
|
||||
a flag name (C,Z,I,D,B,R,V,N) has been left in.</i></p>
|
||||
|
|
56
help/dbg-screen-layout.html
Normal file
56
help/dbg-screen-layout.html
Normal file
|
@ -0,0 +1,56 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>AppleWin Debugger Tutorial</title>
|
||||
<meta http-equiv="CONTENT-TYPE" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="DIRECTION: ltr" lang="en-US">
|
||||
<h2></a><a name="Debugger Screen Layout"></a>Debugger Screen Layout</h2>
|
||||
<p>This section gives an overview of the debugger's screen layout.</p>
|
||||
|
||||
<p>Here's a typical debugger view (with annotations describing the parts):</p>
|
||||
|
||||
<img src="img/debugger-layout-annotated.png" hspace="5" vspace="5">
|
||||
|
||||
<h3><a name="Soft-switches"></a>Soft-switches</h3>
|
||||
<p>This encodes information about the video and MMU soft-switches.</p>
|
||||
|
||||
<p>The first 5 rows describe the current <b>video</b> settings and can be interpreted as follows:
|
||||
<ul>
|
||||
<li>50: $C050 - GR /TEXT (inverse indicates which is active)
|
||||
<li>52: $C052 - FULL/MIX (inverse indicates which is active)
|
||||
<li>54: $C054 - PAGE 1/2 (inverse indicates which is active)
|
||||
<li>56: $C056 - LO/HIRES (inverse indicates which is active)
|
||||
<li>5E: $C05E - DHGR/HGR (inverse indicates which is active)
|
||||
</ul>
|
||||
</p>
|
||||
|
||||
<p>The next 6 rows describe the current <b>MMU</b> settings and can be interpreted as follows:
|
||||
<ul>
|
||||
<li>00: $C000 - 80Sto0/1 (inverse indicates state of 80STORE)
|
||||
<li>02: $C002-C005: Rm/xWm/x (NB. 'R' is blue and 'W' is red for readability)
|
||||
<ul>
|
||||
<li>Rm Read from main mem for $0200-$BFFF; Use OUT C002 to enable
|
||||
<li>Rx Read from aux mem for $0200-$BFFF; Use OUT C003 to enable
|
||||
<li>Wm Write to main mem for $0200-$BFFF; Use OUT C004 to enable
|
||||
<li>Wx Write to aux mem for $0200-$BFFF; Use OUT C005 to enable
|
||||
</ul>
|
||||
<li>0C: $C00C - Col40/80 (inverse indicates state of 80COL)
|
||||
<li>0E: $C00E - ASC/MOUS (inverse indicates state of ALTCHARSET)
|
||||
<li>80: $C080-C087: B2/M R/W (Language Card Bank2)
|
||||
<li>88: $C088-C08F: B1/M rNN (Language Card Bank1 and RAMworks 64K bank number)
|
||||
<ul>
|
||||
<li>'B2' or 'B1' is inverse when that LC bank is enabled.
|
||||
<li>If 'M' is inverse: ROM is active for reading.
|
||||
<li>If 'M' is not inverse: LC2 or LC1 RAM is active.
|
||||
<li>If 'W' is inverse: RAM is write enabled.
|
||||
<li>If 'W' is not inverse: RAM is write protected.
|
||||
<li>'rNN' will appear if a RAMworks 64K bank is active.
|
||||
</ul>
|
||||
</ul>
|
||||
</p>
|
||||
|
||||
<p style="MARGIN-BOTTOM: 0in"><br>
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
|
@ -10,49 +10,29 @@
|
|||
<P><FONT size="3">Revision 3. Mar 12, 2006.</FONT></P>
|
||||
<H2>Table of Contents</H2>
|
||||
<UL>
|
||||
<LI>
|
||||
<A href="#Introduction">Introduction</A>
|
||||
<LI>
|
||||
<A href="dbg-entering-debugger.html">Entering and exiting the Debugger</A>
|
||||
<LI>
|
||||
<A href="dbg-scrolling.html">Scrolling</A>
|
||||
<LI>
|
||||
<A href="dbg-registers.html">Registers</A>
|
||||
<LI>
|
||||
<A href="dbg-flags.html">Flags</A>
|
||||
<LI>
|
||||
<A href="dbg-execution.html">Execution</A>
|
||||
<LI>
|
||||
<A href="dbg-memory.html">Memory</A>
|
||||
<LI><A href="#Introduction">Introduction</A>
|
||||
<LI><A href="dbg-entering-debugger.html">Entering and exiting the Debugger</A>
|
||||
<LI><A href="dbg-screen-layout.html">Debugger Screen Layout</A>
|
||||
<LI><A href="dbg-scrolling.html">Scrolling</A>
|
||||
<LI><A href="dbg-registers.html">Registers</A>
|
||||
<LI><A href="dbg-flags.html">Flags</A>
|
||||
<LI><A href="dbg-execution.html">Execution</A>
|
||||
<LI><A href="dbg-memory.html">Memory</A>
|
||||
<UL>
|
||||
<LI>
|
||||
<A href="dbg-memory.html#Memory_View">Viewing Memory</A>
|
||||
<LI>
|
||||
<A href="dbg-memory.html#Memory_Search">Searching Memory</A>
|
||||
<LI>
|
||||
<A href="dbg-memory.html#Memory_Change">Changing Memory</A>
|
||||
</LI>
|
||||
<LI><A href="dbg-memory.html#Memory_View">Viewing Memory</A>
|
||||
<LI><A href="dbg-memory.html#Memory_Search">Searching Memory</A>
|
||||
<LI><A href="dbg-memory.html#Memory_Change">Changing Memory</A>
|
||||
</UL>
|
||||
<LI>
|
||||
<A href="dbg-symbols.html">Symbols</A>
|
||||
<LI>
|
||||
<A href="dbg-calculator.html">Calculator</A>
|
||||
<LI>
|
||||
<A href="dbg-windows.html">Windows</A>
|
||||
<LI>
|
||||
<A href="dbg-breakpoints.html">Breakpoints</A>
|
||||
<LI>
|
||||
<A href="dbg-configuration.html">Configuration</A>
|
||||
<LI><A href="dbg-symbols.html">Symbols</A>
|
||||
<LI><A href="dbg-calculator.html">Calculator</A>
|
||||
<LI><A href="dbg-windows.html">Windows</A>
|
||||
<LI><A href="dbg-breakpoints.html">Breakpoints</A>
|
||||
<LI><A href="dbg-configuration.html">Configuration</A>
|
||||
<UL>
|
||||
<LI>
|
||||
<A href="dbg-configuration.html#Colors">Colors</A>
|
||||
<LI>
|
||||
<A href="dbg-configuration.html#Fonts">Fonts</A>
|
||||
<LI>
|
||||
<A href="dbg-configuration.html#Scripts">Scripts</A>
|
||||
<LI>
|
||||
<A href="dbg-configuration.html#Settings">Settings</A>
|
||||
</LI>
|
||||
<LI><A href="dbg-configuration.html#Colors">Colors</A>
|
||||
<LI><A href="dbg-configuration.html#Fonts">Fonts</A>
|
||||
<LI><A href="dbg-configuration.html#Scripts">Scripts</A>
|
||||
<LI><A href="dbg-configuration.html#Settings">Settings</A>
|
||||
</UL>
|
||||
</LI>
|
||||
</UL>
|
||||
|
|
|
@ -5,9 +5,9 @@
|
|||
<meta http-equiv="CONTENT-TYPE" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="DIRECTION: ltr" lang="en-US">
|
||||
<h2><a name="Calculator"></a><a name="Windows"></a>Windows</h2>
|
||||
<h2><a name="Windows"></a>Windows</h2>
|
||||
<p>Due to the amount of information available, the debugger now features
|
||||
"windows." You can switch to th full screen console to read the help, or
|
||||
"windows". You can switch to the full screen console to read the help, or
|
||||
to the data window to view memory.</p>
|
||||
<p><br>
|
||||
<br>
|
||||
|
|
51
help/fullspeed.html
Normal file
51
help/fullspeed.html
Normal file
|
@ -0,0 +1,51 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>Full-speed mode</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="FONT-FAMILY: verdana; BACKGROUND-COLOR: rgb(255,255,255)" alink="#008000"
|
||||
link="#008000" vlink="#008000">
|
||||
<h2 style="COLOR: rgb(0,128,0)">Full-speed mode</h2>
|
||||
<hr size="4">
|
||||
|
||||
<p style="FONT-WEIGHT: bold">Overview:</p>
|
||||
<p>Emulation can be run in full-speed (aka unthrottled) mode.</p>
|
||||
|
||||
<p style="FONT-WEIGHT: bold">Details:</p>
|
||||
<p>This can be enabled manually or automatically in a variety of ways:</p>
|
||||
|
||||
<ul>
|
||||
<li>Permanently enable by the AppleWin <a href="cfg-config.html">Configuration</a> tab's 'Emulation Speed Control', and setting 'Custom Speed (in MHz)' to 'Fastest'.
|
||||
<li>Scroll Lock key: can be configured to toggle normal/full-speed mode, or only enable full-speed when pressed.
|
||||
<ul>
|
||||
<li>See <a href="cfg-input.html">Input</a> for configuring how Scroll Lock behaves.
|
||||
</ul>
|
||||
<li>When 'Disk access speed' is set to 'Enhanced Speed' (the default), then whenever the Disk][ drive motor is on, the emulator will automatically switch to full-speed (and when the motor is switched off, then the emulator will automatically revert to what the 'Emulation Speed Control' has been set to).
|
||||
<ul>
|
||||
<li>See <a href="cfg-disk.html">Disk</a> for configuring 'Disk access speed'.
|
||||
</ul>
|
||||
<li>From the built-in debugger, single-stepping via the 'gg' command.
|
||||
</ul>
|
||||
|
||||
<p style="FONT-WEIGHT: bold">Limitations and things to bear in mind:</p>
|
||||
<ul>
|
||||
<li>Full speed mode favours speed over video accuracy:
|
||||
<ul>
|
||||
<li>The Apple II's video is only updated periodically (once a wall-clock 60Hz frame) instead of each opcode.
|
||||
</ul>
|
||||
<li>All sound (speaker, Mockingboard, etc) is muted.
|
||||
<li>Video-based timing/synchronisation loops won't work correctly.
|
||||
<ul>
|
||||
<li>The video-scanner won't advance its h/v position, so the floating bus will always return the same value.
|
||||
<li>Specifically code that does Apple II+ VBlank detection (using the floating bus) will hang, until full-speed mode is disabled. (But Apple //e soft-switch VBlank detection does work.)
|
||||
</ul>
|
||||
<li>Card detection routines (that rely on floating bus) won't work correctly.
|
||||
<li>One of your PC's CPU cores will run at 100%.
|
||||
<ul>
|
||||
<li>EG. Simply boot the Apple II (or //e) without a disk in drive-1.
|
||||
</ul>
|
||||
</ul>
|
||||
|
||||
</body>
|
||||
</html>
|
BIN
help/img/debugger-layout-annotated.png
Normal file
BIN
help/img/debugger-layout-annotated.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 54 KiB |
|
@ -43,15 +43,12 @@
|
|||
key will pause emulation. Press
|
||||
<span style="font-style: italic;">Pause</span>
|
||||
again to resume emulation.</p>
|
||||
<p><span style="font-weight: bold;">Scroll Lock:</span><br>
|
||||
Holding down the PC's
|
||||
<span style="font-style: italic;">Scroll Lock</span>
|
||||
key temporarily sets the emulation to full speed (i.e. unthrottled).<br>
|
||||
<p><span style="font-weight: bold;">Scroll Lock:</span><br>
|
||||
<span style="font-style: italic;">Scroll Lock</span>
|
||||
key can be configured to toggle normal/full-speed mode, or only enable full-speed when pressed. See <a href="cfg-input.html">Input</a> for configuring how <span style="font-style: italic;">Scroll Lock</span> behaves.
|
||||
NOTE: The status of the PC's
|
||||
<span style="font-style: italic;">Scroll Lock</span>
|
||||
LED is meaningless. The emulator will only run full speed while the
|
||||
<span style="font-style: italic;">Scroll Lock</span>
|
||||
key is pressed down.</p>
|
||||
LED is meaningless.</p>
|
||||
<p><span style="font-weight: bold;">Shift+Insert:</span><br>
|
||||
Paste text from Windows' clipboard. Text gets fed a character at a time to the
|
||||
Apple's keyboard hardware. The 'CR+LF' combination gets converted to CR.</p>
|
||||
|
|
BIN
help/resources/Debugger-screen-layout.pptx
Normal file
BIN
help/resources/Debugger-screen-layout.pptx
Normal file
Binary file not shown.
BIN
help/resources/debugger-layout.png
Normal file
BIN
help/resources/debugger-layout.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 26 KiB |
|
@ -12,28 +12,30 @@
|
|||
Copyright © 1994-1996, Michael O'Brien<br>
|
||||
Copyright © 2001, Oliver Schmidt<br>
|
||||
Copyright © 2002-2005, Tom Charlesworth<BR>
|
||||
Copyright © 2006-2016, Tom Charlesworth, Michael Pohoreski, Nick Westgate, Linards Ticmanis
|
||||
Copyright © 2006-2017, Tom Charlesworth, Michael Pohoreski, Nick Westgate, Linards Ticmanis
|
||||
<br>
|
||||
<br>
|
||||
<a href="applewin-team.html">AppleWin team</a>
|
||||
<br>
|
||||
<a href="acknowledgements.html">Acknowledgements</a>
|
||||
<br>
|
||||
<br>
|
||||
Select one of the following categories:
|
||||
<ul>
|
||||
<li>
|
||||
<a href="quickstart.html">Quick Start</a>
|
||||
<li>
|
||||
<a href="history.html">Historical Information</a>
|
||||
<li>
|
||||
<a href="diskimages.html">Disks and Disk Images</a>
|
||||
<li>
|
||||
<a href="toolbar.html">Using the Toolbar</a>
|
||||
<li>
|
||||
<a href="keyboard.html">Using the Keyboard</a>
|
||||
<li>
|
||||
<a href="dbg-toc-intro.html">Using the Debugger</a>
|
||||
<li>
|
||||
<a href="resources.html">Resources</a></li>
|
||||
<li><a href="quickstart.html">Quick Start</a>
|
||||
<li><a href="history.html">Historical Information</a>
|
||||
<li><a href="diskimages.html">Disks and Disk Images</a>
|
||||
<li><a href="toolbar.html">Using the Toolbar</a>
|
||||
<li><a href="keyboard.html">Using the Keyboard</a>
|
||||
<li><a href="savestate.html">Save-state Files</a>
|
||||
<li><a href="sound.html">Sound</a>
|
||||
<li><a href="clock.html">Clock</a>
|
||||
<li><a href="uthernet.html">Uthernet network card</a>
|
||||
<li><a href="CommandLine.html">Command line</a>
|
||||
<li><a href="configuration.html">AppleWin Configuration</a>
|
||||
<li><a href="dbg-toc-intro.html">Using the Debugger</a>
|
||||
<li><a href="resources.html">Resources</a></li>
|
||||
<li><a href="appendix.html">Appendix</a></li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
||||
|
|
48
help/uthernet-wifi-workaround.html
Normal file
48
help/uthernet-wifi-workaround.html
Normal file
|
@ -0,0 +1,48 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>WiFi workaround</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="FONT-FAMILY: verdana; BACKGROUND-COLOR: rgb(255,255,255)" alink="#008000"
|
||||
link="#008000" vlink="#008000">
|
||||
<h2 style="COLOR: rgb(0,128,0)">WiFi workaround</h2>
|
||||
<hr size="4">
|
||||
<p style="FONT-WEIGHT: bold">Overview:
|
||||
</p>
|
||||
<p>A (heavyweight) workaround for the WiFi issue.</p>
|
||||
|
||||
<p style="FONT-WEIGHT: bold">Details:
|
||||
</p>
|
||||
<p>Installing a virtualization solution like the (free) VMware
|
||||
Workstation Player provides a virtual ethernet card. Then installing
|
||||
WinPcap inside the virtual machine allows access to the internet via
|
||||
WiFi from AppleWin.</p>
|
||||
|
||||
<p>VMware allows you to configure the virtual ethernet card in two ways:</p>
|
||||
<ul>
|
||||
<li>Bridged, this means that the virtual Uthernet card becomes visible
|
||||
with its MAC address in the WiFi net and that an Apple II DHCP client
|
||||
gets its address from the usual DHCP server (typically a WAN router).
|
||||
<li>NAT, this means that the virtual Uthernet card is part of a virtual
|
||||
network with three participants:
|
||||
<ul>
|
||||
<li>A virtual Ethernet card added by VMware to the "outside" (aka host) Windows.
|
||||
<li>The virtual Ethernet card used by the "inside" (aka guest) Windows.
|
||||
<li>The virtual Uthernet card.
|
||||
</ul>
|
||||
<br>
|
||||
That virtual network has its own IP address range and has its own DHCP
|
||||
server (being part of VMware). An Apple II DHCP client gets its
|
||||
address from that DHCP server.
|
||||
</ul>
|
||||
|
||||
<p>Another positive aspect of that "emulation inside vitualization"
|
||||
approach is that the "inside" (aka guest) Windows always has just one
|
||||
single network interface: that virtual ethernet card mentioned above.
|
||||
And that interface has always the same name (even when switching
|
||||
between Bridged and NAT) so one never has to fiddle with network
|
||||
setting of the emulators using WinPcap.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||||
<html>
|
||||
<head>
|
||||
<title>Save-State Files</title>
|
||||
<title>Uthernet network card</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
|
||||
</head>
|
||||
<body style="FONT-FAMILY: verdana; BACKGROUND-COLOR: rgb(255,255,255)" alink="#008000"
|
||||
|
@ -15,25 +15,23 @@
|
|||
<P style="FONT-WEIGHT: bold">Acknowledgment:
|
||||
</P>
|
||||
<P>Uthernet (TFE) support in Applewin was made possible by implementing the GPL
|
||||
source written by Spiro Trikaliotis for the Vice emulator - <A href="http://www.viceteam.org/">
|
||||
http://www.viceteam.org/</A></P>
|
||||
source written by Spiro Trikaliotis for the Vice emulator - <A href="http://vice-emu.sourceforge.net/index.html#developers">
|
||||
http://vice-emu.sourceforge.net/index.html#developers</A></P>
|
||||
<P style="FONT-WEIGHT: bold">Details:
|
||||
</P>
|
||||
<P>To enable Ethernet support in AppleWin you must first download and install
|
||||
<P>To enable ethernet support in AppleWin you must first download and install
|
||||
WinPcap.
|
||||
</P>
|
||||
<P>An Alternative to downloading WinPcap is to get the Ethereal package which
|
||||
includes WinPcap along with Ethereal network analyzer code. To use Ethereal to
|
||||
<P>An alternative to downloading WinPcap is to get the Wireshark package which
|
||||
includes WinPcap along with Wireshark network analyzer code. To use Wireshark to
|
||||
capture traffic (other than your own) you must be plugged into a shared hub vs
|
||||
a switch. If you plan on doing any network programming ethereal is a definite
|
||||
a switch. If you plan on doing any network programming Wireshark is a definite
|
||||
must have.
|
||||
</P>
|
||||
<P>WinPcap: <A href="http://www.WinPcap.org/install/default.htm">http://www.WinPcap.org/install/default.htm</A>
|
||||
or Ethereal:
|
||||
<P>WinPcap: <A href="http://www.WinPcap.org/install/default.htm">http://www.WinPcap.org/install/default.htm</A>
|
||||
or Wireshark: <A href="https://www.wireshark.org">https://www.wireshark.org</A>
|
||||
</P>
|
||||
<P><A href="http://www.ethereal.com/download.html">http://www.ethereal.com/download.html</A>
|
||||
</P>
|
||||
<P>After AppleWin starts, select the settings ICON and then select the Ethernet
|
||||
<P>After AppleWin starts, select the settings icon and then select the ethernet
|
||||
settings button.
|
||||
</P>
|
||||
<P>Uthernet will be disabled. Select Uthernet from the list of available ethernet
|
||||
|
@ -44,13 +42,15 @@
|
|||
</P>
|
||||
<P>If you have more than one interface you may need to select them in turn in order
|
||||
to get the text description for each interface vs what WinPcap likes to use for
|
||||
a reference. Select Ok. and then close AppleWin. *Note:* Wireless does not work
|
||||
with WinPcap.
|
||||
a reference. Select Ok. and then close AppleWin.
|
||||
</P>
|
||||
<P>NOTE: Due to a current limitation you must exit AppleWin and re-run AppleWin for
|
||||
'a' ethernet interface change to take effect.
|
||||
<P><span style="font-weight: bold;">Note:</span> Wireless does not work
|
||||
with WinPcap (but see <A href="uthernet-wifi-workaround.html">WiFi Workaround</A>).
|
||||
</P>
|
||||
<P>In order to test the Ethernet emulation out you should grab a copy of Contiki
|
||||
<P><span style="font-weight: bold;">Note:</span> Due to a current limitation you must exit AppleWin and
|
||||
re-run AppleWin for an ethernet interface change to take effect.
|
||||
</P>
|
||||
<P>In order to test the ethernet emulation out you should grab a copy of Contiki
|
||||
for the Apple II here - <A href="http://www.a2retrosystems.com/downloads.htm">http://www.a2retrosystems.com/downloads.htm</A>
|
||||
</P>
|
||||
<P>Grab the 80 Col. Primary Disk and Supplementary Disk images if using Apple //e
|
||||
|
@ -88,6 +88,6 @@
|
|||
<P>If you have ZoneAlarm running then try disabling it inorder to access the web.
|
||||
if you are still having difficulty then you should refer to the VICE network
|
||||
support page for additional information - <A href="http://vicekb.trikaliotis.net/13-005.shtml">
|
||||
http://vicekb.trikaliotis.net/13-005.shtml</A></P>
|
||||
http://vicekb.trikaliotis.net/13-005.shtml</A></P>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -252,8 +252,8 @@ DISK_ICON ICON "DISK.ICO"
|
|||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 1,26,3,4
|
||||
PRODUCTVERSION 1,26,3,4
|
||||
FILEVERSION 1,26,3,6
|
||||
PRODUCTVERSION 1,26,3,6
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
|
@ -271,12 +271,12 @@ BEGIN
|
|||
VALUE "Comments", "https://github.com/AppleWin"
|
||||
VALUE "CompanyName", "AppleWin"
|
||||
VALUE "FileDescription", "Apple //e Emulator for Windows"
|
||||
VALUE "FileVersion", "1, 26, 3, 4"
|
||||
VALUE "FileVersion", "1, 26, 3, 6"
|
||||
VALUE "InternalName", "APPLEWIN"
|
||||
VALUE "LegalCopyright", " 1994-2017 Michael O'Brien, Oliver Schmidt, Tom Charlesworth, Michael Pohoreski, Nick Westgate, Linards Ticmanis"
|
||||
VALUE "OriginalFilename", "APPLEWIN.EXE"
|
||||
VALUE "ProductName", "Apple //e Emulator"
|
||||
VALUE "ProductVersion", "1, 26, 3, 4"
|
||||
VALUE "ProductVersion", "1, 26, 3, 6"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
|
|
@ -1270,6 +1270,8 @@ int APIENTRY WinMain(HINSTANCE passinstance, HINSTANCE, LPSTR lpCmdLine, int)
|
|||
// Need to test if it's safe to call ResetMachineState(). In the meantime, just call DiskReset():
|
||||
DiskReset(); // Switch from a booting A][+ to a non-autostart A][, so need to turn off floppy motor
|
||||
LogFileOutput("Main: DiskReset()\n");
|
||||
HD_Reset(); // GH#515
|
||||
LogFileOutput("Main: HDDReset()\n");
|
||||
|
||||
if (!bSysClkOK)
|
||||
{
|
||||
|
@ -1365,7 +1367,7 @@ int APIENTRY WinMain(HINSTANCE passinstance, HINSTANCE, LPSTR lpCmdLine, int)
|
|||
LogFileOutput("Main: MB_Reset()\n");
|
||||
|
||||
sg_Mouse.Uninitialize(); // Maybe restarting due to switching slot-4 card from MouseCard to Mockingboard
|
||||
sg_Mouse.Reset();
|
||||
sg_Mouse.Reset(); // Deassert any pending IRQs - GH#514
|
||||
LogFileOutput("Main: sg_Mouse.Uninitialize()\n");
|
||||
|
||||
DSUninit();
|
||||
|
|
|
@ -255,6 +255,8 @@ void CPageConfigTfe::init_tfe_dialog(HWND hwnd)
|
|||
if (gray_ungray_items(hwnd))
|
||||
{
|
||||
/* we have a problem: TFE is disabled. Give a message to the user */
|
||||
// TC (18 Dec 2017) this vicekb URL is a broken link now, so I copied it to the AppleWin repo, here:
|
||||
// . https://github.com/AppleWin/AppleWin/blob/master/docs/VICE%20Knowledge%20Base%20-%20Article%2013-005.htm
|
||||
MessageBox( hwnd,
|
||||
"TFE support is not available on your system,\n"
|
||||
"there is some important part missing. Please have a\n"
|
||||
|
|
|
@ -49,7 +49,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|||
#define ALLOW_INPUT_LOWERCASE 1
|
||||
|
||||
// See /docs/Debugger_Changelog.txt for full details
|
||||
const int DEBUGGER_VERSION = MAKE_VERSION(2,9,0,8);
|
||||
const int DEBUGGER_VERSION = MAKE_VERSION(2,9,0,12);
|
||||
|
||||
|
||||
// Public _________________________________________________________________________________________
|
||||
|
@ -188,7 +188,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|||
|
||||
// Config - Disassembly
|
||||
bool g_bConfigDisasmAddressView = true;
|
||||
int g_bConfigDisasmClick = 0; // GH#462 alt=1, ctrl=2, shift=4 bitmask
|
||||
int g_bConfigDisasmClick = 4; // GH#462 alt=1, ctrl=2, shift=4 bitmask (default to Shift-Click)
|
||||
bool g_bConfigDisasmAddressColon = true;
|
||||
bool g_bConfigDisasmOpcodesView = true;
|
||||
bool g_bConfigDisasmOpcodeSpaces = true;
|
||||
|
|
|
@ -543,6 +543,7 @@ HDC GetDebuggerMemDC(void)
|
|||
SelectObject(g_hDebuggerMemDC, g_hDebuggerMemBM);
|
||||
}
|
||||
|
||||
_ASSERT(g_hDebuggerMemDC); // TC: Could this be NULL?
|
||||
return g_hDebuggerMemDC;
|
||||
}
|
||||
|
||||
|
@ -1902,392 +1903,412 @@ WORD DrawDisassemblyLine ( int iLine, const WORD nBaseAddress )
|
|||
const int DISASM_SYMBOL_LEN = 9;
|
||||
#endif
|
||||
|
||||
HDC dc = GetDebuggerMemDC();
|
||||
if (dc) // TC: Why would this be NULL?
|
||||
int nFontHeight = g_aFontConfig[ FONT_DISASM_DEFAULT ]._nLineHeight; // _nFontHeight; // g_nFontHeight
|
||||
|
||||
RECT linerect;
|
||||
linerect.left = 0;
|
||||
linerect.top = iLine * nFontHeight;
|
||||
linerect.right = DISPLAY_DISASM_RIGHT;
|
||||
linerect.bottom = linerect.top + nFontHeight;
|
||||
|
||||
bool bBreakpointActive;
|
||||
bool bBreakpointEnable;
|
||||
GetBreakpointInfo( nBaseAddress, bBreakpointActive, bBreakpointEnable );
|
||||
bool bAddressAtPC = (nBaseAddress == regs.pc);
|
||||
bool bAddressIsBookmark = Bookmark_Find( nBaseAddress );
|
||||
|
||||
DebugColors_e iBackground = BG_DISASM_1;
|
||||
DebugColors_e iForeground = FG_DISASM_MNEMONIC; // FG_DISASM_TEXT;
|
||||
bool bCursorLine = false;
|
||||
|
||||
if (((! g_bDisasmCurBad) && (iLine == g_nDisasmCurLine))
|
||||
|| (g_bDisasmCurBad && (iLine == 0)))
|
||||
{
|
||||
int nFontHeight = g_aFontConfig[ FONT_DISASM_DEFAULT ]._nLineHeight; // _nFontHeight; // g_nFontHeight
|
||||
bCursorLine = true;
|
||||
|
||||
RECT linerect;
|
||||
linerect.left = 0;
|
||||
linerect.top = iLine * nFontHeight;
|
||||
linerect.right = DISPLAY_DISASM_RIGHT;
|
||||
linerect.bottom = linerect.top + nFontHeight;
|
||||
|
||||
// BOOL bp = g_nBreakpoints && CheckBreakpoint(nBaseAddress,nBaseAddress == regs.pc);
|
||||
|
||||
bool bBreakpointActive;
|
||||
bool bBreakpointEnable;
|
||||
GetBreakpointInfo( nBaseAddress, bBreakpointActive, bBreakpointEnable );
|
||||
bool bAddressAtPC = (nBaseAddress == regs.pc);
|
||||
bool bAddressIsBookmark = Bookmark_Find( nBaseAddress );
|
||||
|
||||
DebugColors_e iBackground = BG_DISASM_1;
|
||||
DebugColors_e iForeground = FG_DISASM_MNEMONIC; // FG_DISASM_TEXT;
|
||||
bool bCursorLine = false;
|
||||
|
||||
if (((! g_bDisasmCurBad) && (iLine == g_nDisasmCurLine))
|
||||
|| (g_bDisasmCurBad && (iLine == 0)))
|
||||
// Breakpoint
|
||||
if (bBreakpointActive)
|
||||
{
|
||||
bCursorLine = true;
|
||||
|
||||
// Breakpoint,
|
||||
if (bBreakpointActive)
|
||||
if (bBreakpointEnable)
|
||||
{
|
||||
if (bBreakpointEnable)
|
||||
{
|
||||
iBackground = BG_DISASM_BP_S_C; iForeground = FG_DISASM_BP_S_C;
|
||||
}
|
||||
else
|
||||
{
|
||||
iBackground = BG_DISASM_BP_0_C; iForeground = FG_DISASM_BP_0_C;
|
||||
}
|
||||
}
|
||||
else
|
||||
if (bAddressAtPC)
|
||||
{
|
||||
iBackground = BG_DISASM_PC_C; iForeground = FG_DISASM_PC_C;
|
||||
iBackground = BG_DISASM_BP_S_C; iForeground = FG_DISASM_BP_S_C;
|
||||
}
|
||||
else
|
||||
{
|
||||
iBackground = BG_DISASM_C; iForeground = FG_DISASM_C;
|
||||
// HACK? Sync Cursor back up to Address
|
||||
// The cursor line may of had to be been moved, due to Disasm Singularity.
|
||||
g_nDisasmCurAddress = nBaseAddress;
|
||||
iBackground = BG_DISASM_BP_0_C; iForeground = FG_DISASM_BP_0_C;
|
||||
}
|
||||
}
|
||||
else
|
||||
if (bAddressAtPC)
|
||||
{
|
||||
if (iLine & 1)
|
||||
{
|
||||
iBackground = BG_DISASM_1;
|
||||
}
|
||||
else
|
||||
{
|
||||
iBackground = BG_DISASM_2;
|
||||
}
|
||||
|
||||
// This address has a breakpoint, but the cursor is not on it (atm)
|
||||
if (bBreakpointActive)
|
||||
{
|
||||
if (bBreakpointEnable)
|
||||
{
|
||||
iForeground = FG_DISASM_BP_S_X; // Red (old Yellow)
|
||||
}
|
||||
else
|
||||
{
|
||||
iForeground = FG_DISASM_BP_0_X; // Yellow
|
||||
}
|
||||
}
|
||||
else
|
||||
if (bAddressAtPC)
|
||||
{
|
||||
iBackground = BG_DISASM_PC_X; iForeground = FG_DISASM_PC_X;
|
||||
}
|
||||
else
|
||||
{
|
||||
iForeground = FG_DISASM_MNEMONIC;
|
||||
}
|
||||
}
|
||||
|
||||
if (bAddressIsBookmark)
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_DISASM_BOOKMARK ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_BOOKMARK ) );
|
||||
iBackground = BG_DISASM_PC_C; iForeground = FG_DISASM_PC_C;
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
iBackground = BG_DISASM_C; iForeground = FG_DISASM_C;
|
||||
// HACK? Sync Cursor back up to Address
|
||||
// The cursor line may of had to be been moved, due to Disasm Singularity.
|
||||
g_nDisasmCurAddress = nBaseAddress;
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
if (iLine & 1)
|
||||
{
|
||||
iBackground = BG_DISASM_1;
|
||||
}
|
||||
else
|
||||
{
|
||||
iBackground = BG_DISASM_2;
|
||||
}
|
||||
|
||||
// This address has a breakpoint, but the cursor is not on it (atm)
|
||||
if (bBreakpointActive)
|
||||
{
|
||||
if (bBreakpointEnable)
|
||||
{
|
||||
iForeground = FG_DISASM_BP_S_X; // Red (old Yellow)
|
||||
}
|
||||
else
|
||||
{
|
||||
iForeground = FG_DISASM_BP_0_X; // Yellow
|
||||
}
|
||||
}
|
||||
else
|
||||
if (bAddressAtPC)
|
||||
{
|
||||
iBackground = BG_DISASM_PC_X; iForeground = FG_DISASM_PC_X;
|
||||
}
|
||||
else
|
||||
{
|
||||
iForeground = FG_DISASM_MNEMONIC;
|
||||
}
|
||||
}
|
||||
|
||||
if (bAddressIsBookmark)
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_DISASM_BOOKMARK ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_BOOKMARK ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
}
|
||||
|
||||
// Address
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_ADDRESS ) );
|
||||
// else
|
||||
// {
|
||||
// DebuggerSetColorBG( dc, DebuggerGetColor( FG_DISASM_BOOKMARK ) ); // swapped
|
||||
// DebuggerSetColorFG( dc, DebuggerGetColor( BG_DISASM_BOOKMARK ) ); // swapped
|
||||
// }
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_ADDRESS ) );
|
||||
// else
|
||||
// {
|
||||
// DebuggerSetColorBG( GetDebuggerMemDC(), DebuggerGetColor( FG_DISASM_BOOKMARK ) ); // swapped
|
||||
// DebuggerSetColorFG( GetDebuggerMemDC(), DebuggerGetColor( BG_DISASM_BOOKMARK ) ); // swapped
|
||||
// }
|
||||
|
||||
if( g_bConfigDisasmAddressView )
|
||||
{
|
||||
PrintTextCursorX( (LPCTSTR) line.sAddress, linerect );
|
||||
}
|
||||
if( g_bConfigDisasmAddressView )
|
||||
{
|
||||
PrintTextCursorX( (LPCTSTR) line.sAddress, linerect );
|
||||
}
|
||||
|
||||
if (bAddressIsBookmark)
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
}
|
||||
|
||||
if (bAddressIsBookmark)
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) );
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
}
|
||||
|
||||
// Address Seperator
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
|
||||
if (g_bConfigDisasmAddressColon)
|
||||
PrintTextCursorX( ":", linerect );
|
||||
else
|
||||
PrintTextCursorX( " ", linerect ); // bugfix, not showing "addr:" doesn't alternate color lines
|
||||
if (g_bConfigDisasmAddressColon)
|
||||
PrintTextCursorX( ":", linerect );
|
||||
else
|
||||
PrintTextCursorX( " ", linerect ); // bugfix, not showing "addr:" doesn't alternate color lines
|
||||
|
||||
// Opcodes
|
||||
linerect.left = (int) aTabs[ TS_OPCODE ];
|
||||
linerect.left = (int) aTabs[ TS_OPCODE ];
|
||||
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ) );
|
||||
// PrintTextCursorX( " ", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ) );
|
||||
|
||||
if (g_bConfigDisasmOpcodesView)
|
||||
PrintTextCursorX( (LPCTSTR) line.sOpCodes, linerect );
|
||||
// PrintTextCursorX( " ", linerect );
|
||||
if (g_bConfigDisasmOpcodesView)
|
||||
PrintTextCursorX( (LPCTSTR) line.sOpCodes, linerect );
|
||||
|
||||
// Label
|
||||
linerect.left = (int) aTabs[ TS_LABEL ];
|
||||
linerect.left = (int) aTabs[ TS_LABEL ];
|
||||
|
||||
if (pSymbol)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_SYMBOL ) );
|
||||
PrintTextCursorX( pSymbol, linerect );
|
||||
}
|
||||
// linerect.left += (g_nFontWidthAvg * DISASM_SYMBOL_LEN);
|
||||
// PrintTextCursorX( " ", linerect );
|
||||
if (pSymbol)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_SYMBOL ) );
|
||||
PrintTextCursorX( pSymbol, linerect );
|
||||
}
|
||||
|
||||
// Instruction / Mnemonic
|
||||
linerect.left = (int) aTabs[ TS_INSTRUCTION ];
|
||||
linerect.left = (int) aTabs[ TS_INSTRUCTION ];
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
if( pData ) // Assembler Data Directive / Data Disassembler
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_DIRECTIVE ) ); // TODO: FIXME: HACK? Is the color fine?
|
||||
else
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
}
|
||||
if (! bCursorLine)
|
||||
{
|
||||
if( pData ) // Assembler Data Directive / Data Disassembler
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_DIRECTIVE ) ); // TODO: FIXME: HACK? Is the color fine?
|
||||
else
|
||||
DebuggerSetColorFG( DebuggerGetColor( iForeground ) );
|
||||
}
|
||||
|
||||
pMnemonic = line.sMnemonic;
|
||||
PrintTextCursorX( pMnemonic, linerect );
|
||||
PrintTextCursorX( " ", linerect );
|
||||
pMnemonic = line.sMnemonic;
|
||||
PrintTextCursorX( pMnemonic, linerect );
|
||||
PrintTextCursorX( " ", linerect );
|
||||
|
||||
// Target
|
||||
if (line.bTargetImmediate)
|
||||
if (line.bTargetImmediate)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "#$", linerect );
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed || line.bTargetIndirect)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "(", linerect );
|
||||
}
|
||||
|
||||
char *pTarget = line.sTarget;
|
||||
int nLen = strlen( pTarget );
|
||||
|
||||
if (*pTarget == '$') // BUG? if ASC #:# starts with '$' ? // && (iOpcode != OPCODE_NOP)
|
||||
{
|
||||
pTarget++;
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "$", linerect );
|
||||
}
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_SYMBOL)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "#$", linerect );
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_SYMBOL ) );
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed || line.bTargetIndirect)
|
||||
else
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "(", linerect );
|
||||
if (iOpmode == AM_M)
|
||||
// if (bDisasmFormatFlags & DISASM_FORMAT_CHAR)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_TARGET ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
char *pTarget = line.sTarget;
|
||||
int nLen = strlen( pTarget );
|
||||
// https://github.com/AppleWin/AppleWin/issues/227
|
||||
// (Debugger)[1.25] AppleSoft symbol: COPY.FAC.TO.ARG.ROUNDED overflows into registers
|
||||
// Repro:
|
||||
// UEA39
|
||||
// 2.8.0.1 Clamp excessive symbol target to not overflow
|
||||
// SYM COPY.FAC.TO.ARG.ROUNDED = EB63
|
||||
// If opcodes aren't showing then length can be longer!
|
||||
// FormatOpcodeBytes() uses 3 chars/MAX_OPCODES. i.e. "## "
|
||||
int nMaxLen = MAX_TARGET_LEN;
|
||||
|
||||
if (*pTarget == '$') // BUG? if ASC #:# starts with '$' ? // && (iOpcode != OPCODE_NOP)
|
||||
// 2.8.0.8: Bug #227: AppleSoft symbol: COPY.FAC.TO.ARG.ROUNDED overflows into registers
|
||||
if ( !g_bConfigDisasmAddressView )
|
||||
nMaxLen += 4;
|
||||
if ( !g_bConfigDisasmOpcodesView )
|
||||
nMaxLen += (MAX_OPCODES*3);
|
||||
|
||||
// 2.9.0.9 Continuation of 2.8.0.8: Fix overflowing disassembly pane for long symbols
|
||||
int nOverflow = 0;
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_OFFSET)
|
||||
{
|
||||
if (line.nTargetOffset != 0)
|
||||
nOverflow++;
|
||||
|
||||
nOverflow += strlen( line.sTargetOffset );
|
||||
}
|
||||
|
||||
if (line.bTargetIndirect || line.bTargetX || line.bTargetY)
|
||||
{
|
||||
if (line.bTargetX)
|
||||
nOverflow += 2;
|
||||
else
|
||||
if ((line.bTargetY) && (! line.bTargetIndirect))
|
||||
nOverflow += 2;
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed || line.bTargetIndirect)
|
||||
nOverflow++;
|
||||
|
||||
if (line.bTargetIndexed)
|
||||
{
|
||||
if (line.bTargetY)
|
||||
nOverflow += 2;
|
||||
}
|
||||
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_TARGET_POINTER)
|
||||
{
|
||||
nOverflow += strlen( line.sTargetPointer ); // '####'
|
||||
nOverflow ++ ; // ':'
|
||||
nOverflow += 2; // '##'
|
||||
nOverflow ++ ; // ' '
|
||||
}
|
||||
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_CHAR)
|
||||
{
|
||||
nOverflow += strlen( line.sImmediate );
|
||||
}
|
||||
|
||||
if (nLen >= (nMaxLen - nOverflow))
|
||||
{
|
||||
#if _DEBUG
|
||||
// TODO: Warn on import about long symbol/target names
|
||||
#endif
|
||||
pTarget[ nMaxLen - nOverflow ] = 0;
|
||||
}
|
||||
|
||||
// TODO: FIXME: 2.8.0.7: Allow ctrl characters to show as inverse; i.e. ASC 400:40F
|
||||
PrintTextCursorX( pTarget, linerect );
|
||||
|
||||
// Target Offset +/-
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_OFFSET)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (line.nTargetOffset > 0)
|
||||
PrintTextCursorX( "+", linerect );
|
||||
else
|
||||
if (line.nTargetOffset < 0)
|
||||
PrintTextCursorX( "-", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
pTarget++;
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE )); // Technically, not a hex number, but decimal
|
||||
}
|
||||
PrintTextCursorX( line.sTargetOffset, linerect );
|
||||
}
|
||||
// Inside parenthesis = Indirect Target Regs
|
||||
if (line.bTargetIndirect || line.bTargetX || line.bTargetY)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (line.bTargetX)
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
PrintTextCursorX( "$", linerect );
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "X", linerect );
|
||||
}
|
||||
else
|
||||
if ((line.bTargetY) && (! line.bTargetIndirect))
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "Y", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed || line.bTargetIndirect)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
PrintTextCursorX( ")", linerect );
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed)
|
||||
{
|
||||
if (line.bTargetY)
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "Y", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
// BUGFIX: 2.6.2.30: DA $target --> show right paren
|
||||
if( pData )
|
||||
{
|
||||
return nOpbyte;
|
||||
}
|
||||
|
||||
// Memory Pointer and Value
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_TARGET_POINTER) // (bTargetValue)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_IMMEDIATE ]; // TS_IMMEDIATE ];
|
||||
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_ADDRESS ));
|
||||
|
||||
PrintTextCursorX( line.sTargetPointer, linerect );
|
||||
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_TARGET_VALUE)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (g_iConfigDisasmTargets & DISASM_TARGET_BOTH)
|
||||
PrintTextCursorX( ":", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ));
|
||||
|
||||
PrintTextCursorX( line.sTargetValue, linerect );
|
||||
PrintTextCursorX( " ", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
// Immediate Char
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_CHAR)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_CHAR ]; // TS_IMMEDIATE ];
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
}
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_SYMBOL)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_SYMBOL ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
if (iOpmode == AM_M)
|
||||
// if (bDisasmFormatFlags & DISASM_FORMAT_CHAR)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_TARGET ) );
|
||||
}
|
||||
}
|
||||
ColorizeSpecialChar( NULL, line.nImmediate, MEM_VIEW_ASCII, iBackground );
|
||||
}
|
||||
PrintTextCursorX( line.sImmediate, linerect );
|
||||
|
||||
// https://github.com/AppleWin/AppleWin/issues/227
|
||||
// (Debugger)[1.25] AppleSoft symbol: COPY.FAC.TO.ARG.ROUNDED overflows into registers
|
||||
// Repro:
|
||||
// UEA39
|
||||
// 2.8.0.1 Clamp excessive symbol target to not overflow
|
||||
// SYM COPY.FAC.TO.ARG.ROUNDED = EB63
|
||||
// If opcodes aren't showing then length can be longer!
|
||||
// FormatOpcodeBytes() uses 3 chars/MAX_OPCODES. i.e. "## "
|
||||
int nMaxLen = MAX_TARGET_LEN;
|
||||
|
||||
// 2.8.0.8: Bug #227: AppleSoft symbol: COPY.FAC.TO.ARG.ROUNDED overflows into registers
|
||||
if ( !g_bConfigDisasmAddressView )
|
||||
nMaxLen += 4;
|
||||
if ( !g_bConfigDisasmOpcodesView )
|
||||
nMaxLen += (MAX_OPCODES*3);
|
||||
|
||||
if( nLen >= nMaxLen )
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) ); // Hack: Colorize can "color bleed to EOL"
|
||||
if (! bCursorLine)
|
||||
{
|
||||
#if _DEBUG
|
||||
// TODO: Warn on import about long symbol/target names
|
||||
#endif
|
||||
pTarget[ nMaxLen ] = 0;
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: FIXME: 2.8.0.7: Allow ctrl characters to show as inverse; i.e. ASC 400:40F
|
||||
PrintTextCursorX( pTarget, linerect );
|
||||
// PrintTextCursorX( " ", linerect );
|
||||
|
||||
// Target Offset +/-
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_OFFSET)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (line.nTargetOffset > 0)
|
||||
PrintTextCursorX( "+", linerect );
|
||||
else
|
||||
if (line.nTargetOffset < 0)
|
||||
PrintTextCursorX( "-", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE )); // Technically, not a hex number, but decimal
|
||||
}
|
||||
PrintTextCursorX( line.sTargetOffset, linerect );
|
||||
}
|
||||
// Inside Parenthesis = Indirect Target Regs
|
||||
if (line.bTargetIndirect || line.bTargetX || line.bTargetY)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (line.bTargetX)
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "X", linerect );
|
||||
}
|
||||
else
|
||||
if ((line.bTargetY) && (! line.bTargetIndirect))
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "Y", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed || line.bTargetIndirect)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
PrintTextCursorX( ")", linerect );
|
||||
}
|
||||
|
||||
if (line.bTargetIndexed)
|
||||
{
|
||||
if (line.bTargetY)
|
||||
{
|
||||
PrintTextCursorX( ",", linerect );
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ) );
|
||||
PrintTextCursorX( "Y", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
// BUGFIX: 2.6.2.30: DA $target --> show right paren
|
||||
if( pData )
|
||||
{
|
||||
return nOpbyte;
|
||||
}
|
||||
|
||||
// Memory Pointer and Value
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_TARGET_POINTER) // (bTargetValue)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_IMMEDIATE ]; // TS_IMMEDIATE ];
|
||||
|
||||
// PrintTextCursorX( " ", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_ADDRESS ));
|
||||
|
||||
PrintTextCursorX( line.sTargetPointer, linerect );
|
||||
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_TARGET_VALUE)
|
||||
{
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ));
|
||||
|
||||
if (g_iConfigDisasmTargets & DISASM_TARGET_BOTH)
|
||||
PrintTextCursorX( ":", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPCODE ));
|
||||
|
||||
PrintTextCursorX( line.sTargetValue, linerect );
|
||||
PrintTextCursorX( " ", linerect );
|
||||
}
|
||||
}
|
||||
|
||||
// Immediate Char
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_CHAR)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_CHAR ]; // TS_IMMEDIATE ];
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
}
|
||||
|
||||
// if (! (bDisasmFormatFlags & DISASM_FORMAT_TARGET_POINTER))
|
||||
// PrintTextCursorX( "'", linerect );
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
ColorizeSpecialChar( NULL, line.nImmediate, MEM_VIEW_ASCII, iBackground );
|
||||
// iBackground, FG_INFO_CHAR_HI, FG_DISASM_CHAR, FG_INFO_CHAR_LO );
|
||||
}
|
||||
PrintTextCursorX( line.sImmediate, linerect );
|
||||
|
||||
DebuggerSetColorBG( DebuggerGetColor( iBackground ) ); // Hack: Colorize can "color bleed to EOL"
|
||||
if (! bCursorLine)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_OPERATOR ) );
|
||||
}
|
||||
|
||||
// if (! (bDisasmFormatFlags & DISASM_FORMAT_TARGET_POINTER))
|
||||
// PrintTextCursorX( "'", linerect );
|
||||
}
|
||||
|
||||
// Branch Indicator
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_BRANCH)
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_BRANCH)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_BRANCH ];
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
linerect.left = (int) aTabs[ TS_BRANCH ];
|
||||
|
||||
if (! bCursorLine)
|
||||
{
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_BRANCH ) );
|
||||
}
|
||||
|
||||
#if !USE_APPLE_FONT
|
||||
if (g_iConfigDisasmBranchType == DISASM_BRANCH_FANCY)
|
||||
SelectObject( GetDebuggerMemDC(), g_aFontConfig[ FONT_DISASM_BRANCH ]._hFont ); // g_hFontWebDings
|
||||
#endif
|
||||
|
||||
// PrintTextColor( sBranch, linerect );
|
||||
PrintText( line.sBranch, linerect );
|
||||
|
||||
#if !USE_APPLE_FONT
|
||||
if (g_iConfigDisasmBranchType)
|
||||
SelectObject( dc, g_aFontConfig[ FONT_DISASM_DEFAULT ]._hFont ); // g_hFontDisasm
|
||||
#endif
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_DISASM_BRANCH ) );
|
||||
}
|
||||
|
||||
#if !USE_APPLE_FONT
|
||||
if (g_iConfigDisasmBranchType == DISASM_BRANCH_FANCY)
|
||||
SelectObject( GetDebuggerMemDC(), g_aFontConfig[ FONT_DISASM_BRANCH ]._hFont ); // g_hFontWebDings
|
||||
#endif
|
||||
|
||||
PrintText( line.sBranch, linerect );
|
||||
|
||||
#if !USE_APPLE_FONT
|
||||
if (g_iConfigDisasmBranchType)
|
||||
SelectObject( GetDebuggerMemDC(), g_aFontConfig[ FONT_DISASM_DEFAULT ]._hFont ); // g_hFontDisasm
|
||||
#endif
|
||||
}
|
||||
|
||||
return nOpbyte;
|
||||
|
@ -2303,7 +2324,7 @@ void DrawFlags ( int line, WORD nRegFlags, LPTSTR pFlagNames_)
|
|||
|
||||
char sFlagNames[ _6502_NUM_FLAGS+1 ] = ""; // = "NVRBDIZC"; // copy from g_aFlagNames
|
||||
char sText[4] = "?";
|
||||
RECT rect;
|
||||
RECT rect;
|
||||
|
||||
int nFontWidth = g_aFontConfig[ FONT_INFO ]._nFontWidthAvg;
|
||||
|
||||
|
@ -2318,33 +2339,36 @@ void DrawFlags ( int line, WORD nRegFlags, LPTSTR pFlagNames_)
|
|||
nSpacerWidth++;
|
||||
#endif
|
||||
|
||||
if (GetDebuggerMemDC()) // TC: Why would this be NULL?
|
||||
{
|
||||
rect.top = line * g_nFontHeight;
|
||||
rect.bottom = rect.top + g_nFontHeight;
|
||||
rect.left = DISPLAY_FLAG_COLUMN;
|
||||
rect.right = rect.left + (10 * nFontWidth);
|
||||
//
|
||||
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_DATA_1 )); // BG_INFO
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ));
|
||||
PrintText( "P ", rect );
|
||||
GetDebuggerMemDC();
|
||||
|
||||
rect.top += g_nFontHeight;
|
||||
rect.bottom += g_nFontHeight;
|
||||
rect.top = line * g_nFontHeight;
|
||||
rect.bottom = rect.top + g_nFontHeight;
|
||||
rect.left = DISPLAY_FLAG_COLUMN;
|
||||
rect.right = rect.left + (10 * nFontWidth);
|
||||
|
||||
sprintf( sText, "%02X", nRegFlags );
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_DATA_1 )); // BG_INFO
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ));
|
||||
PrintText( "P ", rect );
|
||||
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_OPCODE ));
|
||||
PrintText( sText, rect );
|
||||
rect.top += g_nFontHeight;
|
||||
rect.bottom += g_nFontHeight;
|
||||
|
||||
rect.top -= g_nFontHeight;
|
||||
rect.bottom -= g_nFontHeight;
|
||||
sText[1] = 0;
|
||||
sprintf( sText, "%02X", nRegFlags );
|
||||
|
||||
rect.left += ((2 + _6502_NUM_FLAGS) * nSpacerWidth);
|
||||
rect.right = rect.left + nFontWidth;
|
||||
}
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_OPCODE ));
|
||||
PrintText( sText, rect );
|
||||
|
||||
rect.top -= g_nFontHeight;
|
||||
rect.bottom -= g_nFontHeight;
|
||||
sText[1] = 0;
|
||||
|
||||
rect.left += ((2 + _6502_NUM_FLAGS) * nSpacerWidth);
|
||||
rect.right = rect.left + nFontWidth;
|
||||
|
||||
//
|
||||
|
||||
int iFlag = 0;
|
||||
int nFlag = _6502_NUM_FLAGS;
|
||||
|
@ -2353,45 +2377,41 @@ void DrawFlags ( int line, WORD nRegFlags, LPTSTR pFlagNames_)
|
|||
iFlag = (_6502_NUM_FLAGS - nFlag - 1);
|
||||
|
||||
bool bSet = (nRegFlags & 1);
|
||||
if (GetDebuggerMemDC()) // TC: Why would this be NULL?
|
||||
|
||||
sText[0] = g_aBreakpointSource[ BP_SRC_FLAG_C + iFlag ][0];
|
||||
|
||||
if (bSet)
|
||||
{
|
||||
sText[0] = g_aBreakpointSource[ BP_SRC_FLAG_C + iFlag ][0];
|
||||
if (bSet)
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO_INVERSE ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_INVERSE ));
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_TITLE ));
|
||||
}
|
||||
rect.left -= nSpacerWidth;
|
||||
rect.right -= nSpacerWidth;
|
||||
PrintText( sText, rect );
|
||||
|
||||
// Print Binary value
|
||||
rect.top += g_nFontHeight;
|
||||
rect.bottom += g_nFontHeight;
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO )); //
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_TITLE ));
|
||||
|
||||
sText[0] = '0' + static_cast<int>(bSet);
|
||||
PrintText( sText, rect );
|
||||
rect.top -= g_nFontHeight;
|
||||
rect.bottom -= g_nFontHeight;
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO_INVERSE ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_INVERSE ));
|
||||
}
|
||||
else
|
||||
{
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_TITLE ));
|
||||
}
|
||||
|
||||
rect.left -= nSpacerWidth;
|
||||
rect.right -= nSpacerWidth;
|
||||
PrintText( sText, rect );
|
||||
|
||||
// Print Binary value
|
||||
rect.top += g_nFontHeight;
|
||||
rect.bottom += g_nFontHeight;
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO ));
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_TITLE ));
|
||||
|
||||
sText[0] = '0' + static_cast<int>(bSet);
|
||||
PrintText( sText, rect );
|
||||
rect.top -= g_nFontHeight;
|
||||
rect.bottom -= g_nFontHeight;
|
||||
|
||||
if (pFlagNames_)
|
||||
{
|
||||
if (! bSet) //(nFlags & 1))
|
||||
{
|
||||
if (!bSet)
|
||||
sFlagNames[nFlag] = '.';
|
||||
}
|
||||
else
|
||||
{
|
||||
sFlagNames[nFlag] = g_aBreakpointSource[ BP_SRC_FLAG_C + iFlag ][0];
|
||||
}
|
||||
}
|
||||
|
||||
nRegFlags >>= 1;
|
||||
|
@ -2399,27 +2419,6 @@ void DrawFlags ( int line, WORD nRegFlags, LPTSTR pFlagNames_)
|
|||
|
||||
if (pFlagNames_)
|
||||
strcpy(pFlagNames_,sFlagNames);
|
||||
/*
|
||||
if (GetDebuggerMemDC()) // TC: Why would this be NULL?
|
||||
{
|
||||
rect.top += g_nFontHeight;
|
||||
rect.bottom += g_nFontHeight;
|
||||
rect.left = DISPLAY_FLAG_COLUMN;
|
||||
rect.right = rect.left + (10 * nFontWidth);
|
||||
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ));
|
||||
PrintTextCursorX( "P ", rect );
|
||||
|
||||
|
||||
DebuggerSetColorBG( DebuggerGetColor( BG_INFO )); // COLOR_BG_DATA
|
||||
|
||||
DebuggerSetColorFG( DebuggerGetColor( FG_INFO_REG ));
|
||||
PrintTextCursorX( "P ", rect );
|
||||
|
||||
rect.left += (_6502_NUM_FLAGS * nSpacerWidth);
|
||||
rect.right = rect.left + nFontWidth;
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
@ -3991,9 +3990,11 @@ void UpdateDisplay (Update_t bUpdate)
|
|||
|
||||
case WINDOW_IO:
|
||||
DrawWindow_IO( bUpdate );
|
||||
break;
|
||||
|
||||
case WINDOW_SOURCE:
|
||||
DrawWindow_Source( bUpdate );
|
||||
break;
|
||||
|
||||
case WINDOW_SYMBOLS:
|
||||
DrawWindow_Symbols( bUpdate );
|
||||
|
@ -4001,6 +4002,7 @@ void UpdateDisplay (Update_t bUpdate)
|
|||
|
||||
case WINDOW_ZEROPAGE:
|
||||
DrawWindow_ZeroPage( bUpdate );
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
|
|
|
@ -201,18 +201,22 @@ void ArgsClear ()
|
|||
//===========================================================================
|
||||
bool ArgsGetValue ( Arg_t *pArg, WORD * pAddressValue_, const int nBase )
|
||||
{
|
||||
_ASSERT(pArg);
|
||||
if (pArg == NULL)
|
||||
return false;
|
||||
|
||||
TCHAR *pSrc = & (pArg->sArg[ 0 ]);
|
||||
TCHAR *pEnd = NULL;
|
||||
|
||||
if (pArg && pAddressValue_)
|
||||
if (pAddressValue_)
|
||||
{
|
||||
*pAddressValue_ = (WORD)(_tcstoul( pSrc, &pEnd, nBase) & _6502_MEM_END);
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
//===========================================================================
|
||||
bool ArgsGetImmediateValue ( Arg_t *pArg, WORD * pAddressValue_ )
|
||||
{
|
||||
|
|
|
@ -555,6 +555,8 @@ int ParseSymbolTable( TCHAR *pPathFileName, SymbolTable_Index_e eSymbolTableWrit
|
|||
char sText[ CONSOLE_WIDTH * 3 ];
|
||||
bool bFileDisplayed = false;
|
||||
|
||||
const int nMaxLen = min(MAX_TARGET_LEN,MAX_SYMBOLS_LEN);
|
||||
|
||||
int nSymbolsLoaded = 0;
|
||||
|
||||
if (! pPathFileName)
|
||||
|
@ -637,6 +639,20 @@ int ParseSymbolTable( TCHAR *pPathFileName, SymbolTable_Index_e eSymbolTableWrit
|
|||
WORD nAddressPrev;
|
||||
int iTable;
|
||||
|
||||
// 2.9.0.11 Bug #479
|
||||
int nLen = strlen( sName );
|
||||
if (nLen > nMaxLen)
|
||||
{
|
||||
ConsolePrintFormat( sText, " %sWarn.: %s%s (%d > %d)"
|
||||
, CHC_WARNING
|
||||
, CHC_SYMBOL
|
||||
, sName
|
||||
, nLen
|
||||
, nMaxLen
|
||||
);
|
||||
ConsoleUpdate(); // Flush buffered output so we don't ask the user to pause
|
||||
}
|
||||
|
||||
// 2.8.0.5 Bug #244 (Debugger) Duplicate symbols for identical memory addresses in APPLE2E.SYM
|
||||
const char *pSymbolPrev = FindSymbolFromAddress( (WORD)nAddress, &iTable ); // don't care which table it is in
|
||||
if( pSymbolPrev )
|
||||
|
@ -652,8 +668,8 @@ int ParseSymbolTable( TCHAR *pPathFileName, SymbolTable_Index_e eSymbolTableWrit
|
|||
);
|
||||
}
|
||||
|
||||
ConsolePrintFormat( sText, " %sWarning: %s%-16s %saliases %s$%s%04X %s%-12s%s (%s%s%s)"
|
||||
, CHC_WARNING
|
||||
ConsolePrintFormat( sText, " %sInfo.: %s%-16s %saliases %s$%s%04X %s%-12s%s (%s%s%s)" // MAGIC NUMBER: -MAX_SYMBOLS_LEN
|
||||
, CHC_INFO // 2.9.0.10 was CHC_WARNING, see #479
|
||||
, CHC_SYMBOL
|
||||
, sName
|
||||
, CHC_INFO
|
||||
|
|
|
@ -589,9 +589,6 @@ void DiskInitialize(void)
|
|||
int loop = NUM_DRIVES;
|
||||
while (loop--)
|
||||
g_aFloppyDisk[loop].clear();
|
||||
|
||||
TCHAR imagefilename[MAX_PATH];
|
||||
_tcscpy(imagefilename,g_sProgramDir);
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
|
|
@ -191,9 +191,6 @@ bool CImageBase::WriteBlock(ImageInfo* pImageInfo, const int nBlock, LPBYTE pBlo
|
|||
// Horribly inefficient! (Unzip to a normal file if you want better performance!)
|
||||
const UINT uNewImageSize = Offset+HD_BLOCK_SIZE;
|
||||
BYTE* pNewImageBuffer = new BYTE [uNewImageSize];
|
||||
_ASSERT(pNewImageBuffer);
|
||||
if (!pNewImageBuffer)
|
||||
return false;
|
||||
|
||||
memcpy(pNewImageBuffer, pImageInfo->pImageBuffer, pImageInfo->uImageSize);
|
||||
memset(&pNewImageBuffer[pImageInfo->uImageSize], 0, uNewImageSize-pImageInfo->uImageSize); // Should always be HD_BLOCK_SIZE (so this is redundant)
|
||||
|
@ -1152,8 +1149,6 @@ ImageError_e CImageHelperBase::CheckGZipFile(LPCTSTR pszImageFilename, ImageInfo
|
|||
|
||||
const UINT MAX_UNCOMPRESSED_SIZE = GetMaxImageSize() + 1; // +1 to detect images that are too big
|
||||
pImageInfo->pImageBuffer = new BYTE[MAX_UNCOMPRESSED_SIZE];
|
||||
if (!pImageInfo->pImageBuffer)
|
||||
return eIMAGE_ERROR_BAD_POINTER;
|
||||
|
||||
int nLen = gzread(hGZFile, pImageInfo->pImageBuffer, MAX_UNCOMPRESSED_SIZE);
|
||||
if (nLen < 0 || nLen == MAX_UNCOMPRESSED_SIZE)
|
||||
|
@ -1218,8 +1213,6 @@ ImageError_e CImageHelperBase::CheckZipFile(LPCTSTR pszImageFilename, ImageInfo*
|
|||
return eIMAGE_ERROR_BAD_SIZE;
|
||||
|
||||
pImageInfo->pImageBuffer = new BYTE[uFileSize];
|
||||
if (!pImageInfo->pImageBuffer)
|
||||
return eIMAGE_ERROR_BAD_POINTER;
|
||||
|
||||
nRes = unzOpenCurrentFile(hZipFile);
|
||||
if (nRes != UNZ_OK)
|
||||
|
@ -1348,8 +1341,6 @@ ImageError_e CImageHelperBase::CheckNormalFile(LPCTSTR pszImageFilename, ImageIn
|
|||
const UINT uDetectSize = GetMinDetectSize(dwSize, &bTempDetectBuffer);
|
||||
|
||||
pImageInfo->pImageBuffer = new BYTE [dwSize];
|
||||
if (!pImageInfo->pImageBuffer)
|
||||
return eIMAGE_ERROR_BAD_POINTER;
|
||||
|
||||
DWORD dwBytesRead;
|
||||
BOOL bRes = ReadFile(hFile, pImageInfo->pImageBuffer, dwSize, &dwBytesRead, NULL);
|
||||
|
@ -1373,9 +1364,6 @@ ImageError_e CImageHelperBase::CheckNormalFile(LPCTSTR pszImageFilename, ImageIn
|
|||
if (pImageType && dwSize)
|
||||
{
|
||||
pImageInfo->pImageBuffer = new BYTE [dwSize];
|
||||
if (!pImageInfo->pImageBuffer)
|
||||
return eIMAGE_ERROR_BAD_POINTER;
|
||||
|
||||
ZeroMemory(pImageInfo->pImageBuffer, dwSize);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2139,8 +2139,8 @@ void RelayEvent (UINT message, WPARAM wparam, LPARAM lparam) {
|
|||
|
||||
// CtrlReset() vs ResetMachineState():
|
||||
// . CPU:
|
||||
// Ctrl+Reset : sp=-3 / CpuReset()
|
||||
// Power cycle: sp=0x1ff / CpuInitialize()
|
||||
// Ctrl+Reset : 6502.sp=-3 / CpuReset()
|
||||
// Power cycle: 6502.sp=0x1ff / CpuInitialize()
|
||||
// . Disk][:
|
||||
// Ctrl+Reset : if motor-on, then motor-off but continue to spin for 1s
|
||||
// Power cycle: motor-off & immediately stop spinning
|
||||
|
@ -2149,6 +2149,7 @@ void RelayEvent (UINT message, WPARAM wparam, LPARAM lparam) {
|
|||
void ResetMachineState ()
|
||||
{
|
||||
DiskReset(true);
|
||||
HD_Reset();
|
||||
g_bFullSpeed = 0; // Might've hit reset in middle of InternalCpuExecute() - so beep may get (partially) muted
|
||||
|
||||
MemReset(); // calls CpuInitialize()
|
||||
|
@ -2182,11 +2183,13 @@ void CtrlReset()
|
|||
|
||||
PravetsReset();
|
||||
DiskReset();
|
||||
HD_Reset();
|
||||
KeybReset();
|
||||
if (!IS_APPLE2) // TODO: Why not for A][ & A][+ too?
|
||||
VideoResetState(); // Switch Alternate char set off
|
||||
sg_SSC.CommReset();
|
||||
MB_Reset();
|
||||
sg_Mouse.Reset(); // Deassert any pending IRQs - GH#514
|
||||
#ifdef USE_SPEECH_API
|
||||
g_Speech.Reset();
|
||||
#endif
|
||||
|
|
|
@ -321,6 +321,15 @@ static LPCTSTR HD_DiskGetBaseName(const int iDrive) // Not used
|
|||
return g_HardDisk[iDrive].imagename;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------
|
||||
|
||||
void HD_Reset(void)
|
||||
{
|
||||
g_HardDisk[HARDDISK_1].hd_error = 0;
|
||||
g_HardDisk[HARDDISK_2].hd_error = 0;
|
||||
}
|
||||
|
||||
//-------------------------------------
|
||||
|
||||
void HD_Load_Rom(const LPBYTE pCxRomPeripheral, const UINT uSlot)
|
||||
|
|
|
@ -35,6 +35,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|||
void HD_SetEnabled(const bool bEnabled);
|
||||
LPCTSTR HD_GetFullName(const int iDrive);
|
||||
LPCTSTR HD_GetFullPathName(const int iDrive);
|
||||
void HD_Reset(void);
|
||||
void HD_Load_Rom(const LPBYTE pCxRomPeripheral, const UINT uSlot);
|
||||
bool HD_Select(const int iDrive);
|
||||
BOOL HD_Insert(const int iDrive, LPCTSTR pszImageFilename);
|
||||
|
|
|
@ -173,6 +173,7 @@ static void Snapshot_LoadState_v1() // .aws v1.0.0.1, up to (and including) Appl
|
|||
// Reset all sub-systems
|
||||
MemReset();
|
||||
DiskReset();
|
||||
HD_Reset();
|
||||
KeybReset();
|
||||
VideoResetState();
|
||||
MB_Reset();
|
||||
|
@ -494,6 +495,7 @@ static void Snapshot_LoadState_v2(void)
|
|||
MemReset();
|
||||
PravetsReset();
|
||||
DiskReset();
|
||||
HD_Reset();
|
||||
KeybReset();
|
||||
VideoResetState();
|
||||
MB_Reset();
|
||||
|
|
|
@ -401,6 +401,7 @@ void CSuperSerialCard::CommTcpSerialReceive()
|
|||
if (m_bRxIrqEnabled && !m_qTcpSerialBuffer.empty())
|
||||
{
|
||||
CpuIrqAssert(IS_SSC);
|
||||
m_vbRxIrqPending = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1333,7 +1334,7 @@ void CSuperSerialCard::SetSnapshot_v1( const DWORD baudrate,
|
|||
// m_vRecvBytes = recvbytes;
|
||||
m_uStopBits = stopbits;
|
||||
|
||||
//m_uDTR = (m_uCommandByte & 0x01) ? DTR_CONTROL_ENABLE : DTR_CONTROL_DISABLE; // TODO: Once GH#386 is resolved
|
||||
m_uDTR = (m_uCommandByte & 0x01) ? DTR_CONTROL_ENABLE : DTR_CONTROL_DISABLE;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
|
@ -1440,7 +1441,7 @@ bool CSuperSerialCard::LoadSnapshot(YamlLoadHelper& yamlLoadHelper, UINT slot, U
|
|||
m_vbRxIrqPending = yamlLoadHelper.LoadBool(SS_YAML_KEY_RXIRQPENDING);
|
||||
m_bWrittenTx = yamlLoadHelper.LoadBool(SS_YAML_KEY_WRITTENTX);
|
||||
|
||||
//m_uDTR = (m_uCommandByte & 0x01) ? DTR_CONTROL_ENABLE : DTR_CONTROL_DISABLE; // TODO: Once GH#386 is resolved
|
||||
m_uDTR = (m_uCommandByte & 0x01) ? DTR_CONTROL_ENABLE : DTR_CONTROL_DISABLE;
|
||||
|
||||
std::string serialPortName = yamlLoadHelper.LoadString(SS_YAML_KEY_SERIALPORTNAME);
|
||||
SetSerialPortName(serialPortName.c_str());
|
||||
|
|
|
@ -109,6 +109,64 @@ static void DisplayBenchmarkResults ()
|
|||
MB_ICONINFORMATION | MB_SETFOREGROUND);
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
//
|
||||
// DC filtering V2 (Riccardo Macri May 2015) (GH#275)
|
||||
//
|
||||
// To prevent loud clicks on Window's sound buffer underruns and constant DC
|
||||
// being sent out to amplifiers (some soundcards are DC coupled) which is
|
||||
// not good for them, an attenuator slowly drops the speaker output
|
||||
// to 0 after the speaker (or 8 bit DAC) has been idle for a couple hundred
|
||||
// milliseconds.
|
||||
//
|
||||
// The approach works as follows:
|
||||
// - SpkrToggle() is called when the speaker state is flipped by accessing $C030
|
||||
// - This brings audio up to date then calls ResetDCFilter()
|
||||
// - ResetDCFilter() sets a counter to a high value
|
||||
// - every audio sample is processed by DCFilter() as follows:
|
||||
// - if the counter is >= 32768, the speaker has been recently toggled
|
||||
// and the samples are unaffected
|
||||
// - if the counter is < 32768 but > 0, it is used to scale the
|
||||
// sample to reduce +ve or -ve speaker states towards zero
|
||||
// - In the two cases above, the counter is decremented
|
||||
// - if the counter is zero, the speaker has been silent for a while
|
||||
// and the output is 0 regardless of the speaker state.
|
||||
//
|
||||
// - the initial "high value" is chosen so 10000/44100 = about a
|
||||
// quarter of a second of speaker inactivity is needed before attenuation
|
||||
// begins.
|
||||
//
|
||||
// NOTE: The attenuation is not ever reducing the level of audio, just
|
||||
// the DC offset at which the speaker has been left.
|
||||
//
|
||||
// This approach has zero impact on any speaker tones including PWM
|
||||
// due to the samples being unchanged for at least 0.25 seconds after
|
||||
// any speaker activity.
|
||||
//
|
||||
|
||||
static UINT g_uDCFilterState = 0;
|
||||
|
||||
inline void ResetDCFilter(void)
|
||||
{
|
||||
// reset the attenuator with an additional 250ms of full gain
|
||||
// (10000 samples) before it starts attenuating
|
||||
g_uDCFilterState = 32768 + 10000;
|
||||
}
|
||||
|
||||
inline short DCFilter(short sample_in)
|
||||
{
|
||||
if (g_uDCFilterState == 0) // no sound for a while, stay 0
|
||||
return 0;
|
||||
|
||||
if (g_uDCFilterState >= 32768) // full gain after recent sound
|
||||
{
|
||||
g_uDCFilterState--;
|
||||
return sample_in;
|
||||
}
|
||||
|
||||
return (((int)sample_in) * (g_uDCFilterState--)) / 32768; // scale & divide by 32768 (NB. Don't ">>15" as undefined behaviour)
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
|
||||
static void SetClksPerSpkrSample()
|
||||
|
@ -130,7 +188,7 @@ static void InitRemainderBuffer()
|
|||
SetClksPerSpkrSample();
|
||||
|
||||
g_nRemainderBufferSize = (UINT) g_fClksPerSpkrSample;
|
||||
if ((double)g_nRemainderBufferSize != g_fClksPerSpkrSample)
|
||||
if ((double)g_nRemainderBufferSize < g_fClksPerSpkrSample)
|
||||
g_nRemainderBufferSize++;
|
||||
|
||||
g_pRemainderBuffer = new short [g_nRemainderBufferSize];
|
||||
|
@ -283,7 +341,7 @@ static void UpdateRemainderBuffer(ULONG* pnCycleDiff)
|
|||
nSampleMean /= (signed long) g_nRemainderBufferSize;
|
||||
|
||||
if(g_nBufferIdx < SPKR_SAMPLE_RATE-1)
|
||||
g_pSpeakerBuffer[g_nBufferIdx++] = (short) nSampleMean;
|
||||
g_pSpeakerBuffer[g_nBufferIdx++] = DCFilter( (short)nSampleMean );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -301,7 +359,7 @@ static void UpdateSpkr()
|
|||
ULONG nCyclesRemaining = (ULONG) ((double)nCycleDiff - (double)nNumSamples * g_fClksPerSpkrSample);
|
||||
|
||||
while((nNumSamples--) && (g_nBufferIdx < SPKR_SAMPLE_RATE-1))
|
||||
g_pSpeakerBuffer[g_nBufferIdx++] = g_nSpeakerData;
|
||||
g_pSpeakerBuffer[g_nBufferIdx++] = DCFilter(g_nSpeakerData);
|
||||
|
||||
ReinitRemainderBuffer(nCyclesRemaining); // Partially fill 1Mhz sample buffer
|
||||
}
|
||||
|
@ -336,21 +394,16 @@ BYTE __stdcall SpkrToggle (WORD, WORD, BYTE, BYTE, ULONG nCyclesLeft)
|
|||
|
||||
UpdateSpkr();
|
||||
|
||||
if (g_bQuieterSpeaker)
|
||||
{
|
||||
// quieten the speaker if 8 bit DAC in use
|
||||
if (g_nSpeakerData == (SPKR_DATA_INIT >> 2))
|
||||
g_nSpeakerData = ~g_nSpeakerData;
|
||||
else
|
||||
g_nSpeakerData = SPKR_DATA_INIT>>2;
|
||||
}
|
||||
short speakerDriveLevel = SPKR_DATA_INIT;
|
||||
if (g_bQuieterSpeaker) // quieten the speaker if 8 bit DAC in use
|
||||
speakerDriveLevel /= 4; // NB. Don't shift -ve number right: undefined behaviour (MSDN says: implementation-dependent)
|
||||
|
||||
ResetDCFilter();
|
||||
|
||||
if (g_nSpeakerData == speakerDriveLevel)
|
||||
g_nSpeakerData = ~speakerDriveLevel;
|
||||
else
|
||||
{
|
||||
if (g_nSpeakerData == SPKR_DATA_INIT)
|
||||
g_nSpeakerData = ~g_nSpeakerData;
|
||||
else
|
||||
g_nSpeakerData = SPKR_DATA_INIT;
|
||||
}
|
||||
g_nSpeakerData = speakerDriveLevel;
|
||||
}
|
||||
|
||||
return MemReadFloatingBus(nCyclesLeft);
|
||||
|
@ -575,7 +628,7 @@ static ULONG Spkr_SubmitWaveBuffer_FullSpeed(short* pSpeakerBuffer, ULONG nNumSa
|
|||
|
||||
if(dwBufferSize0)
|
||||
{
|
||||
wmemset((wchar_t*)pDSLockedBuffer0, (wchar_t)g_nSpeakerData, dwBufferSize0/sizeof(wchar_t));
|
||||
wmemset((wchar_t*)pDSLockedBuffer0, (wchar_t)DCFilter(g_nSpeakerData), dwBufferSize0/sizeof(wchar_t));
|
||||
#ifdef RIFF_SPKR
|
||||
RiffPutSamples(pDSLockedBuffer0, dwBufferSize0/sizeof(short));
|
||||
#endif
|
||||
|
@ -583,7 +636,7 @@ static ULONG Spkr_SubmitWaveBuffer_FullSpeed(short* pSpeakerBuffer, ULONG nNumSa
|
|||
|
||||
if(pDSLockedBuffer1)
|
||||
{
|
||||
wmemset((wchar_t*)pDSLockedBuffer1, (wchar_t)g_nSpeakerData, dwBufferSize1/sizeof(wchar_t));
|
||||
wmemset((wchar_t*)pDSLockedBuffer1, (wchar_t)DCFilter(g_nSpeakerData), dwBufferSize1/sizeof(wchar_t));
|
||||
#ifdef RIFF_SPKR
|
||||
RiffPutSamples(pDSLockedBuffer1, dwBufferSize1/sizeof(short));
|
||||
#endif
|
||||
|
|
|
@ -58,6 +58,12 @@ void uilib_get_general_window_extents(HWND hwnd, int *xsize, int *ysize)
|
|||
strlen = SendMessage(hwnd, WM_GETTEXTLENGTH, 0, 0);
|
||||
/* RGJ added cast for AppleWin */
|
||||
buffer = (char *) malloc(strlen + 1);
|
||||
if (buffer == NULL) // TC: add null check for AppleWin
|
||||
{
|
||||
*xsize = 0;
|
||||
*ysize = 0;
|
||||
return;
|
||||
}
|
||||
GetWindowText(hwnd, buffer, strlen + 1);
|
||||
|
||||
hdc = GetDC(hwnd);
|
||||
|
|
|
@ -32,8 +32,6 @@
|
|||
#include <windows.h>
|
||||
#include <tchar.h>
|
||||
|
||||
extern void uilib_get_general_window_extents(HWND hwnd, int *xsize, int *ysize);
|
||||
|
||||
typedef struct {
|
||||
unsigned int idc;
|
||||
int element_type;
|
||||
|
|
|
@ -722,14 +722,7 @@ BYTE VideoSetMode (WORD, WORD address, BYTE write, BYTE, ULONG uExecutedCycles)
|
|||
case 0x5F: if (!IS_APPLE2) g_uVideoMode &= ~VF_DHIRES; break;
|
||||
}
|
||||
|
||||
// Apple IIe, Technical Notes, #3: Double High-Resolution Graphics
|
||||
// 80STORE must be OFF to display page 2
|
||||
if (SW_80STORE)
|
||||
g_uVideoMode &= ~VF_PAGE2;
|
||||
|
||||
// NTSC_BEGIN
|
||||
NTSC_SetVideoMode( g_uVideoMode );
|
||||
// NTSC_END
|
||||
|
||||
return MemReadFloatingBus(uExecutedCycles);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue