Jump to content




What makes an Operating System


  • You cannot reply to this topic
34 replies to this topic

#21 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 28 March 2013 - 04:16 AM

As quoted before, here is the proper, and commonly accepted definition of an Operating System:

Quote

An operating system (OS) is a collection of software that manages computer hardware resources and provides common services for computer programs. The operating system is a vital component of the system software in a computer system. Application programs usually require an operating system to function.
Source
Let's go over the main points of that shall we?
  • "Manages computer hardware resources"
    • This is part of the OS built into CraftOS. The functions and APIs built into the BIOS allow code being executed to control different peripherals, as well as output signals. We have modems, disk drives, peripheral cables, and even other computers as being hardware that the OS can control and access.
  • "The operating system is a vital component of the system software in a computer system"
    • Without the CraftOS, you would have to interface directly with the core code of the system which is the BIOS. Definitely possible through creatign new programs to replace everything, but not preferrable. You could liken this to removing the operating system on your computer, and accessing the hardware directly through the BIOS of your computer.
  • "Application programs usually require an operating system to function"
    • Again, without CraftOS, you would have a very difficult time doing anything. You would have to write your own directories, your own input system, and your own output system to determine what is happening after you execute code.
So before you go off the handle, it is entirely possible to write a completely new operating system in ComputerCraft. Please don't be so close minded because of your programming skill shortcomings. I would never attempt to write an Operating System, because I am nowhere skilled enough to write one without causing problems.

#22 Tiin57

    Java Lunatic

  • Members
  • 1,412 posts
  • LocationIndiana, United States

Posted 28 March 2013 - 04:28 AM

I'm sorry, but I have to butt in here obnoxiously.

View PostCranium, on 28 March 2013 - 04:16 AM, said:

