Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Conditional breakpoints in Vice
2004-05-21 17:29
Cybernator

Registered: Jun 2002
Posts: 154
Conditional breakpoints in Vice

According to the manual, conditional breakpoints are set like this: break [<address> [if <cond_expr>] ]

But I don't see info about cond_expr. I need a breakpoint when A==some value.
If I write: break $1000 if A==$10, the condition is: 10==16, which is always false.

I'd appreciate a tip or something.
2004-05-22 11:32
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
i made a program that does this:

_start
inc d021
dec d020
sta 02
_last
jmp start

then wrote break _last if $02==f8

it works
2004-05-22 11:33
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
? condition gives you the info
2004-05-22 15:24
iAN CooG

Registered: May 2002
Posts: 3132
Quote: ? condition gives you the info


Both internal help and html documentations seem very vague on this subject. Debugging a game I tried this:

break 290e if 2914==0

$2914 is ALWAYS 0 but monitor never breaks and goes straight.

I cant also use registers,
if a == 0
is interpreted as location $0a
if AC == 0
is interpreted as location $ac
if X == 0, if XR/Y/YR causes "unexpected token"

2004-05-22 18:15
Steppe

Registered: Jan 2002
Posts: 1510
Have you tried it with the "$"?

break 290e if $2914==0 Hm...
2004-05-22 18:49
iAN CooG

Registered: May 2002
Posts: 3132
Quote: Have you tried it with the "$"?

break 290e if $2914==0 Hm...


Yes, of course with and without $.
Anyway any number is hex for default unless I set it to decimal with "radix d".
2004-05-23 01:27
SIDWAVE
Account closed

Registered: Apr 2002
Posts: 2238
If you want to break on the A,X,Y = something,
use $030c, 030d, 030e
2004-05-23 05:23
iAN CooG

Registered: May 2002
Posts: 3132
Quote: If you want to break on the A,X,Y = something,
use $030c, 030d, 030e


Those are register updated for Basic usage, AFAIR. Quite useless while debugging games ;)

ADDR AC XR YR SP 00 01 NV-BDIZC LIN CYC
.;f501 fe 82 01 f7 2f 37 00100001 000 002

(C:$f501) m 30c
>C:030c 00 00 00 00 4c 48 b2 00 31 ea 66 fe 47 fe 4a f3

as you can see no values match the registers.
Anyway I tried also this and as i expected didn't work.

Maybe it's the Windows port of Vice (v1.14) that is faulty.
Sometimes "del" crashes it, I have to remove breakpoints using the mouse on the disassebly window... another reason for me to feel more comfortable with CCS internal monitor :)
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Board Rider/Commodor..
Alakran_64
Mason/Unicess
Jammer
dyme
Krill/Plush
megasoftargentina
Apollyon/ALD
B.A.
Guests online: 136
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 The Ghost  (9.6)
9 Wonderland XIV  (9.6)
10 Bromance  (9.6)
Top onefile Demos
1 It's More Fun to Com..  (9.8)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 Rainbow Connection  (9.5)
6 TRSAC, Gabber & Pebe..  (9.5)
7 Onscreen 5k  (9.5)
8 Wafer Demo  (9.5)
9 Dawnfall V1.1  (9.5)
10 Quadrants  (9.5)
Top Groups
1 Oxyron  (9.3)
2 Nostalgia  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top Webmasters
1 Slaygon  (9.7)
2 Perff  (9.6)
3 Morpheus  (9.5)
4 Sabbi  (9.5)
5 CreaMD  (9.1)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.044 sec.