Onno Kortman has taken semu, a minimal RISC-V emulator, and cross-compiled it with llvm-mos, an LLVM port to the MOS 6502 processor, in order to run Linux on the Commodore 64. Kortman writes: "The screenshots took VICE a couple hours in 'warp mode' to generate. So, as is, a real C64 should be able to boot Linux within a week or so."
Very nice, but my first thought was "surely this will not fit in 64k of ram!". And it doesn't. It requires a 16MB REU!<p>To explain for the uninitiated how rare this bit of hardware is. The REU available for the c64 back in the day were 256kB and 512kB. These are most commonly built replicas as there are schematics available for them. Sometime in the late 90s there was also an "expansion" for c64 that contained a completely new CPU (superCPU - 65816) that was code compatible with the original and I believe this device could accommodate up to 16mb.<p>Later reimplementations based purely on fpga popped up including a REU with 16mb. The original SuperCPU schematic was lost to time. Allegedly fpga based expansions are available to buy for few hundred EUR now, but I don't know anyone that attempted to buy one or has one.<p>So, although it is a neat trick(still a cool tech achievement) , saying it runs on c64 is akin to saying I got doom3 running on a 386, but my 386 is actually a pci card in a modern pc...<p>If I can't pull my c64 with hardware available back in the day (or hardware one could realistically built back in the day) I'm not sure saying "runs on c64" is correct.<p>Coming back to the subject of a REU, why has no one published a schematic for one yet? There are cheap SRAM chips floating on ebay. It should be trivial to put one together. Unfortunately it isn't, because the original (Super Cpu) had two components we need a beefy fpga to emulate. The supercpu itself and it's dma controller which was a custom asic I believe.<p>Perhaps as cheap(ER) fpgas or uC with fpga-like functionality become available someone will create an open source "super cpu". As of yet, everyone I ever heard using these, uses emulation. Nothing wrong with that, but I get the most out of my "retro hobby" by running original hardware. Emulation is very useful for dev, but for general use it's a bit "meh" for me.
Not Linux related, but I've been trying trying recent (at least to me..) C-64 accessories:<p>I've tried the "Kung Fu Flash"- it's a software defined cartridge that is cheap- just a single STM32 and can do pretty much everything. I bought this because I'm trying to duplicate the developer experience I see on "8-bit show and tell"- it can emulate the "super snapshot", but not the REU. It's a really nice way to quickly try a lot of C-64 software and games.<p><a href="https://8bithardware.wixsite.com/website/post/kung-fu-flash" rel="nofollow noreferrer">https://8bithardware.wixsite.com/website/post/kung-fu-flash</a><p><a href="https://github.com/KimJorgensen/KungFuFlash">https://github.com/KimJorgensen/KungFuFlash</a><p>I also have an SD2IEC: what I've learned is that it would have been useful to get a variant with an extra DIN socket. It's nice but I was never a fan of C-64's DOS and this reinforces it. To mount a D64 disk image you have to: OPEN1,8,15,"CD:MYIMAGE.D64":CLOSE1... yuck..<p>JiffyDOS (replacement ROM for the C-64) improves this (it's faster and includes a permanent DOS wedge), I bought one- it's on the way. I'm curious to try it with the real 1541 drive.<p>What got me started on this recently is the "Penultimate +2" cartridge for the VIC-20:<p><a href="https://www.youtube.com/watch?v=eNGyneXHKJQ">https://www.youtube.com/watch?v=eNGyneXHKJQ</a><p>In this case, I basically bought a VIC-20 just to try out the cartridge.
A demonstration of Turing equivalency. Any Turing complete computer can do what any other Turing complete computer can do if you don’t care about time.
Is this different from Lunix?<p><a href="https://en.wikipedia.org/wiki/LUnix" rel="nofollow noreferrer">https://en.wikipedia.org/wiki/LUnix</a>
This isn't Linux running on C64 per se. This is C64 emulating a RISC-V environment on which Linux runs.<p>Still impressive of course, but semantics matter :)
I wonder, if instead if requiring REU, it could work by using a few dozen floppy discs as RAM, prompting the user to swap discs as needed.<p>I’d be interested in watching a time-lapse video of that on real hardware, if someone has a couple of months/years to spare. ;)
I recently came into possession of a fully-functioning TRS-80 Model 4, and I fantasize regularly about putting some vaguely Unix-esque thing on it. The fantasy continues.
Minimal FORTHs (<a href="https://en.wikipedia.org/wiki/Forth_(programming_language)" rel="nofollow noreferrer">https://en.wikipedia.org/wiki/Forth_(programming_language)</a>) can run on an unexpanded VIC-20 (5K) or even early TRS-80 Model 1 (4K) -- with room and functionality to spare...<p>On the VIC-20, you even get a few colors!
That 16MiB memory requirement makes this rather disappointing, given that you can run Linux on machines with only 4 MiB of RAM: <a href="https://tldp.org/HOWTO/4mb-Laptops.html#toc3" rel="nofollow noreferrer">https://tldp.org/HOWTO/4mb-Laptops.html#toc3</a>
Now someone needs to do the same with a ZX spectrum ;-)<p>As others have mentioned, a 6502 is very poorly suited to C-style code, but a Z80 should be somewhat better with that.
So, I like Linux and I love my C64, but.. Linux are for computers too primitive to come with their own kernel and.... the C64 comes with a kernel and shell right from the factory :P