How long will it take to complete an OS????

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply

How long will it take to code a basic OS with Hard disk access, from scratch???

1 day(eccentric)
1
7%
1 week(you r a perfect programmer)
1
7%
1 month
2
14%
3 months
10
71%
 
Total votes: 14

User avatar
mahesh
Posts: 2
Joined: Sun Nov 04, 2007 9:26 am

How long will it take to complete an OS????

Post by mahesh »

This is not about a "COMPLETE" OS, but a basic OS with hard disk access, keyboard drivers, CUI interface etc...
Craze Frog
Member
Member
Posts: 368
Joined: Sun Sep 23, 2007 4:52 am

Post by Craze Frog »

More!
User avatar
AndrewAPrice
Member
Member
Posts: 2309
Joined: Mon Jun 05, 2006 11:00 pm
Location: USA (and Australia)

Post by AndrewAPrice »

It depends.

Starting off (i.e. writing your first operating system kernel) then 3 months to a year.

An programmer writing their 5th kernel could probably whip up something in around half a week (reusing a lot of their previous code).

What exactly do you mean by "hard disk access"? Reading individual clusters? Or loading programs off a disk (file system drivers, ELF parsing, page management?)
My OS is Perception.
User avatar
JamesM
Member
Member
Posts: 2935
Joined: Tue Jul 10, 2007 5:27 am
Location: York, United Kingdom
Contact:

Post by JamesM »

I've been working on mine (3rd reincarnation from scratch) since the beginning of July and ignoring my recent shakeup of syscall and IPC interfaces have:

GNU bash ported (so that counts as your CLI)
newlib ported (c library)
keyboard driver etc (comes as standard with the TTY server)
hard disk access is done. I have work to do on the sector cache and also some bugs to fix in the ext2 implementation (read only atm).

I have a shedload of other less obvious things as well, including (NEW!!!) an almost capabilities based syscall and IPC interface. To make (most) syscalls a process requests a resource and performs a call on it. The resource maps in kernel space to a C++ class. Processes can now also create resources (and can be named, if required) so other processes can call functions on them remotely (my primary method of IPC). Ph33r.

I have been coding OSs as my main project (talking an average of ~1h per day every day, ~3 h per day I actually worked on them!) since October of last year. So if you have that sort of commitment you can make an OS in just < 6 months if you really want to.

Your timescales are waaaay too short though, writing an OS is possibly the hardest project you can embark upon.
jal
Member
Member
Posts: 1385
Joined: Wed Oct 31, 2007 9:09 am

Re: How long will it take to complete an OS????

Post by jal »

A real-mode 16 bit OS can be done quite quickly, using INT13h for disk access. Otherwise > 3 month unless it's your full time job. It helps if you have everything planned on forehand, but totally from scratch, this is a very unrealistic time table.


JAL
User avatar
os64dev
Member
Member
Posts: 553
Joined: Sat Jan 27, 2007 3:21 pm
Location: Best, Netherlands

Post by os64dev »

* none of the above

You cannot write an OS in three months and have it fully tested.
Author of COBOS
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Post by Combuster »

4 years and counting :wink:
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
User avatar
bewing
Member
Member
Posts: 1401
Joined: Wed Feb 07, 2007 1:45 pm
Location: Eugene, OR, US

Post by bewing »

It certainly depends on what language you choose, and what you mean by "scratch", too.
I wrote my own MBR, my own bootloader, made up my own filesystem, and made up my own executable format. I wrote it all in assembler, and singlestep debugged the whole thing. It's taken me a bit over a year so far, probably working 6 hours a day at it -- and I'm about at the stage that you specified.
frank
Member
Member
Posts: 729
Joined: Sat Dec 30, 2006 2:31 pm
Location: East Coast, USA

Post by frank »

1-2 years if you work on it all the time
User avatar
JackScott
Member
Member
Posts: 1036
Joined: Thu Dec 21, 2006 3:03 am
Location: Hobart, Australia
Mastodon: https://aus.social/@jackscottau
Matrix: @JackScottAU:matrix.org
GitHub: https://github.com/JackScottAU
Contact:

Post by JackScott »

3 years and counting... most of that time has been spent reading manuals and debugging code. New features are few and far between.
User avatar
JoeKayzA
Member
Member
Posts: 79
Joined: Wed Aug 24, 2005 11:00 pm
Location: Graz/Austria

Post by JoeKayzA »

For me it's also around 3 years now (on this project), 90% of the time was only design theory and gaining knowledge, not active coding work.
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Post by Solar »

The question is unfair at best, because those who have the experience and up-front knowledge to do it in a relatively short time usually also have full-time jobs and can spare only a couple of hours per week on OS development.

I had been a pretty good C/C++ coder at the time I started my OS project, so I did lose little if any time wrapping my mind around the concept of a freestanding programming environment.

But it took me over three months just reading, getting up to speed with what could be done and whether it would be wise to do so. When it's your first OS project, you usually don't know about stuff like memory allocation algorithms, SYSCALL vs. SYSENTER, or the intricacies of CPUID. You could simply start hacking away in trial & error fashion, but if you got into this because you want to put your design ideas into reality (instead of the hacking / show-off value), that's not the right way to do it. So I read the Intel Manual Book 1 cover-to-cover, and pondered over several chapters of Book 2 to nail down various concepts I had in mind for memory management and IPC.

Then I did spend quite some time in setting up version control software, a communication forum etc. - things that were only auxiliary to the OS effort itself, and ultimately a factor in the failure of the project (because the forum became a time-sink that bogged everything down eventually); but an experience in itself which I did put to use numerous times in a professional context. (For example, I learned about Wikis that way, about the futility of design-by-committee, about pro's and con's of various VCS packages, about versioning / packaging schemes etc. etc.)

All in all, I did invest the spare time of over a year in that project, with only a simple "hello world" "kernel" to show for it. Do I consider that time wasted? Certainly not. Two spinoffs from that project are the GCC Cross-Compiler tutorial and the PDCLib project, plus numerous postings at MT and edits in the OS FAQ.
Every good solution is obvious once you've found it.
User avatar
AndrewAPrice
Member
Member
Posts: 2309
Joined: Mon Jun 05, 2006 11:00 pm
Location: USA (and Australia)

Post by AndrewAPrice »

Solar wrote:The question is unfair at best, because those who have the experience and up-front knowledge to do it in a relatively short time usually also have full-time jobs and can spare only a couple of hours per week on OS development.
I agree - I have too many college assignments to work on my OS every day/week.

I tend to go jump between a week of doing of getting a lot done, and then 3-4 months and only change about 10 lines of code.
My OS is Perception.
User avatar
piranha
Member
Member
Posts: 1391
Joined: Thu Dec 21, 2006 7:42 pm
Location: Unknown. Momentum is pretty certain, however.
Contact:

Post by piranha »

1.5 years......1 since I started using Linux......

-JL
SeaOS: Adding VT-x, networking, and ARM support
dbittman on IRC, @danielbittman on twitter
https://dbittman.github.io
Post Reply