Questions from a beginner

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
schwarzerosen
Posts: 1
Joined: Sun May 24, 2009 9:22 pm

Questions from a beginner

Post by schwarzerosen »

Hello.

I have started making my kernel, and I have hit a little snag. I was hoping some of you may be able to help. I was planning on a hybrid kernel. The main issue is knowledge. I do not understand how one works(well, I have a basic, but very incomplete idea). How does the kernel load what it needs(drivers, etc.)? How do applications work with the kernel? Will I need to make API libraries? What about basic commands(changing directories, removing files, etc.)?

I am unable to find many in-depth resources on this. Any help or advice would be greatly appreciated.

Thank you,
SchwarzeRosen.
“Should array indices start at 0 or 1? My compromise of 0.5 was rejected without, I thought, proper consideration.”
(Stan Kelly-Bootle)
“Software is like sex: It’s better when it’s free.”
(Linus Torvalds)
User avatar
JackScott
Member
Member
Posts: 1033
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:

Re: Questions from a beginner

Post by JackScott »

Hi,

Our Wiki has the answers to all of those questions. It can be found at http://wiki.osdev.org/

In future, it's best to search both the wiki and this forum before posting, since bets are that every single beginner question has already been answered.
User avatar
kop99
Member
Member
Posts: 120
Joined: Fri May 15, 2009 2:58 am

Re: Questions from a beginner

Post by kop99 »

Hi,...
I think James Molloy's tutorial is very helpful for beginers...
http://www.jamesmolloy.co.uk/tutorial_html/index.html
User avatar
ehenkes
Member
Member
Posts: 124
Joined: Mon Mar 23, 2009 3:15 am
Location: Germany
Contact:

Re: Questions from a beginner

Post by ehenkes »

I think James Molloy's tutorial is very helpful for beginers...
It shows how to start in a practical sense, but from a design viewpoint it has a lot of weaknesses. How to run processes or threads in user mode is not fully explained. Pmm and Vmm is not clearly separated in chapter 6.

Does a book "OS development for Dummies" exist?
User avatar
NickJohnson
Member
Member
Posts: 1249
Joined: Tue Mar 24, 2009 8:11 pm
Location: Sunnyvale, California

Re: Questions from a beginner

Post by NickJohnson »

ehenkes wrote:Does a book "OS development for Dummies" exist?
That's an oxymoron, even for the Dummies series. :lol:

I think the whole "genesis" section of JamesM's tutorial is really the important part though. Once you have a build system, bootloader, and emulator set up, you can figure real things out from various documentation or reading others' code. That's why I usually recommend it to newbies.
User avatar
ehenkes
Member
Member
Posts: 124
Joined: Mon Mar 23, 2009 3:15 am
Location: Germany
Contact:

Re: Questions from a beginner

Post by ehenkes »

That's an oxymoron, even for the Dummies series.
I think it should be possible. It has to be a mixture of design principles, why to select what, and easy-to-understand example OS.
I think the whole "genesis" section of JamesM's tutorial is really the important part though. Once you have a build system, bootloader, and emulator set up, you can figure real things out from ...
That is right. Bran´s tutorial is a fundamental core of it.
User avatar
neon
Member
Member
Posts: 1567
Joined: Sun Feb 18, 2007 7:28 pm
Contact:

Re: Questions from a beginner

Post by neon »

The problem with this is that the implementation details of any kernel is specific on your design needs. You can build your design off of others (might be bad) or build your design around the generic design and concept of - in your case - a hybrid kernel.

Click here for a nice introduction of what hybrid kernels are.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
User avatar
ehenkes
Member
Member
Posts: 124
Joined: Mon Mar 23, 2009 3:15 am
Location: Germany
Contact:

Re: Questions from a beginner

Post by ehenkes »

Where could one find an article about making own API libraries?
Is there an alternative to JM´s tutorial, e.g. with an micro kernel approach?
User avatar
neon
Member
Member
Posts: 1567
Joined: Sun Feb 18, 2007 7:28 pm
Contact:

Re: Questions from a beginner

Post by neon »

ehenkes wrote:Where could one find an article about making own API libraries?
There isnt anything to learn. A library is just a set of routines that provide an interface for working with something or a way to abstract something. So long as the level of abstraction is the same across the interface of the library, you have effectively created a good library.
ehenkes wrote:Is there an alternative to JM´s tutorial, e.g. with an micro kernel approach?
I dont think so, microkernels are somewhat hard to set up and almost always specific on your overall system architecture design. I can show you my setup if you like for an example.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
User avatar
JamesM
Member
Member
Posts: 2935
Joined: Tue Jul 10, 2007 5:27 am
Location: York, United Kingdom
Contact:

Re: Questions from a beginner

Post by JamesM »

Hi,
ehenkes wrote:Where could one find an article about making own API libraries?
Is there an alternative to JM´s tutorial, e.g. with an micro kernel approach?
The point behind those OS tutorials is to introduce a concept and to show how concepts can be practically concreted and linked together - taking the numerous abstractions in theory books and resources and showing how to take that and implement it.

The concrete concepts required for a microkernel implementation are all covered in that tutorial. All you need to add is a robust IPC system - message passing or something similar.

And the criticism is constructively received - I'm working long-term on a groundup rewrite of them (found at http://jamesm-tutorials.googlecode.com/) that attempts to address a lot of the comments I've received. Especially that about the task switching section and the seperation of physical and virtual memory managers. Now all I need to do is get the time to finish it... :(
Post Reply