A83: Can't get this routine to work...


[Prev][Next][Index][Thread]

A83: Can't get this routine to work...




This routine tries to swap the contents of graph_mem with saferam1, but ends 
up copying much more than 768 bytes:

SwapApd:
	ld hl,graph_mem
	ld de,saferam1
	ld bc,768
SwapApd2:
	ld a,(de)
	ldi
	dec hl
	ld (hl),a
	inc hl
	dec c
	jr nz,SwapApd2
	dec b
	jr nz,SwapApd2
	ret

What did I do incorrectly?
________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com