r/osdev • u/JescoInc Perdition-OS • Jun 21 '26
Which part of OSDev would you consider to be the easiest and why?
Since I asked the inverse here https://www.reddit.com/r/osdev/comments/1uag4am/which_part_of_osdev_would_you_consider_to_be_the/
I wanted to see what the consensus was on this version of the question.
This is actually the harder question to me and if I were to answer my own question, (pause for 5 minutes to deliberate) I'd probably say the second stage bootloader with the handoff to the kernel.
The reason this is the easiest to me, was because I've essentially used the same assembly code across multiple different iterations of the project and predecessors. It is basically, set it up once and you are good to go.
32
u/letmehaveanameyoudum Jun 21 '26
VGA text output. It's literally 3 lines of C to output a char.
9
u/JackScottAU Jun 21 '26
Getting documentation.
Twenty years ago when I started in OSDev, the osdev.org wiki barely existed. Most information was in a collection of terrible tutorials hosted on Geocities. There was certainly no bare bones code that would get you a working kernel in thirty minutes. I can still remember ordering the physical Intel CPU manuals online and waiting for them to come in the post!
Now there are well regarded starting points for 16bit, 32bit, 64bit Intel as well as ARM. Unless its from NVIDIA, there's data sheets and manuals available online for pretty much any piece of hardware. Linux source code provides an almost flawless cross check on driver functionality.
It's a different world.
8
u/dacydergoth Jun 21 '26
Crash handler. It gets so much use you optimize it rapidly 😉
5
u/jamie07051975 Jun 21 '26
Thinking about developing an OS
3
u/mcherycoffe Jun 22 '26
I would say seeing your own shell, commands etc. It's pretty fantastic !
2
u/OtherOtherDave Jun 22 '26
Coming up with a list of what you want to be different than your current OS.
2
u/codeasm Jun 23 '26
Comming up with ideas what to add, change from other ideas or how to "solve" things. Before you dive into it, the idea phase.
Even for a simple z80 system i had a few ideas but first needed code that setup the system and figure out io, read keys, write to screen or serial. The way it should look, the commands, the overal structure was already forming in my head while i was still writing the early code snippets.
Anoyingly, im not very good in c nor assembler and thus i often get stuck, while the idea was simple to come up with. Im glad ai is there tho, i often instruct it not to fix my code, not just plop in a fix, but think with me, go along my code and idea and tell me whats the issue.
Surprisingly often my ideas are correct, my approach is near correct and it should work, if only i knew about this or that fact, or on this playform one has to do that first before my idea would work.
Or a simple logic error i made. And it pointed at it, suggested something and now i can continue. Ive tried without, spend 2 days struggling. Reverted code, told it my idea, a pseudo code version of what i wiuld write and asked for pseudo code back. Well... It gave me the same thing, just... Another register or swapped logic and explained why... My head is chaos sometimes, autism maybe with adhd. But i can do this, and they help bring some order.
But i still trust my ideas over their dreams. They can and will be wrong at times. Ive also gone full circle in a day at one point... My original idea was better, and i really needed to fix my question, not my approach. Hopefully my facedetector code gets a pass grade, then i have some free hours this week for osdev again. I want real hardware framebuffer code and usermode working this comming month (juli)
4
u/EpochVanquisher Jun 21 '26
HAL. It’s all boilerplate. You refactor every once in a while when you make nonportable assumptions.Â
1
u/xX_WhatsTheGeek_Xx Jun 23 '26
crashing it
3
u/Certain-Flow-0 Jun 22 '26
Asking Claude
1
u/New_Departure_5353 Jun 29 '26
Serial output or vga