Commit Graph

282 Commits

Author SHA1 Message Date
Andrea
11fcaa63d1 Synch linux branch (PR #1432)
. Debug.cpp: fix compilation errors.
. Remove obsolete __attribute__((regparm(1))) & WATCOM.
. Support MINGW32.
. Replace sprintf with StrFormat().
---------
Signed-off-by: Andrea Odetti <mariofutire@gmail.com>
2025-09-18 10:40:02 +01:00
tomcw
7433d7b84d Debuggger: Mini mem dump: switch to 'sN/' (slot) prefix for MB & AY device types 2025-09-12 19:59:37 +01:00
TomCh
04ba39b1dd Debugger: support prefixed addresses for mini memory dump windows (PR #1427)
* Mem dump cmds without any args will now display the prefix address
* Support data sub-window (that reflects m1 dump)
* Breakpoint display: Right align R and W at end of line
* Help doc: Update Memory page to include prefix address examples
* Help doc: Update Breakpoint & Memory pages: add images showing address prefixes as shown in the UI
---------
Co-authored-by: michaelangel007 <michaelangel007@sharedcraft.com>
2025-09-08 21:58:22 +01:00
TomCh
54f86f0cdc Debugger: support address prefixes for slot, bank, language card & ROM (#1419)
* Minor tidy

* Changes:
. semicolon now Comment EOL
. double fwd-slash now Divide floor
. (single fwd-slash unassigned)

* . fwd-slash now parsed in Range_GetPrefix()
. WIP: 'bp bank/addr'

* Add error msgs

* Extend Breakpoint_t struct

* Update cmd 'bpl' to support displaying prefixes

* Do prefix checks & output error msgs

* Add _CheckBreakpointValueWithPrefix()
. support bank, for BP_OP_EQUAL
Stop reason: include BP id

* WIP: fix BPs (non-BPM)

* Fix cmd 'bpr'

* Stop reason: don't show BP id for BP_HIT_REG (as it already includes it)
Add comment about nArgs from calling funcs
Refactor _CmdBreakpointAddCommonArg(): nArgs

* Stop reason for memory BP: show full prefixed address

* Stop reason: output BP id in consistenct way

* Support ROM prefix filter

* Complete addr prefix logic

* Improve logic

* BP: 'HDD DMA to/from memory' - use common hit id function

* Support rw bank 100

* Support double forward-slash at start of line as a comment

* Refactor: use debugger naming convention for vars

* Changed prefix errors from 'bad' to 'out-of-range'

* DebugInitialize(): Reset g_breakpointHitID

* Refactor: use debugger var naming convention & formatting style

* Switch divide-operator to the underscore char, and allow double-fslash as a comment anywhere on a line

* Update help for debugger calculator

* Update help for debugger breakpoints

* Update help for debugger breakpoints (conditional)

* Fix help:breakpoints.html & fix ArgsGetRegisterVlaue() to do case-insensitive compare

* Fix underscore to be treated as a alphanumeric in a few edge cases

* Revert to using '//' as divide operator

* Help: update debugger Breakpoints & Calculalor pages

* Help: update debugger Calculator (missed one)

* Detabify and align

* Display (1) or (2) prefix for LC1 or LC2 breakpoint

* #1419 Added Aux.1 and Aux.N indicators

* Display (1) or (2) suffix for LC1 or LC2 breakpoint

* Extend cmd 'bpl' to display BP's end addr

* Show both bank and slot together

* Fix spacing for BP with range

* Add: FG_INFO_BP_MEM, FG_INFO_MEM_WRITE, BG_INFO_MEM_BANK_LC, FG_INFO_MEM_BANK_LC colors

* Cleanup

* Add 3x5 mini hex numbers

* Mini hex font to have rounded 0,A,C glyphs

* Display 2 hex Bank now

* Support edge-case for bank 0x100

* Tidy up end red spacer

* Refactor & introduce new struct AddressPrefix_t

* Fix a few bugs:
. bpl: fix end addr
. fix for 'R' and 'W' not coloured for single-byte BPs (eg. bpmr 100)

---------

Co-authored-by: michaelangel007 <michaelangel007@sharedcraft.com>
2025-09-06 02:43:57 -07:00
tomcw
8b31042c13 Add cmd line: -debugger-auto-run <script file>
. Use this to override the default "DebuggerAutoRun.txt"
2025-08-31 17:38:43 +01:00
Michael "Code Poet" Pohoreski
afe3824f99 Debugger output error levels (#1422) 2025-08-29 16:51:30 -07:00
Michael "Code Poet" Pohoreski
32749dbcad #1397 Add warning when trying to copy memory and the source end address is less than the source start address. (#1398) 2025-05-02 15:26:57 -07:00
TomCh
839c493b67 Support IIe aux slot: 80-col(1KiB) card via generic read ptrs (#1341, PR #1391)
Better support the IIe's aux slot when it's empty or has the 80-col(1KiB) card.
- any h/w using this alternate CPU emulation, (ie. aux=empty or 80-col(1KiB)), then the 'mem' cache is completely bypassed.
Debugger: change all the direct 'mem' accesses to go via ReadByteFromMemory().
TestCPU6502: test the alt CPU emulation code too.
2025-04-03 21:10:02 +01:00
Michael "Code Poet" Pohoreski
9d312230e5 Debugger view output QoL (#1384, PR #1387)
. Add HGR Pages 6, 7, 8 Visualizer viewing for Language Card.
. Update help for HGR Visualizer hotkeys 6, 7, 8 and debugger commands HGR6, HGR7, HGR8.
2025-03-02 15:57:27 +00:00
Michael "Code Poet" Pohoreski
c1592b90f4 Debugger view output QoL (#1384, PR #1385)
. Add (missing) help for Debugger's View Output
2025-02-22 16:57:10 +00:00
Andrea
acbef19489 Remove TEXT() and _T(). (PR #1379) 2025-02-13 20:48:37 +00:00
Andrea
168e868677 Remove TCHAR and <tchar.h> (PR #1373)
. Replace TCHAR -> char.
. Remove <tchar.h> and related functions.
2025-02-08 11:09:09 +00:00
michaelangel007
f44d058a09 Debugger: 2.9.2.6 Added: QoL: Turning a symbol table on/off now shows the current status. 2025-02-06 11:48:28 -08:00
michaelangel007
977cc01d85 Debugger: 2.9.2.5 Added: Symbol table for DOS 3.3 using file A2_DOS33.SYM2 2025-02-06 11:47:33 -08:00
michaelangel007
fa608c1f89 Debugger: 2.9.2.4 Fixed: DA RESET = 3F2 was displaying help instead of being parsed. 2025-02-06 10:38:15 -08:00
michaelangel007
3659beb776 Debugger 2.9.2.3: Fixed: DB HGR = 2000:3FFF and DB FOO = 300 wasn't parsing correctly from 2.9.1.3. Fix for commit 48e0fe3a. 2025-02-06 10:37:10 -08:00
michaelangel007
cb0da8538d Debugger 2.9.2.2: Fixed: DB HGR = 2000:3FFF was displaying help instead of being parsed. 2025-02-06 09:59:00 -08:00
michaelangel007
6c6d821051 Debugger 2.9.2.1 Added: Error message when trying to add a symbol > 51 characters. See Issue #1342 2025-01-06 15:45:47 -08:00
tomcw
c336a0ce40 Fix 2 minor bugs:
1) Debugger: wasn't accounting for 80STORE when checking PAGE2 switch (eg. CTRL+PRNTSCRN)
2) 80-col 1KiB card (std80): wasn't checking SW_WRITERAM
2025-01-05 17:25:32 +00:00
TomCh
16b2cf329e Support IIe aux slot: empty or with 80-col(1KiB) card (#1341, PR #1351)
Add new command line switch: -aux <empty|std80|ext80|rw3>
Add 6502/65C02 x normal/debugger alt read support for CPU emulation (#1353).
Fix bug in MemReadFloatingBus() reading from mem[] - no good, if MF_AUXREAD is set.
Support odd 80-col text video mode when aux slot is empty:
. add a new videoMode flag for VF_80COL_AUX_EMPTY.
Correctly support 80COL & DHIRES soft-switches when aux slot is empty or with std80 card.
Support VidHD's SHR with -aux <empty|std80>.
Save-state: support aux slot empty or with std80 card.
2024-12-30 21:39:16 +00:00
Andrea
35f176e4d8 Replace DWORD -> uint32_t. (PR #1350)
Some have been left where tightly coupled with the Win32 API.
2024-12-21 12:32:00 +00:00
TomCh
29c02d6bf2 Gh1267 update paging (#1326)
MemGetBankPtr(): simplify with a default arg. (#1262, PR #1326)
. UpdatePaging(): improve comment for page0 & page1 and memdirty
2024-08-24 20:18:28 +01:00
tomcw
fea4173b43 Debugger: CmdOutputRun:
. for scripts that can be loaded: output script pathname to console.
. for scripts that can't be loaded: don't truncate pathname that's output to console.
2024-01-01 11:11:51 +00:00
tomcw
ab9a856bc1 Debugger: allow pathnames > CONSOLE_WIDTH(=80) for scripts run via CmdOutputrun()
. specifically for the DebuggerAutoRun.txt script (which runs at AppleWin start-up)
. internally changed MAX_ARG_LEN from 127 to MAX_PATH(260), which is used to size Arg_t::sArg[]
2023-12-31 11:45:06 +00:00
tomcw
52447ad7d9 Load save-state: fix page 0 & 1 corruption when loading save-state with a RAMWorks card with 2 or more aux 64K banks (#1262) 2023-12-31 10:14:47 +00:00
tomcw
a7a2ef63f2 Bump debugger version: 2.9.2.0 (fixes #1206) 2023-07-21 21:18:23 +01:00
Andrea
eead359a85 Fix warning about wrong printf modifier for size_t. (PR #1241) 2023-06-18 20:21:29 +01:00
michaelangel007
03ce472e63 Debugger: 2.9.1.26: When adding symbols list the address first then the name for readability 2023-06-06 09:35:45 -07:00
Michael "Code Poet" Pohoreski
677ba8ffb3 Debugger: 2.9.1.25 Fixed: R P ## wasn't setting P flag status register. (#1238) 2023-06-03 19:03:11 -07:00
Michael "Code Poet" Pohoreski
000ebab3c5 Debugger 2.9.1.24 (#1236) 2023-06-03 11:08:16 -07:00
Michael "Code Poet" Pohoreski
928090c756 Debugger df qol (#1229)
* Remove trailing whitespace
* Debugger 2.9.1.21 Fixed: 'df' showing zero was displaying 0 instead 0.0
* Fix debug float output
* Debugger 2.9.1.22 Fixed: 'df <addr>' was incorrectly getting marked up as 'db'
* Debugger 2.9.1.23: Show floating-point values in scientific notation.
* Cleanup formatting
* Fix debug FAC output
2023-06-03 11:04:28 -07:00
tomcw
47841bf58a Debugger: Improve stop reason for 'brkop n' cmd to include address 2023-05-19 22:24:10 +01:00
Michael "Code Poet" Pohoreski
e1b0b20aad Debugger DISK INFO QoL (#1212)
* Bump debugger version 2.9.1.19

* Cleanup

* Debugger: Update DISK INFO to display disk info across 2 lines of text

* Debugger: Fix ConsolePrint() to wrap long lines of text

* Debugger: Update DISK INFO to show last nibble for non WOZ floppy image

* Replace optional pointer with reference in GetCurrentState()

* Add Log.h to Disk.h

* Cleanup GetCurrentState()

* Cleanup whitespace

* Add single line output for DISK INFO foundation. Still need CONFIG DISK #

* 2.9.1.21 Added: DISK INFO [#]
2023-04-28 16:28:49 +01:00
Michael "Code Poet" Pohoreski
f8da683d45 1204 debugger long input crash (#1213)
* Debugger: Clamp long input
* Fix backspace when input line has 78 characters
* Colorize console error line
* Cleanup alignment
* Init
* Refactor common expression
* Add support for a long input line when we decide to enable it
* Unabbreviate SOL and EOL
2023-04-24 20:00:08 -07:00
Michael "Code Poet" Pohoreski
33185f3f2b Update BMP import from GIMP 2.10 with X8 R8 G8 B8 (#1209) 2023-04-10 14:33:55 -07:00
michaelangel007
a68a29bcd0 Debugger: More QoL when BP hit #1200 2023-04-01 12:37:46 -07:00
tomcw
79024f0078 Debugger: match new stop reason message for HDD DMA (PR #1200) 2023-03-31 14:35:05 +01:00
michaelangel007
48f4a03e6c Debugger: Cleanup formatting 2023-03-31 03:59:12 -07:00
michaelangel007
db5b668eec Debugger: Step-over #1194 2023-03-31 03:46:04 -07:00
Michael "Code Poet" Pohoreski
a3c6156508 Debugger step-over can fail (#1194, PR #1203)
. QoL cleanup (show RTS address) for step-over failure cases
. Add source code for repro test 1 and 2
2023-03-31 09:45:54 +01:00
michaelangel007
4e8006456f Debugger: Cleanup LBR formatting 2023-03-29 08:25:34 -07:00
Michael "Code Poet" Pohoreski
72566373ce Debugger stop reason (#1200)
* Add global breakpoint so we can display last breakpoint triggered information

* Cleanup

* 2.9.1.15 Pretty print what register and breakpoint number when a breakpoint is triggered

* Bump debugger version 2.9.1.15

* Fix missing space between type and var

* Cleanup

* Add CHC_REGS
2023-03-26 10:54:30 -07:00
michaelangel007
4c08b9c20c Debugger: Cleanup: Alphabetize and Prototype breakpoint utility helpers 2023-03-23 12:42:44 -07:00
michaelangel007
8c9ba27acd Debugger: Remove unused func 2023-03-23 12:33:31 -07:00
michaelangel007
2dd3f0dbe0 Debugger: Cleanup: Apply Debugger coding started to functions 2023-03-23 12:32:14 -07:00
michaelangel007
755f023ed8 Debugger: Cleanup: DRY no breakpoints message 2023-03-23 12:16:21 -07:00
michaelangel007
730c2d8fcc Update coding standard with style already in use 2023-03-23 08:47:38 -07:00
michaelangel007
a767763486 Debugger: QoL for bpchange when no args 2023-03-23 08:06:02 -07:00
michaelangel007
f97531c5c0 Cleanup function to match coding-standard 2023-03-23 08:05:29 -07:00
michaelangel007
a8e6941a68 Debugger: Post cleanup for #1191. Pre-requsite for bpchange. 2023-03-23 08:00:56 -07:00