Real-mode assembly kernel barebones

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
mac
Member
Member
Posts: 144
Joined: Tue Sep 23, 2014 6:12 pm

Real-mode assembly kernel barebones

Post by mac »

(AKA something I was probably not supposed to do yet but followed it anyway for kicks, anyway it works)

I did this real-mode barebones assembly part I tutorial on the wiki, just to see how far I can go. I used PARTCOPY, Nasm and Virtualbox. I'm impressed by what I have done. Can't say I fully get the picture of the order and executions of the instructions do yet, which is what I fear that might make me a fake around here.

If I made my own suggestion, I would probably take a long(?) detour trying to learn C. What do you think?
User avatar
BASICFreak
Member
Member
Posts: 284
Joined: Fri Jan 16, 2009 8:34 pm
Location: Louisiana, USA

Re: Real-mode assembly kernel barebones

Post by BASICFreak »

SeanMc wrote:If I made my own suggestion, I would probably take a long(?) detour trying to learn C. What do you think?
That would probably be a good road for you to go down. C is a lot easier to read (and write) than ASM (Not as much micromanagement as the compiler does a-lot for you).

If you plan on learning C on the OSDev route I would highly recommend installing GRUB onto a disk image and creating your first "Hello World" Protected Mode Multi-boot complaint kernel. From there you can add any drivers or features you would want.

In the world of OSDev you only *NEED* a few lines of ASM, and most of the time it is just the privileged instructions (e.g. invlpg, lgdt, lidt, etc...) and/or boot code.


NOTE: I know many people would say to write simple applications first, which may be good advice - but I shall leave that decision with you.


Good Luck :),

B!
BOS Source Thanks to GitHub
BOS Expanded Commentary
Both under active development!
Sortie wrote:
  • Don't play the role of an operating systems developer, be one.
  • Be truly afraid of undefined [behavior].
  • Your operating system should be itself, not fight what it is.
mac
Member
Member
Posts: 144
Joined: Tue Sep 23, 2014 6:12 pm

Re: Real-mode assembly kernel barebones

Post by mac »

Well it wouldn't hurt me if I did a bit of user application programming.

Still, I'm glad I did this, even if I don't ever want to code in ASM much again.
Post Reply