>I already tried many LDI's and PUSH/POP system on my own, but unfortunately
>the process of changing SP makes PUSH/POP slower than sequence of LDI's.

The fastest scrollleft code I could think of is the folowing code snippet
which should be repeated 9*height times and
It's best to write a routine to generate it runtime and fill in the proper
SP values.

;2 pixel scroll left code element 224Ts or 16T/byte

;AF' and index registers are note used as they slowdown the avarage speed.

 LD SP,&8001 ;12 HardCode address for each element
 POP AF    ;4
 POP BC
 POP DE
 POP HL
 exx             ;4
 POP BC
 POP DE
 POP HL
 dec sp        ;8
 push hl       ;16
 push de
 push bc
 exx
 push hl
 push de
 push bc
 push af

It's 20% faster and takes 29% less space then LDI's.

BTW These timings (and earlier mentioned) are RAM timings when the ASIC is
NOT updating the display.

Edwin

Reply via email to