[A83] Re: program slowing
[Prev][Next][Index][Thread]
[A83] Re: program slowing
You might try this as a more flexible delay:
b=number of delays
delay:
ei
dloop:
halt
djnz dloop
ret
At 01:36 PM 8/14/2001 -0400, you wrote:
>you could make a lable that caused a short delay.
>
>delay:
> ei ;interrupts must be enabled for halt
> halt ;waits 1/200th of a second
> ret ;returns to call
>
>longdelay:
> ld b,100 ;djnz's 100 times
>longdelaylp:
> call delay ;calls delay
> djnz longdelaylp ;dec's 'b', jumps to longdelaylp if b is not 0
> ret
>
>to get a short delay, call delay, do get a long delay call longdelay
References: