_UnPrEdictAbLe_

All that you need to find out about what am I upto.

Archive for the 'My operating system' Category


Another OS brainstorm(?)

Posted by Anurag on 25 October, 2007

I feel that my brain is heating up from inside, too much thinking going on lately! I wish there was an ‘off’ switch which I could press so that I leave all worries and thoughts. Well, there is this ‘die’ option, or ‘drugs/drinking’ option, but then I prefer neither. The first option, well, of course is like a permanent solution, but there is no ’switch on’ after it. The second option … well I decided to never use it.

I am going home on this 31st evening. A lot of wrapping up to do, I want to buy presents for my family members as a token for the first money I’ve earned (that comes under ‘taxable’ income ;)). And then, I’ve this OS thought process going on, and I need to plan in advance for the coming holiday, how will I utilize the time as well as give enough time to people there.

Office work is going on as usual, but the workload since TODAY has been unusually low. So, all day I’ve been reading articles about operating systems. Most of which say that Linux is a clone of a 30 year old system, UNIX. And a lot of them say that most OSes are based on the three tier thing, kernel, files/folders and processes. We must change this to something that is shown in hollywood, no windows nothing, just some vague interface to get the information we want. This thought is influencing me a lot.

Another thought that comes to me is the ease of use of the existing systems. If we were to shift to a vague system with no “Firefox”, no “Windows Media Player” (eh, “MPlayer”), no “Start menu” (eh eh, “K Menu” (eh eh eh “Gnome’s whatever menu”)), and whatever application you used to like! Well, it might take a decade for people to finally accept (if ever) such a thing.

Then there are people who ask to ‘do-away’ with GCC. Does that mean we need to implement another compiler? How can anyone not port ‘GCC’ to their OS (except Microsoft)? And people ask us to do-away with C! Imagine coding a new OS with D, and writing a compiler for it along with the OS! If we do port GCC, then how will GCC run if we’re not basing upon ‘kernel, files and processes’? Yeah, the C code we write can work the way we want, but GCC needs to run on ‘files’ and write ‘compiled binary files’. Also, the gcc executable and shared libraries are also ‘files’ stored in a specific ‘directory structure’. And all the C code which we write is ‘files’. How can the compiler survive in an environment that gives up this basic structure?

A way of doing it would be to create ‘emulation of kernel/files/processes’ in the new OS. The compiler will run in this emulated environment and spit out binary ‘files’. There should be some way of running ‘files’ created by GCC on the new OS, which supposedly wont support ‘files’?  The idea seems wierd, apart from creating an overhead of an emulator for the existing structure of computer systems. Maybe a little more pondering on it can give some clearer picture. Rather, the method should be, what will be the new structure? And then later we can answer other questions of compatibility with existing structures and porting applications.

I know I am talking really wierdly these days, but then, my knee injury has really damaged my ‘brain’ (My wound has fully recovered now!). Anyways, I’ll keep posting more on this. For the ‘conventional’ OS development talks, which I keep writing as and when I read more and more, I’ve created a wiki, http://myos.scribblewiki.com/Main_Page. Do visit to read more, and all wierd thoughts will find place in this blog, hehe.

Ciao.

Posted in Life in Bangalore, My operating system, Thoughts | 4 Comments »

Dream Operating System

Posted by Anurag on 14 October, 2007

Anyone who is remotely related to programming, internet and such has a dream to create something of his own. Often this dream is of creating a new Operating System of their own. An operating system that will be faster than any other, will support everything and will have so many features that it’ll outnumber Windows XP in its user-base!

Yes, its close to impossible to outnumber Windows XP user-base or even Free BSD for that matter ;). Yes, its close to impossible to make something faster than them and still support as much as they do! Yeah, you can make a ‘hello world OS’ which is zillion times faster than any other, but whats the use?

Ok, all this was to build up a platform to talk to you. Well, just like ‘everyone’, even I have dreams. And they never become concrete, only day-dreams of all that I said before :D. But then, I realized that I wasted some 8 years in just dreaming! I didn’t take the next step which generally ‘human beings’ take. Thats how the human race has progressed from apes to what we are now, ‘mobile apes’ :D.

Anyways, so basically, till now I was a dumb day-dreamer like a couple of million more, when this angel came and told the golden words in my ear, … “IDIOT! START TOH KAR” (means, Idiot! Stop dreaming and start something). And then, me, following her words began to look in the world around me.

Coming to the point directly after all this drama, the straightforward deal is Tanu asked me to do something in this regard, and I began reading about OS development, and trying out ’something’ ;).

Ok so the next FAQ looks to be, ‘So have you begun your own OS?’. Dude, chill, Microsoft Inc. took five whole years before they could change these lines :D

printf (”Welcome to Windows XP\n”); to printf (”Welcome to Windows Vista\n”);

So, its not that simple as it sounds in the dream world. At least the 80X86 processor is not as simple as it should have been. And then there are other mental blockages for me. Here is a list,

1. Why make another *nix clone? Why not something new?

2. Everything is a file, umm.. *nix concept, I want something original, WHAT?

3. Copy windows? Uh, not even in my dreams :P

4. Why C? Why not my own D or E or F or G? Do I need to write another compiler :O

5. Why OS? What happened to web-dev and python scripting? And eh, computer vision?

6. My own filesystem or new? Why old? Why not be ‘readable’ by others? Linux also did ext2, why not me do my own AFS or something?

7. Ok, so if I use C, how do I write my kernel? I don’t even know much about it!

8. Uh, all this GDT, IVT, IDT, Page table, Multitasking, PCI, A20 line, and every damn thing has a hundred configuration settings. Am I enough or I need help?

So, basically I didn’t reach all this just by beginning. First I encountered Viral Patel (http://www.viralpatel.net), who is a anti-ME. He actually made a fully functional ‘CLOSED SOURCE’ OS, called Taj OS (named after Taj Mahal).

Then I reached www.osdev.org, which is a whole portal dedicated to help people like me try their hands on some OS development. It lists more than hundred hobby operating systems developed by people, many of which are open source and closely resemble *nix or DOS. The site has extensive tutorials for all aspects of OS development, with some holes left, which I might fill up one day.

I started using ‘nasm’ compiler to write initial bootable code in assembly. Using ‘vmware’ to keep it ’safe’, I booted the first few experiments, and with the help of Fedora Core 7 rescue DVD, I installed the bootloader onto the ‘virtual vmware hard disk’. So, now my small bootable assembly program can boot from a disk, read the keyboard and display messages! Cool for a start, at least I can feel that :D. Ofcourse, that hard disk will be able to boot my OS (rather boot code) and nothing else, even if we try GRUB.

Now, my next tasks are to read this book, THE INTEL MICROPROCESSORS (750 pages :() by BARRY B. BREY and C. R. SARMA (Rs. 299 only :D). And then I’ll have a better clue of the things that are happening. Then I might decide to begin some design of an OS, if I still have interest left. I also read the source-code of Ace OS (1.0 and 2.0), DEX OS 1.1, which are small operating systems, written in C and are somewhat understandable. Viral’s OS doesn’t run on my vmware and I don’t have a floppy drive, :D.

Ok, maybe I am thinking too high, but if I make one, I won’t make a ‘floppy OS’ for some DOS work, I’ll make a real installable OS with a CD setup and a hard-disk GRUB compatible install. I might not remain compatible with *nix, so maybe it’d be difficult to port Linux applications to it, but I’ll maybe write some of my own!

Right now, all this is a distant dream, but gladly the first bricks have been laid. And soon, when I am on the same level as other OSdevers (term for OS developers), I’ll come up with some concrete thing to write here.

Created a new page to log my knowledge and status on this issue.

Any comments are welcome. Any people interested in development can discuss with me, learn and share. But right now, as there is no ‘development plan’, there is no ‘development team’. Though, I will need more people by my side when I really go into doing it. And as you know, that there is no plan, YOU can affect the plan, and YOU can make it your plan. So, like me, you wont have hesitation in joining me when we actually begin work, because it’ll be YOUR OS too!

More information soon. Cheers!

PS: I fell from the bike, injured my knee, so maybe some cells in my ‘brain’ have been killed or altered, so I am thinking wierdly these days. Operating system and me, really huh?

PS2: Am perfectly fine guys, just an injury on the knee, so thanks for being concerned, but don’t worry, I’ll be ok.

PS3: HA HA HA, ok fine so you are not concerned, neither am I concerned about your concern ;).

PS4: Someone ask me to shut-up yaar!

Ok bye then. Take care.

Posted in Hardware, Linux, My operating system, Project work, System software, Thoughts | 7 Comments »