![]() |
assembly boot code
i'm trying to make a startup disk , i want to study the boot code that i will write on the first sector on the disk
anybody can tell me where is that code and what assembler do i use to compile it ? thanks |
You can use pretty much any assembler to assemble it, and what do you mean "where is that code?" If you're asking for an example, here's one that helped me when I was experimenting a couple of years ago:
http://osdever.net/tutorials/hello_btldr.php?the_id=85 |
i'll take a look at that
but if u have anything that is quick and easy to write on a floppy boot sector i want to boot from the floppy the CMD or write anything on the screen thanks and it will be alot better if it's compatible with MASM |
I used NASM, so I tried to use more material for NASM. I don't have any of the MASM sites bookmarked, so i can't help you there, but it's the same concept so it shouldn't be too difficult to change the code up a little bit and make it compatible with MASM. Also, I used debug to write to the disk. You could try that.
|
i'm a biginner i couldnt understand most of the code
i just really need to get the job done and then do the understanding part i know it sounds crazy but i gotta do it so how can i get a code straight to a compiler and then write the files to a disk and boot from it ? thanks for helping me |
Why don't you begin your beginneriness with something that clues you in a tad more than you are. Or, if you want someone to do your stuff FOR you, don't beat around the bush, just say so.
|
Quote:
Quote:
|
before you create a bootloader you have to understand that the bios looks for the value 0x55 in the 510 location of the device (which is a drive A) and 0xaa in the 511 location. here is the code to write a simple bootdisk in C but this is not very good because it just goes into the bootloader and comes straight out.
Here is the code Quote:
|
There's a tab key reachable by your left pinky on most keyboards. Learning to use it wisely might induce more people to read your code. Just sayin'.
|
Boot.ini
goto command prompt and type attrb -r -h -s boo.ini to make it editable and viewable.
|
| All times are GMT -5. The time now is 4:43 PM. |
Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC