Tweaked the sound code again, to eliminate garbage data between
loading ROMs.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2342 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Updated ROM properties for 'Gingerbread Man' homebrew ROM, which
uses the Genesis controller.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2341 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
any UI items within the debugger.
Added BoosterWidget UI class for changing BoosterGrip data in
the debugger I/O tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2339 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
first time that paddle movement is able to be set from within
the debugger!
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2337 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
I/O tab in the debugger. For now, only joystick is
partly implemented. Eventually, all Stella controllers
will have UI items (where it makes sense), allowing to
completely control input devices from within the
debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2334 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
other than that specified by 'romdir'. I'm not going to document
this functionality, since it's a convenience function that will
probably only be used by me anyway.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2333 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
actually change values in the emulation core when clicked.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2328 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Updated all bankswitch schemes for potential buffer overflow
issues. Copying was being done without regard for the size of the
ROM buffer.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2325 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
these aren't fully activated yet, but they're the next thing I plan
to work on.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2322 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
I'm still waiting on a test ROM to verify that its output is valid.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2319 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
these logs!
Moved TODO and Credits info directly to the webpage, where it will hopefully
be easier to maintain.
Fixed 'crackling' sound when loading a new ROM, introduced with the 3.5
sound restructuring. It looks like stale data was being loaded by the
sound processing callback. As well, moved the computation of certain
division variables from the sound callback to the framerate re-calculator
(where it's recomputed 1/5 of the time or less).
Updated AboutDialog with info about Stella DonationWare status, and active
members of Stella development.
Updated OSX in-app HTML documentation about Stella DonationWare status.
Bumped version # to 3.5.1_svn, and the process starts again.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2318 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
it should always display the playfield colour, even if it
would normally use P0/P1 colours in normal mode.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2317 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
mean 'hardware-accelerated, double-buffered'. This distinction
is important, since eventually such a mode won't necessarily be
OpenGL-backed (it might be Direct3D, OpenGLES, etc).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2312 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
but at least it progresses through different screens when you press
1, 2, 3.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2307 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Eventually I'll find a more elegant way to represent this.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2301 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
separately to different paddles.
Updated documentation for impending 3.5 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2296 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
'const string&', which saves a string c'tor call each time they're
accessed.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2293 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
when it isn't needed. According to SDL this shouldn't be necessary, but
some combinations of video modes and audio hardware cause sound to stop
working if it's repeatedly opened and closed. So we have to keep it open.
Always attempt to use 2 channels (aka stereo) when opening the SDL audio
device. This is now required, since ROMs can request mono or stereo mode,
and the sound system can no longer be closed and re-opened with the
desired settings. So we need to always use 2 channels to accommodate
when it might be needed. This actually more closely emulates the 2600,
which does have two audio channels. The 'mono' vs 'stereo' ROM property
basically controls whether these channels are exposed (ie, does the
virtual console have two-channel audio hardware installed). In that sense,
these settings control how the channels are mixed.
Updated some settings to have more reasonable defaults.
Added acknowledgement for people that have donated hardware to help with
development.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2291 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
They were being saved correctly for all sticks, but only loaded for
the first one.
Removed some redundant settings related to TV effects stuff.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2289 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
ROMs with an odd # of scanlines will display the image in
black & white, just as on a real system.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2287 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
have actually been loaded during the program run. Otherwise,
it will erase previous mappings.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2286 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
saved per device, so that unplugging and replugging a joystick won't cause
the previous mappings to be lost.
All attributes of a joystick (ie, number of sticks, number of axes, buttons,
hats on each stick) are dynamic, meaning that hardcoded values are no
longer used, making the handling more robust.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2285 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
desktop on OSX and Windows, and the home directory in Linux.
The associated commandline has been changed to 'snapdir'.
Added 'GL VBO' toggle button to the Video Settings UI, and in
general cleaned up its interface.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2282 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
in this area.
Added commandline argument 'thumb.trapfatal', which causes fatal errors in
the Thumb ARM emulation to really be treated as fatal (ie, the emulation stops
and throws an exception). This is enabled by default (as it always should be).
When disabled, fatal errors simply log the error and continue with emulation.
This was added because the current HarmonyCart ARM code isn't always exactly
compatible with the emulation in Stella, and there is a lagtime from when
Harmony implements something to when the same functionality is added to Stella.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2279 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Specifically, the 3-voice audio routines read from ROM instead of RAM, and
the setting the ARM MAM register no longer causes the ARM emulation to crash.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2278 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
distinct GUI vs non-GUI (aka TIA) classes. This makes it easy to proceed
from this point on, since I don't have to worry about breaking one mode
when making changes to the other.
Preliminary support for TIA scanlines in OpenGL mode. It's disabled for
now, but is progressing nicely. This will be part of the new TV effects
in the next major release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2273 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
In the process of converting the code to be OpenGL ES compliant, we shouldn't
hurt the performance on systems with more advanced versions.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2272 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
compliant. It actually went smoother than I thought it would.
This show allow Stella to run well on *any* hardware-accelerated
OpenGL machine, not just those with beefy video cards.
Cleaned up the code a little, removing more references to the old
OpenGL TV filtering (which will be replaced by Blargg NTSC
filtering soon enough). Also removed 'gl_texrect' option, which
specified to use the GL_TEXTURE_RECTANGLE_ARB extension (for
non power-of-two textures). It was never enabled by default,
didn't work with ATI cards, and wasn't accessible in the UI,
so I doubt anyone will miss it. Besides, it's not supported in
OpenGL ES 1.x.
Next is to look into VBO/PBO, to see if more optimizations can
be done.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2265 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
don't normally use the commandline (mostly Windows, but in some cases OSX as
well). The 'showinfo' commandline argument has been renamed 'loglevel', but
it has the same purpose. A new option 'logtoconsole' has been added, which
determines whether log output should also be directed to the commandline/
console (previously, it was always printed to the console). All these items
are now accessible from Options -> System Logs.
For anyone reading this (and that cares), now I can finally move on to the
OpenGL rewrite. The plan is that the new code will use OpenGL ES, which
is a subset of OpenGL 1.5. The main advantages are that you won't need
an advanced OpenGL card, and OpenGL ES is supported on most new 'smaller'
systems (iPhone, Android, etc), making ports much easier.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2264 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
BSPF_snprintf instead, which should eliminate any potential
buffer overflows. Also moved from static arrays to stringstreams
where appropriate to make things safer and more C++ like.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2263 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
of the C++ standard.
Fixed bug when using snprintf; we must use BSPF_snprintf, since the function
has different names in different OS's.
Optimized loading of PNG images in the RomInfoWidget so that memory allocations
aren't continuously being done. Basically, memory is allocated once and then
only re-allocated if a new image is larger than all previous ones. This can
increase memory use slightly, as the image data stays around between image loads,
and it remembers the largest image loaded. But if you images are all mostly the
same size, it should hurt memory usage too much. And it really helps on certain
systems where repeated (re)-allocations can cause problems.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2261 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Blargg NTSC filtering, but we need to revert to base functionality first.
Cleaned up the debugger API wrt converting values from integers to strings
(and vice-versa). There is now only one method for each of these functions,
rather than several ways to do so. In the process, convert from unsafe
sprintf functions into snprintf (eliminate potential buffer overflows).
The debugger 'print' command now indicates if any assigned label represents
a read-only location (R), a write-only location (W), or a read/write location
(R/W).
Fixed bug in DataGridWidgets (used in debugger ROM and CPU registers), where
scrolling the mouse-wheel would cause a segfault. Scrolling the mousewheel
now changes these items as expected.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2260 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
contents. The file was being accessed and read, but the commands it contained
weren't being executed! This bug appeared in April 2010, so it looks like
not many people are using this feature (or at least they're not reporting it).
Cleaned up a few compiler warnings in DebuggerParser class.
Bumped version # for beta release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2254 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
for UNIX systems. Pathnames are always accessed internally as
full/absolute pathnames, and while they can be loaded and saved
with the '~' symbol (to indicate the users home directory), they
are still always mapped to absolute paths.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2252 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Fixed bug in handling analog axes with jitter; they were overriding events from
digital, hat and keyboard input.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2251 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
The debugger 'saverom' command now uses absolute filenames, and by default
will save data in the users home directory if a proper path isn't included
in the filename. This fixes a major bug where ROMs were being saved to
the current or application directory, which in some cases were invalid
locations.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2250 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
several cases (fixes problems when moving the mouse too fast or
when changing between video modes). Added extra signature to the
bankswitch autodetection for the 4A50 scheme.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2249 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
- it doesn't have a hotkey any more
- it is changed in the "Input Settings' UI, not in 'Video Settings'
- it only has meaning while in emulation mode
- it is enabled by default
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2245 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
That's why I'm not bumping the final version number until
just before the release ...
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2238 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This basically shows a messagebox as soon as the debugger starts,
describing the error and offering the choice to continue debugging
or exiting the ROM entirely.
The DPC+ code now catches fatal errors from the Thumb ARM
emulation code and shows it as a fatal error in the debugger.
This means you no longer need to look at the commandline for
this output, and you immediately know that something has
gone wrong.
Added 'exitrom' debugger parser command, which completely exits
from the debugger *and* the ROM, going back to the ROM launcher.
Cleaned up the API a little, rearranging some classes and
adding references instead of pointers. More work to be done
in this area.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2234 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
console (which doesn't exist on every platform). Also use proper C++
stringstreams instead of C-style arrays (which are evil). If an exception
is thrown, start the debugger with a fatal error message. Currently, this
message is simply printed in the debugger info window. Still TODO is add
a dialog to show the entire input from within the UI, as well as a way
to exit the ROM when a fatal error occurs.
Cleaned up the API a little, adding explicit declarations for when a method
can throw an exception. Also merged some empty classes directly into their
header files.
Added functionality to the System class for querying whether it has
been reset while in 'autodetect' mode. Autodect mode is defined as
when Stella starts and temporarily runs to autoconfigure itself.
Some classes (such as Thumb ARM emulation) need to know this, and
suppress debugging output/throwing exceptions when not running in
normal emulation mode.
I hope to have a new release done by the end of this week, or the end
of the month at the latest.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2232 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Updated documentation with info about 2600-daptor, including
usage and its creator. Also included more in-depth explanation
for the various controller types.
Errors from the Thumb ARM emulation code are now caught as exceptions,
and thrown to the parent class instead of calling exit() and simply
crashing Stella. For now, the messages are simply printed and
emulation continues. This will be expanded to show a detailed crash
log in the debugger, and offer the option to exit the ROM.
Removed most of the menus from the OSX port. They weren't being
maintained anyway, and most of them didn't work. I've modelled this
on the way other cross-platform OSX programs work (notably, ScummVM).
Basically, there are menus for exit and help, but otherwise you
should use the menuing system in the application itself.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2231 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
which are specialized paddles classes that invert the axis, direction,
and axis+direction, respectively. Updated all applicable ROMs in the
properties database.
Cleaned up the menus in the OSX port; some of them weren't even tied
to anything. I'm seriously considering removing them all, except for
the Help and Quit items.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2230 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
- mouse can now emulate joystick, booster-grip and driving controllers
- digital and mouse sensitivity for paddles can now be tweaked
separately, and have a greater range
- the mouse now correctly honours its controller setting, and only
controls a device on one one port (not both at the same time)
Added support for 2600-daptor device. Credit for creator of device
is forthcoming. This device is basically an updated Stelladaptor,
with improved handling for paddle data.
Grabmouse functionality is no longer user-definable; the mouse is
always grabbed while playing a game, and released otherwise.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2228 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
and doesn't currently compile. I don't have the hardware to develop
it any further, and no longer have the time in any event. If someone
steps up to continue support, it can be added back into the codebase.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2227 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
but can be disabled by removing the 'THUMB_SUPPORT' directive from the
Visual Studio project file).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2217 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Wrapped THUMB ARM emulation in a define, so that it can be excluded
from builds. To enable it, the 'THUMB_SUPPORT' directive must be
included in the build process. This has been added to the OSX
project files, but is still TODO for Linux and Windows.
Removed some obsolete include paths from the OSX project files,
dating back about 5 years or so.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2215 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Also fixed warnings when compiling on 64-bit compilers.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2214 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
launcher is selected, not the actual ROM directory. This speeds up
access, because generally you'll want to audit the directory you're
actually looking at.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2196 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Hopefully this marks a return to Stella development, as I haven't had
much free time over the past month or so.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2194 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Added infrastructure to System and Device classes to deal with CodeAccessBase
even when the bankswitching scheme bypasses the normal System::PageAccess
way of reading ROM space. This allows bankswitching schemes 2E, AR, FE and
4A50 to support emulation core 'hints' for more accurate disassembly. The
only scheme not supported now is MC, which isn't really working anyway (I've
never actually had a test ROM for this scheme).
It's getting close, folks ...
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2184 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
multiple concatentation of strings. This should be faster, or at least
lead to less string constructor calls.
Output of 'ROW' directives in the disassembly now shows only 8 items per
line, instead of 16. This allows to see all the bytes without having a
'...' in between. A future release may customize this to the size of the
output area.
Fixed output from debugger 'disasm' command to properly align different
directive types and show GFX and PGFX output.
Bumped state file version to 3.3 final, since there are no further
changes to the code that will break the file format.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2183 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Removed reference to disassembly 'SKIP' command, since it isn't implemented
yet.
Decided on Nov. 15 for the 3.3 release date, and updated all relevant files.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2181 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
disassembly. This allows the debugger 'jump' command to be more accurate.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2180 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
for these opcodes.
The 'data source' in the debugger CPU area now also shows the SP register,
since it's used for TSX and TXS.
Bumped version # for another test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2177 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Still TODO is add support for PHA, PHP, PLA and PLP, and to somehow track
accesses that are stored in zero-page RAM first. These latter items may
end up being pushed after the 3.3 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2175 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
(ie, each bit now takes priority over ones with lower value). This
doesn't change the processing in any way, but simply makes the bitstring
more accurately reflect what's going on.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2174 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
tired of doing it manually every time it changes.
Tweaked the handling of JSR, RTI and RTS commands, so they don't erroneously
mark associated addresses as CODE when in fact they're never actually
executed.
Several parts of the Distella code were marking areas as DATA, even though
it depending on knowing the values for the X and Y registers (which it
doesn't, as it's a static analysis). As such, these areas are now marked
as ROW instead, since that's as precise as a static analysis can do. The
processing blocks are left there, though, in case Distella is improved in
a future release.
All the above changes allow for better disassembly with less
'false positives' (ie, areas marked as CODE or DATA when they really aren't).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2172 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
emulation core, and distella). This allows to better see exactly how an
address is marked in the disassembly.
Updated Changelog with changes I forgot that I made (you know it's time
for a new release when you forget what's been added since the last one).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2170 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
the given screen. This is allowed in windowed mode, since the window
manager normally takes care of it. In the case of fullscreen mode, however,
it is never allowed, and an error message is shown.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2169 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
to use curly braces {} instead of apostrophes. This matches the
functionality from older releases.
Fixed debugger prompt messages to show correct info when opening
various files (config files, autoexec, etc).
The debugger 'type' command now accepts a range of values.
Reverted handling of ROMs that aren't in the internal database;
they're inserted with their extension again, just as in older
releases.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2168 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
weren't being flipped after a refresh. This could be the cause of a
recently reported problem with fullscreen OpenGL mode 'bleed-through'
of the desktop.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2165 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
in the emulation core, since at that point it's unknown what they are.
I suspect there are other places in the core where this is being done,
so I need to go over the entire M6502.m4 file again.
In Distella, when tentatively marking an address range as CODE, stop
when encountering the first address marked as DATA/GFX/PGFX by the
emulation core. This is required since Distella will happily disassemble
CODE as far as possible, but addresses specifically marked as
DATA/GFX/PGFX obviously indicate the CODE range is finished. This is
also why it's so important to correctly mark areas as DATA; the
Distella algorithm depends on accurate information to know when to stop.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2163 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
in a consistent way. Directives set manually have top priority, then the
results from a dynamic analysis (aka, from actually running the code), and
finally from a static analysis (aka, Distella itself).
Sometimes Distella will mark a section as CODE even if it hasn't been
marked as such dynamically. This occurs after a relative branch, which
Distella has no idea how to evaluate. It's possible that the code will
be executed eventually, but also that it will never be executed. As such,
these lines are marked with a '*', indicating that disassembly results
are tentative. If you get weird looking disassembly for these addresses,
it's probably a hint that it isn't really code at all.
PC addresses in the disassembly labels are now aligned with labels, and
shown in a lighter color. These can still be toggled on and off.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2162 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
to the emulation core. That is, if something is determined to be CODE in
Distella and *not* in the emulation core, then it shouldn't be marked as such.
Note that the disassembly will still show it as CODE; it's just that the core
will not. This fixes issues with manually specifying directives from the
debugger prompt, whereby setting a directive and later turning it off never
actually turns it off (as it was being permanently set).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2160 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
whether or not they're in cart space (aka, above $1000). Other parts of
the code can then choose whether to use them, if desired. This fixes a bug
in the 'Data src' output in the CPU area of the debugger, whereby addresses
were zeroed if they resulted from addresses below $1000.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2158 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
detection and marking of those areas into the TIA class itself, specifically
at the location of the write. In other words, there's no longer an IF
statement executed for every STx opcode; the marking is done directly
within the write to GRPx or PFx, so extra code is only executed when
actually storing to those locations.
Fixed several cases of opcodes marking an area as CODE when it should have
been DATA.
Added output to the CPU area of the debugger for displaying the source
address for loading data into the A/X/Y registers. Note that these are
only modified when actual addresses are used, so immediate and zero-page
mode will show addresses as zero (meaning that no address was involved
in retrieving the data).
Tweaked console font to better diffentiate the disassembly output between
graphics for players and graphics for the playfield.
Bumped state file format because of changes to M6502. This means old
state files will be broken.
Bumped version # for next test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2157 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
previously defined GFX directive is now used for player graphics
only). The 6502 core tracks each of these separately, which provides
for more accurate disassembly.
Modified debugger font and disassembler to show GFX and PGFX with
special characters, instead of using 'X' as Distella does. This also
allows gives much more informative disassembled outout.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2156 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
the various header files. Basically, I'm following advice from
Effective C++, and including only what's absolutely necessary. For
definitions that don't need to be included, the designation 'class xxx'
is used instead. This could potentially lead to faster compile times.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2155 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
marking them as GFX. Still TODO is somehow differentiate these (based
on block, colour, etc). Also requires testing to see if this slows
down the emulation too much.
Removed un-implemented debugger console commands to query the last
addresses used in the A/X/Y registers, since they're going to be added
to the debugger UI itself in the CPU area.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2153 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
values instead of 16-bit.
Fixed compilation of System class and M6502 disassembly tracking when
compiling without debugger support. In this case, the tracking is not
done, and all related operations are completely #ifdef'ed out (resulting
in no extra speed/memory usage at all).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2152 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
currently done by remembering the addresses accessed on execution of
LDA/LDX/LDY, and marking them as GFX during a zero-page STA/STX/STY.
This is obviously as WIP and required much more testing, but I'm
pleasantly surprised by how useful it is so far.
Bumped version # for AtariAge test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2147 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
used as a peek operand). Still TODO is deal with poke areas, which would
be relevant in carts with extended RAM.
The interaction between the internal tracking and Distella is now much
tighter, in that knowledge gained by Distella is used in the core code,
and vice versa. This allows the best of both worlds, where the internal
tracking finds stuff at runtime (that couldn't be found in a static
analysis), and Distella tracks potential paths (that haven't occurred at
runtime yet).
Added 'type' debugger prompt command, which basically queries an address
for its disassembly type (CODE/GFX/DATA, etc).
Added debugger commands to query the last address used in an operation
for various registers, but they're only stubs at the moment.
Updated the bankswitch schemes to deal with accesses in and around the
hotspot areas. Previously, peek accesses in these areas weren't being
recorded as DATA areas.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2145 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
realized that not all things that are referenced are actually data; code can be
referenced too.
Implemented handling of 'DATA' directive. This is very similar to 'GFX',
except X's are not shown for the bits, and the disassembled bytes are always
in hex. For now, it can only be activated manually with a cfg command.
Its real value will become apparent once the emulation tracks when
addresses are actually accessed, differentiating from addresses that are
never referenced (ie, 'ROW'). This will fix the current deficiency in
modifying DATA values (it can't be done, since they're packed into 16 bytes per
line and not changable).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2144 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
in general) into the emulation core. For now, this means integrating the
directive names into CartDebug, and having Distella using those same names.
The new directive names were determined by discussion with Omegamatrix on
AtariAge, and are listed in order of decreasing hierarchy:
SKIP (the 'bit' trick to skip over sections of code)
CODE (addresses accessible to the program counter)
GFX (addresses where data is loaded into TIA GRPx registers)
DATA (addresses referenced somewhere in the ROM)
ROW (addresses never referenced at all)
The next TODO item is to have the 6502 core set these values during emulation.
This is currently (crudely) done with a true/false setting in System::peek,
where true corresponds to CODE. This will be extended, so that false
corresponds to DATA. Eventually GFX will also be detected, by watching writes
to the TIA GRPx registers. Still to work out is how to detect SKIP sections.
Anything not marked with one of the above directives will be marked as ROW,
which essentially means ROM space that is never used. This will have the
nice side effect of detecting dead ROM space, potentially leading to space
optimizations.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2143 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
view. Instead of showing each separate item (in related items), simply
show a 'toggle' option instead.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2142 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
accept a second argument, indicating a range is to be used.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2141 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
operand should be shown, not the two-byte address which it resolves into.
Bumped version # for another test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2140 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
disassembly listing) to show/hide opcode/instruction addresses.
The disassembler now includes hints from current PC location *and* 'code
access points' from the emulation core. Testing has shown that some ROMs
don't show completely accurate disassembled output unless both options are
used.
Updated most of the remaining bankswitch schemes to use the new 'code access
points' functionality during disassembly, allowing for very accurate
disassembled output. Note that the more esoteric schemes (AR, 4A50, FE, MC)
are supported for now.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2139 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
addresses used as part of code execution (ie, from the PC) during emulation.
This gives Distella much more information than can be determined from a
static analysis alone, resulting in an extremely accurate disassembly.
This also allows to generate very accurate debugger .cfg files.
Not all carts have been ported to this new scheme yet, particularly ones
having extended RAM that can be mapped out dynamically.
Note that this new scheme doubles the amount of RAM used for storing ROM
images, so up to 128KB extra will be used. There's also a small runtime
check for each instruction executed. Preliminary testing doesn't show
any slowdowns, but we'll see how it goes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2138 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Cart class it's simply an optimization, but the Distella change actually
modifies the list of addresses (vs. modifying a copy of the list).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2137 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Updated Create_builds to properly deal with spaces in Win32 home directory, and to pause until the EXE release file(s) are actually created.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2136 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
screen size (vertically), the window will open in partially truncated mode,
where the top of the PAL image is cut off. This normally won't be a problem,
as it's mostly blank space anyway.
App window centering is now honoured when changing video zoom levels, not
just when changing eventhandler states.
Bumped version # for another test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2135 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
used the current directory.
Fixed error in generating directive lists; there sometimes were 'holes'
at the boundary of CODE <=> DATA transitions.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2129 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
directives associated with a given bank (or all banks). Sometimes the
directives are so borked that's it's easier to remove them all at once.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2127 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
database, it now has its extension removed (.bin, .a26, etc).
Symbol and config files are now loaded when the debugger is first entered,
not when the ROM is actually loaded. This speeds up ROM loading, since
the user may never need to access these file (ie, they may never enter the
debugger).
The debugger 'loadconfig' and 'saveconfig' commands are now implemented.
Bumped version # for next test release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2126 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Basically, directories are now guaranteed to always end in the path
separator. Ensuring this makes certain sections of code work faster,
and guaranteeing it allows higher layers of code to not worry about it.
Added 'cfgdir' commandline argument, to specify the default directory
for Distella-like Stella-compatible config files.
Implemented 'loadconfig' debugger prompt command. It's currently
working great with several test config files provided by Omega of
AtariAge.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2125 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
mouse button context menu in the disassembly listing. This is used to
set the default display format for GFX data sections (currently, binary
and hex are supported).
Fixed bug in several debugger input areas to accept the '\' symbol.
This symbol is needed when entering data in binary format (it must
prefix the data if the default base for that field isn't binary).
Added 'jump' debugger prompt command, used to scroll the disassembly
to the given address (or there-abouts, if the address isn't valid).
Editing data in the disassembly now won't cause the display to jump to
the current PC. The display will only move to the PC when it actually
changes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2123 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
There was a bug in the linked list code causing directives to be added
incorrectly. Also, merging is now done when possible instead of
creating new nodes. This keeps the directive count as small as possible,
and also helps with memory (less allocations happening).
Fixed bug in printing the 'ORG' directive; it was being printed
before the bank was disassembled, so on the first run it was always 0.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2122 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
longer simply added to a list, but intelligently 'merged' (so that
the entire range represented by all directives contains no overlap).
This makes the disassembly a little faster, since it doesn't have to
iterate redundantly. Still TODO in this area is intelligent insertion
for the same type (ie, if inserting in between like blocks, the
blocks should coalesce, instead of being clipped and then a new range
inserted in between).
Added 'loadconfig' and 'saveconfig' debugger prompt commands, which
will eventually access Distella-like config files. No implementation
is present yet.
Added 'listconfig' debugger command, which lists all directives
currently defined by the user, as well as the directives resulting
from a disassembly of a bank (taking into account extra knowledge
that Stella has WRT cached entry points). This command can show
information for a specified bank, or all banks in the cart.
User-defined directives can now be removed; simply issue the same
command that caused an insertion (ie, attempting to insert the same
type and range will remove it instead).
Fixed bug in Distella processing of directives; similar to the
standalone Distella, directives should be processed *before* any
automatic code determination is done.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2121 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
from a Distella config file. For now, the commands are only accessible
within the debugger prompt, and can only be added (no removal/editing).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2120 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
case-insensive. Currently supported are all commands and
pseudo-registers. Equates/labels and user-defined functions are
still a WIP, since they're stored in various hashtables accessible
by name, which is still a case-sensitive operation. In general,
tab completion is mostly case-insensitive.
Changed the delimiter for surrounding lines with spaces from curly
braces ({}) to the apostrophe (').
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2115 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
address space is shown (either $F000 - $F7FF or $F800 - $FFFF).
This eliminates a lot of .byte directives that are invalid in
2K mode anyway, and speeds up the disassembly a little.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2113 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
'Virtual Devs' tab to 'Devices & Ports'. Updated documentation and
snapshots for this change.
Added Halo 2600 ROM info to internal properties database.
Increased default setting for 'joydeadzone' from 0 to 13. This means
the default deadzone is somewhere around half the axis range (~16500).
Fixed behaviour of hat events; events weren't actually being turned off
until the stick was centered.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2108 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
seems that bankswitching wasn't being enabled before rewinding, and hence
any bankswitching being done on state load was being ignored. This also
affected the loadstate and savestate debugger commands, which weren't working
for exactly the same reason.
Bumped version # for impending point release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2107 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
Added 'ramrandom' commmandline argument, used to toggle randomizing or
zeroing or all RAM in the system (both zero-page and SARA).
Disassembler now properly supports all test cases, including rewinding
within the debugger.
Added preliminary support for disassembling from zero-page RAM.
Bumped version # for final release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2100 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
The disassembler now accepts a range of start addresses and remembers
old entry points, so the disassembly becomes more complete each time
the debugger is used.
Changes to address offsets within the same bank are now supported
(ie, changing from $fxxx to $dxxx within the same bank properly
updates the display).
Re-added ability to manually change banks from the debugger prompt
and the disassembly UI. This now works correctly with the Distella
code.
Cleanup of the Cartridge::bank(...) API: if a bank cannot be changed,
the calling code will now know about it. This fixes confusion with
some ROMs, whereby changing a bank in the debugger prompt would print
a success message even if the operation failed.
Note that these changes have broken rewind in the debugger. Actually,
it only exposes problems that the rewind functionality already had :)
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2098 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba