Sem descrição

Carlos Fenollosa f8369ec919 lesson 17, video scroll há 10 anos atrás
00-environment fc73be819b updated READMEs há 10 anos atrás
01-bootsector-barebones fc73be819b updated READMEs há 10 anos atrás
02-bootsector-print fc73be819b updated READMEs há 10 anos atrás
03-bootsector-memory fc73be819b updated READMEs há 10 anos atrás
04-bootsector-stack fc73be819b updated READMEs há 10 anos atrás
05-bootsector-functions-strings 83179b891e lesson 7, reading from disk há 10 anos atrás
06-bootsector-segmentation ee0eefad66 lesson 6, segmentation há 10 anos atrás
07-bootsector-disk 2f1378d7a3 lesson 13, first kernel há 10 anos atrás
08-32bit-print adc8463383 lessons 8, 9, 10, entering 32-bit mode há 10 anos atrás
09-32bit-gdt b9999306a5 lessons 8, 9, 10, entering 32-bit mode há 10 anos atrás
10-32bit-enter afa376d2b6 lessons 8, 9, 10, entering 32-bit mode há 10 anos atrás
11-kernel-crosscompiler 32355dbc28 lesson 11, cross-compiler há 10 anos atrás
12-kernel-c 14f51e8246 updated lesson 12 README há 10 anos atrás
13-kernel-barebones 18c8989d33 lesson 13 comments há 10 anos atrás
14-checkpoint 3530dd700c lesson 16, kprint há 10 anos atrás
15-video-ports ee368f41d4 lesson 15, video ports há 10 anos atrás
16-video-driver 3530dd700c lesson 16, kprint há 10 anos atrás
17-video-scroll f8369ec919 lesson 17, video scroll há 10 anos atrás
.gitignore 8638875ac2 lesson 14 há 10 anos atrás
README.md fc73be819b updated READMEs há 10 anos atrás

README.md

os-tutorial

How to create an OS from scratch!

New lessons will be added about every week, at the same pace that I learn each concept

I have always wanted to learn how to make an OS from scratch. In college I was taught how to implement advanced features (pagination, semaphores, memory management, etc) but:

  • I never got to start from my own boot sector
  • College is hard so I don't remember most of it.
  • I'm fed up with people who think that reading an already existing kernel, even if small, is a good idea to learn operating systems.

Inspired by this document and the OSDev wiki, I'll try to make short step-by-step READMEs and code samples for anybody to follow. Honestly, this tutorial is basically the first document but split into smaller pieces and without the theory.

Features

  • This course is a code tutorial aimed at people who are comfortable with low level computing. For example, programmers who have curiosity on how an OS works but don't have the time or willpower to start reading the Linux kernel top to bottom.
  • There is little theory. Yes, this is a feature. Google is your theory lecturer. Once you pass college, excessive theory is worse than no theory because it makes things seem more difficult than they really are.
  • The lessons are tiny and may take 5-15 minutes to complete. Trust me and trust yourself. You can do it!

How to use this tutorial

  1. Start with the first folder and go down in order. They build on previous code, so if you jump right to folder 05 and don't know why there is a mov ah, 0x0e, it's because you missed lecture 02. Really, just go in order. You can always skip stuff you already know.

  2. Open the README and read the first line, which details the concepts you should be familiar with before reading the code. Google concepts you are not familiar with. The second line states the goals for each lesson. Read them, because they explain why we do what we do. The "why" is as important as the "how".

  3. Read the rest of the README. It is very concise.

  4. (Optional) Try to write the code files by yourself after reading the README.

  5. Look at the code examples. They are extremely well commented.

  6. (Optional) Experiment with them and try to break things. The only way to make sure you understood something is trying to break it or replicate it with different commands.

TL;DR: First read the README on each folder, then the code files. If you're brave, try to code them yourself.

Contributing

I'm still learning this. For the moment, please restrict your contributions to fixing possible bugs or improving existing documents. I'm not yet ready to accept enhancements.