Subject: Re: [stella] Ruffin Bailey's Disassembly of missile.bin From: Chris Wilkson <ecwilkso@xxxxxxx> Date: Mon, 24 Jun 2002 22:17:25 -0400 (EDT) |
On Mon, 24 Jun 2002, Ruffin Bailey wrote: > Here are my guesses for what's going on: > If you want to load zero into Y, you'll need to have this line: > LDY #$00 > > There's an outside chance that you left off the $ before the 00. If you > leave out the "#", it'll read from address 00 (does that even exist?). > Leaving out the $ -- I'm not sure what that does. :^) I just tried The "#" tells the assembler than the operand is an actual piece of data, not an address. This is the "immediate" addressing mode. The "$" tells the assembler that the operand is a hexadecimal value. Leaving it out tells the assembler that is is a decimal value. So in the case of 0-9, they are the same with or without the "$". But things get crazy if you type "#80" (meaning 80 hex = 128 decimal) and the compiler assumes 80 decimal. The default varies of course with the assembler used, but you get the idea. -Chris ---------------------------------------------------------------------------------------------- Archives (includes files) at http://www.biglist.com/lists/stella/archives/ Unsub & more at http://www.biglist.com/lists/stella/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [stella] Ruffin Bailey's Disass, Ruffin Bailey | Thread | Re: [stella] Ruffin Bailey's Disass, Glenn Saunders |
Re: [stella] Ruffin Bailey's Disass, Ruffin Bailey | Date | RE: [stella] the joy of 6502 assemb, Garon Grainger |
Month |