Minimal 64x4: The Oddball in Home Computer Development
Вставка
- Опубліковано 11 вер 2024
- I showcase and release the 'Minimal 64x4' home computer with VGA, PS/2 and SSD. It packs 4x the processing power of a Commodore C64!
It is a free and non-commercial project for you to explore how computers work and build your own machine, too. Have fun!
Reference manual and bill of materials (BOM):
docs.google.co...
OS, software, KiCAD project, Gerber PCB files:
github.com/slu...
Hans Jacob's games:
github.com/han...
Matt Heffernan's (The Retro Desk) 8-Bit Battle Royale: • TOP SPEED! 8-Bit Battl...
James Sharman's jam-1: • Is this the most power...
Byte Attic's Agonlight-2: • The BIG Agon light™ RE...
BBC Micro picture by Stuart Brady commons.wikime...
ZX Spextrum picture by Bill Bertram commons.wikime...
C64 picture by Evan Amos commons.wikime...
Commander X-16 picture by TexElex texelec.com/wp...
Legacy Minimal 64:
• Minimal 64 Home Comput...
github.com/slu...
docs.google.co...
Legacy Minimal UART CPU:
• Building the Minimal C...
docs.google.co...
github.com/slu...
This is really great, I appreciate you so much. There's a real need for something like a hacker console with a reasonable amount of power but isn't overburdened with complexity and restrictions. Developing software used to be fun and immediate with a huge amount of creative freedom. Now it's extremely bogged down by complexity and security concerns.
That is exactly how I felt before developing the Minimal 64x4!
What you are describing is more closely matched by the Uzebox than the Minimal64x4, which isn't quite minimal enough for me. The Uzebox Omega only requires one chip to run and you can build it in a weekend.
Exactly ! It's about learning, one individual being able to comprehend the entire system, and the mathematics learning journey.
Only 5.8k subs?!?!?!
Your videos feel like Bisqwit videos. It's like watching a master at work.
Thank you! Glad you appreciate this.
It's up to you (and the UA-cam algorithm) to push that number ;-)
He does sound a lot like Bisqwit. I thought this could actually be him posting as another user!
I've just been nudged towards this video, and my mind is blown. PCBs ordered! Can't wait to build this and learn how it works. Full marks for the documentation too. I need to study it in more depth when I have the time, but it looks like you've assembled probably the best computing fundamentals learning resource I've ever seen.
Thanks Dan, I am glad you like it. Let me know how the build goes.
I've never ordered PCBs before. Could you tell me which company you used and any details I need to attend to? For example, should this thing be made of base material FR-4, and is it two-layer?
@@pbrninja19 I order my PCBs locally, but it doesn't matter. Just upload the KiCAD project as a zip or the provided Gerber files and they'll happily do the rest. 2 layers, simplest stuff. Good luck!
@@pbrninja19 I used JLCPCB, but you might use PCBWay or any other. Upload the gerber zip file, probably just run with all the defaults. The hardest part is choosing the colour! (I chose red :) ).
@@slu467 Thanks for the advice. I ended up ordering from AISLER in Germany. Very convenient! Thanks.
This is incredible. I was digging around for fun stuff to put in a PCB order I needed to place, and this fits the bill with aplomb. Cant wait!
This is seriously awesome! I love the care you put into these projects, and the fantastic detailed documentation 🥳
We do indeed share a love of basic computation. Before looking at your manual, I'm astonished at your x64's speed.
Hansfor this, and for looks like documentation!
I first learned how to code in basic and was immediately challenged with performance issues. It's almost the first challenge you run into, so everything you do always considers performance first. This leads to totally weird and convoluted ways of doing things. It's a totally different mindset that is no longer necessary, for better or worse.
That resonates with me. Not having to worry about performance gives total freedom to the programmer. That *may* lead to beautifully abstracted solutions but may lead to convoluted ones, too. Personally, I feel I need technical limitations to fuel my creativity. Weired, and the only reason I find these simple 8-bit machines enjoyable.
Du hättest damit in den 70er Jahren so einen Sprung nach vorne gemacht. Ich find deinen Ansatz einfach nur geil. Alles mögliche rausholen bei begrenzter Hardware. Sagenhaft. Freue mich über jedes Video von dir. Und vllt gibts ja nochmal ne Art Serie zu einem fixen Stand. Einfach Klasse was du da aus ein "paar" 74er (plus ein paar neuere Bausteine weils die alten nciht mehr gibt) und jede Menge Hirnschmalz da baust. Auch den Ansatz mit der "python like" Sprache für das System, der Speicherung und und und .... Schön soviel Kreativität zu sehen. Macht echt Spaß.
Freut mich, dass es dir gefällt. Wie du schon schreibst: In den 70ern hätte es diese riesigen FLASH-Speicher nicht gegeben :-)
@@slu467 Unabhängig von dem mehr als luxoriösem Flash und RAM von heute ... is ja nur ersatz weils dieses kleine Fisselszeug an Speichern heute kaum noch gibt. Und ein bissl Spaß muss ja auch noch sein :-) ,,,, Ich find das Projekt End-Geil ... Freu mich auf jedes neue Video ....
Wow, 🎉what an amazing project and achievement! Congratulations
Thanks a lot!
Nicely done Slu4! It would be interesting to see how much you can do with this.
Thanks, James ;-) computationally, the Minimal 64x4 could pull off some early 3D rendering, I guess. Definitely not DOOM ;-) Any suggestions? When it comes to graphics and sound however, the Minimal 64x4 can't do much (intentionally). Here your jam-1 really shines!
Very impressive. I can see what you've done to speed it up, with the fetch being far more efficient, amongst other optimisations. It's all very clever. This video came out just at the right time as I was about to build you Minimal 64, just after I finish my 6502 project first. I really want to build this one and add colour graphics at some point, using the expansion port.
Hi David, good to see you here ;-) That fetch cycle is kinda neat, isn't it :-)
Great to see another video from you. This project is amazing!
I like the off-the-beaten-track approach! It also seems to work very well for you, which helps :P Very cool video, I wish I had the skills to develop such a computer. Best I can do is an even more minimal CPU(-instruction set), because my brain is not big enough for more ;P
Thanks, man. Actually, building it smaller is always more difficult.
This is really top work, and it's been amazing to see the way the Minimal family has developed. One thing I was wondering was if there was any documentation of what all the microcode control signals are? I'm able to guess some based on the schematics and a few are explained in the Reference Manual, but a full list of all 24 signals and what they do/mean would be a very welcome addition to the documentation!
Hi and thanks a lot for your kind words. The documentation has a section 'CPU Architecture'. All control signals are explained there 😁
@@slu467 hmm, well I feel silly. I was so focused looking at the schematics and the assembly bits of the manual that I didn’t think to look in the architecture section! 😅 Thank you for reminding me that there was more than what I was focused on!
One for the rythm
and one for the algo! 😉
That's a great project, and you really put some Herzblut in it!
Keep it up! Greetings from NRW!
Thanks a lot!
Wow! This is amazing! Congratulations and great work!
Thank you so much!
Great job, but the UX is that of a 1981 PC or a Spectrum+2 without sound or color. Computers really became much more fun to use (games, utilities and creative software) with that and multitasking.
This game selection is sort of a replay of the late Apple II and early PC era - say 1979-1983, and when computers could do more, deeper and more fun and reactive game (and utility and creative software!) ideas emerged.
Those computers who punched up, the C64 and MSX2 a little, but especially the Amiga, really covered both the clunky terminal style computers all the way to black box consoles with only arcade style games, and added the modern computing UX in 1985 that didn't really become real on competing brands until circa 1998. A small part of this is due to the complexity of the hardware or staring at chip or transistor counts, but what was ahead of its time was the vision. It was the computer of the future, a deliberate step away from the clunky old computers.
How would you implement something that would be as bold and say, "NO!" no more textmode. No more monochrome. No more lagging and stuttering and hourglasses. High resolutions in color, multiple monitors, expansion support, and a way to manage graphics space and performance requirements? Amiga was great out of the box, while the PC struggled mightily for the longest time - even swapping RAM to harddisk when you moved the (software) mouse pointer!
You might end up with circuitry akin to the Amiga. Or RTG/graphics card/dedicated VRAM akin to all the brands that struggled (until they put GPUs on the graphics cards). Or perhaps a really neat solution? Dual-port SRAM? Go! \o/
Fantastic video and fantastic results!
Thank you! Cheers!
For video, you need two registers (however many bits = colour depth of screen). Let's say it's 4-bit each, so that's a single 8-bit register. These go into a quad 2:1 mux with your current VGA output being the channel select. Need a mux faster than ~40ns which should be doable. What this gives you is a completely CPU driven foreground and background colour. I personally really like the RRGGBBVV scheme dreamt up by Lucid Science which gives you two common value bits per channel and in 8-bits gives you CLOSE TO Amiga-level colour palette. Now, this could simply be done at the beginning of the raster line with an interrupt tied to the HBLANK (you have that right?) or by polling the beam counters. With a moderately fast CPU you should be able to pull off some pretty crazy COPPER effects.
This is a thing of beauty!
Thanks for appreciating 🙂
I thought I am a geek, turned out I have no clue what that word means. Hope there will be more about this project.
Thanks! Would love that too, but our audience here is very limited ;-)
This is amazing! I love you minimalism and perfection (as well, as your previous cute projects). This is kind of art and beauty!
Thanks a lot! Glad you appreciate this.
I don't think you will have 10 million likes soon but you are awesome.
There was quite a decent version of space invaders on the Commodore PET, a 1MHz 6502 based machine with character based video. The BBC B had a 2MHz 6502 and could manage bitmapped colour graphics with wireframe 3D. It wasn’t about the hardware back then, it was how clever the software was.
That's what I find ascinating, too.
If Elite can only draw convex shapes, how did the do the docking port? Does elite z sort objects? But this fails with pointy ships ( Star Detroyers).
I hate wireframe with occlusion. The correct way is as expensive as flat shading. I still have not figured out how to catch all z sort glitches (on retro hardware). Feels like BSP and z-buffer are faster if you want correct results. Now do that on 8 bits.
@@ArneChristianRosenfeldt you’ll note that the docking port was a flat rectangle on one side of the station, and only displayed when within range. The whole point about Elite graphics wasn’t that they were good (there was a lot of flickering and the occasional visual glitch), it was that it was possible at all in such a limited system. The line drawing was done by the CPU on a single buffered, mono, bitmapped display (there was a trick whereby the video mode was switched to colour for the status panel at the bottom of the screen). There was no space or capacity for double buffering, Z planes, polygon drawing etc.
@@stevetodd7383 Yeah, just when you write an engine or tune hardware for 3d, you don't want your interface to leak the implementation. The flickering can be replaced by a disintegrated look where edges move independently from one frame to the next. C64 can do double buffering. Maybe the BBC micro is low on RAM?
@@ArneChristianRosenfeldt the original BBC B supported only 32K of RAM, which had to hold code plus VRAM. Later versions for the BBC Master or 6502 co processor didn’t have the same memory limits, but the original code needed to play a number of tricks with the video hardware to fit it all in.
Wonderful, simply wonderful
Many thanks!
@@slu467 looks like the vram is shadowed now, was that the main source of the speed bump or was there some other big change that gave you the 2x processing speed boost?
@@StevenSherman-kr4xmShadowing VRAM got me from 6MHz to 8MHz clock speed. The real efficiency gain lies in the new instructions fetch, transfering PC to MAR in just one clock cycle and in the introduction of fast zero-page instructions. So it's multiple things - as always ;-)
Wow, another iteration already! 😲 Very cool!
Very nice! :)
Just a heads up, your link is wrong for the Legacy Minimal UART CPU video
Oh thanks for pointing this out. Will correct it asap.
Very impressive! Love it!
I know it's not in your objectives, but some color could probably be achieved with hacks and a palette control, just like some early home computers did it.
The easiest thing would probably be changing the color of the output to something else (e.g. all blue/black instead of all white/black), followed by a doing groups of lines/columns in a different color.
I want 50 shades of amber.
Beautiful project. Love your work!
Thank you! Cheers!
What are the architectural differences that make the 64x4 twice as fast as your original "minimal 64" at the same clock speed?. I can't see that from just comparing your "CPU architecture" diagrams... Since you are not pipelining the CPU, is it just the addition of more instructions (so that some code may use fewer clock ticks to execute) which makes it faster, or is it something else?
3 Things: a. CPU clockrate went up from 6 to 8MHz. b. Way more efficient instruction fetch. c. Faster zero-page instructions for time-critical stuff.
@@slu467 Thanks for your reply. The Acorn ARM1 processor obviously was a totally different architecture, as it was a load-store pipelined processor, but interestingly the PC was set from MAR+1 not the opposite. The PC just follows MAR+1 unless it's a data memory access. This is possibly faster than attempting to use the PC to set the MAR. So in ARM processors the PC always points to the next instruction and that affects offsets in branch instructions. Assemblers and compilers must take care of that when generating branch instruction offsets because the processor itself does not compensate for that during instruction decoding
While your graph matches the commercial history of computing, you can get high performance out of TTA's and they minimize complexity at the *gain* of performance.
I think you should be able to remove the dependence of VRam from System Ram, thus releasing the 16Kb that are currently highjacked by VGA output.
So instead of writing to physical memory for the VREG to capture it, why not just output both the VGA pixel address and data onto a special port so that the VREG updates from that, avoiding completely the need to reserve these 16kB (from 0x4000 to 0x7fff) of system RAM?.
The advantage is of course that you get extra 16Kb of ram for general purposes, which is a whooping 25% of all available ram.
The only 2 drawbacks that I can think of are:
- The inability to perform "reads" on video ram, but that's rarely needed or even a bad programming practice if some code actually does it.
- The slightly slower updating of video ram, but that's probably negligible in real game scenarios given that most of the time the processor will be doing far more demanding computing tasks than just updating bytes to the VGA monitor.
Does this make sense?
Have to think about this. I consider reading back from VRAM quite important for doing pixel graphics, e.g. setting random pixels, drawing lines etc. The new pixel has to be ORed into the existing data byte...
@@slu467 In such case things certainly get a bit more tricky. My suggested approach is of course implementing VGA output as a sort of "graphic unit" to which the main cpu only sends commands. So if setting/clearing individual pixels must be supported maybe this can be done by specifying bit masks. That of course makes things more demanding on the side of such "graphic unit" because it must handle internal reads on its own video memory to honour such masks. Anyway, just a thought.
@@RelayComputer Yes, this kind of development is a continuous trade-off. Many different approaches come to mind. I went for minimal effort/complexity on the hardware side.
this is like a spiritual successor to gigatron lol
Well, it is a *very* different project...
As soon as you get Turing Machine, regardless of how simple, you can compute anything. It's just a matter of how fast your can cycle the instructions.
This is no Turing machine. You mean "Turing complete".
jAM-1 Is still the GOAT. that said nice project
Yeah, you are right -- but there's this performance-to-complexity-ratio thing and that jam-1 uses 1.3s for the Mandelbrot benchmark... ;-)
@@slu467 I'm biased. This really was/is a dope project but Jam1 has such a nice architecture...
Really great project loved it 👌. Would like to see how it compares to a 40 instruction rv32i riscv isa
Very exciting...I'm already occupied with Agon Light development, but I wonder how fast a Forth would be on it?
welcome back
It has been a while... but this stuff takes some much time to come up with...
What the estimated cost of soldering such awesome machine?
What sellers do you recomend buying the components? Im from Portugal
PCB and parts should be a around 100$. Only buy parts from trusted sellers of electronic components. Cheap copies often violate the timing requirements.
I don't understand gap between other with simmillar IPC count, do you have much faster RAM than old 8-bits ?
Yes, the RAM and FLASH I am using were not available back in the old days.
PCEngine has 7 MHz RAM.
A computer who cannot boot up with display 80 characters is not grown up. But great project !
Yeah, 52cols in 8x8 is about as good as it gets on the Minimal ;-) 80cols are nice for programming but a pain for games. The aspect ratio just looks off to me. I thought about an 80cols editor for the Minimal 64x4 using an 8x5 pixel font. But this is cheating and probably doesn't look nice...
@@slu467so this needs to be flexible, not minimal?
8:20 This "8-bit battle royal" cannot possibly be right. I guess the ipc and cpi values listed are some kind of weighted mean values? However, how can the eZ80 possibly have a higher clocks per instruction (4.03) than 6502 (2.33) when many eZ80 instructions execute in a single cycle, and very few takes as much as 4 cycles... Makes no sense.
I learned about 65ec02 which also only needs a single clock for a lot of instructions.
@@ArneChristianRosenfeldt Indeed, although that one is not on this list afaik. The 65EC02 also does this only for things like INX, CLC, etc, while the eZ80 can do a full 16-bit or even 24-bit addition in a single clock cycle.
This is amazing.
Glad you find this interesting. Cheers!
Bit random but is the value of R27 meant to be zero?
Yes, that is intentionally. There are rare cases where the 377 and 161 registers of the address inputs of the control ROMs differ in propagation delay. A nonzero R27 can then be used to slow down the 377 just a tad to avoid switching spikes. Never used it, though.
@@slu467 thanks
Truly an amazing project! I only have a question, its possible to push the speed? If this is based in logic chips, likely its possible to find faster ones and you would not need to add new chips
I'd rather not go down this rabbit hole. The timing has to support VGA (in a minimalistic way). It doesn't help to speed things up by 30% or something since that would mess up VGA timing.
@@slu467I hate the fixed timing on the C64. TED in the plus 4 can be sent to turbo mode using software. This is the way to deal with the dynamic hardware market back in the day and the different color clocks on the globe.
Was it possible to build that system in 80s? How much would it cost in that time?
It's the very large FLASH ICs that weren't available in the 1980s like they are today.
@@slu467I assume you could have used banks of programmable ROMS at the time if you were willing to pay?
Back up the truck, the Zilog Z80 is less complex and less performance than the MOS 6502? Perish the thought!
The 6502 is an early example of a more efficient multi-pipelined CPU while the Z80 is not. The Z80 has other advanced feature for sure, but it lacks this more modern achitecture.
@@slu467I measure complexity in terms of transistor count. Area for a given fab process. I think that embedded needs 8bit. Home computers need 16 bit address lines or more. Every coder wants flat memory. Paging is seen as complex and only accepted for cartridges , error correction sectors on CD.
Hey im building a computer for science fair/ fun and i was thinking of using a 6845 chip but i can't find much of any videos on it do u know anything about it?
People mostly didn't have videos to learn from back then, you know?
they generally worked from a good fundamental education in math, electronics, logic and read documentation (books, publications, etc)) on the chips to be used.
The 6845 is only for controlling the CRT controller (IIRC) and forms just one part of a graphics device.
What CPU are you using? The 6845 has a typical 6800 bus design and is really suited for a 6502 or 6800/6809/68000 computer, but if you are using an 8080/8085 or Z80, there are some hidden traps (as I found out in the hard way). If you have any more questions, simply reply to this comment.
Just to clarify: The Minimal 64x4 does *not* use any integrated CPU - lust logic chips. The "CPU" is built from scratch here.
6845 for video timing? Easy to get Motorola datasheet online. Beautiful document to read. I actually have one in the first graphics card I designed for my Nat Semi 32008 homebrew many years ago as a teenager... I used it mainly because it was the legendary 6845 and it actually was pretty good for versatile timing generation. Lots of "legendary" chips in my homebrew just because... Got it to work for PAL timing (although greyscale because a colour monitor would be unimaginably expensive to me) and some weird IBM terminal I rescued from a rubbish bin. There's a fair bit you need to do for a complete video solution though such as pixel shift register and DAC (I went cheap with a transistor and a bunch of resistors as I had no money). As well as how your CPU will play nicely with it and the memory system. I don't think I'd use one today as big cheap (compared to the old days) fast RAMs and EPROMs mean different but simpler ways of doing more interesting things.
@@slu467 But you still have a CPU, however primitive, it's just LESS integrated than a single silicon wafer and MORE integrated than using discrete transistors and diodes.
E Light
You did not list the most important of al 1980's CPUs, the M6809! Nothing was more beautiful until RISC-V.... The 6502 was cheap and limited.
I would say MIPS comes close to RISC-V, since RISC-V is based on MIPS, which was started back in the 80s. However, I do admit that 6809 is about as good as an 8-bit CPU can get. I have tried designing an 'optimal 8-bit Architecture' several times, and the end result is usually close to a 6809.
Unfortunately, the 6809 was quite expensive at the time and soon x86 and 68000 appeared, too. So it didn't get used in the mass market as much as the 6502. Still a nice processor.
@@andyhu9542 HEC you are right 😉
@@andyhu9542I just really miss it. I first learned BASIC on the TRS-80 Color Computer and then M6809 Assembly.. then C and others.. Writing my first few things in RISC-V brought back the memories.
I loved the 6809 but it certainly wasn't important. It was a failure in the market and I don't recall much other than the Tandy Coco and some mutant clone of CP/M...
naja ....
68000: 1.4Mips, 64x4: 1.5 to 1.8Mips, both @ 8MHz. Register bit width or mul/div support is of cause a different thing ;-) I love the 68000. Had so much fun writing assembly code on it back in the Amiga days.
Why are you hammering your keyboard like that? Applying more force to key presses will neither make you type any faster nor more accurately, so it has zero advantages but a lot of disadvantages, including faster wear of the keyboard and long term harm to your finger joints.
Thank you for pointing this out. I made extra sure you hear me typing 🙂
Maybe try running a unix-like on here. Neofetch on a 64x4???