I have visited the site and thought I would throw back up a old framework. I had extended this framework into a almost complete kernel. I still think could be very useful to someone who wants to jump right into developing a kernel using bochs under windows with MSVC 7 or MSVC Express. I have also updated the archive to include a BATCH file so as soon as you unzip it you can run the kernel in bochs! No crazy stuff. No complex commands. Its easy. Also you can simply open the solution file and start tinkering with the kernel, if you screw it up delete it and reunzip the kernel. The kernel included has nothing but a initialization and then displays a letter across video memory just to show that it booted correctly.
-The updated archive with the BATCH file.
http://mcguire.sytes.net/msvcoek.zip
-The old archive missing the BATCH file.
http://www.freewebs.com/kmcguire/hod/fi ... svcoek.zip
-It uses a format called HOD witch I have a little still up on the web at.
http://www.freewebs.com/kmcguire/hod/
If the mcguire.sytes.net link is broken at times simply use notepad to create a file named bochs.bat and type the following inside it.
bochs.exe -f mykernel.cfg
I also figure this maximizes the entertainment or hobbyist value of writting a kernel since it removes the need to write a boot loader, and insteads lets someone concentrate on the so called 'fun' stuff.
MSVC Kernel Framework
- Kevin McGuire
- Member
- Posts: 843
- Joined: Tue Nov 09, 2004 12:00 am
- Location: United States
- Contact:
MSVC Kernel Framework
Last edited by Kevin McGuire on Thu Dec 29, 2005 12:00 am, edited 4 times in total.
- Kevin McGuire
- Member
- Posts: 843
- Joined: Tue Nov 09, 2004 12:00 am
- Location: United States
- Contact:
Re: MSVC Kernel Framework
oops, I was playing around making sure everything worked and I noticed that global varibles were not working and returning the value 0x00. Im not sure for the cause but the work around is as following.
Edit the 2ndstage.cpp
Find the line that says:
hod_Relocate(0x900, 0xFA000);
Change that line to:
hod_Relocate(0x900, 0x1FC000);
You can try lower values or different. It seems the memory area at 0xFA000 is speacil in bochs and possibly on other systems. Sorry.
http://mcguire.sytes.net:8080/ (I did not realize port 80 did not work.)
Edit the 2ndstage.cpp
Find the line that says:
hod_Relocate(0x900, 0xFA000);
Change that line to:
hod_Relocate(0x900, 0x1FC000);
You can try lower values or different. It seems the memory area at 0xFA000 is speacil in bochs and possibly on other systems. Sorry.
http://mcguire.sytes.net:8080/ (I did not realize port 80 did not work.)
Last edited by Kevin McGuire on Thu Dec 29, 2005 12:00 am, edited 1 time in total.
- Kevin McGuire
- Member
- Posts: 843
- Joined: Tue Nov 09, 2004 12:00 am
- Location: United States
- Contact:
Re: MSVC Kernel Framework
I have done a complete revision to the framework.
It is now the:
Microsoft Visual C++ Express 32BIT Kernel Framework
I only have express installed. You can still use earlier versions however, you will need to download the options.txt and setup the solution and project by hand.
The kernel is now Multi-Boot Compliant, and can be loaded by GRUB.
It no longer needs ANY other programs to help format the kernel.
It uses a stub with source code in the archive to perform any boot initialization that GRUB can not perform.
It supports static and global varibles. (For Once I can use strings!)
It includes a Virtual Floppy driver for WinNT(XP/2K).
It includes BOCHS, preconfigured to use drive A: for boot.
It include nasm, presetup to compile the stub code.
It includes Solar's grub_disk.img.
It has not been thoughly tested, but any bugs have to be minor. (It comes with all the source.)
It uses John Fine's gdt.inc code.
http://my.execpc.com/~geezer/os/
http://www.mega-tokyo.com/forum/index.p ... 0#msg75930
So the bottom line is, this archive, now contains the real deal for writting a kernel with MSVC++. No tricks. Done the right way.
I don't care if you make money from it!
(Be patient this link will work. Sometimes it does go down.)
http://mcguire.sytes.net:8080/
I hope I got everything.
It is now the:
Microsoft Visual C++ Express 32BIT Kernel Framework
I only have express installed. You can still use earlier versions however, you will need to download the options.txt and setup the solution and project by hand.
The kernel is now Multi-Boot Compliant, and can be loaded by GRUB.
It no longer needs ANY other programs to help format the kernel.
It uses a stub with source code in the archive to perform any boot initialization that GRUB can not perform.
It supports static and global varibles. (For Once I can use strings!)
It includes a Virtual Floppy driver for WinNT(XP/2K).
It includes BOCHS, preconfigured to use drive A: for boot.
It include nasm, presetup to compile the stub code.
It includes Solar's grub_disk.img.
It has not been thoughly tested, but any bugs have to be minor. (It comes with all the source.)
It uses John Fine's gdt.inc code.
http://my.execpc.com/~geezer/os/
http://www.mega-tokyo.com/forum/index.p ... 0#msg75930
So the bottom line is, this archive, now contains the real deal for writting a kernel with MSVC++. No tricks. Done the right way.
I don't care if you make money from it!
(Be patient this link will work. Sometimes it does go down.)
http://mcguire.sytes.net:8080/
I hope I got everything.