Commit Graph

662 Commits

Author SHA1 Message Date
stephena 336536745f More Coverity fixes.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3236 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-12-09 17:08:52 +00:00
stephena 8b7043d74a More bugfixes as indicated by Coverity.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3235 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-12-06 18:12:17 +00:00
stephena 9e23bc3580 Some bugs indicated by running Stella through Coverity. Note that many
of these aren't actually bugs per-se, but are to follow good programming
practices.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3234 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-12-05 01:30:17 +00:00
stephena 47911eff21 Some cleanup of redundant spacing. Now that I'm free for basically the next month,
I'll be starting work on Stella again.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3233 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-12-04 19:08:14 +00:00
stephena ef5f1bad4d More clang warning cleanups.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3209 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-15 15:50:25 +00:00
stephena 2ccebc9720 Oops, a little too much pruning, detected by compiling in OSX.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3206 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-14 21:44:24 +00:00
stephena 687b638437 Second pass at cleaning up warnings generated by -Weverything in clang.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3204 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-14 18:14:00 +00:00
stephena f539cef173 I decided to turn on '-Weverything' compiler flag in Clang++ to
see what errors are present in the code.  This is the first pass
in cleaning up the errors it found.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3203 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-13 23:23:12 +00:00
stephena 92fcba53a5 Fixed a few code warnings in the new jitter code.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3201 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-12 18:51:35 +00:00
stephena 4e1b4c95f9 Fixed incorrect bankswitch hotspots for 'MDM' scheme in the debugger.
Changed next version # to 4.6.5; 4.7 will include improved paddle
emulation, but it's not ready yet.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3196 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-09 16:54:39 +00:00
stephena cc7943610d Created a new class RiotRamWidget, which takes the place of the
old RamWidget.  Class RawWidget is now an abstract base class
to RiotRamWidget and CartRamWidget, allowing to share quite a lot
of code.  In the process, both classes now implement input from
the binary and decimal widgets, not just the DataGridWidget.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3195 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-09-07 23:12:00 +00:00
stephena 237f0e5d35 The debugger CPU area now has editable decimal and binary fields for the
registers.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3189 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-07-26 17:28:57 +00:00
stephena 05623c52eb Remove several BSPF defines that are obsolete.
Changed valid() method Serializer to an explicit bool() operator,
to function similar to C++ streams.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3185 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-07-11 22:03:12 +00:00
stephena 4792b534d5 Fairly large commit, but basically it is only enabling the 'override'
C++11 keyword.  This makes developing/maintaining class hierarchies
more manageable.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3182 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-07-10 18:59:03 +00:00
stephena c5819cae46 In my never-ending attempt to eliminate pointers whereever possible,
change all throws of 'const char*' to runtime_error.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3168 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-06-12 20:44:09 +00:00
stephena 99f88719e5 C++ streams can now use a 'string' filename; it no longer has to be 'const char*'.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3167 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-06-12 17:37:58 +00:00
stephena a8a30a1746 Cleaned up I/O in a few places, using C++ streams where appropriate.
For those reading these logs, I hope to get back to Stella development soon.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3166 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-06-11 00:26:13 +00:00
stephena e7fb7318fb Bumped version #.
Introduce namespace to class MD5, so the method call is now MD5::hash()
instead of simply MD5().

Added C++11 '= delete' constructors to most classes, to more clearly
indicate the intent of the class.  Note that this isn't absolutely
necessary, but is considered good form.  I will be teaching a C++ class
over the summer using Stella for examples, so it makes sense to follow
the standard and the textbook recommendations :)


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3164 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-04-26 19:02:42 +00:00
stephena 72ec5f2371 Finally fixed text-entry bug in the debugger. In the process, moved to
C++11 lambdas for enabling per-widget text filtering.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3159 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-04-22 15:02:17 +00:00
stephena 36229b4ee1 And so it begins (again); bumped version # for next release.
Now that there are no dirty updates, remove redundant calls to draw();
calling setDirty() is now sufficient to get the changes shown in the
next frame.  This is also slightly faster, since redrawing is done
only when necessary.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3156 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-03-21 20:00:00 +00:00
stephena 6f194fcd76 DataGridWidget now supports keypad +/-.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3147 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-02-09 19:32:28 +00:00
stephena 2549e4f4c1 Fixed error messages in state loading, and reverted some C++11 features
so that Stella is supported in GCC 4.8.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3144 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-02-06 16:34:01 +00:00
stephena 0afb189322 Updated copyright to 2015. Happy New Year to anyone reading these logs :)
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3131 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2015-01-01 03:49:32 +00:00
stephena 04b99e3503 Fixed some shadowed variable warnings detected by Xcode.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3111 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-12-20 22:59:43 +00:00
stephena f5ceb39149 Cleaned up the various methods for setting default mappings for the keyboard
and joysticks.  It's now easier to read/follow, and has less code.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3110 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-12-19 21:32:19 +00:00
stephena 6c900cdec5 Some minor code cleanups, and converting 0 to nullptr.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3106 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-12-13 21:00:33 +00:00
stephena 31ca88d283 Changed CartWD hotspots from $30 - $3F of the cart RAM area to the TIA area (I really need
to learn to read the specs more closely).  Changed hotspot change to trigger 3 cycles after
initiated instead of 3 address changes.

Added CartWDWidget debugger class, to view/change cart-specific functionality from within
the debugger.

