68kMLA Classic Interface

This is a version of the 68kMLA forums for viewing on your favorite old mac. Visitors on modern platforms may prefer the main site.

Click here to select a new forum.
Unix for 8-bit Apple
Posted by: ChristTrekker on 2009-09-01 13:24:58
Anyone heard of LUnix? Unix on a C64 - page seems a bit old though. And uCLinux ideas might be helpful about getting around lack of MMU.

EDIT: Doh...didn't remember that LUnix had already been posted early in this thread.

Posted by: H3NRY on 2009-09-12 22:33:02
The //e doesn't have an MMU. There are just soft switches, addresses in the $C03x range you hit to switch banks of RAM. Works the same as the Language Card on the Apple][.

About the closest to Unix anyone ever got was Anix or Anux, which consists of the RWTS portion of DOS 3.3 and a few commands which load from disk and have a Unix-y flavor. No networking, no multitasking, no VM, no remote console, and not developed enough to even use as a base for applications. I worked with a guy once who was a fresh UCB grad and Unix whiz who thought he would base an industrial control system on Anix. He struggled mightily for about a month and gave up. In the end he used DOS and Applesoft, much as it hurt his vanity.

Unix may not be impossible on a 6502, but you'll find it a real challenge. Akin to going 160 MPH on a flat-head Indian. Speaking of hopping up underpowered machines, there are 68000 CPU cards that go in an Apple//e slot. Run the kernel on one of those and the UI on the 6502?

Posted by: barana on 2009-09-12 23:21:03
Anyone heard of LUnix? Unix on a C64 - page seems a bit old though. And uCLinux ideas might be helpful about getting around lack of MMU.
EDIT: Doh...didn't remember that LUnix had already been posted early in this thread.
I know of someone who was melding 2.6 kernal and uclinux together to boot on an A500.

and yes i know exactly who it is. he was coming along nicely.

Posted by: Dog Cow on 2009-09-13 10:36:55
The //e doesn't have an MMU. There are just soft switches, addresses in the $C03x range you hit to switch banks of RAM. Works the same as the Language Card on the Apple][.
Well, it does. That's what Apple calls it. But it's not the same as everyone else's MMU.
Unix may not be impossible on a 6502, but you'll find it a real challenge. Akin to going 160 MPH on a flat-head Indian. Speaking of hopping up underpowered machines, there are 68000 CPU cards that go in an Apple//e slot. Run the kernel on one of those and the UI on the 6502?
Since starting this topic, I've decided to set my goals lower to a simple task-switcher. Much easier, and there have already been some written.

Posted by: Nathan on 2010-04-23 16:44:03
Considering the relatively open design, someone could probably make an MMU card for the Apple. Although you might only be able to effectively use memory that was only addressable by the card. You'd probably need some software to make all the hardware access it's memory through the card though I assume.

Posted by: ClassicHasClass on 2010-04-24 09:31:40
The other approach is to simply virtualize the 6502. This is not as ludicrous as it sounds, but it is definitely slower. OTOH, by making stack and the virtual memory manager software, you can make them do anything, and you can always pre-emptively interrupt a virtual processor. To wit,

http://www.floodgap.com/retrobits/kim-1/emu.html

It runs on an unmodified Commodore 64.

Posted by: Dog Cow on 2010-04-24 10:12:40
...and we've already got a Java VM for the Apple II, so we're all set.

Posted by: Gorgonops on 2010-04-25 10:08:41
No, it was 16bit but could address 256Mb of memory with 18 address lines. A 6502 has 16 address lines but that doesn't make it a 16bit computer. If you went by that argument an 8086 was a 19bit computer and an 8088 was a 20bit computer.
Not to pointlessly nitpick a really old statement in a zombie thread, but... sure, why not, I'll nitpick an old statement in a zombie thread.

I think Porter is confusing the PDP-7 with the PDP-11. The PDP-7 was a genuinely old-fashioned 18 bit machine, descended from the PDP-1 architecture. (It was basically a cheaper and faster PDP-4, which in some respects was a *simplified* PDP-1) What made it "old fashioned" was that it had no general-purpose registers and a relatively tiny instruction set with 16 opcodes and only a 13 bit "direct" addressing range. It had some "interesting" features compared to similar machines of the age which made it better suited to real time/multitasking than other more batch-oriented "small computers", but it's really a different animal from just about any microprocessor-based computer.

The PDP-11, on the other hand, was a solidly 16-bit machine. They all had 16 bit direct addressing, but "real" UNIX was limited to the PDP-11/45 and larger systems which had a segment-based MMU which expanded physical addressing to 18 to 22 bits. (A "Mini-UNIX" was available for the smaller models, but that lacked any form of memory protection.)

In some respects the closest microcomputer analog to the fully UNIX-capable PDP-11 models is the Intel 80286. The addressing model is similar and the 80286 has a capable-enough MMU to fully allow for virtual memory and swapping. (Keep in mind the reason that Bill Gates called the 80286 "brain-damaged" was that it didn't include a facility for virtualizing "real mode", and thus couldn't easily multitask existing DOS programs. If DOS is off the table it's a quite capable CPU by... late 1970's standards.)

< 3