Page 1 of 5
The J64C
Posted: Wed Sep 06, 2023 6:39 am
by J64C
Hi Guys,
I have recently bit the bullet to get back in to attempting to make some sort of homebrew computer and after only a couple of weeks I have done a fair bit of the groundwork.
It's a simple build with just a few components (for now) and runs pretty stable at 5 MHz, which is pretty good considering the state of the wiring.
It presently consists of the following and will most certainly be expanded upon-
- CPU: W65C02
RAM: 128K (64K accessible)
ROM: ATMega 8535
I/O: 1x W65C22
Address Control: Xilinx XC9535XL
VGA: GameDuino
Very limited right now and constructed with parts that I happened to have on hand, hence some of the design choices. There is no form of input yet. That's next on the to-do list.
Here's a gif of it running side by side with identical code base vs a Commodore 64. (C64 left, J64C right).
I'm extremely happy with the progress so far and have had many sleepless nights working out and resolving various problems along the way.
Re: The J64C
Posted: Wed Sep 06, 2023 7:35 am
by drogon
Well done!
I did look at the Gameduino way back for my project but went another route - are you using the original or the newer 3X one? The key would be getting high speed SPI going...
-Gordon
Re: The J64C
Posted: Wed Sep 06, 2023 7:45 am
by J64C
Thanks Gordon!
It's the original GameDuino here. I grabbed a couple a while back for 'future projects'.
Yep! I have some ideas in mind for getting the SPI running much faster (hopefully 8x). Also on the long to-do list.
Re: The J64C
Posted: Mon Sep 11, 2023 2:26 am
by J64C
Just ordered some boards through PCBWay.
Just has a couple of ports allocated though an edge connector for now. That should give me enough to play with for a little while, until the next version.
Re: The J64C
Posted: Mon Sep 11, 2023 5:10 pm
by fachat
You have edge connector plugs at hand? I tend to use pin headers for IO as they are cheaper.
Edit: but cool build!
Re: The J64C
Posted: Mon Sep 11, 2023 10:06 pm
by J64C
Thanks!
Yep, I have a bunch of edge connectors on hand that I bought on Ali Express a while back for next to nothing.
Re: The J64C
Posted: Tue Sep 19, 2023 7:05 am
by J64C
The boards are in! Wish me luck!

Re: The J64C
Posted: Tue Sep 19, 2023 9:04 am
by AndrewP
Good luck! I'm liking the few component build and I'm sure assembly will all go swimmingly !
Re: The J64C
Posted: Thu Sep 21, 2023 8:13 am
by J64C
Well this turned out to be better than anticipated. My first attempt at a homebrew computer is working perfectly!
Started out at 1.5 MHz, but had some initial issues getting beyond that. I seemed to be able to iron out the quirks in the bootloader/reset side of things and sorted that out.
I have a jumpered clock divider, being driven be a 25.175 MHz can oscillator and gradually tested doubling the 1.5 MHz, restarting the board.
- 1.57 MHz - Stable
3.15 MHz - Stable
6.3 MHz - Stable
12.59 MHz - Stable
I thought. What are the chances I can bypass this setup altogether and it still work? So I thought, I'll give it a try.
25.175 MHz! Still stable!!! Been running on my bench for the past hour, doing its thing sending data to the screen via a GameDuinio board. Craziness!
Not even sure what this thing will top out at, but it's going far beyond my wildest expectations.
Will keep you all posted!

Re: The J64C
Posted: Thu Sep 21, 2023 10:19 am
by gfoot
Very nice! For this sort of thing I'd recommend running the Dormann test suite, I rigged it to run in an endless loop for soak testing and found it quite good for catching bugs I'd otherwise never have found.
It's also interesting to see how fast you can take the 65C22, I'm not sure if anybody has explored that yet. You'd probably need to write a test suite for all of its functionality to be sure.
Re: The J64C
Posted: Thu Sep 21, 2023 10:27 am
by J64C
Thanks gfoot! Much to test here that's for sure and lots of coding ahead.
I think Plasmo has had a bit of experience with overclocking, getting in to the low 30's from memory.
Going to be heaps of fun with this project though. I'm beyond happy with the progress so far.
Re: The J64C
Posted: Thu Sep 21, 2023 11:15 am
by gfoot
Plasmo got to the high 30s, but I don't think he had a 65C22 in the circuit so that may be the biggest question mark. Other than that, if your CPLD and address decoding are fast enough then hopefully you'll get similar results!
Re: The J64C
Posted: Thu Sep 21, 2023 12:05 pm
by plasmo
The fastest I ran 65C22 was 24MHz. 65C22 and W65C02 use the same 0.6u lithography so I think a simple RAM, ROM, W65C02, and W65C22 design similar to
ZG6502 may run into 30+ MHz, ROM access time is the bottle neck. The original ZG6502 can only run 7.37MHz because W65C51 is the bottleneck.
I'm convinced that 25.175MHz is a stable frequency for W65C02. My
most recent design just assumes 25.175MHz will work even with few expansion boards.
Bill
Re: The J64C
Posted: Thu Sep 21, 2023 10:11 pm
by J64C
Probably sounds far fetched. But I have this running next to me right now at 40 MHz!
Added a gif video showing how the screen is being filled and cleared (which you can compare with the one in the first post here).
Safe to say the W65C22 isn't going to cause as much of a bottleneck as people would think. Time to push on and see where the upper limit is! 
Edit - Make that 50 MHz!!! 
50 MHz seems to be where it caps out before it cracks it. Time to play with clock stretching and see if I can squeeze any more.
Ah man... Scratch all of that. I was feeding that clock in to a clock divider. So I'm still running at 25 MHz.
Still the gif video above still stands. It's moving along very nicely!
Re: The J64C
Posted: Thu Sep 21, 2023 10:48 pm
by plasmo
40Mhz is realistic. I have a hand wired design that does 40Mhz with elevated supply voltage of 5.4V. I have a revised pc board coming in next week that I hope to run 40Mhz at nominal 5V.
50Mhz is incredible!
Bill