Still TODO is CartWD patching.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3105 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-12-13 19:45:18 +00:00
stephena c7fc207b13 Looks like I was a little to eager with the 'auto' keyword; it broke
some code in CartDebug.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3104 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-12-12 16:50:39 +00:00
stephena ca5f456cf9 Running in autodetect mode should not start the disassembly.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3102 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-24 22:09:06 +00:00
stephena c8400dcfe6 Fixed debugger 'reset' command help documentation.
Renamed 'Vlist' to 'VarList', since it's more descriptive.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3092 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-19 22:29:33 +00:00
stephena 37d9c6c99f Converted from C-style 'typedef' to C++ 'using' where appropriate.
I find the newer syntax more readable, since it acts exactly like
an assignment statement.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3088 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-19 12:10:45 +00:00
stephena 61aa0bb4f4 Visual Studio needs std::mem_fn in association with std::function.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3084 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 20:33:56 +00:00
stephena 3a04afcf96 Use BSPF-defined datatypes where appropriate.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3083 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 14:17:19 +00:00
stephena d5a470cbcc Debugger reset command now does a full system reset.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3082 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 12:47:33 +00:00
stephena 086658799d It looks like I can use std::function in expressions after all (keeping
in mind that YACC stuff deals strictly in pointers, and can't be changed).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3081 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 01:50:19 +00:00
stephena f0539ae7e1 Cleaned up function calling from expressions for various debugger subsystems.
I'd hoped to use std::function, but I don't want to dive any further into the
arcane YACC syntax.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3080 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 01:36:44 +00:00
stephena 021e0caa55 Changed to std::function in DebuggerParser.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3079 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-17 00:08:23 +00:00
stephena a6eded9c65 Cleaned up cheat classes, replacing pointers with smart_ptr.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3078 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-16 21:08:21 +00:00
stephena 29fe39dd99 Made M6502 own all breakpoint/trap info instead of sharing pointers to
it with the debugger (this eliminates more new's and empties another d'tor.

Re-wrote PackedBitArray to use a bitset instead of home-made code.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3075 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-16 16:13:58 +00:00
stephena 526fbed5e6 Some reorganization of debugger Expression classes, and using unique_ptr.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3073 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-15 23:10:58 +00:00
stephena 4544f59b53 Replaced #define'd macros with lambdas where possible. Did I mention
I also love lambdas?

Minor cleanups to other parts of the code (missing virtual, cleanup
d'tors, move methods from public to private, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3071 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-10 23:35:24 +00:00
stephena 49eadb7463 More conversions from normal for to range-based for. Yes, I really love
range-based for that much.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3070 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-10 21:59:56 +00:00
stephena b863b55594 Some more optimizations and small code cleanups.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3066 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-10 16:13:28 +00:00
stephena 4c9e139fcc Cleaned up the OSystem code for managing Console and Debugger, removing
stuff from destructors and using unique_ptr.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3063 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-09 22:03:50 +00:00
stephena 5d927915ab A few more unique_ptr instances which I missed.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3061 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-09 13:41:55 +00:00
stephena 1b7635649c More conversions to unique_ptr, so deletes can be removed.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3060 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-09 04:01:31 +00:00
stephena 92aa5c2e36 Just when I thought there were no more cleanups to do ...
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3059 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-09 03:05:19 +00:00
stephena b89dfa7436 Updated OSX project file, fixed some minor compile warnings,
and bumped version # to 4.5 for the next release (whenever it
may happen).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3057 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-08 22:40:50 +00:00
stephena 7b9169c18d Convert all arrays in the codebase to vectors, so that we get all
the advantages of C++11 (move semantics, list initialization, etc).
I'd hoped to somehow wrap a vector behind Common::Array and not have
to change the codebase to this extent, but it didn't work out.  And
I've since read that it's bad form to extend from std::vector anyway.
This is *THE LAST* bit of work I'm doing with arrays; everything is
now a proper vector.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3055 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-08 21:27:36 +00:00
stephena 740eeed579 You know what's better than adding move semantics and initializer
lists to the Array class?  Completely deleting all that code and
using a std::vector directly :)


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3054 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-07 23:28:40 +00:00
stephena 9cf9b41989 Fixed some yacc issues, and a memory leak in debugger expressions.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3053 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-07 19:32:54 +00:00
stephena f54118226c Some formatting/nullptr fixes for src/debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3052 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-07 15:52:24 +00:00
stephena a9aa84e3a3 Some more nullptr and formatting cleanups.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3051 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-07 14:26:56 +00:00
stephena a48c4fc6a8 A slight restructuring of the Controller classes, to fix CompuMate
support broken in rev 3034.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3038 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-04 00:34:56 +00:00
stephena 79ada8685c The long march to converting Stella to C++11 has finally started. Already,
I've found and fixed a few memory leaks.  You will need an up-to-date compiler.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3031 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-11-02 23:40:20 +00:00
stephena 877f2c9f3c Final updates for 4.2 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3026 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-28 16:44:18 +00:00
stephena 27e005d7a5 Final batch of fixes from cppcheck.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3024 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-27 14:41:46 +00:00
stephena d891357cad More cleanups from cppcheck.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3021 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-26 19:51:02 +00:00
stephena bc1308db23 Some small issues detected by 'cppcheck'. There looks to be quite a
few more ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3020 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-26 18:46:17 +00:00
stephena 958d8940fc Pass OSystem and DialogContainer as reference instead of pointer in
all GUI classes.  This makes sense, since the underlying classes
were returning them as references anyway.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3019 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-26 17:45:42 +00:00
stephena ba926bc4f6 Made some more methods const.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3015 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-25 20:14:09 +00:00
stephena 6d753fd335 CPU registers can be selectively randomized with cpurandom option.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3014 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-23 15:52:39 +00:00
stephena ebf44d2631 A few more const and method cleanups.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3012 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-22 14:54:25 +00:00
stephena f8be548312 Fixed bug in initial size for the debugger; it would sometimes try to use a size larger
than the desktop.

Some code cleanups; add const and optimize some methods.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3010 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-21 22:12:50 +00:00
stephena 42dec8321d Changed debugger shortcuts to Control-combos to match the old
Alt-comboes, as these are easier to remember than function keys.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3009 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-19 14:55:48 +00:00
stephena 964e1d7d88 Text input is all parts of the UI will now use the users own
keyboard layout.  This means that non-US layouts can finally
enter (ASCII-only) text with Alt-Gr key-combos.  Because of these
changes, the global debugger keys for rewind/step/trace/scan+1/frame+1
are now the function keys F4 to F8, respectively.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3006 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-17 14:02:53 +00:00
stephena 537eef7384 'cpurandom' includes the SP register, and is now turned off by default.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@3005 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-10-13 23:59:49 +00:00
stephena 56d84a3c04 Fixed some dead code warnings generated by llvm scan-build.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2992 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-09-06 00:33:17 +00:00
stephena 2cb4d31c5b Fixed only minor compiler warning.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2991 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-09-04 20:34:58 +00:00
stephena b7cdaad634 Fixed minor compiler warning, and bumped version #.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2990 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-09-03 15:23:36 +00:00
stephena f9f423bf25 Fixed bug in 'MDM' debugger tab; it was always showing bank 0.
Updated docs for upcoming 4.1 release.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2983 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-08-31 23:16:57 +00:00
stephena ddafc3a650 Added cart debugger tab for 'MDM'.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2981 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-08-29 15:33:04 +00:00
stephena a7aece9d36 Improved DASH bank state display in the debugger; it now shows info from
all 8 'slots'.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2973 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-08-09 01:04:46 +00:00
stephena 05f455789e Changing banks in the DASH debugger tab is now working.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2968 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-31 17:05:21 +00:00
stephena af254b3d85 Fixed DASH bug when changing banks; the debugger didn't recognize the change,
and hence didn't re-disassemble.

Fixed long-standing bug in the debugger disassembly; addresses marked as $F000
(or equivalent) were never being highlighted in the disassembly view.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2967 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-31 15:54:14 +00:00
stephena cced0aef33 The DASH debugger tab now correctly shows the state of all banks/segments
currently in use.  Still TODO is activate the 'Commit' buttons, so that
the banks can be changed from the UI.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2966 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-29 22:37:17 +00:00
stephena 21eff3b800 First version of DASH debugger tabs. The bankswitching tab is still a WIP.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2964 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-29 00:29:02 +00:00
stephena 9f172cbb42 Fixed potential bug in Cartridge API; renamed bank() to getBank(),
since there are issues with mixing overloading and virtual functions.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2963 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-28 13:40:37 +00:00
stephena 2f4a3e7966 Cleaned up the Cartridge::bankXXX API. Carts which are non-bankswitched
or those which implement their own unique scheme no longer have to
implement bank and bankCount; this base class versions will be used
instead.

Removed the debugger 'bank' command, since it didn't work for all cart
types, and is obsolete now that the UI allows to change banks for
all cart types.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2960 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-24 17:15:28 +00:00
stephena 979417bd00 Fixed last-minute compiler warning.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2950 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-07-01 13:43:19 +00:00
stephena 534f7680e6 Updated changelog and some dates.
Updated to latest PNG code.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2942 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-30 14:38:18 +00:00
stephena 16be8f8a8e Added 'Cart RAM' debugger tab for DPC/Pitfall2 scheme. It is quite similar
to the DPC+ scheme, so I suspect its omission was an oversight.  Other than
the more esoteric types, the only scheme left needing a cartram tab is
DASH, but that one is still in development ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2940 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-30 01:23:23 +00:00
stephena 9b99e414aa Added debugger controller widgets to Xcode, and fixed minor
compile warning.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2939 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-30 00:54:30 +00:00
stephena 10283cb75b Added new debugger controller widgets for VS, and fixed an error when converting an 8-bit hex value into a 4-bit one. Granted, I was calling the method incorrectly, but it's strange that Windows and Linux have different behaviour for snprintf.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2938 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-30 00:31:36 +00:00
stephena e3cc672368 Added an oft-requested debugger feature: add buttons to the AtariVox/SaveKey
controller area to reset the EEPROM to default values.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2937 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-29 23:25:53 +00:00
stephena 81d0dfdbdc Some final fixes for the new cartram debugger tab. In cases where
the RAM is always mapped into the same place in ROM, the ram grid
now shows addresses with the correct read port address, and
ram labels are properly accessed.  In cases where the RAM is hidden
from the 6507 or not mapped into the same place at the same time,
the addresses show actual real addresses of the RAM from the POV of
the cart itself (ie, RAM location zero is labeled 0, not as $1xxx).
This is necessary since quiescent RAM doesn't actually have a 6507
address.  Also, labels are disabled in this case.

Fixed bug with incorrect offsets when reading cart RAM labels;
it seems to be a copy/paste issue, since all such methods were
written as if the cart was SaraChip-based.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2936 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-29 18:37:55 +00:00
stephena da86a3b175 Removed the last remains of dirty-rect updating from the FrameBuffer.
This code was originally there for software mode, where it was very
expensive to update pixels, so it was done as little as possible.
However, it was also a bit of a hack, and sometimes interfered with
double-buffered hardware rendering.  So now showing the various UI's
will burn slightly more CPU, but will be guaranteed to work under
all conditions.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2934 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-21 20:51:08 +00:00
stephena 12e727ae4e The 'savesnap' command in the debugger prompt now actually saves a
snapshot of the TIA image, including partial rendering (if applicable)
and scanline indicator.  Previously it only saved the TIA image, which
basically made it useless from the debugger POV.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2931 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-20 23:01:11 +00:00
stephena 61972b350a Finally some love for the OSX port. The Xcode project now compiles and runs,
and contains only one Objective-C warning (more research required).  There
are also some fixes for minor warnings.

There are still some issues, though.  First, SDL2.0.3 has to compiled
manually, as the public binaries don't work (this is documented and
a bug reported on the SDL mailing list).  Second, fullscreen->window
transition is causing a crash, which I still need to track down.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2926 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-16 16:34:48 +00:00
stephena 8fbbadd2e3 Various changelog updates for 4.0 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2925 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-15 19:25:46 +00:00
stephena 815e0b2d33 Cleaned up the Rect class, which is something I've been meaning to do
for a long time.  Changed to unsigned int everywhere, and removed
functions that I will never use (the class originally came from
ScummVM).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2923 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-13 19:53:44 +00:00
stephena 05c007cbae Made StellaMod an actual enum, rather than simply typedef'ing
to SDL mod.

Added a hack/fix for Alt-key combos being printed in the debugger
prompt (ie, when stepping though a frame with Alt-f, the 'f' character
was shown in the prompt).  This will be fixed when PromptWidget
becomes an EditableWidget (not for the 4.0 release).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2922 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-13 19:34:35 +00:00
stephena 5c75ff1c15 Finally added a large patch from SpiceWare which adds an extended
cart RAM tab to the debugger.  This is tailored to each respective
cart bankswitch type, allowing much more information to be shown than
you'd see in the normal RAM area.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2921 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-13 16:28:28 +00:00
stephena d275773413 OK, I originally intended to fix FrameBuffer::scanline for SDL2,
which I though a just a one or two-liner equivalent to glReadPixels.
Turns out that SDL2 doesn't return 24-bit RGB data (only 16 or 32-bit),
so the PNGLibrary had to massage the data.  In the process, converted
the PNG saving functions to actually use PNG library functions, which
greatly simplified converting packing from 32 -> 24-bit.  Historically,
the PNG save functions were written before libpng was a requirement,
so they were hand-rolled.  Once libpng was integrated into the codebase,
it didn't make much sense to not use it anymore.

So an expected two-line code fix became this commit ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2919 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-13 13:35:41 +00:00
stephena 53edeb9171 Text input is now working in the debugger prompt (a rewrite of the
PromptWidget class to use EditableWidget will probably happen after
release 4.0).

All text input now seems to be working as in Stella 3.9.3.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2915 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-10 21:53:02 +00:00
stephena aa6c1b3d58 Text input is now working in all classes inheriting from EditableWidget
(specifically, DataGridWidget and RomListWidget are now working).

More work is required for PromptWidget, since it was created before
EditableWidget existed, and hence duplicates a lot of that classes code.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2914 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-10 21:04:36 +00:00
stephena 90248b2701 First pass at converting text input to the new SDL2 scheme. Basically,
the old way mixed both single-key events and Unicode input into one
method, and the new way separates them (using a new handleText method).

Currently it seems to be working fine in the ROM launcher (yay!, I
can now quickly jump to ROMs by name again).  There are still some
issues in the debugger, which I'll work on next.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2913 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-06-10 16:43:35 +00:00
stephena c8b27ec114 Some pretty huge changes right across the board.
Changed pointers to references in c'tor calls, making things a little safer.

Removed FBSurfaceTIA, since it was tied too closely to SDL itself.  Added a
class called TIASurface that is functionally very similar, but is more generic
and accessible by the FrameBuffer directly.  Eventually, this class will take
responsibility for all things related to rendering the TIA image (Blargg TV
effects, phosphor mode, etc).

TIA rendering is currently borked; fixes will follow ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2889 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-05-12 23:34:25 +00:00
stephena b418d5a4f5 Changed FBSurface API to access/modify source and destination rendering
rectangles.  Now that the underlying rendering is hardware accelerated,
this API more closely matches what is actually occurring.  As well, it
makes things easier comprehend: 'src' rect is the actual surface data,
and 'dst' rect is its final output onscreen (scaling, etc being applied).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2883 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-05-04 16:59:11 +00:00
stephena d0d04948c7 The keyboard now works in TIA emulation mode. Still TODO is get ASCII
characters working, so the UI can be used.

