[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
6502 Delay Loops using Applesoft
- Subject: 6502 Delay Loops using Applesoft
- From: Allen Bong <allenbsf6502@gmail.com>
- Date: Thu, 25 Nov 2010 15:08:36 -0800 (PST)
- Complaints-to: groups-abuse@google.com
- Injection-info: o23g2000prh.googlegroups.com; posting-host=60.52.10.180; posting-account=0pSeuwoAAABUNs-tiy2n5vORF7izTcNI
- Newsgroups: comp.sys.apple2
- Organization: http://groups.google.com
- User-agent: G2/1.0
- Xref: g2news2.google.com comp.sys.apple2:21201
Hi,
Has anyone written a gereral delay loop calculating program in
Applesoft, to calculate the constants required to gererate the
required time delays in 6502 codes?
For example:
ZP1 EQU $XX ;ANY UNUSED ZP ADDR
ZP2 EQU $XX ;ANY UNUSED ZP ADDR
DELAY PHA
LDA K1
STA ZP1
LOOP1 LDA K2
STA ZP2
LOOP2 DEC ZP2
BNE LOOP2
DEC ZP1
BNE LOOP1
PLA
RTS
I have searched through google and never found one. But there are
some written using JAVA for other cpu and mcu. I ask because I needed
them from time to time doing small projects and if someone has already
written one, I wouldn't have to reinvented the wheel or else........
Thank you.
Allen