This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
makerimages's profile picture

OS making related 2 questions

Started by makerimages, 20 July 2012 - 04:55 AM
makerimages #1
Posted 20 July 2012 - 06:55 AM
exactly how do you write a CC os? and how to make the disk install the files to the computer??

thanks
PatriotBob #2
Posted 20 July 2012 - 07:56 AM
The current bios.lua isn't exactly geared towards that….
You could just hijack the startup script and put your "OS" in a subdirectory (/os) or some such… but that's less than ideal.

To do it right you really should rework the bios.lua your server to be more flexible in it finding a boot loader.

But to answer your question…
It's easiest to put all the files your os needs on a floppy disk sub directory.
Then in the root directory of the disk… put a startup file.
The startup file should copy the os files to the main partition, copy the os startup script to the root of the main partition and eject the disk.

This will allow you to walk up, insert the disk, Ctrl+R to reboot, and then computer will install the OS and eject the disk at your face.