SDL Window events are now sent to the EventHandler core.  For now, only
the window expose event is handled (redraws window if it's been hidden).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2872 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-03-09 19:22:04 +00:00
stephena fdf9ed708a Removed concept of 'base' surfaces, which was an optimization for software rendering.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2862 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-03-02 02:02:00 +00:00
stephena 45d0740819 Some reorganization of the FrameBuffer classes, to move all SDL-related stuff
into FrameBufferSDL2 only.  This will make conversion to actual SDL2 code much
easier, since it won't be touching any of the core emulation code in src/emucore.
Next TODO is something similar for EventHandler (which uses SDL heavily and is
too tied to a core class).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2846 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-02-05 22:09:57 +00:00
stephena 7c4a0a331d Added new bankswitch code from 3.9.3 (RevEng and CPUWIZ) to trunk.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2837 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-01-17 15:39:11 +00:00
stephena aa5691af8a OK, it looks like I'm back to Stella development, after a several month
break.  First thing to do is update the year.  Happy new year to anyone
reading these commit logs.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2833 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2014-01-12 17:23:42 +00:00
stephena a911a5b368 And so it begins. This is only symbolic ATM, but I've now killed
software rendering support.  I've been wanting to do this for years,
and finally the time has come.  So for now, you need OpenGL for Stella
to build and run.

Expect major breakage over the next few months, as I port to SDL2.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2829 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-09-27 19:47:15 +00:00
stephena cda1e301e2 Temporary workaround for saving TIA image from debugger window; we only
ever want to see the TIA, not the entire debugger area too.

This will be fixed for Stella 4.0, once I remove the @#*%$-ing software
rendering support.  That part of the code keeps coming back to haunt me
for years.  It will be *SO MUCH EASIER* to deal with these things when
everything is a FBSurface that can be stretched/scaled as necessary.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2828 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-09-16 14:37:44 +00:00
stephena c5f011f1fe Added 'savesnap' debugger command, on the request of Spice from AtariAge.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2825 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-09-12 22:37:01 +00:00
stephena fa9951e95f Final updates for 3.9.2 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2822 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-31 13:49:19 +00:00
stephena 963c5d621b Changed 'dbg.boldfont' to dbg.fontstyle', which allows to use a combination
of bold and normal fonts within the debugger UI.  Because of the # of changes
this requires, this is as far as I'll willing to go with UI configurability.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2820 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-26 13:01:29 +00:00
stephena 8aa736b35a Added ability to use bold fonts in the debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2816 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-24 15:51:37 +00:00
stephena 587959c273 Well, that was fast. Fixed bug in parsing constants from the DASM lst file.
I wasn't completely sure how the file was structured, but it's starting to
make a lot more sense now.  I think in the end, it will be better to use this
file as much as possible.

Bumped version #, and starting all over again.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2815 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-22 21:34:22 +00:00
stephena 4d0be67af0 Some minor fixes for the VS project file.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2811 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-21 12:37:22 +00:00
stephena 28b80d93cf The TIA info area of the debugger is now font-sensitive.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2804 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-20 15:23:07 +00:00
stephena 4ef0416e26 When loading symbol files, strip leading numbers from names using the
number.name convention (which seem to be pass #'s for DASM).  Initially
having this info in Stella was simply visually inconsistent, but now
it also interferes with recompiling when saving the disassembly (IOW,
the data put into the symbol file by DASM can't be fed back into DASM
again in these cases).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2803 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-20 14:29:28 +00:00
stephena f02995b485 CPU register 'source' addresses in the debugger now show labels,
when applicable.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2802 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-20 14:00:25 +00:00
stephena 7b79b0a971 The debugger CPU area is now font-sensitive.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2799 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-19 17:45:17 +00:00
stephena 29167a2e87 When using different font sizes in the debugger, the TIA display /
tab area and RAM area now take advantage of extra space.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2798 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-19 15:23:33 +00:00
stephena 30a3f3742c TIA graphics registers now more closely illustrate how they're drawn
to the screen (inactive pixels are 'transparent' in the UI).  In the
case where there is only one possible object below the register, a
'blank' uses the underlying colour (ie, in normal priority, a blank
PF is 'coloured' using COLUBK).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2797 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-19 14:35:58 +00:00
stephena 8ea92e67ef In the debugger TIA output, set inactive pixels in GRPx and PFx to
COLUBK instead of always using colour 0 (black).  This is more
informative, as it displays how the registers actually work when
being drawn to the screen.  Thanks to Tjoppen of AtariAge for this.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2796 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-16 12:25:42 +00:00
stephena 60dd213a0a Added preliminary support for DASM lst files (currently to differentiate
symbol names in the DASM symbol file).  This partly fixes a deficiency in
symbol files, whereby two names could have the same address (one has an
address, the other as a constant), and Stella would use whichever one
occurred in the file last.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2795 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-15 16:07:58 +00:00
stephena 77dfaa0ebc Rearrangement of GUI-specific code from Debugger to DebuggerDialog; more
cleanups and removals to follow.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2794 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-13 16:44:23 +00:00
stephena bcb4c592d3 Some minor font-related UI fixes in the debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2793 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-12 16:52:49 +00:00
stephena 465cc76769 Some reorganization of the console font initialization, in preparation
for different-sized debugger fonts.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2791 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-12 15:02:38 +00:00
stephena 45115d5754 Minor cleanup of the BSPF API, and fix bool warning from VS 2012.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2789 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-11 15:41:36 +00:00
stephena c840bb9809 Removed some (long) dead debugging code.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2788 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-10 21:21:17 +00:00
stephena 893bfd4a41 Override properties dialog is now called 'Power-on options', and includes
extended abilities (see changelog and docs for more info).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2783 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-08-09 13:09:47 +00:00
stephena 1619c1a349 Regenerated the UI fonts, included the tool to actually do so (it was
previously on my local system, not in the repo), and fixed some minor
UI layout issues.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2778 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-31 15:46:02 +00:00
stephena 189f10f201 InputTextDialog used in debugger RamWidget wasn't closing properly
on exit; it attempted to close the debugger dialog instead!


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2775 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-30 21:43:20 +00:00
stephena 4958e87c3e Cleaned up ContextMenu API wrt multiple setSelected methods; in some cases,
it was confusing which one was being called.

Fixed output in debugger bankstate info; in some cases, hex numbers were shown
when decimal was required.

Fixed regression wrt the last TIA change (incorrect framerate counter); the
PAL autodetection was failing in certain cases.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2774 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-30 20:31:14 +00:00
stephena 270abc889d Removed BSPF_toString, since its functionality is now provided by Variant.
This is the beginning of a major cleanup of the bspf.hxx file, which
has gotten unwieldy over the years.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2772 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-29 15:10:39 +00:00
stephena 95fe213f3a Consolidated the code for converting integers to strings in various
bases into a Common::Base class.  Previously, this functionality was
spread across several classes, and used different approaches to formatting.
While the code still mixes C++ streams and C-style sprintf's, at least
it will now be easier to modify it all in one place.

Related to the above, added ability to use upper or lower case
characters for HEX output in the debugger.  This is toggled by the
new debugger prompt command 'uhex', which is also tied to a new
commandline argument, 'dbg.uhex'.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2770 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-27 22:28:41 +00:00
stephena a1ac026cbc Added 'cpurandom' commandline argument and associated UI item, to randomize
the CPU registers (A/X/Y/PS) on ROM load.

Added 'INTIM Clks' to the debugger I/O tab, showing the number of clocks
before the current INTIM value decreases by 1.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2768 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-21 00:27:52 +00:00
stephena 13c3ca9964 TIA position counters (POSP0, POSM0, etc) in the debugger now show values
in decimal, not hex.

All DataGridWidgets (ie, most of the inputs in the debugger) have more
strict input filtering, allowing to use $,#,\ specifiers for different
bases, as well as restricting input based on the specifier used (ie, if
you've entered a '\', only '0' and '1' are allowed, etc).

Updated libpng to latest version.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2767 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-19 13:43:42 +00:00
stephena 04f6a16f97 Fixed error tracking PC changes in disassembly when the PC and bank mirror
didn't match.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2766 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-07-17 23:00:55 +00:00
stephena 3f4085f8b9 Added ability to change 'tiadriven' and 'ramrandom' to the debugger UI.
Cleaned up the class comments wrt ScummVM; the attributions only needed to
be in the base classes, since all the derived stuff was written later.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2763 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-06-29 00:02:49 +00:00
stephena 8f8c85250c Preparation for 3.9 release, updated documentation.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2756 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-06-26 16:03:08 +00:00
stephena f5ed7ccf5c When patching code in the disassembly list, the current base is now used.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2755 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-06-23 00:22:16 +00:00
stephena f3d412fce7 Improved the new Snapshot Settings dialog with more informative text.
Added option to save snapshots using either internal database name
(the default) or actual ROM filename.

Extended FSNode API for parsing filenames and adding/removing extensions,
which was previously being done in different ways throughout the codebase.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2753 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-06-21 12:15:32 +00:00
stephena c179a00725 Added specific dialog for changing Distella settings to disassembler.
This will eventually grow to include all relevant options in Distella.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2747 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-06-17 15:57:41 +00:00
stephena 4c6667f64d Some performance improvements. Probably not noticable on current
systems, but seems to improve issues on slower computers.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2745 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-30 16:07:19 +00:00
stephena 3eddecdd01 Oops, now that I've changed EditableWidget::setText, I have to change
the getter to match.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2744 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-29 16:45:18 +00:00
stephena 969d4b5fe2 Some more work on the debugger ROM UI area. Changed previous bank
selection widget to a display of current bank state, taking into
account the more esoteric bank schemes.  Currently, some functionality
is disabled/removed for now; I'll work on this for the next commit.

The format for displaying disassembler GFX/PGFX (binary or hex) is now
obeyed in the disassembly file output as well.

Changed various comments/enums/etc referring to 'preliminary' code to
'tentative' code, matching the actual intended meaning and the current
documentation.

Small API change for EditTextWidget; changed method name to setText, since
that's what I keep typing for some reason.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2743 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-29 16:27:12 +00:00
stephena 7931699eb7 Some cleanup of ASM output; only print headers for various constants
if they are actually used in the disassembly.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2741 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-21 16:57:12 +00:00
stephena e053ed4e0e Rearranged disassembly file output header to be output after an
initial pass of the disassembler.  This was required in certain cases,
notably when issuing 'savedis' when the code was currently running from
zero-page.

Fixed missed labels for zero-page RAM when running ZP code.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2740 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-20 21:53:25 +00:00
stephena 1bdc9423bd Fixed for debugger prompt tab completion, and using RAM labels as destination
jump points when running code in ZP mode.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2738 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-20 16:48:31 +00:00
stephena 09d7ec7eb9 *Many* improvements to the debugger disassembly, both in-GUI and in saving
to an external file.

  - RIOT/TIA mirrors are now used whenever possible.  This includes *all*
    possible mirrors in the entire 64K address space.  This was needed to
    make the disassembly byte-exact when recompiling the ROM.

  - Disassembly to a file now includes all required defined constants
    (RIOT/TIA, non-locatable labels, user-defined, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2737 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-19 20:55:25 +00:00
stephena 640927b1c6 The debugger disassembly (both in the ROM view and the prompt) and the
listconfig command are now synchronized, and produce the same output.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2736 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-17 01:05:50 +00:00
stephena a5bdbaf997 Some work on listconfig and friends. First of all, it's now only enabled
for single-bank ROMs, same as disassembly (since the underlying framework
has been modified).  Second, it now actually works :)  I can't see how it
worked before, and since I didn't get any complaints/reports, I really have
to question how much use this code actually gets.

Still TODO is fix errors in CODE vs. PCODE (preliminary code) (in
the Distella code, we should clearly mark the difference).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2735 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-16 22:05:14 +00:00
stephena f533fcad34 Some cleanup of dead code, and changes to the file I/O in the debugger.
For now (and the next release), filenames are hardcoded to sane defaults.
Eventually, the code may be extended to use BrowserDialog to query the names,
but it's taking much too long to get working, and I want to get a new release
done before the end of May.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2734 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-16 19:11:44 +00:00
stephena f4d0641219 A rather large commit, but basically all that's happened is
converting StringMap to VariantList.  In the process, some of the
code is much cleaner, and the Variant infrastructure allows
work to continue on a more full-featured ContextMenu.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2732 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-09 14:22:34 +00:00
stephena 726c9b92bc Some minor code cleanups, using references instead of (evil) pointers.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2730 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-09 10:08:30 +00:00
stephena 7de6bbd99b Added 'Variant' class, which is basically a variable type. Reimplemented
the Settings class to use Variant.  Still TODO is modify various UI elements
that currently accept StringMap to use Variant instead.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2726 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-08 23:34:42 +00:00
stephena 0929adc20d Some dead code cleanup, detected by clang++.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2725 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-07 18:53:21 +00:00
stephena 86b6191570 Fixed crash when entering the debugger in software mode.
Some cleanup of the various enum's in the UI classes.

Fixed issues with ordering when adding dialog boxes; this fixes a
bug when adding a dialog from another dialogs ::loadConfig(), in
which case the first one is placed below the second and can't be
seen (mostly applies to MessageBoxes).

Fixed bug in handling OSystem::setBaseDir(); if the directory didn't
exist, then the newly created one wouldn't have a slash appended at the
end.  This causes all further (sub)directories to be created/named
incorrectly.

Started work on extending BrowerDialog to load files as well as
directories, and to allow editing of the items from within the dialog
itself.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2713 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-05-01 16:56:43 +00:00
stephena e3903ca2b8 Added CTY scheme to the debugger ROM tab. Just as with the last
commit (AR), this one isn't yet fully implemented.

That's it for the bankswitch schemes.  Now I can move on to the
remaining items for the 3.9 release.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2709 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-24 22:24:41 +00:00
stephena 3839b54d22 Cleaned up the API for adding/removing dialogs in the GUI. It's strange
how one thing leads to another.  This started when I noticed that exiting
the debugger with a context menu still onscreen locked that widget, and
it couldn't be selected again ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2708 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-24 20:30:16 +00:00
stephena 0d7df2d0ae Added Supercharger/AR scheme to the debugger ROM tab.
No extra functionality is present; this will have to wait
until a future release after I have a better understanding
of the AR scheme.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2707 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-24 16:50:24 +00:00
stephena bbba4926d4 Finished CompuMate debugger ROM tab (for now at least; we need a
virtual keyboard added to the UI at some point).

Cleaned up the CheckBoxWidget API, and introduced new checkbox
'contents' that will hopefully more clearly indicate what is going
on (fully drawn square means selected, square with empty circle means
selected by not editable, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2706 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-24 12:55:23 +00:00
stephena 9a8dc860c0 Added Compumate to the debugger ROM tab, but there are still
a few UI items left to complete.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2704 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-22 16:41:05 +00:00
stephena 777a6ceb8c Added DPC+ scheme to the debugger ROM tab. This may need to be
extended into yet another tab, since there's still the need to
show the display bank, frequency bank and DPC Harmony RAM.  Or
maybe there isn't a need to see this extra stuff??

Some more cleanups of the graphics/UI API.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2703 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-21 20:02:55 +00:00
stephena f1530ca86d Added extra registers to the DPC scheme in the debugger ROM tab.
The remainder of this commit is basically some cleanup of the
Widget API, and infrastructure fixes to allow CartDebugWidgets to
have change tracking.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2702 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-20 22:23:42 +00:00
stephena de6dbc060c Added first pass of DPC scheme to the debugger ROM tab. For now,
it only contains the same functionality as F8; it needs to be
expanded to show more DPC-specific stuff.

Updated all schemes that contain a fixed RAM address range
(mostly the Superchip ones) to exclude that range from the
accessible ROM area.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2700 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-18 16:57:33 +00:00
stephena ff09b61c55 Added 4A50 scheme to the debugger ROM tab. They're starting to get
a lot more complex ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2699 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-18 15:30:19 +00:00
stephena df77cc8997 Fixed crash with disasm command in debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2698 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-17 23:11:32 +00:00
stephena a6bec42db7 Well, that didn't take long. I went ahead and added the ability
to erase/load/save the Flash memory in the FA2 scheme (it's stored
in the Harmony cart, but emulated with a file).  This is a debugger,
so it might as well have access to all the lower-level stuff in
the cart.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2697 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-17 22:32:49 +00:00
stephena fb0df96cfe Added FA2 scheme to ROM debugger tab (loading/saving RAM to
Harmony flash with hotspot $FF4 is mentioned, but currently
unsupported).

Implemented changing banks for MC scheme (although no test ROMs
exist, so we don't even know if the scheme works).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2696 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-17 19:59:05 +00:00
stephena a7566af776 Added MC scheme to debugger ROM tab. This isn't complete, since I
don't have any test ROMs to confirm whether the current
bankswitching code even works.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2695 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-17 17:25:13 +00:00
stephena 8487a60faa Fixed configure script wrt Thumb ARM support; the help message
never actually included info on how to enable/disable it.

StringParser is now width-sensitive, in that it can also split
on a maximum string length.  This is useful for making the various
UI items font-size independent, and to flow the text accordingly.

Increased minimum size of debugger window to 1080x720, which allows
things to be laid out a little nicer, and gives some much needed
extra room.  Sorry guys, the most common resolution now in use
is 1366x768, so it's time to move with the times.

Cleaned up some of the descriptions in the ROM debugger tab(s).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2694 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-17 15:00:32 +00:00
stephena 0a8050faf4 Added FE scheme to the debugger ROM tab. Even though this is
a multibank scheme, the tab doesn't allow to change banks,
since the current bank is at address-level resolution, and
it would immediately change back upon the next address change.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2693 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-15 17:21:30 +00:00
stephena b97b643d17 Added SB scheme to the debugger ROM tab.
Improved keyboard and mouse navigation for PopupWidget and associated
ContextMenu dialogs.

Tweaked bankswitch autodetection for 29K ROMs; the only possibilities
are ARM (FA2) or DPC+.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2692 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-15 16:17:51 +00:00
stephena 2872b6be03 Added X07 scheme to the debugger ROM tab. Since I have only one
test ROM, and it is extremely basic, I can't be sure how well this
new functionality works.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2691 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-12 13:12:39 +00:00
stephena 1b0b6a9f20 Added E0 and E7 schemes to the debugger ROM tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2690 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-12 12:36:57 +00:00
stephena 88c7d39b96 Added 3E scheme to debugger ROM tab. This is the start of the more
esoteric schemes (ie, the ones that no longer follow the '4K per bank'
design).  Arguably, this is the entire point of adding the cart-specific
debugger ROM tab; to make it easier to work with such schemes.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2689 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-11 14:58:18 +00:00
stephena 40e4687372 Added 3F scheme to the debugger ROM tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2687 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-07 20:09:28 +00:00
stephena 368c26c371 Added FA scheme to debugger ROM tab. Now begins the more difficult work;
adding the more esoteric schemes to the debugger ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2686 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-06 22:13:26 +00:00
stephena 1ff7568c68 Added 0840/CV/EF/EFSC/F0/UA schemes to debugger ROM tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2685 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-06 21:04:11 +00:00
stephena 4c227932f1 Added F4SC/F6SC/F8SC schemes to debugger ROM tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2684 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-06 14:09:16 +00:00
stephena 3cfe7218dc Added F4/F6/F8 bankswitch schemes to the debugger ROM info tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2683 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-06 00:25:08 +00:00
stephena fbebe17d6b Improved cart description for 2K and 4K formats in the debugger.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2682 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-05 20:45:42 +00:00
stephena 05a39cb1e0 More debugger work for 2K/4K ROMs.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2681 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-05 13:29:54 +00:00
stephena 263e8e6240 First pass at adding cart-specific info to the ROM tab in the debugger.
For now, only 4K is shown.  Eventually this will be included for all
bankswitch types, whereby the UI will be tailored to the specifics
of each scheme, so that ROM/RAM banks will be able to viewed and
changed more easily.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2680 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-04-04 21:38:22 +00:00
stephena ac1bccf454 First pass at adding a cart-specific bankswitch/info tab to the
debugger.  In the process, I had to spend several days extending
the UI/dialog class to actually contain multiple tabs.  This was
harder than expected, and it still isn't quite finished.  In many
ways, we're beginning to reach the limits of the current code; it
was never designed for a full-fledged, graphically rich UI.

For now the tab is empty, but eventually it will contain general
info about the ROM bankswitch type (size, virtual layout, etc),
but also cart-specific info, including the ability to change
banks, which can be vary greatly among the different schemes.
Eventually, it may even allow to see/modify very cart-specific
info (like display RAM in DPC, etc).

Better handle errors in opening the serial port (AtariVox support)
for Windows and OSX.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2678 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-31 00:10:05 +00:00
stephena 95f91262fd Use a more 'C++' way of initializing member variables.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2674 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-14 13:22:26 +00:00
stephena d9c05df0f2 Uninitialized variable caused disassembly failure on 4K ROMs.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2673 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-14 12:25:35 +00:00
stephena 467ac0a280 Sub2K ROMs now show only the actual data in the binary. This allows
the saved disassembly to be compiled to the exact same binary.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2669 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-13 21:16:14 +00:00
stephena 895fd7b263 Changed PC indicator colour on the advice of someone who is partly
colour-blind; the old (light) colour was very hard to see.  Actually,
I agree with that assessment, even though I'm not colour-blind myself.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2668 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-12 17:30:42 +00:00
stephena 1173b88c79 Only mark actual undefined opcodes as defined by DASM as being
undefined.  The rest are defined but illegal, which is different
(mostly because many ROMs released in the past 10 years make
extensive use of illegal opcodes).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2667 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-12 17:14:00 +00:00
stephena 1ade2900e4 More fixes to debugger disassembly for DASM. The code now prints
out-of-range labels for cases where a label is in the middle of a
multi-byte instruction (Kool Aid Man), and properly indicates
mirrors of TIA read/write addresses (Meltdown).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2666 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-11 19:43:19 +00:00
stephena b97d5120b9 Some debugger/disassembly work:
- Removed 'SKIP' directive, since it wasn't implemented anyway, and
    I see no way to implement it

  - Add 'aflag' setting to diassembly output, matching usage in Distella.
    This is needed for diassembly output, otherwise DASM barfs on the code.

  - Fixed several long-standing bugs in Distella disassembly wrt ROW
    directives and labeling.  Previously, the output you see in the debugger
    wasn't completely correct, since it wasn't compiling properly in DASM.

  - Illegal opcodes are now shown as .byte directives; this allows the code
    to compile in DASM.

  - Print 16 bytes per line in .byte directive in external disassembly,
    same as Distella.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2665 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-10 22:12:37 +00:00
stephena 5d5719e390 Added equates used to the disassembled output. This is the same as how
DiStella works, so you don't have to include a vcs.h file.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2659 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-05 18:01:55 +00:00
stephena ffc99a9345 First pass at adding diassembly output from the debugger. It's already
working quite well for a single-bank ROM, but more work is required for
multi-bank.  Output is currently sent to the console, as I'm still in
the formatting phase.  Saving to a file will be easy once the format
is nailed down.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2657 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-03-04 23:35:26 +00:00
stephena b613ac7f36 Fixed missing initialization in Distella settings. It doesn't really
matter (since they're updated anyway), but it's more correct to always
set defaults.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2639 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-02-28 12:17:04 +00:00
stephena 5a65d64538 Final changes to the TIA code for the 3.8 release. I've added
TODOs and pointed out areas where improvements are likely needed,
in preparation for asking for help in the implementation.

Turned off 'resolvedata' in the debugger when disassembly ZP RAM.
It seems to be buggy in certain cases, and it's easier to just
leave it off in that mode, since (a) not many games run from ZP,
and (b) it's only at most 128 instructions.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2617 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-02-21 21:57:42 +00:00
stephena 4610fd608d Fixed INTIM/TIMINT multiple reads in the debugger, which changed the
state of the registers and messed up further emulation.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2614 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-02-17 22:33:53 +00:00
stephena ec77f9d1b5 Add MessageBox class to GUI namespace, since it conflicts with Windows messagebox.
Eventually, this will have to be done for all GUI elements.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2601 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-02-10 22:26:06 +00:00
stephena ecdcf6177d More work on the FilesystemNode API.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2597 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-02-03 00:13:08 +00:00
stephena c4e5360a18 Updated copyright dates to 2013.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2579 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2013-01-04 19:49:01 +00:00
stephena 01d8c298ae Added 'dis.relocate' commandline argument, which passes the
Distella '-r' option (Relocate calls out of address range) to
the disassembler core.  Also added UI item to dynamically
change the setting.

Renamed 'resolvedata', 'showaddr' and 'gfxformat' commandline
arguments to start with 'dis', indicating that they're part
of the disassembler.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2504 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-27 19:27:55 +00:00
stephena 8f65771872 The built-in Distella was assuming the 'r' flag (-r on commandline)
option was set, which normally isn't when disassembling standalone
ROMs.  As such, the disassembly didn't match standard Distella output.
The 'fflag' and 'rflag' options from Distella have therefore been
integrated, but they're not configurable at this point (hardcoded
to true and false, respectively).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2502 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-27 13:07:38 +00:00
stephena 4281ac2436 Removed a few redundant FIXME and TODO's.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2488 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-20 18:26:59 +00:00
stephena 86372a5fa4 Fixed disassembly issue for zero-page code; system equates weren't being
properly marked as such.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2485 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-19 19:14:52 +00:00
stephena 344c672f89 Fixed bug in disassembly in zero-page RAM when accesses were made
outside the $80-$FF area.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2484 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-19 18:51:30 +00:00
stephena aa544ecfe9 Fixed bug when loading from ZIP files created in OSX. In some
cases, these archives contain directories named '__MACOSX' which
contain link files that were being erroneously detected as actual
ROMs.

Added FilesystemNode::isFile() method, and updated several places
in the code to use it.  Previously, determining whether something
was a file was simply testing if it wasn't a directory, but this
logic isn't always valid (it's possible to be neither a regular
file *nor* a directory).

Bumped version # for RC release.  It's getting very close ...


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2477 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-05-16 20:52:33 +00:00
stephena 809da97ad3 Potential performance improvement for Arrays. A reserve() method is now
available, which helps with constant resizes of arrays with a large number
of push_backs.  For now, only the ROM launcher and debugger disassembly
really needs it.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2442 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-04-15 21:13:01 +00:00
stephena 186fa5c1be Before I get back to mousemode and Blargg stuff, I decided to
make another pass at getting rid of raw pointers.  As I've come
to realize over the years (and in particular with reading the C++11
standard), raw pointers are evil and error-prone.  So this fixes
some of them at least.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2438 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-04-11 16:10:24 +00:00
stephena 5ce726f180 Fixed some compiler warnings picked up by Xcode 4.3
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2417 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-03-16 13:19:29 +00:00
stephena 47c5f4681e Added 'fixed debugger colors' command to right-click menu of TIA output
in the debugger, and updated the debugger documentation.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2377 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-29 22:54:23 +00:00
stephena 1ef29f585e MouseControl class now properly switches between various controller modes,
and take 'swapport' and 'swappaddles' settings into account.  Next TODO is
add per-ROM settings for specific axis mode.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2371 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-29 17:08:51 +00:00
stephena 08ae1c3fe8 Updated how the debugger is created, and protected against using the
debugger before it has been initialized.

Tweaked the format auto-detection by also looking at the TIA scanline
at which drawing first occurs.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2359 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-17 22:20:20 +00:00
stephena 73dbe861a6 Refactored the keycode handling through the GUI classes, making it more
generic than SDL, but less generic than simply using int's for everything.
This will help once we start porting to SDL2, which has an updated keycode
handling system.  The plan is that the internal core keyboard stuff is now
insulated from any further changes in SDL.

This also allows eventually adding support for CompuMate controller,
which needs access to keycode names in a generic way.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2356 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-14 22:00:54 +00:00
stephena 76dc1ce716 Some rearrangement of code in Console class, so that Controller::enable
is no longer required.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2353 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-13 21:13:10 +00:00
stephena 996cccde17 Minor positioning fixes for debugger I/O tab controllers.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2352 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-10 18:24:13 +00:00
stephena 3113bea297 Added driving controller widget to the debugger I/O tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2351 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-10 18:10:28 +00:00
stephena 30bfa0e639 Added keyboard controller to the debugger I/O tab.
Cleaned up the Event object in the EventHander, turning
it into a reference instead of a pointer (pointers are evil).

Minor speed optimization to Keyboard class; the update method
isn't required, since all work is done on the initial write().


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2350 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-09 17:23:44 +00:00
stephena 666eb49bae Added skeleton classes for Driving and Keyboard widgets.
Updated the OSX project files for all new classes.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2346 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-08 19:58:55 +00:00
stephena 5f0bfc2a9f A few documentation updates.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2345 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-08 19:06:42 +00:00
stephena 293a8a69b4 Added TIA INPTx and VBLANK D6/D7 items to the debugger I/O tab.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2343 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-08 16:55:10 +00:00
stephena f8c6693583 Added Genesis controller UI to the debugger I/O tab.
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
2012-01-07 17:05:18 +00:00
stephena d39404f5c9 Added NullControlWidget, for those controllers that won't have
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
2012-01-07 00:39:46 +00:00
stephena 35255514c8 Added paddle widget to the debugger I/O tab. This is actually the
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
2012-01-06 18:17:41 +00:00
stephena fcf3aed924 Fixed crash in TIA zoom in the debugger, thanks to report from
SvOlli of AtariAge.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2335 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-05 21:30:35 +00:00
stephena b10720321a First pass at adding controller-specific UI items to the
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
2012-01-05 18:28:24 +00:00
stephena 11fe5f4da1 Changed TIAColor enum names on the advice of Rainer M. Canavan,
due to name-clash issues in Irix.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2331 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2012-01-03 20:26:37 +00:00
stephena 8c0109f3a1 SWCHB and SWBCNT UI items recently added to the debugger now
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
2012-01-02 21:34:32 +00:00
stephena d8b59f7083 Added RIOT port B information to the I/O tab in the debugger.
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
2011-12-31 22:43:55 +00:00
stephena c95d5f804d Updated all files to copyright 2012. Happy New Year to anyone reading
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
2011-12-31 21:56:36 +00:00
stephena b6cab4e626 Removed redundant 'audiofirst' commandline argument, and fixed displaying
of RAM addresses in debugger RamWidget.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2295 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-12-23 00:04:58 +00:00
stephena 52cf172661 Reverted FSNode getPath() modifications introduced in Stella 3.4.1, since it causes massive performance regressions in Windows XP.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2292 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-12-22 21:29:24 +00:00
stephena 40a66edee4 Cleaned up usage of sprintf in the codebase, changing to
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
2011-07-13 14:13:49 +00:00
stephena f549cf9661 Removed some 'throw(...)' declarations, which are deprecated in the latest version
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
2011-07-03 21:52:33 +00:00
stephena 377765f565 Removed all traces of the OpenGL TV filters. This is due to be replaced by
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
2011-07-03 17:08:42 +00:00
stephena 221aa50a5b Make sure all hexidecimal number output in the debugger is in uppercase.
Bumped version number.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2259 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-06-12 20:20:19 +00:00
stephena 2d9d487300 Fixed bug with autoexec.stella debugger file not actually executing its
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
2011-06-11 22:45:50 +00:00
stephena df71aa03d1 Cleaned up the FilesystemNode API a little, removing some redundant code.
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
2011-06-09 14:00:30 +00:00
stephena d5ce0042e4 Tweaked the mouse motion detection for invalid values, and bumped version #
for the next point release.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2244 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-06-02 19:25:52 +00:00
stephena 670b61a15a Fixed a few compiler warnings, and bumped version # for final release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2240 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-05-28 14:00:12 +00:00
stephena bc7daa397e Added ability for the debugger to start up in 'fatal error' mode.
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
2011-05-26 16:14:46 +00:00
stephena 5025a21d92 Updated Thumb ARM emulation to log its output instead of printing to the
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
2011-05-24 16:04:48 +00:00
stephena 4e6d4cb1c6 Cleaned up some inlines that weren't needed.
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
2011-05-10 15:04:19 +00:00
stephena 3339dc276d Updated copyright info for 2011. Happy New Year to anybody reading
these logs :)


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2199 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2011-01-01 16:04:32 +00:00
stephena 595e7dc41f Some last minute final changes before the 3.3 release.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2188 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-11-12 18:54:08 +00:00
stephena c9ab109524 Converted several 'toString' methods to use stringstreams instead of
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
2010-11-11 16:46:41 +00:00
stephena 747164b4c5 If both PGFX and GFX are set for an address, PGFX should take priority.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2182 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-11-11 02:38:53 +00:00
stephena fca261c4e3 Updated debugger documentation for recent disassembly changes.
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
2010-11-10 22:38:16 +00:00
stephena 7a368c4bbb All directives other than ROW now have an associated address in the
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
2010-11-10 14:50:38 +00:00
stephena 277f034e89 Added register tracking for ORA, TSX and TXS. More testing is required
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
2010-11-10 14:01:41 +00:00
stephena 14d1c17acc Re-arranged the bits in DisasmType to match their order of importance
(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
2010-11-07 23:05:20 +00:00
stephena 773092142e Added rule for recompiling the M6502.m4 script to the Makefile, because I'm
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
2010-11-07 22:52:42 +00:00
stephena ea8d329e0c Don't mark code disassembled in ZP RAM has tentative (with a '*' symbol).
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2171 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-11-07 20:41:15 +00:00
stephena 192ab931f2 Updated 'type' command to show information from all sources (directive list,
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
2010-11-07 18:10:58 +00:00
stephena e8b080551f Reverted grouping characters for multi-character debugger prompt commands
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
2010-11-04 19:29:12 +00:00
stephena 3011aa7d12 Addresses directly after a relative branch should not be marked as DATA
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
2010-10-24 14:55:42 +00:00
stephena bea8ac0ffd Properly implemented an hierarchy wrt marking an address in the disassembly
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
2010-10-23 20:57:31 +00:00
stephena dac213c6c3 Added debugger prompt commands for the remaining directive types.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2161 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-10-23 17:50:45 +00:00
stephena 0af08634a8 Addresses marked with certain directives within Distella should not propagate
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
2010-10-22 20:24:37 +00:00
stephena 3c4bcf3900 Changed label for recently added 'source address' items in the CPU area
of the debugger.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2159 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-10-22 11:22:36 +00:00
stephena 8cb6a83512 Reworked M6502 detection of debugger GFX sections, by moving the actual
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
2010-10-21 21:01:00 +00:00
stephena 0388ab89e5 Added a new directive called PGFX, used for playfield graphics (the
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
2010-10-21 17:46:23 +00:00
stephena 7411867290 Decided to take a little break from the debugger stuff, and clean up
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
2010-10-18 18:39:57 +00:00
stephena bd06b3db1e Fixed bug in OSX port, where the name of the application wasn't shown
in Activity Monitor.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2154 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-10-12 15:29:22 +00:00
stephena 2f11619e78 The emulation core now tracks writes to PF0/PF1/PF2 as well as GRPx,
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
2010-10-11 23:32:37 +00:00
stephena e8c91c7876 Fixed infinite loop in Distella; a section of code needed to use 32-bit
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
2010-10-11 23:06:37 +00:00
stephena b775a83e00 Fixed crash in starting up the debugger; a re-disassemble should only occur after the debugger has started up completely.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2148 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-10-11 14:21:54 +00:00
stephena 5624d30d93 The emulation core now tracks access to DATA areas (currently, any address
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
2010-10-10 20:24:22 +00:00
stephena 5d0b25cd48 Re-added 'REFERENCED' type to Distella, instead of always using 'DATA'. I just
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
2010-10-09 17:55:22 +00:00
stephena fa3dc7cc38 Beginning the process of more properly integrating Distella (and disassembly
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
2010-10-07 22:34:22 +00:00
stephena f51c16c54f Shortened some options in the right-mouse click menu in the disassembly
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
2010-10-05 00:15:12 +00:00
stephena 9e583f146f The various trap commands in the debugger (trap, trapread, trapwrite) now
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
2010-10-03 22:09:34 +00:00
stephena 64ca5275d2 Fixed disassembly output error for 'relative' opcodes; only the signed
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
2010-10-03 18:48:44 +00:00
stephena 4b44dcb948 Added 'showaddr' commandline argument and associated UI item (right-click in
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
2010-10-03 18:19:09 +00:00
stephena 5fe91e2841 Greatly improved the disassembler output, but having Stella keep track of
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
2010-10-03 00:23:13 +00:00
stephena d6a38c8e44 Changed several string invocations to use references instead. For the
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
2010-09-30 15:56:38 +00:00
stephena cb7b93f8d1 Debugger 'saveconfig' wasn't taking pathname of ROMs into account; it always
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
2010-09-11 14:26:21 +00:00
stephena db8fd2465f Added 'clearconfig' debugger prompt command, to quickly remove all
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
2010-09-07 22:03:20 +00:00
stephena 7f75957e11 When a ROM doesn't exist and is temporarily inserted into the properties
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
2010-09-06 23:29:05 +00:00
stephena 2d08d4e459 Cleaned up handling of various file paths throughtout the codebase.
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
2010-09-06 00:17:51 +00:00
stephena 871d851e4d Make sure address selected with 'jump' command is valid.
Bumped version # for next AtariAge test release.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2124 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-09-05 18:02:26 +00:00
stephena 8f68c677d4 Added commandline argument 'gfxformat', also accessible from a right
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
2010-09-05 17:57:21 +00:00
stephena 00d64f9f02 Further improvements to adding directives to the disassembler.
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
2010-09-01 16:44:31 +00:00
stephena f8b2621ab5 Many big improvements to disassembler directives. Directives are no
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
2010-08-31 16:37:27 +00:00
stephena e0dd8b1451 First pass at extending the disassembler to support CODE/DATA/GFX commands
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
2010-08-30 12:04:56 +00:00
stephena d664beb45d Several changes to make entering commands at the debugger prompt
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
2010-08-23 16:19:17 +00:00
stephena f742f67788 Optimized Distella in the case of 2K ROMs. Now only half the
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
2010-08-23 12:07:09 +00:00
stephena 0fa706c558 Fixed bug in debugger rewind states are reported in the Stella tracker. It
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
2010-08-21 21:05:12 +00:00
stephena b2ed949082 Some final changes for the 3.2 release, including documentation updates.
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
2010-08-19 21:48:28 +00:00
stephena d007c3502f Several big improvements to the debugger:
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
2010-08-16 16:41:24 +00:00
stephena 764e598536 Fixed debugger 'runto' command; it was case sensitive, so it never
matched anything most of the time.  Also, as this operation can take
a somewhat long time on slower systems, a progress bar is now shown.

Fixed handling of bit 6 in VBLANK TIA register, which is related to
how INPT4 and INPT5 are handled.  This fixes at least one ROM that
should have failed in Stella, but didn't.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2096 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-08-12 16:55:47 +00:00
stephena 6faa9b4b69 Several fixes across the board for better functionality in 'small'
window mode.  Using modes smaller that 640x480 should now work in
all cases when using the 'maxres' commandline argument.  Also, the
lower limit of 320x240 is now strictly enforced in all cases.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2075 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-07-22 15:41:46 +00:00
stephena ec096dca6f Updated configure script to test for an external PNG library, and if
not found fall back to using the internal version (for Linux, and all
systems that use the configure script).

The debugger can now be resized in between ROM launches (ie, before
a ROM is actually started).  Previously, the entire program had to
be restarted for resizing to take effect.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2045 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-11 19:09:20 +00:00
stephena cd34147f5e Oops, the disassembly output should align based on the length of the
entire disassembled text, not just the label length.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2043 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-05 01:23:39 +00:00
stephena ffae9a0d56 Size hints are now passed to the disassembly output, so that the cycle
counts are aligned after the disassembly text with as little space as
necessary.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2042 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-05 01:17:03 +00:00
stephena 4735feda13 Mostly completed support for showing .sym label information in the
disassembly output.  Still TODO is add some visual improvements
(ie, align the cycle counts to not take too much space, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2041 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-04 16:33:56 +00:00
stephena befafd5d62 Second pass at integrating .sym labels into disassembly output.
There's currently a problem in the internal code I have, so I need
to submit in pieces until it's tracked down.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2040 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-03 12:54:45 +00:00
stephena 88f7f656e6 First pass at integrating dasm '.sym' labels into the disassembly output.
For now, only the infrastructure is being modified.

Make disassembly output a little nicer by drawing a vertical line
separating disassembly text from the actual raw bytes.

Some changes to the SDL sound code initialization, which will (hopefully)
eventually lead to a fix for those users with ATI video drivers, and
not having sound after the first game has been played.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2039 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-06-03 12:41:49 +00:00
stephena 0c1029076c First pass at making Distella aware of labels defined in a .sym file
or from the user.  Before this is done, the parser needs to recognize
variable-length labels (right now, it used fixed spacing and assumes
the largest label is 8 characters).

Fixed bug in Distella; a label was being printed with an incorrect
quote symbol, which would break parsing of that line.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2038 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-05-12 00:04:14 +00:00
stephena dd832f2ef4 Only return a label for IO registers if one has been defined.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2023 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-23 22:05:57 +00:00
stephena 66690033c4 Fixed segfault when accessing RIOT IO registers, any of its mirrors,
and associated labels in the debugger prompt.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2022 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-23 19:25:11 +00:00
stephena 32aa9d3186 Fixed a *REALLY* annoying bug in Windows with the latest code. It seems that System::PAGE_xxx enumerations were already defined elsewhere in a Windows header file. This was very irritating to track down. As a result, they're now named System::PA_xxx (for 'PageAccess').
The file selector in Windows now ignores all items starting with '.', not just the directories '.' and '..'.  This is most apparent when using the Windows port and browing Linux shares, which shows many dot files.

git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2012 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-14 22:35:46 +00:00
stephena d0391c28f2 Added 'continuous snapshot mode', currently tied to the Shift-F12
key.  This enables automatically taking snapshots every X seconds
while in emulation mode.  The interval (in seconds) can be set
with the 'ssdelay' commandline argument.

Some minor cleanups to the EventHandler methods, making them
const when possible.

Added latest DPC+ changes from Spiceware.

Fixed issue with ROMs that run entirely from ZP RAM; no disassembly
was being generated when entering the debugger.  For now, this
special case is detected, and the disassembly is generated for
the code that ran before the PC entered ZP RAM space.  Eventually,
this will go away when the Distella fully supports disassembling
below 0x1000.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2009 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-14 15:41:42 +00:00
stephena b65adcd49b Removed some debugging code, and tweaked the docs a little.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2006 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-12 22:44:30 +00:00
stephena 132b947ee2 Debugger pseudo-registers are now available in prompt tab completion.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2005 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-12 22:26:41 +00:00
stephena af8c5a5133 Added 'PageType' infrastructure to PageAccess, which basically
informs the rest of the system about how a page of address
space is to be treated (READ, WRITE, READWRITE).  This makes it
much easier to track if a read from the write port has occurred.
As such, the _rwport command should now be somewhat faster.
Eventually, the debugger/disassembler will use this info to
colorize the output.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2004 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-12 19:56:14 +00:00
stephena a2ca2730c1 Cleaned up some more FIXME and TODO:
1) Removed all references to FBO in OpenGL.  I won't be taking this
path, and will wait until SDL 2.0 integrates it directly.  In fact,
most of the OpenGL TV filters will disappear in the next release, to
be replaced with Blargg NTSC filtering.

2) Defined the remaining color constants in OSystem.

Re-added showing the results of parsing debugger script commands
in the prompt.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2003 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-11 13:44:22 +00:00
stephena b3a16fc0a5 Fixed another Distella bug wrt RELATIVE addressing. This fixes an
issue I noticed River Raid, where labels were being generated above
0x10000 (the maximum should be 0xFFFF).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2002 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-10 21:57:49 +00:00
stephena 2193c94b12 Updated boilerplate on top of each source file to include
'Stephen Anthony' (aka, me) in addition to Brad Mott as copyright
holders for Stella.  I think I've been with the project long
enough now (almost 10 years) to justify being specifically mentioned
above and beyond 'the Stella Team'.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2001 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-10 21:37:23 +00:00
stephena ea6ea9a7bd Renamed 'autocode' commandline argument and associated UI item
to 'resolvedata', since that more accurately describes what it does.
Also, it now accepts arguments as strings (never, always, auto)
instead of 0, 1, 2.

Updated main documentation for changes in OSX port 'basedir'.

Updated debugger documentation for recent command additions, and
provided new snapshots where the UI has changed.

It seems to be getting close to a new release - perhaps this
coming Friday.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1999 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-10 20:00:16 +00:00
stephena b781611925 Some updates to the PromptWidget and DebuggerParser.
The descriptions for the debugger commands are more streamlined
and better explained, and are neater when output.

Added 'cls' debugger command, which actually isn't for the debugger
at all, but for the prompt.  This erases all showing text and history.

Removed 'bank' debugger command, since it was already removed from
the RomWidget UI.

Removed 'listwatches' debugger command, since it wasn't implemented
anyway.  Besides, any watches are printed on every command access,
so it was pointless to have another function to do it.

Removed 'poke' debugger command; 'ram' and 'rom' do the same thing.

Fixed bugs in 'function' debugger command; it now correctly adds
functions without crashing.  Related to this, added 'listfunctions'
and 'delfunction' debugger commands for user-defined commands.

Fixed bug in completions for functions; it was including user-defined
functions twice.

Some general code cleanups in DebuggerParser (use ostringstream
instead of constantly creating new strings) and Expression
classes (make some methods const, for safety).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1998 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-10 00:52:47 +00:00
stephena 10c82a9457 Removed 'md5instate' commandline argument (it was previously added
post-3.0), and reworked how state files are accessed.  The cart type
now determines if a state file is valid, meaning developers can use
one state file across multiple builds of their program.

Added 'runtopc' debugger command, and associated UI item in the
RomWidget area.  This steps the code until the PC matches the given
value.

Added '16in1' bankswitch scheme, which is useful for ROMs named
'128-in-1' in RomHunter database.  Also, all multicart schemes now
show the current ROM onscreen while switching between them.

Fixed bug in Serializer class when accessing files in read-only mode.
Such files would be created and set to zero size, even if only
reading was requested.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1997 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-09 20:13:12 +00:00
stephena aab9ff0d54 Oops, I forgot that Visual C++ doesn't support static allocation of a dynamic array. This must be a gcc-only thing.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1994 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-08 21:30:35 +00:00
stephena 5294859e6d Removed some redundant 'FIXME' and 'TODO' items.
Removed final traces of SpeakJet emulation (the SpeakJet class).
It doesn't look this is ever going to be resurrected.

Tab completion results in the debugger prompt widget are now sorted.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1993 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-08 21:22:15 +00:00
stephena 964415508d Tab completion in the PromptWidget is now working again. As well,
the completion now includes functions (built-in and user-defined).

Cleaned up some more of the debugger documentation, mostly
related to tab completion.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1992 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-08 18:21:00 +00:00
stephena 56b6e74f04 Finally updated the Changelog, which should have been done way before
this.  That's the main problem with long delays between releases; I
forget exactly what's changed.

Fixed bug in Distella in handling relative addressing.  Wraparound
was potentially occuring on a 32-bit integer, which caused a crash
when accessing a 4K array.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1990 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-06 21:47:46 +00:00
stephena e536a9ee00 Some minor cleanups to the Distella class.
The debugger 'disasm' command now works again for addresses below
0x1000, and it also now correctly accepts the number of lines to
output in the disassembly.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1989 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-06 15:15:44 +00:00
stephena a94c579fec Fixed bug in debugger 'runto' command; it now looks at the generated
disassembly instead of re-disassembling again.  Still TODO is make the
search case in-sensitive.

Added latest DPC+ code from Spiceware.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1988 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-04 13:15:35 +00:00
stephena 1103f1dfbb Some cleanups to various classes, removing some debug print statements.
Partial cleanup of the debugger 'help' command, making the output line
up a little nicer.  More work is required in this area.

Fixed bug in EditableWidget; setEditString now implies that editing will
be started (if it's been enabled).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1987 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-03 17:11:23 +00:00
stephena 7bd307ebc8 First pass at getting function parsing working again in the debugger.
Added latest DPC+ code from Spiceware.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1986 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-04-03 12:45:20 +00:00
stephena 4c75e52a96 Fixed segfault that could occur on startup when a ROM triggered a read
from the write port.  Basically, the cartdebug class depended on the
console existing, but it wasn't being created until after it was required.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1979 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-29 02:21:32 +00:00
stephena 6bea26cd95 Moved the setDirtyPage call for read from write port from the Cart
class to the CartDebug class, since it's really a debugger feature.

Fixed comments on some of the methods in CartDebug.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1977 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-28 04:26:41 +00:00
stephena 8fe2d5f6c1 The System 'dirty page' code is now connected to CartDebug. It now tests
whether the range 0x1000 - 0x1FFF (aka cart space) has been modified, and
if so, it forces a re-disassembly.  Still TODO is modify all the cart
classes that manually handle poke operations to set the page as dirty
when a write actually succeeds.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1974 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-26 01:33:40 +00:00
stephena 4ca87ba76b Re-disassemble and reset the start vector in the debugger if the disassembly
doesn't result in the PC being present.  This fixes some bugs in the more
esoteric bankswitch schemes, and also enables rewind to show the correct
disassembled results.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1972 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-26 00:03:35 +00:00
stephena 9c73d139de The disassembly is now properly updated when performing a 'reset'
or rewind command.

Updated 'FE' bankswitch scheme to the new disassembly infrastructure;
it now properly indicates that it has two banks, and keeps track of
when the bank changes.

Some cleanups to CartXXX classes; most methods didn't need to be
virtual.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1971 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-23 18:00:47 +00:00
stephena dc22bc6b04 Some cleanups to the RomListWidget. Long '.byte' lines no longer spill
over onto the opposite side of the screen.  Breakpoints set by clicking
in RomListWidget only apply if they've actually been enabled.  This
fixes a bug whereby a breakpoint could look like it is enabled when
it really isn't.  Related to this, breakpoints cannot be set for
disassembly lines that don't contain a valid address or an empty
bytes area (basically, empty lines and lines containing '.byte' items).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1970 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-22 17:24:08 +00:00
stephena 0ed4a9fa79 OK, I've finally gotten back to Stella development and fixing the
disassembler.  Hopefully this will lead to a new release very soon.

Added 'autocode' commandline argument and associated UI item (in the
RomWidget debugger area), which controls how Distella will use the
'automatic code determination' option.  If set to 0/never, this is
completely disabled.  If set to 1/always, it is always enabled.
The default is 2/automatic, whereby it is first turned on, and then
turned off if the disassembly doesn't contain the current PC address.

RomListWidget has now been completely reworked, so that it informs
RomWidget of its intent to change breakpoints and patch ROM.  If
either of these fail, the action won't be performed, and more
importantly, it won't appear onscreen as if the action has succeeded.
This fixes an old bug whereby patching could fail, yet the onscreen
ROM data was actually changed.  Related to this, the list has been
made as efficient as possible, and its contents are never un-necessarily
copied.  Also, lines in the disassembly that cannot be modified no
longer show an edit area.

Due to the way the new disassembly works, you can no longer switch between
banks in the RomWidget (Distella would probably fail to disassemble in
such as case).

EditTextWidget can now indicate its contents have changed when adding
text to it.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1966 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-18 16:36:12 +00:00
stephena 2cc0d60940 First pass at adding 'hints' to each Cart class that its bank has changed.
This is very useful for conditional re-disassembly, since many bankswitch
schemes consist of ROM only, and once disassembled, cannot possibly have
a different disassembly at some later point.  This is mostly done for such
static schemes (2K, 4K, etc), but more work is required for carts with
extended RAM.  Basically, the cart knows best how its been accessed, so
it makes sense to have the hints there.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1965 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-06 18:56:36 +00:00
stephena e0310e8f35 Checking in WIP for Distella integration. Moved the internal text
handling to C++ stringstreams instead of C-style character arrays,
which fixed some segfaults (sprintf is evil).

First pass at tying the number of banks to the disassembly.  The idea
is that the startup bank (which is now identified by the cart) always
starts at address at 0xfffc, while the other banks are defined by the
PC at the first time we enter the debugger.  This is still a WIP,
since there's no actual checking done yet to see if the current PC
is in the current disassembly.

Added 'ctrlcombo' commandline argument, which completely disables
checking for Control-x key combos.  This is useful when playing
2-player games where the 'f', 'r' and 'Control' keys are supposed
to be treated separately.  Previously, pressing Control and 'r' or
'f' processed some other action (change framerate, reload rom, etc).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1964 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-03-05 22:02:12 +00:00
stephena 6de4e358e1 More changes to CartDebug. Labels read from a symbol list or defined on
the debugger commandline are now reflected in most parts of the debugger UI.
Still TODO is have DiStella use those labels in the disassembly, and deal
with the formatting issues this will entail.

Still completely broken are built-in functions, getting an equate address
based on label, and tab-completions.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1963 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-28 17:12:16 +00:00
stephena 0c6f564fa8 Fixed segfault where output from DiStella::disasm wasn't being parsed
correctly.  Disabled built-in functions until I get to that area of
code, since I'm tired of seeing an error message every time I test
new changes.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1962 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-27 23:21:14 +00:00
stephena 8b22097cb6 Further improvements to read vs. write mode in the debugger for TIA
addresses.

Fixed a bug in processing accumulator-access opcodes in the debugger;
an uninitialized char array was causing a segfault.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1961 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-27 22:46:20 +00:00
stephena a150ece7ae Updated DiStella disassembly to differentiate between the intent of an
instruction (read vs. write) for those addresses that have different
meanings based on how they're accessed.  For now (and probably forever),
this only affects TIA addresses.

These ideas were ported from the old Stella disassembler.  Perhaps they
should be ported to distella as well, since it makes for more accurate
results.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1960 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-27 21:24:24 +00:00
stephena 67f53ceb6b ContextMenu dialog now properly works with scrolled content (both with
the mouse and the keyboard arrow keys).  Still TODO is change the scroll
placeholder text into something that looks a little nicer (perhaps a
graphic arrow or something).

Added output of field header names when using 'listrominfo'.  This makes
it very easy to see what each column actually represents.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1954 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-24 14:46:05 +00:00
stephena 691c9b2e1d Added support for the Sega Genesis gamepad controller. This
controller uses the directional pad and button 'B' as a normal
joystick, but can also use button 'C' as a second 2600 button
(with the logic reversed).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1950 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-23 14:49:12 +00:00
stephena 8ca34a4d90 Checking in WIP for DiStella integration. The disassembly is now shown in
the RomListWidget instead of being printed to the terminal.  There are still
graphical glitches with this, but for a first pass, it's nice to see actual
Distella output in Stella.

Partially working 'disasm' command from the PromptWidget.  Currently, it
only disassembles cart address space (aka, 0x1000 or above).

Removed the old disassembly code from CartDebug.  Still TODO is fix the
label stuff, both in getting DiStella to use it, and adding/removing
labels.  This is greatly reduced now that we only have to worry about
user labels.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1934 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-07 21:23:26 +00:00
stephena 03191759ab More DiStella cleanups; the disassembly now properly uses peek() and dpeek()
methods from Debugger directly.  As well, the start address is now passed
into DiStella::disassemble() directly; decision to start from the reset
vector is done outside DiStella.  This is in preparation for starting
the disassembly from any valid address.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1933 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-02 22:21:03 +00:00
stephena deedb04709 DiStella::disassemble is now called from RomWidget! Of course, the output
isn't actually sent to the UI yet (it's still printed to the console), but
at least the two parts of the code are now talking to each other.  Note
that the disassembly window in the debugger will be empty until I get this
changeover complete.  And with that, I'm not feeling well, so I'm taking
the rest of the night off.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1932 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-01 22:24:38 +00:00
stephena 91f1406ed4 Checking in WIP of converting DiStella to use the System class
from within Stella (vs. reading ROM data from a file).
Compilation is currently broken.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1931 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-02-01 20:00:50 +00:00
stephena 898d16b863 Further improvements to the DiStella class. The output is now properly
parsed into a DisassemblyList structure.  For now, this is just being
printed out again.  The next change will be to pass this to RomWidget
and have it displayed in the UI.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1929 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-01-31 19:41:57 +00:00
stephena 231958dbdf Checking in current progress of DiStella class. The code now directs all
output to a specified function instead of the console.  The formatting is
also in a very fixed format.  That makes the next part easier; parsing
the output into a DisassemblyList structure that Stella can deal with
and show in the RomWidget.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1928 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-01-31 02:07:19 +00:00
stephena 28114a8c51 OK, this is the first pass at a huge reorganization of the debugger
classes.  First off, the distella code has been integrated into a
DiStella class.  This code isn't yet tied to the debugger, but it does
at least compile and generate valid output.

The RamDebug class has been replaced by a CartDebug class, which
takes responsibility for the previous RamDebug stuff as well as 
things related to Cart address space (read from write ports,
disassembly, etc).

Fixed E7 bankswitching when reading from the write port in the upper
256byte area.

Fixed 'read from write port functionality' in general for all carts
that supported it previously.  Basically, if _rwport is enabled, the
address is checked to be an actual read (vs. one that's part of a
normal write cycle), *and* it's actually an illegal access (each
cart/bankswitch type now provides a hint to indicate this condition).

Still TODO is clean up the rework, properly integrate DiStella, and
fix labels and defines (which seem to be completely broken).


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1922 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-01-17 16:48:45 +00:00
stephena e234139a3c Updated Stella headers in all files:
The license file is actually named 'License.txt', not 'license'
  The 'Stella Team' has a capital T, not lowercase.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1921 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-01-10 03:23:32 +00:00
stephena d372671277 Updated copyright dates to 2010.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1920 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2010-01-10 02:58:28 +00:00
stephena 88df583c23 First pass at reorganizing the disassembler code. The entire functionality
will be integrated intp CpuDebug, which will also be merged with distella.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1914 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-12-17 21:07:56 +00:00
stephena 19f146038d Added more accurate functionality for the _rwport debugger command. It now
properly distinguishes between intermediate reads which are part of writes,
and ordinary reads.  In the former case, only a read which has a different
address than a write is flagged as an error; intermediate reads acting on
the same address as the corresponding write are considered normal, and won't
trigger a break.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1901 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-11-11 20:53:57 +00:00
stephena 54a5d77542 Added '_rwport' debugger directive, which can be used in conditional
breaks to test whether an illegal read to the write port of cartridge
RAM has occurred.  It can be used as follows:

  breakif {_rwport == 100}   // break if read was done at wport address 100
  breakif {_rwport}  // break if read was done at *any* wport address

This currently works for all extended RAM carts that worked before.
Specifically, 4A50, DPC, AR and possibly several others aren't supported
yet.  More testing is required.

Renamed CartFASC and CartMB to CartFA and CartF0, respectively.  This
naming now matches that used in other emulators.

CartMC now properly handles read from write port, by using random
values instead of just zero.  However, no test ROMs are available for
this scheme, so there may still be issues.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1896 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-11-08 16:46:10 +00:00
stephena 03a854f206 Bumped version number to 3.0_rc. I won't have time to complete the
debugger disassembly improvements, so it will have to wait until 3.1.

Updated various files for impending 3.0 release.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1874 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-09-09 18:00:31 +00:00
stephena 6144e4fd57 Improved ROM launcher so that going to a parent folder automatically
selects the item that was previously selected.

Fixed bug in Cheat dialog where editing a cheat didn't remove the old one.

Updated TODO, rearranging improved disassembly as the #1 priority for the
next release; I don't have time to finish it now.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1873 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-09-09 15:59:22 +00:00
stephena 383bce947b Fixed gcc warning.
git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1869 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-09-02 00:12:29 +00:00
stephena a7da944b36 Simplified TIA class by removing 'greying' functionality to the debugger,
where it more properly belongs.  The greyed values are now from PAL
color-loss, which is also calculated for NTSC (though it's never actually
used in NTSC mode for regular rendering).  This also fixes problems with
debugger state files being saved with greyed values, and sometimes having
the frame greyed twice (hence making it impossible to see).  It should
also result in a slight speed increase, since some code has been taken
out of the TIA rendering fast path.

Added electron beam indicator the the TIA output in the debugger.
Basically, it's just a small square indicating where drawing will
start for the next instruction.

Fixed TIA output in the debugger so that right-clicking and selecting
'fill to scanline' actually works without first having to manually
enter partial frame mode.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1868 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-09-01 11:54:59 +00:00
stephena 33130a78f0 Updated 'Fixed Debug Colors' for PAL mode to more closely match the ones
in NTSC.

First pass at disassembly of ZP RAM in the debugger UI.  For now, the
entire range is disassembled, with no regard for alignment (so the PC
won't necessarily always line up with the disassembly).  Also, changes
to RAM don't yet trigger a re-disassembly.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1867 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-08-30 19:37:10 +00:00
stephena a13fad2d0f Only add states to the rewind/undo list with actions triggered by the user;
don't add one when the console is first created.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1861 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-08-25 14:33:11 +00:00
stephena ddc77bd7e7 Added button for rewind to the debugger, next to the buttons which it
applies to.

Bumped version # to alpha3.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1860 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
2009-08-25 12:46:56 +00:00