Your source is Wikipedia? I honestly trust Wikipedia, because the moderators on there are so quick (Lochie says he's one of them, IIRC), but no one else seems to. Credibility is key, young grasshopper.

#23 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 28 March 2013 - 04:59 AM

Yes. That's my source. I go there when I want a quick definition. If I want some actual research, I'm going to go to a more established resource like a library. Wikipedia is not always right, unless it is just a simple definition.

#24 Pinkishu

  • Members
  • 484 posts

Posted 28 March 2013 - 07:00 AM

View Posttiin57, on 28 March 2013 - 04:28 AM, said:

I'm sorry, but I have to butt in here obnoxiously.

View PostCranium, on 28 March 2013 - 04:16 AM, said:

Your source is Wikipedia? I honestly trust Wikipedia, because the moderators on there are so quick (Lochie says he's one of them, IIRC), but no one else seems to. Credibility is key, young grasshopper.

I somehow doubt theres an "official" definition and "requirements book" for the term Operating System

#25 PonyKuu

  • Members
  • 215 posts

Posted 28 March 2013 - 08:30 AM

Cranium, the main question was, what is the point? For fun? That's indeed acceptable, but is there some conditions when you need to write such a huge piece of complex code for practical usage?

#26 MysticT

    Lua Wizard

  • Members
  • 1,597 posts

Posted 28 March 2013 - 08:59 AM

View PostPonyKuu, on 28 March 2013 - 08:30 AM, said:

Cranium, the main question was, what is the point? For fun? That's indeed acceptable, but is there some conditions when you need to write such a huge piece of complex code for practical usage?
Well, I do it for fun more than anything (I think all of us are here for that, this is a game after all :P). But the idea is to provide an environment that helps the user in whatever he wants to do. This can be anything like having an easy to use shell (in this case, most people won't consider it an OS if there's nothing more than that), some apis to help you make programs easier, adding multitasking, etc.
So, the os is essentially the interface between the user or the user programs and the computer.

Things that are NOT Operating Systems:
A startup program that just shows a loading screen with some text (this is not even usefull).
A collection of programs/apis. They are just that, a collection/pack of programs or apis, no matter how good or usefull they are.

This is different from real life OS's, but CC computers are different from real computers, so why should they be the same?

This is just my opinion, and I would like to hear if someone has a different one.

#27 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 28 March 2013 - 02:43 PM

I think that for something to be considered a true CC OS, it has to handle things with the peripherals and the input/output in a different way than is currently in CraftOS. If you were to write a new protocol for computers to talk over rednet, while sharing files, and being able to do so in the background, it would be nice. This is one thing you can do to make an OS of your own. Make something that drastically changes the way that all of this is handled. This would of course mean a rewrite of almost everything in CraftOS, but that's the point.

#28 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 28 March 2013 - 03:18 PM

Based on what you have said, Cranium, removing CraftOS would essentially be a Lua promt. Therefore, as most 'OS'es don't use Shell programs, one could say that a ComputerCraft OS, is technically and 'OS'. Now, there are some better examples that others. I would consider anything that is not part of the editable APIs part of CraftOS (the colours api, for example). In terms of hardware, in our case peripherals, that is (base on my deffinition) bios managed. Therefore, most of the 'OS'es do manage their hardware.

#29 Mailmanq!

  • Members
  • 123 posts
  • LocationI am omnipresent... DUH

Posted 28 March 2013 - 03:36 PM

Can we just let people make the 'OS'es and let me feel stupid because they are way smarter than me and made something cool? I don't really care if the name suits it or not. For example, lets take PearOS, because it looks cool, PearOS sounds way better than Pear Fancy Program Runner n' Things. Actually the latter sounds pretty cool, but anyway it doesn't matter the name. A computer craft computer as MysticT said are way different from real computers, so why treat them as so. The idea of an OS is drastic changes to how things are done in ComputerCraft, generally on the input side though. Input, is very crucial... oh wait, I started rambling on again.

#30 Cranium

    Ninja Scripter

  • Moderators
  • 4,031 posts
  • LocationLincoln, Nebraska

Posted 28 March 2013 - 03:44 PM

View Postoeed, on 28 March 2013 - 03:18 PM, said:

Based on what you have said, Cranium, removing CraftOS would essentially be a Lua promt. Therefore, as most 'OS'es don't use Shell programs, one could say that a ComputerCraft OS, is technically and 'OS'. Now, there are some better examples that others. I would consider anything that is not part of the editable APIs part of CraftOS (the colours api, for example). In terms of hardware, in our case peripherals, that is (base on my deffinition) bios managed. Therefore, most of the 'OS'es do manage their hardware.
Not so! I mean that if you took away the everything, you can still rewrite the entire OS to your liking. You can build the system from the ground up. The only limitation you would have is the sandbox that ComputerCraft is written into with the Java code. You can get rid of all of the programs in ROM, and you are only left with the open sandbox that is available through java. Many of the APIs in ComputerCraft aren't even necessary for its basic functionality.

#31 Imagine³

  • Members
  • 4 posts

Posted 29 March 2013 - 01:59 AM

Can I ask why you said "not only for linux"

#32 gamax92

  • Members
  • 157 posts

Posted 31 March 2013 - 05:08 AM

People tend to think that linux is the only os that has a kernel and that one is not needed. Yet many OS have a kernel, Linux, OS/2, Windows, Windows 3.11 even, MSDOS, etc. They all have kernels.

Also, I'm restoring the original post. A majority of the post has been restored thanks to the quotes and Google Cache.
----
Oh and btw, CraftOS is the bios.lua, its not /rom/programs/shell.

Taking off the /rom/programs/shell only leads to the shell api being missing.
Removing bios.lua makes us loose all the patched Lua api's but we still have the api's from LuaJ
We still have Term api, Fs api, Redstone api, Peripheral api, Os API, HTTP api, and the BIT api because all of those are written in the java side of ComputerCraft.

Without CraftOS which is bios.lua, we still have a bunch of things to work with.

I'm not saying "To make an operating system, you need to make your own bios.lua" but you can take over the majority of CraftOS and manage it like it is the hardware.
Infact if you really wanted to, you can exploit your way into the bios to take over, but thats a different story.

#33 Unit158

  • Members
  • 7 posts

Posted 01 April 2013 - 08:09 AM

http://wiki.osdev.or...anded_Main_Page

Some things on here should help explain how to make a good operating system. I know it is for actual computers, but the design knowledge and most of the principles can still be applied to computercraft.

#34 Kilobyte

  • Members
  • 122 posts

Posted 06 April 2013 - 01:56 AM

Another note:
On a cosole based computer you usually have these components:
1. BIOS

The bios is hardcoded and does stuff like the self-test or looking for bootable medias. In CC this is represented by The Java Part.

2. The Bootloader.

Its usually located in the MBR of the first partition of the First Harddrive, Its loaded by the bios. Its tasks are to actually launch the kernel.possibly after asking the user to select one. In CC This is part of the BIOS.lua

3. The Kernel

The kernel loads modules and drivers, then provides an interface for applications while restricting their rights (more or less). if the OS supports Multitasking it also distributes recources over the different processes/threads. This is again part of bios.lua for cc

4. The Shell

The shell is just a regular program, usually running with same permissions as any other program. its task is to give the user an interface so he can actually work with the computer. on linux this usually is /bin/bash or /bin/sh by default, for cc its /rom/programs/shell. The shell itself is no part of the OS.


An OS is not just an API/library. at the same time its not just a program. An OS usually runs in the background all time, with more or less stuff to do. (even in CC theres always a task in the background: rednet.run() it manages the modem <-> rednet api mapping.

I hope this was helpful. (yes, lots of redundand stuff, but i think its a more clear definition)

#35 FuuuAInfiniteLoop(F.A.I.L)

  • Banned
  • 435 posts
  • LocationThe left part of this post

Posted 15 April 2013 - 11:31 AM

One thing more to add: Kill CraftOS or you are not a real OS

http://www.computerc..._40#entry110382





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users