I just need help

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.
MeLkOr

I just need help

Post by MeLkOr »

I am pretty good with the basics of C++ but what I would really like to do is program an operating system but I have no idea where to begin or what to use. I have been to lots of websites and read tons of articles but nothing is on low enough of a level. I need to know what language to use what to write it in and basic stuff you really need to know when you are first starting out. I would really apriciate help.
-MeLcOr
Tim

Re:I just need help

Post by Tim »

Well, what do you want to know? Your question is a little vague.

Generally, you should:
1. Get hold of a boot loader
2. Write a short 'kernel' which prints "hello world"
3. Expand on that

I can recommend the GRUB boot loader, since it contains all the boot loader binaries and a sample kernel, written in C.
MeLkOr

Re:I just need help

Post by MeLkOr »

So where can i get that bootloader? Next question... (not so broad this time) What language do you recomend using for the kernel and other programs?
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:I just need help

Post by Pype.Clicker »

may i recommend you the reading of the FAQ, which should reply to all these questions ...
The #1 recommended language is C for it is close enough to hardware and does not require a complex runtime environment like C++ (though some of our members, including Daryl Dudey has worked on a small config for C++)

Interpreted / mixed language like Java, Basic, Csharp, Perl, Lisp, etc. are excluded almost from start.
Therx

Re:I just need help

Post by Therx »

You can get a GRUB image that you can write to a floppy disk from http://therx.sf.net/osdev/files/grub.zip. You need to write this to a floppy using RAWRITE (search for that in Google and you should get a download location). Most people write their OS in a mixture of assembly and C. If you are working under windows the C compiler is DJGPP (www.delorie.com), under Linux GCC. The assembler is called NASM (nasm.sf.net). Once you have these the beginners kernels that I'd recommend to work your way through are downloadable from my.execpc.com/~geezer/ along with lots of information.

Any probs just ask

Pete
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re:I just need help

Post by Solar »

MeLkOr wrote: I am pretty good with the basics of C++ but what I would really like to do is program an operating system but I have no idea where to begin or what to use.
Please don't be offended, this suggestion is sincere:

#1 - get more experience with C++, compiler / binary internals, and assembler. Just knowing the basics of C++ doesn't help with an OS.

#2 - get a good book on generic OS internals. For English people the standard is Tanenbaum's books (look it up in the FAQ).

#3 - try helping in some other guy's OS project first, to get some idea of what's actually required.

Launching yourself right into an all-new OS project if you don't even know where to start is bound to leave you very frustrated.
Every good solution is obvious once you've found it.
MeLkOr

Re:I just need help

Post by MeLkOr »

Thanks. I will try that and replay with other questions. (Which i'm sure i'll have) Well, I just though of one. Do you use regular C commands and include files when making an OS?
-MeLkOr
MeLkOr

Re:I just need help

Post by MeLkOr »

I was also wondering if you have to use RAWRITE because I am having trouble downloading it?
-MeLkOr
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:I just need help

Post by Pype.Clicker »

whether you need RAWRITE mainly depends on which OS you use. if you can't download it (it should be available in DOSTOOLS directory of SuSE ftp, for instance), you still can use partcopy instead (afaik).

If you're running Linux, just use /dev/fd0 directly ;)
Tim

Re:I just need help

Post by Tim »

If you're using Cygwin on Windows (recommended), then you can use the same /dev/fd0 method, with the dd program.
MeLkOr

Re:I just need help

Post by MeLkOr »

Just wondering but whats the point of being good at C++ if i'm not using C++ for making the OS? All of your other suggestions are valid and I would love to help someone build an OS but I live in a small town in the middle of nowhere USA! There isn't anyone making OS's around here!
-MeLkOr
Tim

Re:I just need help

Post by Tim »

MeLkOr wrote:Just wondering but whats the point of being good at C++ if i'm not using C++ for making the OS?
Then use C++! Nobody's stopping you. C++ is a fine language for OS development, as is C.
All of your other suggestions are valid and I would love to help someone build an OS but I live in a small town in the middle of nowhere USA! There isn't anyone making OS's around here!
That's what the Internet is for. There's nobody making their own OS around me, either.
MeLkOr

Re:I just need help

Post by MeLkOr »

:) lol Anyone need any help building an OS? Glad to help if there is.
-MeLkOr
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:I just need help

Post by Pype.Clicker »

hehe. who can decline such a nice offer ?

if you see something in the Clicker's todo list that fits your ambition, contact me ...

The kernel core is object-oriented C (hybrid OO-design with classical implementation), but it should be possible to write C++ modules without additionnal complexity, provided that you don't need RTTI or exceptions handling ...
User avatar
Candy
Member
Member
Posts: 3882
Joined: Tue Oct 17, 2006 11:33 pm
Location: Eindhoven

Re:I just need help

Post by Candy »

Tim Robinson wrote:
All of your other suggestions are valid and I would love to help someone build an OS but I live in a small town in the middle of nowhere USA! There isn't anyone making OS's around here!
That's what the Internet is for. There's nobody making their own OS around me, either.
I started a CS study 2 years ago, and after looking around on the education, nobody, including teachers, was even thinking about doing OS programming. (Did find a group that was making a 3D MMORPG though... :)) If you want to make an OS, be happy you found this site. It's one of the very few sites in the world where a lot of people doing OS dev can be found. (thank god... I myself was almost thinking there were only 3 dozen people in the world crazy enough... might still be though :))
Post Reply