Pico PIO programming

A project log for PZ1 6502 laptop

I am building a laptop with a W65C02, lots of memory, SID-sound, decent graphics and a filesystem.

adamklotblixtadam.klotblixt 03/03/2024 at 10:320 Comments

I've been stuck the last few days with trying to get PIO code running properly on the Pico. Lots of trouble getting it to work to read addr, read/write data and write control- and bank-registers. Mainly me getting the config wrong, setting the pindirections incorrectly.

The main takeaway is that when the arm core wait-loops for data from the PIO, it takes more time than actually doing the work directly in the arm core the way I've done it so far. To gain performance, the PIO needs to do stuff in the background while the arm core does some heavy lifting.

To get more performance to the arm cores, in the PZ1 case that means an external CPLD to do address decoding and memory access.

Also, now I really know how the PIO works, which is great for the future.