amindelavar wrote:hi!
I am new in os development and my english is not good.
I am learning from "Operating System Development Series" in "Brokenthorn". but in linux not windows.
I am in "Tutorial 10: Prepare for the Kernel Part 1". but i can not enter to protected mode. also i'm using qemu.
please HELP ME!
As has already been said, we would need to see your source code as it currently exists, or at least the part where you think the problem lies, in order to determine the cause. Further, you need to describe the problem in greater detail; saying it doesn't work without saying what
does happen simply isn't sufficient information for us to work with.
That having been said, there is some advice I can give.
First, I would strongly recommend that if you haven't set up version control for your source code, and an offsite repository on a host such as
Cloudforge or
GitHub, do so
now before proceeding with anything else. Trust me, at some point you
will delete important files by accident, or have a drive failure, or need to trace back through your changes to find out where a bug was introduced, or want to share your code with someone else in a way that let's them see the latest changes without having to send them updates repeatedly. These things happen to
everyone, sooner or later.
If nothing else, it makes asking questions here easier, as you can post a link to the files in the repo rather than pasting large code samples into your messages.
It is about more than just backups; it gives you a record of your changes in a way that makes it easy to search through them. It also allows you to make 'experimental' branches to test things out while leaving your 'trunk' code unchanged, and later you can merge the successful experiments into the trunk. If you get in the habit of committing to VCS regularly, it
will save your butt.
Second, I strongly recommend reading the wiki page
How To Ask Questions, as well as the Eric S. Raymond essay/how-to article it is based on,
"How to Ask Questions the Smart Way". I don't mean this in a condescending way; we've all been novices at one point. Asking questions effectively on Internet message boards is actually a surprisingly involved skill, one which takes time and knowledge to master.
Third, there are known flaws in the Brokenthorn tutorial series; I am not familiar enough with the tutorial personally to point them out, but I expect that there are others here who are. This is not to say that it is a bad tutorial as such. This is pretty much an unavoidable issue with any tutorials in this topic, and for all its problems, it is my understanding that BT is better than many others. It does mean that you need to be judicious in using anyone's tutorials, rather than following them exactly.
Finally, if you haven't already, I would strongly recommend reading the introductory material in the wiki (I know I've already mentioned some of these, but bear with me):
After this, go through the material on the practical aspects of
running an OS-dev project:
Then you should read up on the core technologies for the platform. Assuming that you are targeting the PC architecture, this would be:
I strongly suggest that you read through the first two set of pages in detail, and preferably at least go through the third part briefly, before doing any actual development.
While this is a lot of reading, it simply reflects the due diligence that any OS-devver needs to go through in order to get anywhere. OS development, even as a simple project, is not amenable to the Stack Overflow cut-and-paste model of software development; you really need to understand a fair amount of the concepts and principles before writing any code, and the examples given in tutorials and forum posts generally are exactly that. Copying an existing code snippet without at least a basic idea of what it is doing simply won't do. While learning itself is an iterative process - you learn one thing, try it out, see what worked and what didn't, read some more, etc. - in this case a basic foundation is needed at the start. Without a solid understanding of at least some of the core ideas before starting, you simply can't get very far in OS dev.
Hopefully, this won't scare you off; it isn't nearly as bad as it sounds. It just takes a lot of patience and a bit of effort, a little at a time.