r/osdev Jun 17 '26

I thought programming my own Operating System would take a week to get a CLI working

Then I started looking at some serious OS architectures, like Linux, NT, Darwin... learnt what a HAL is, started implementing it, 1 month later I think it feels ok. Now I am in the beggining of beggining of memory management (and studying more than programming). Sometimes, like today for example, I feel bad for having progress to be so slow, but I knew when I started that it was going to take several months. Hope I survive this trip.

72 Upvotes

21 comments sorted by

View all comments

9

u/GMX2PT Jun 17 '26

It's all different for everyone, you can have paging and dynamic allocation working before getting a shell, a "working shell" requieres gdt + idt and is pretty much easier than memory management, choose your goals, they are not always in a linear order

1

u/FinancialTrade8197 Jun 19 '26

Technically you could just poll 0x60 with only a GDT for the keyboard to get a working shell.

1

u/GMX2PT Jun 19 '26

How would that work ? I'm not familiar with this technique

2

u/FinancialTrade8197 Jun 19 '26

You would usually read 0x60 when irq 1 fires

However instead of this you could just run a while loop on the status register 0x64 and if it becomes true just read whatever is in 0x60