View Single Post
Old 06 June 2010, 20:38   #60
pmc
gone
 
pmc's Avatar
 
Join Date: Apr 2007
Location: completely gone
Posts: 1,596
What version of Devpac are you using AlfaRomeo...?

I put this code into Devpac V3.18 and it assembled and ran with no problems.

By the way, code would be shorter like this:

Code:
	lea	TEXT(pc),a0
	move.b	(a0)+,d0
	subq.b	#1,d0
	lea	COPY(pc),a1
loop	move.b	(a0)+,(a1)+
	dbf	d0,loop
	move.b	#0,(a1)
	rts

TEXT	dc.b	5,"HELLO"
COPY	ds.b	6
EDIT: Only just noticed that Bipps had already posted a shortened version earlier... ;-)

Last edited by pmc; 06 June 2010 at 20:50. Reason: Only just noticed...
pmc is offline  
 
Page generated in 0.04257 seconds with 11 queries