refactor: make the demos into dedicated files
[lunaix-os.git] / docs / README_en.md
1 <p align="center">
2   <img width="auto" src="img/lunaix-os-logo.png">
3 </p>
4
5 <p align="center">
6   <a href="../README.md"><b>简体中文</b></a> | <span><b>English</b></span>
7 </p>
8
9 # The LunaixOS Project 
10 LunaixOS - A simple (yet naive), POSIX-complaint (hopefully!), operating system from scratch. This is started for educational & learning purpose, for my online video tutorial on OS development **in Chinese**:[*Do It Yourself an Operating System*](https://space.bilibili.com/12995787/channel/collectiondetail?sid=196337).
11
12 ## Features
13
14 This operating system is a macro-kernel, has its root in Intel's x86 platform and its ecosystem. It runs in protected mode and uses 4GiB addressing with two-level paging mechanism. It does not have x86_64 variant and does not support multi-core machine. 
15
16 The memory is split into two parts, that is, 3GiB for user space (0x400000~0xBFFFFFFF) and 1GiB for kernel space (0xC0000000~0xFFFFFFFF). Such paradigm is a common practicing found in major operating systems, for example x86_32 version of Linux and Windows. For a more detailed arrangement of memory in LunaixOS, please refer to [LunaixOS Virtual Memory Mappings](docs/img/lunaix-os-mem.png).
17
18
19 The following list presents all features it does have in current stage.
20
21 + Multiboot for bootstrapping
22 + APIC/IOAPIC as interrupt controller and programmable timer.
23 + ACPI table parsing.
24 + Virtual memory & paging
25 + Memory management & demand paging
26 + PS/2 Keyboard support
27 + Muti-tasking and task management
28 + 15 commonly used POSIX syscall([See Appendix 1](#appendix1))
29 + User Space
30 + Signal
31
32 ## Project Structure
33
34 | | |
35 |-----|------|
36 | [lunaix-os](lunaix-os/) | LunaixOS source code |
37 | [slides](slides/) | Slides used in my videos |
38 | [reference-material](reference-material/)| References |
39
40 ## Referenced Tutorial
41
42 **THERE IS NONE !** The project is based solely on my understanding on operating system concepts and relevant research. And has referenced no third party tutorial nor open source project like the Linux or other hobbyist project.
43
44 Thus, the author has devoted large amount of time to go through any related materials such as technical references, manuals, textbooks, and industrial standards. To further ensure the technology used and knowledge taught is up-to-date and is coming "straight from the factory".
45
46 You can find most of aforementioned materials in [reference-material](reference-material/).
47
48 The following list also enumerated such materials the author has used:
49
50 #### Manuals, Technical References and Standards
51 + [Intel 64 and IA-32 Architecture Software Developer's Manual (Full Volume Bundle)](https://www.intel.com/content/www/us/en/developer/articles/technical/intel-sdm.html)
52 + [ACPI Specification (version 6.4)](https://uefi.org/sites/default/files/resources/ACPI_Spec_6_4_Jan22.pdf)
53 + IBM PC/AT Technical Reference
54 + IBM VGA/XGA Technical Reference
55 + 82093AA I/O Advanced Programmable Controller (IOAPIC) (Datasheet)
56 + MC146818A (Datasheet)
57 + Intel 500 Series Chipset Family Platform Controller Hub (Datasheet - Volume 2)
58
59 #### Textbook
60 + *Computer System - A Programmer's Perspective Third Edition* (Bryant, R & O'Hallaron, D), a.k.a. CS:APP
61 + *Modern Operating System* (Tanenbaum, A)
62
63
64 #### Website 
65 + [OSDev](https://wiki.osdev.org/Main_Page) - For material gathering.
66 + [FreeVGA](http://www.osdever.net/FreeVGA/home.htm) - For VGA references.
67 + GNU CC & LD online documentation.
68
69 #### Others
70 + Linux Manual - For learning the system call behavior on real machine.
71
72
73 ## Appendix 1: Supported System Call<a id="appendix1"></a>
74
75 ### Unix/Linux/POSIX
76 1. `sleep(3)`
77 1. `wait(2)`
78 1. `waitpid(2)`
79 1. `fork(2)`
80 1. `getpid(2)`
81 1. `getppid(2)`
82 1. `getpgid(2)`
83 1. `setpgid(2)`
84 1. `brk(2)`
85 1. `sbrk(2)`
86 1. `_exit(2)`
87 1. `sigreturn(2)`
88 1. `sigprocmask(2)`
89 1. `signal(2)`
90 1. `kill(2)`
91
92 ### Unique to LunaixOS
93
94 1. `yield`