> ld hl,DATA_AREA
> ld de,DATA_AREA+1
> ld bc,4096-1
> ld (hl),0
> ldir
Yes, it is the faster method to fill a memory area.
In general, for a loop with more than 256 steps, I use the following
code:
ld bc,ITERATIONS
LOOP: push bc
...
(whatever must be done ITERATIONS times)
...
pop bc
dec bc
ld a,b
or c
jr nz,LOOP
*** XX MSX USERS MEETING IN BARCELONA: DECEMBER 8th 2001 ***
--------------------------------------------------------------------------------------------------------------------------
Konami Man - AKA Nestor Soriano (^^)v
http://www.konamiman.com - [EMAIL PROTECTED]
ICQ#: 18281450
"Celebrating the imprudences must be unfailingly consequent with it said,
not for the fact in itself, but for some that another onomatopoeia to the use"
--------------------------------------------------------------------------------------------------------------------------
--
For info, see http://www.stack.nl/~wynke/MSX/listinfo.html