[Coco] Need help with Assembler Program

Charles Shrader charles at shrader.com
Sat Feb 2 13:23:56 EST 2008


Greetings!

I'm playing with EDTASM++ in an emulator (I've just ordered a real
cartridge from Cloud-9) and am having
Some problems with an "example" program I found on the internet.

When I assemble, I get no errors.  But when I try to execute the
program, I get unusual results.

I'm wondering if the subroutines I'm referencing aren't located where
this listing shows them.

I'm running on Dave Kiel's Coco 2 emulator.  Here are some of the
subroutines that this program calls:

JSR	43304 -   this is supposed to do a CLS routine.
JSR	[40962] - this should be a CHROUT subroutine.

I take it that an address in brackets [] is a relative address - the
data at memory location 40962 is
a pointer to the actual location of the CHROUT subroutine?

I'm wondering if these subroutine locations are actually for a Coco3
perhaps??

The entire test program I'm trying to get running is:


00100 START    JSR     43304           CLS SUBROUTINE 
00110          LDA     #65             ASCII A 
00120 AGAIN    JSR     [40962]         CHROUT SUBROUTINE 
00130                  INCA            NEXT IN ALPHABET 
00140                  CMPA    #91     ONE PAST ASCII Z? 
00150                  BNE     AGAIN 
00160                  LDA     #32     ALPHABET DONE 
00170                  LDB     #6      PRINT 6 SPACES 
00180 REPEAT   JSR     [40962] 
00190                  DECB 
00200                  BNE     REPEAT 
00210 LOOP      BRA    LOOP 
00210                  END 


Chuck

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.516 / Virus Database: 269.19.18/1255 - Release Date:
2/1/2008 9:59 AM
 




More information about the Coco mailing list