|
|
 | | From: | sanjaya | | Subject: | Assembler code | | Date: | 14 Jan 2005 20:38:45 -0800 |
|
|
 | > >>can someone help me with the assembler code to move memory contents > >>from $DA00-$DBFF (Bank 1 main memory) to $8000-$81ff (main memory). > >> > >>thanks, > >>sanjaya > > > >
Don't we have to activate soft switches to copy from Bank 1, Main meory?
thanks, sanjaya
|
|
 | | From: | Laine Houghton | | Subject: | Re: Assembler code | | Date: | Sat, 15 Jan 2005 09:49:46 -0700 |
|
|
 | "sanjaya" wrote in message news:95bec359.0501142038.7cf17bad@posting.google.com... >> >>can someone help me with the assembler code to move memory contents >> >>from $DA00-$DBFF (Bank 1 main memory) to $8000-$81ff (main memory). >> >> >> >>thanks, >> >>sanjaya >> > >> > > > Don't we have to activate soft switches to copy from Bank 1, Main meory? > > thanks, > sanjaya
Yes. On powerup bank 2 is switched in. Reading $C08B (TWICE) sets $D000-$DFFF to bank 1 read/write
lda $DA00 ;get byte in bank 2 sta $300 ;save byte bit $C08B bit $C08B ;switch in bank 1 lda $DA00 ;get byte in bank 1 sta $301 ; save byte bit $C083 bit $C083 ; switch bank 2 back in lda $DA00 cmp $300 bne ERROR
|
|
|