OS Development Under MS-DOS
Re: OS Development Under MS-DOS
i am no turbo C expert
but, perhaps you could write it as a tiny model (.COM) program
but, perhaps you could write it as a tiny model (.COM) program
Re: OS Development Under MS-DOS
I personally recommend against flat binary kernels tbh. I would just parse the output executable of the compiler and linker of your choice and use that.
If you really want to go flat binary, you might be able to use exe2bin to convert the EXE to a flat binary. Or, you can just use a .COM file (its a flat binary) if Turbo C supports it.
If you really want to go flat binary, you might be able to use exe2bin to convert the EXE to a flat binary. Or, you can just use a .COM file (its a flat binary) if Turbo C supports it.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Re: OS Development Under MS-DOS
Nathan,
DednDave is right. Compile in TINY memory model and link to a COM file (TLINK can do this without EXE2BIN). Provide your own C0T.OBJ with ORG 0 (or ORG anything you like) instead of ORG 100H. Write a bootloader to load this file from your boot disk.
Roel
Edit: fixed typo.
DednDave is right. Compile in TINY memory model and link to a COM file (TLINK can do this without EXE2BIN). Provide your own C0T.OBJ with ORG 0 (or ORG anything you like) instead of ORG 100H. Write a bootloader to load this file from your boot disk.
Roel
Edit: fixed typo.
Last edited by qw on Mon Feb 08, 2010 3:59 am, edited 1 time in total.
Re: OS Development Under MS-DOS
Very nice!
I'm going to test this and post here what I got.
I'm going to test this and post here what I got.
Re: OS Development Under MS-DOS
I agree with you but I wouldn't recommend MZ-EXE.neon wrote:I personally recommend against flat binary kernels tbh. I would just parse the output executable of the compiler and linker of your choice and use that.
Nathan,
Good luck!
Roel
Re: OS Development Under MS-DOS
Hello,
While I would agree that EXE might not be best for beginners here, I would encourage anyone to use what is best for their projects' goals, whether it is EXE or not.Hobbes wrote:I agree with you but I wouldn't recommend MZ-EXE.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Re: OS Development Under MS-DOS
Then the OP may like BootProg.
Re: OS Development Under MS-DOS
That's an awesome tool, but someone here already tried to use it?Hobbes wrote:Then the OP may like BootProg.
Also, using Turbo C, as the compiler and BootProg as my bootloader. I can do a OS running VESA mode(or like VESA), as Windows 3.11?
Best Regards.
- Combuster
- 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: OS Development Under MS-DOS
Necromancy alert.
Re: OS Development Under MS-DOS
Combuster wrote:Necromancy alert.
Could you please isntead of make jokes, help me?
Re: OS Development Under MS-DOS
I am not sure I understand your question. Windows 3.11 didnt use VBE but it doesnt mean that you cant use it.
Also note its VBE not Vesa, Vesa is the organization that developed the VBE specs.
Also note its VBE not Vesa, Vesa is the organization that developed the VBE specs.
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}
Re: OS Development Under MS-DOS
Hi, as long as the Boot Loader you use has the ability to set the VBE graphics mode, then you will be able to program the graphics code using the C language. You could also set the graphics mode after boot, using a vm86 method.
Visit the Montrom user page for more info.
Re: OS Development Under MS-DOS
Thanks for adviding me. Now I know that they aren't the same thing.neon wrote:I am not sure I understand your question. Windows 3.11 didnt use VBE but it doesnt mean that you cant use it.
Also note its VBE not Vesa, Vesa is the organization that developed the VBE specs.
I'm going to take a look at vm86. Thanks.montrom wrote:Hi, as long as the Boot Loader you use has the ability to set the VBE graphics mode, then you will be able to program the graphics code using the C language. You could also set the graphics mode after boot, using a vm86 method.
Re: OS Development Under MS-DOS
Nathan, if you're developing a real mode OS, you don't need Virtual 8086 Mode at all.