Notes for abstracting the OS from the machine - djragsdale/OSJS GitHub Wiki

The machine should be a javascript class. It contains private methods bit[] read(bitLocation(int), length(int)), void write(value(bit[]), bitLocation(int)), bit[] resolvePointer(int bitLocation), and void register(tag(char[8]), value(bit[])). It contains public methods void interpretAssembler(codeLines(string[])) and {name(string):bitLocation(int)} getInterrupts(). OSes utilizing it should contain utility functions leftPad, charToBitArray, and malloc to help with memory allocation.