Managed World

Techno-babble from yet another babbler RSS 2.0
# Sunday, September 10, 2006

Before I joined the ranks at Microsoft, a hobby I started to take up was Operating System development. Technically, I didn't get very far yet (I had just started). My "kernel" (if you can even call it that) basically just printed "Hello World" to the screen. But heck, it was booting up from a floppy, loading the kernel into memory, and executing to do that (in a VM of course, I wouldn't even dare run my hobby OS on an actual machine :P).

Unfortunately, for the last several months I have been in "corporate housing" while my wife and I sell our house back in the Portland area. This means that I don't have access to various belonging of mine because they are in storage which we don't have access to. Included in this list of belongings is my main desktop computer that I was using as my development box. I have since switched over to developing with my laptop, but my OS development environment was on that machine. I haven't had the time to recreate that environment, so my hobby has kind of fallen by the wayside as of late.

Recently though, I came across these two articles which outline how you can use Visual Studio to compile your own Kernel. More specifically, it outlines how to compile a PE-format executable which can be booted by using GRUB. To my delight, I was able to recreate his findings and write the hobbyist OS I had started before in about 20 minutes. I would go into the compiler/linker options that make this possible, but why don't you just read the original resources.

However, word to the wise, OS development is not something you can just waddle on into. I would advise against using OS development as a way to learn C for example. OS development should be fun, so do yourself a favor and don't frustrate yourself from the get go :).  

Now, if you're a geek like me where the idea of messing around with writing your own OS sounds exciting, there are some resources you should definitely check out that I've come across (I know they've made it easier on me):

Websites

Books

Okay, that should keep you busy for a while (I know that I've just tipped the iceberg of all those resources :P). The best advice I can give comes from the OS-FAQ Wiki: make sure you understand everything that is going on. Don't just copy code and continue plugging along. You need to understand what the code is doing. If you use the code, understand what it does. After all, if you don't, how do you expect to fix it if it breaks (and inevitably with OS development it _will_ break).

Once you're comfortable with the boot process, how grub works, getting into C land, etc., then feel free to check out the two articles on using Visual Studio 2005 to build your OS. The good news? Every tool you will need (at least for the first huge chunk of it) is available for totally free (assuming of course that you can do it from VC2005 Express which I haven't tried yet). Is there a better price than that with all the resources above at your disposal as well? I think not :).

Enjoy and happy dev'ing :).

Posted in Programming
 #       Comments [2]
Monday, September 11, 2006 6:43:37 AM (Pacific Standard Time, UTC-08:00)
Thanks for posting the resources..that would be a good start for me. Have been waiting for a long time to fiddle around with OS development but could never get enough time/energy to start ;). Hopefully this should be a good start.
Andy
Monday, September 11, 2006 10:30:35 AM (Pacific Standard Time, UTC-08:00)
Well, enjoy yourself Andy :). Trust me, when you're able to get your OS to boot and print "Hello World!" on the screen, it's an enjoyable feeling. Of course, it's all uphill from there :p.
Name
E-mail
Home page

Comment (Some html is allowed: a@href@title, strike) where the @ means "attribute." For example, you can use <a href="" title=""> or <blockquote cite="Scott">.  

Live Comment Preview

Contact

Email Me Send mail to the author(s)

Calendar

<October 2008>
SunMonTueWedThuFriSat
2829301234
567891011
12131415161718
19202122232425
2627282930311
2345678

About this site

Jason Olson's thoughts on Programming, Games, Music and Life in General

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2008
Jason Olson

Sign In
All Content © 2008, Jason Olson
Theme based on 'Business' created by Christoph De Baene (delarou)