Posted 14 February 2014 - 12:58 PM
In my naivety (and lack of looking at this forum), I somehow thought a multitasking CC operating system that supports native CraftOS programs would be something new and interesting. Much to my surprise (not really), it isn't. Anyway, as a result, I've spent the last few days making KAOS.
KAOS accomplishes multitasking by sandboxing the default CraftOS shell, while intercepting events and API calls. KAOS-aware programs (such as the included task manager) may reach out of the sandbox and interact with the other processes and more.
I think I've managed to iron out most bugs, so it should be relatively usable by now. KAOS is pretty lightweight in its current state, and it doesn't ship with anything other than the "kernel", a couple of system services and the aforementioned task manager. It also currently does not support shutting down - calling os.shutdown() will simply exit the active process. It does support rebooting, though.
KAOS doesn't have window management and all process currently take up all (well, most of) the screen when they are active. As awesome as some of the windowing OSes are, I feel that it's a somewhat pointless exercise considering the screen is already very small and that native CraftOS programs will never support window resizing.
Here's a screenshot of the startup screen. If you click the white bar at the top, it will switch the active process to the KAOS System Service.
Here's the KAOS System Service. When processes crash, error messages will be posted here. Clicking the white bar again will spawn a new shell process.
Holding Ctrl+T will no longer send a terminate event. Instead, it will launch the Task Manager. "Switch To" will switch to the selected process. "Kill" will end a process. "Terminate" will send a classic terminate event, which is useful for shells running CraftOS programs that won't close. "Cancel" will switch back to the previous process. KAOS has a hard limit of 256 processes, but I didn't implement a scroll bar in the Task Manager yet, so managing them might prove difficult at the moment.
If the shell is closed by a terminate event, it is currently considered a crash because it ends the process with a call to error().
Here's a demo of a shell running the paint program, because why not:
To install KAOS, run the following. Be aware that it will replace your startup script.
If you are interested in how KAOS-aware processes work, I suggest taking a peek at the included programs (in /kaos/programs and /kaos/system) and perhaps even the kernel, if you're feeling brave.
That's it for the initial pre-release. I hope someone will find a use for it. I will probably continue to work on it, so all feedback is appreciated.
KAOS accomplishes multitasking by sandboxing the default CraftOS shell, while intercepting events and API calls. KAOS-aware programs (such as the included task manager) may reach out of the sandbox and interact with the other processes and more.
I think I've managed to iron out most bugs, so it should be relatively usable by now. KAOS is pretty lightweight in its current state, and it doesn't ship with anything other than the "kernel", a couple of system services and the aforementioned task manager. It also currently does not support shutting down - calling os.shutdown() will simply exit the active process. It does support rebooting, though.
KAOS doesn't have window management and all process currently take up all (well, most of) the screen when they are active. As awesome as some of the windowing OSes are, I feel that it's a somewhat pointless exercise considering the screen is already very small and that native CraftOS programs will never support window resizing.
Here's a screenshot of the startup screen. If you click the white bar at the top, it will switch the active process to the KAOS System Service.
Spoiler
Here's the KAOS System Service. When processes crash, error messages will be posted here. Clicking the white bar again will spawn a new shell process.
Spoiler
Holding Ctrl+T will no longer send a terminate event. Instead, it will launch the Task Manager. "Switch To" will switch to the selected process. "Kill" will end a process. "Terminate" will send a classic terminate event, which is useful for shells running CraftOS programs that won't close. "Cancel" will switch back to the previous process. KAOS has a hard limit of 256 processes, but I didn't implement a scroll bar in the Task Manager yet, so managing them might prove difficult at the moment.
Spoiler
If the shell is closed by a terminate event, it is currently considered a crash because it ends the process with a call to error().
Spoiler
Here's a demo of a shell running the paint program, because why not:
Spoiler
To install KAOS, run the following. Be aware that it will replace your startup script.
pastebin run s7itaxPE
If you are interested in how KAOS-aware processes work, I suggest taking a peek at the included programs (in /kaos/programs and /kaos/system) and perhaps even the kernel, if you're feeling brave.
That's it for the initial pre-release. I hope someone will find a use for it. I will probably continue to work on it, so all feedback is appreciated.
Edited on 14 February 2014 - 01:42 PM