Need help with C Kernel

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.
gerryg400
Member
Member
Posts: 1801
Joined: Thu Mar 25, 2010 11:26 pm
Location: Melbourne, Australia

Re: Need help with C Kernel

Post by gerryg400 »

Thanks, but what is the easiest way for me to boot this kernel.bin file?
The barebones tutorial tells you exactly how to do it. However you need to install cygwin or use a Linux (possibly virtual) machine to get all the tools needed. 'Easiest' depends on your current situation and knowledge. I've never tried it but I believe Qemu has a built in bootloader. I guess if that works it would be the easiest.
If a trainstation is where trains stop, what is a workstation ?
chibicitiberiu
Member
Member
Posts: 68
Joined: Thu May 28, 2009 11:46 pm

Re: Need help with C Kernel

Post by chibicitiberiu »

You may want to use unsigned char instead of char for the videomem pointer, this way you can use all 256 characters, and all text colors.
Tibi,
Currently working on the Lux Operating System
Fanael
Member
Member
Posts: 38
Joined: Fri Oct 16, 2009 9:20 am

Re: Need help with C Kernel

Post by Fanael »

gerryg400 wrote:However you need to install cygwin or use a Linux (possibly virtual) machine to get all the tools needed.
Could you explain why one needs Cygwin or Linux in order to do what OP wants to?
User avatar
Code0x58
Posts: 10
Joined: Tue Jul 27, 2010 2:13 pm
Location: Surrey, England

Re: Need help with C Kernel

Post by Code0x58 »

Cygwin/Linux would most likely be for GCC if you choose to use it, which is quite likely, but you could use another C compiler (such as OpenWatcom's) and their linker. I myself use NASM + GCC (in MinGW) and wlink (OpenWatcom's linker), but might switch GCC for OW. If your using GRUB, OpenWatcom happily works with ELFs.
User avatar
Combuster
Member
Member
Posts: 9301
Joined: Wed Oct 18, 2006 3:45 am
Libera.chat IRC: [com]buster
Location: On the balcony, where I can actually keep 1½m distance
Contact:

Re: Need help with C Kernel

Post by Combuster »

Fanael wrote:
gerryg400 wrote:However you need to install cygwin or use a Linux (possibly virtual) machine to get all the tools needed.
Could you explain why one needs Cygwin or Linux in order to do what OP wants to?
Because a single install of cygwin (or linux) contains the whole pipeline of tools to build, test, run, and distribute your work. You get a compiler, linker, link archiver, build tool, image tools, image writers, and compression utilities in one convenient package. And it's all command-line based so it becomes easy to perform all tasks under a single command.

And it's better to stick to an established standard when having problems instead of deviating from it without knowing what you do - it essentially eliminates the environment as a factor. So yes, we expect the OP to use cygwin unless he has a convincing reason not to.
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]
Post Reply