Register | Login
Views: 19364387
Main | Memberlist | Active users | ACS | Commons | Calendar | Online users
Ranks | FAQ | Color Chart | Photo album | IRC Chat
11-02-05 12:59 PM
0 user currently in General Emulation.
Acmlm's Board - I2 Archive - General Emulation - 6502 ASM Confusion (w/ bbitmaster's FCEUD)
  
User name:
Password:
Reply:
 

UserPost
dan
Posts: 335/782
Yep, that confused me too when I first started using FCEUd.
Parasyte
Posts: 178/514
Aye, the disassembler syntax may take some getting-used-to. Whenever you see an @ symbol, that's telling you the address which the instruction will work on. (Meaning the address which will be read or written, etc.) The = symbol is also rather non-standard. It's purpose is telling you what data is currently at that working address. Not the value to be written. It comes in handy when you're interested in what data will be loaded from the working address. But it doesn't necessarily have a purpose when storing.
bbitmaster
Posts: 59/103
I just wanted to say, don't feel bad. I am the same way with even the simplest things.

You'd be amazed how stupid I feel sometimes, and yet people may look up to me for working on FCEUXD, and many other things.

What counts is that you're diving into this stuff. Just by taking that first step, you've gone farther than many others. So feel free to ask any more questions. You'll get better if you keep trying.

And yes, I have lost my wallet several times, and I am terrible to leave my headlights on.
Reshaper256
Posts: 103/143
Wow, surprisingly simple... I assumed the = meant that the receiving address or register was having the value after the = written to it. Now I see that I just need to scroll the Logger up until I find what actually changed $0000 to #$FE. Thanks a lot!

I don't know how long it would have taken me to catch such a fundamental misunderstanding. I'm stupid with simple, important stuff. You don't want to know how many times I've lost my wallet and car keys...
DahrkDaiz
Posts: 447/885
When you see a "=" after an address on a given line of assembly, that means that the address is equal to the value before the instruction is executed. If you did a breakpoint on F27D for execute, then it'll show STY $00 = #$FE, then Step Into to go to the next instruction, an scroll up in the debugger and you'll see that $00 is now #$03. Hope this clears things up
Reshaper256
Posts: 102/143


I'm sure many (or most) of you would recognize the above pic as the Trace Logger from bbitmaster's incredible new release of FCE Ultra Debug. Being new to ASM, but having some references to go by (http://www.obelisk.demon.co.uk/6502 and its links, mostly), I'm beginning to understand more, but I've hit a roadblock that I've spent the last few afternoons trying to figure out. Hopefully someone with more ASM knowledge could help me out with this.

The highlighted portion of the pic above contains the instruction:

$F27D : 84 00 - - - - - STY $00 = #$FE - - - - - - - - - - - - A:FE X:0D Y:03 P:nvUBdIzc

From my understanding, 84 00 instructs the value held in the Y-register (from what I see it's $03) to be stored at $00 on the zero page (at $0000).

Why then is the value stored to $0000 #$FE and not #$03?

Isn't the Y-register holding the value $03 before, during, and after this instruction?

After looking at other instances where I thought a number should be stored to memory from one of the registers, I discovered that most of them were storing values that I would not expect them to. Obviously I've missed something, or am reading something incorrectly.

Any help would be appreciated.
Acmlm's Board - I2 Archive - General Emulation - 6502 ASM Confusion (w/ bbitmaster's FCEUD)


ABII


AcmlmBoard vl.ol (11-01-05)
© 2000-2005 Acmlm, Emuz, et al



Page rendered in 0.011 seconds.