A86: Re: actual asm help


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

A86: Re: actual asm help




You are only incrementing HL once, but decrementing it twice, so it points
to _freemem-1.  This could be your problem...

> _freemem points to some free mem
>
>     ld hl,_freemem
>     ld a,1
>     ld (hl),a
>     inc hl
>     ld (hl),a
>
>     dec hl
>     dec hl
>     ld a,(hl)
>     jp "a routine to display the correct character that i'm pretty sure
> works
>                 it... for example... cp 1
>                                                jp z,put_1
>                                                ....then it does a "ret"
>     inc hl
>     ld a,(hl)
>     jp "the same char display routine"




References: