Still not got started...

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.
User avatar
Troy Martin
Member
Member
Posts: 1686
Joined: Fri Apr 18, 2008 4:40 pm
Location: Langley, Vancouver, BC, Canada
Contact:

Re: Still not got started...

Post by Troy Martin »

Have you even tried?
Image
Image
Solar wrote:It keeps stunning me how friendly we - as a community - are towards people who start programming "their first OS" who don't even have a solid understanding of pointers, their compiler, or how a OS is structured.
I wish I could add more tex
Axalto
Posts: 17
Joined: Wed Apr 01, 2009 12:58 pm

Re: Still not got started...

Post by Axalto »

Troy Martin wrote:Have you even tried?
#-o oops!
Joke, I tryed.
I'm now trying to instal another version of it.
User avatar
neon
Member
Member
Posts: 1567
Joined: Sun Feb 18, 2007 7:28 pm
Contact:

Re: Still not got started...

Post by neon »

Rather then choosing different kinds of development tool chains, pick one (preferably one that you have the most experience with) and use that. GCC, DJGPP, Cygwin, MSVC, C::B, et al... there are alot of tutorials on setting up each of these.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
User avatar
Troy Martin
Member
Member
Posts: 1686
Joined: Fri Apr 18, 2008 4:40 pm
Location: Langley, Vancouver, BC, Canada
Contact:

Re: Still not got started...

Post by Troy Martin »

It looks like you write code in C# and then it translates into assembly that is assembled by NASM and linked into flat binary.
neon wrote:Rather then choosing different kinds of development tool chains, pick one (preferably one that you have the most experience with) and use that. GCC, DJGPP, Cygwin, MSVC, C::B, et al... there are alot of tutorials on setting up each of these.
You're right. This whole topic isn't much of a good idea fountain.
Image
Image
Solar wrote:It keeps stunning me how friendly we - as a community - are towards people who start programming "their first OS" who don't even have a solid understanding of pointers, their compiler, or how a OS is structured.
I wish I could add more tex
Axalto
Posts: 17
Joined: Wed Apr 01, 2009 12:58 pm

Re: Still not got started...

Post by Axalto »

Troy Martin wrote:It looks like you write code in C# and then it translates into assembly that is assembled by NASM and linked into flat binary.
...and autostart and configurate a emulator, makes an image to burn it to a CD or DVD or makes it ready to boot it from USB.
:D
User avatar
quanganht
Member
Member
Posts: 301
Joined: Fri May 16, 2008 7:13 pm
Location: Hanoi, Vietnam

Re: Still not got started...

Post by quanganht »

Axalto wrote: ...and autostart and configurate a emulator, makes an image to burn it to a CD or DVD or makes it ready to boot it from USB.
Nope. Do that and you will lose tons of CD/DVD. Only make an image.
"Programmers are tools for converting caffeine into code."
User avatar
JamesM
Member
Member
Posts: 2935
Joined: Tue Jul 10, 2007 5:27 am
Location: York, United Kingdom
Contact:

Re: Still not got started...

Post by JamesM »

I really wouldn't recommend getting started with an OS written in a managed language like C#. Don't think I'm bashing the OS, because I'm not - its a truly excellent idea.

However, I'm fairly certain that you won't know the half of what's going on with it - a lot of stuff gets done behind the scenes in one of these operating systems, and so I would recommend starting with something a little smaller, and written more close-to-the-bone (In a language like C, or even asm) to see exactly what is happening.

Once you understand that, then you can move on to understanding OSes like cosmos and singularity.
Axalto
Posts: 17
Joined: Wed Apr 01, 2009 12:58 pm

Re: Still not got started...

Post by Axalto »

JamesM wrote:I really wouldn't recommend getting started with an OS written in a managed language like C#. Don't think I'm bashing the OS, because I'm not - its a truly excellent idea.

However, I'm fairly certain that you won't know the half of what's going on with it - a lot of stuff gets done behind the scenes in one of these operating systems, and so I would recommend starting with something a little smaller, and written more close-to-the-bone (In a language like C, or even asm) to see exactly what is happening.

Once you understand that, then you can move on to understanding OSes like cosmos and singularity.
I know, but this user-kit is the only working compiler/linker/emulator I've ever found. :D :) :wink: :| :? :( :x I hate this stupid linker!

Oh, and I already understand all the teoratical stuff.
User avatar
Troy Martin
Member
Member
Posts: 1686
Joined: Fri Apr 18, 2008 4:40 pm
Location: Langley, Vancouver, BC, Canada
Contact:

Re: Still not got started...

Post by Troy Martin »

NASM + GCC + LD works extremely well, you just need to know how to use it, and that's documented in our wiki. Search it and you will have yourself a booting OS you wrote in under twenty minutes, ten if you just use NASM.
Image
Image
Solar wrote:It keeps stunning me how friendly we - as a community - are towards people who start programming "their first OS" who don't even have a solid understanding of pointers, their compiler, or how a OS is structured.
I wish I could add more tex
Axalto
Posts: 17
Joined: Wed Apr 01, 2009 12:58 pm

Re: Still not got started...

Post by Axalto »

I followed every step and it still didn't worked.
quok
Member
Member
Posts: 490
Joined: Wed Oct 18, 2006 10:43 pm
Location: Kansas City, KS, USA

Re: Still not got started...

Post by quok »

You followed every step of what? And what about it didn't work?
Axalto
Posts: 17
Joined: Wed Apr 01, 2009 12:58 pm

Re: Still not got started...

Post by Axalto »

Every step of the Bare bones c tutorial.
The linker keeps saying:
"loader.o(.text+0x14): In function 'loader':
: undefined reference to `kmain'"
So, what have I done wrong?
[edit]YAY! I've found a solution!
I used a hex-editor to analize the kernel.o file and my compiler had put _kmain instead of kmain in the output file.
So I changed "global kmain" and "call kmain" to "global _kmain" and "call _kmain".
I only need to try it.[edit]

[edit2]AARCH! It dousn't work!
I finally get the good file (kernal.bin) but I can't get it on a floppy/cd/qemu/bochs.[edit2]
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: Still not got started...

Post by Combuster »

Axalto wrote:[edit2]AARCH! It dousn't work!
I finally get the good file (kernal.bin) but I can't get it on a floppy/cd/qemu/bochs.[edit2]
Once again, DO YOUR HOMEWORK BEFORE ASKING
"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