C64 Expansion Port IO1 and IO2 and PEEK and POKE

From: Leif Bloomquist <leif_at_schemafactor.com>
Date: Sat, 7 May 2016 14:15:52 -0400
Message-ID: <CAOTCz+HAHYENDW3EQ_OgBtmSsC0pnf8Ld5R3Gcrcwej0aQheFw@mail.gmail.com>
Hi all,

I recently got one of the Dorktronic Expansion Port breakouts
(http://www.ebay.com/itm/331840785722), great way to explore the
mysteries of the C64 Expansion Port.

I have an Arduino wired in, triggering interrupts on falling edges on
/IO1 and /IO2 incrementing simple counters (one for each).

It works well, but here's an interesting mystery, that folks on
cbm-hackers might appreciate.

When I do a PEEK from BASIC of the IO space (i.e 57088 for IO2), I get
a single falling edge on /IO2, as expected.

But when I do a POKE (again from BASIC), I get *two* falling edges.
 This is quite repeatable.

That's unexpected, any theories on why this may be?

I don't have a scope unfortunately.  Had a quick browse through the
BASIC disassembly, nothing jumped out.



Leif Bloomquist | leif@schemafactor.com | +1 416-737-2328 | Check out
my blog! http://www.jammingsignal.com

"Every choice, no matter how small, begins a new story." - xkcd

       Message was sent through the cbm-hackers mailing list
Received on 2016-05-07 19:00:03

Archive generated by hypermail 2.2.0.