Remix.run Logo
▲ jonstewart 3 hours ago

The Apollo Guidance Computer had 4KB of RAM and 16KB of ROM. Can you write a scheduler that would execute 8 programs related to landing on the moon in 4KB?

▲da_chicken 2 hours ago | parent | next [-]

An asynchronous scheduler with task priority, interrupts, and real-time response. That goes on a spaceship with less than 70 Watts of power available for the computer. That weighed about 70 pounds. When there has never been that sort of a multi-tasking computer controlled avionics before.

At a time when the contemporary computer systems that used asynchronous, priority-scheduled multitasking operating systems were things like IBM OS/360 mainframes and DEC PDP-6/PDP-10 minicomputers.

It was like having an Apple II in mid 1960s with double the word size.

▲Gibbon1 an hour ago | parent [-]

I used san RTOS written in assembly for the Atmel AVR. AvrX (by John Barello)

You can look at the code here.

https://github.com/kororos/AvrX

Compiles down under 2k.

The thing is while actually doing that isn't crazy hard, they did that with hardly any existing examples to go by. And without modern tools.

▲bronson 3 hours ago | parent | prev [-]

And it ran at 0.043 MIPS. Each task would get maybe 5000 instructions per second, minus scheduler overhead.