flat assembler
Message board for the users of flat assembler.
Index
> OS Construction > [idea]Boot code tutorial |
Author |
|
calpol2004 23 Feb 2006, 19:20
definetly a good idea. there aren't a lot of tutorials out there for this kind of thing. And the the ones that do exist don't go that in-depth. unfortunatly im way to inexperienced myself to write one . Maybe in a few months/years when i got the hang of this OS development ill write one .
|
|||
23 Feb 2006, 19:20 |
|
vid 23 Feb 2006, 19:34
yes, i couldn't myself find such information together.
|
|||
23 Feb 2006, 19:34 |
|
Madis731 25 Feb 2006, 13:42
Hmm, I'm just starting, but I'll think about it when I get better...I just got the hang of 512-byte bootloader. Now the next step is to increase the codespace to include more code in the ...runnin' outta space...
|
|||
25 Feb 2006, 13:42 |
|
Borsuc 28 Feb 2006, 18:08
code is loaded at 0x7C00 flat address (segments and offsets may vary).. seriously, I think everybody with their own OS knows this
upon entry, dl=drive number (there are not many sites explaining this) the last two bytes should be 55 AA (note, if you use dw 0xAA55 is still correct, 'cause of little endian thing, but I suggest you use db 0x55, 0xAA it's far clearer). i'm not really experienced, but I wanted to share what I know 'bout booting rules. |
|||
28 Feb 2006, 18:08 |
|
kake_zinger 01 Mar 2006, 07:39
I think writing a 512 byte multiboot program would make a nice asm programming contest. I mean pure boot sector loader no 2nd stage, but no space consuming limitations either like FAT filesystem, just pure boot loader on raw disk with data of which LBA has which OS boot sector and able to jmp there with keyboard number input. I'm thinking about a setup where first n sectors of the boot media are left unpartitioned raw space and actual OS partitions only come later. I'm not sure the Windows Wirus likes this approach though.
I don't think it can be done with all meaning of multiboot, including fdd hdd cdrom and usb. Or something along these lines but also including a full pmode OS which drops the user to kind of text command line shell to do whatever he wants, with a program to "continue" booting to other OS later on. I've been working on something like this but recent hardware and time problems have forced me to abandon the project for the moment. What I had in mind was kind of anti-OS which is made for programming and using the PC hardware directly, and only. A simple free flat space with no limitations (and no support either, because the more services are builtin, the more limitations there inherently are due to the design of the services). My project used simple keyboard polling (not interrupt) for input because with interrupt come the questions of the data input model etc which lead much further than at first would be obvious. A bit like good C64 days. (A "proper" input-output model brings forth concepts like pipes, interprocess communication and such and are way removed from the simple reality of a Personal Computer with display memory output and keyboard input.) |
|||
01 Mar 2006, 07:39 |
|
MazeGen 01 Mar 2006, 08:54
SpooK wrote some OS Dev Guide, but there seems to be some kind of error at the moment.
http://win.asmcommunity.net/board/index.php?topic=18162.0 |
|||
01 Mar 2006, 08:54 |
|
smiddy 03 Mar 2006, 19:24
Hey vid (et al),
Well, in my time away I haven't had the opportunity to do any ASM coding at all. My plan is to be more involved again by the 20th of this month. Since I know a few things about booting from both a hardware and software perspective, something like a boot loading tutorial is something I could do that would get my juices flowing again and reaquaint me with ASM coding. I realize this doesn't help you now, but for future folks learning ASM and how the x86 systems work it may be helpful too. |
|||
03 Mar 2006, 19:24 |
|
Dex4u 03 Mar 2006, 19:55
Great smiddy , It would be much easier to point someone to a good "boot code tut", than keep answering the same ??.
|
|||
03 Mar 2006, 19:55 |
|
TDCNL 15 Apr 2006, 18:15
smiddy wrote: Hey vid (et al), Sounds absolutely great for us and for you too Can you guess (we won't turn you down if it's not exactly correct) a date for when you think you got some tutorial on it? _________________ :: The Dutch Cracker :: |
|||
15 Apr 2006, 18:15 |
|
TDCNL 15 Apr 2006, 18:17
The_Grey_Beast wrote: code is loaded at 0x7C00 flat address (segments and offsets may vary).. seriously, I think everybody with their own OS knows this Who exactly has put the drive number in DL ? The BIOS stub that is copied into RAM at bootup? Anyway, why do you need bytes 0x55, 0xAA at the end? I'm very curious at bootloaders _________________ :: The Dutch Cracker :: |
|||
15 Apr 2006, 18:17 |
|
tom tobias 16 Apr 2006, 10:49
Quote:
http://support.microsoft.com/kb/q149877/ and please search for Kake_Zinger on the forum, he recently provided a good explanation.... |
|||
16 Apr 2006, 10:49 |
|
LocoDelAssembly 16 Apr 2006, 15:34
Did you see a BIOS that really doesn't boot up without that signature? All my computers boots a floppy without that mark. I'm not so sure about HDD but at least one of my computers boots without signature.
|
|||
16 Apr 2006, 15:34 |
|
bogdanontanu 16 Apr 2006, 18:25
I have seen a LOT of computers that do NOT boot without that signature.
In fact i have never seen one that boots without a 55AA signature at the end of the floppy boot sector... it is just a simple test after all... why will a BIOS not do it? |
|||
16 Apr 2006, 18:25 |
|
LocoDelAssembly 16 Apr 2006, 22:33
Never? my three computers (one with AMI BIOS and the others with AWARD BIOS) boots a floppy regardless of the presence of the signature. Well, now I know the signature is not for OSes but for BIOSes too. Thanks for the data!!
|
|||
16 Apr 2006, 22:33 |
|
bogdanontanu 17 Apr 2006, 01:22
Yes, never ... but doh i must believe you... how did you tested?
Are you sure that the signature was not there on the floppy? Who produced the computers? Anyway it does not matter much as long as your computer DOES boot a disk with a good signature. Since the target of an OS is to run on ALL computers... any OS writter must obey the rules and place the signature OR else his OS will not run on SOME computers For example it will not run on my computers! BIOS is the program that startups the computer and it is the task of the BIOS to load the first sector from floppy (or HDD or other devices) and to launch it into execution. But if you did not know that already.... hmmm This signature test is done for this first sector as a check for not launching into execution random foloppy's that are in fact not bootable. IF the BIOS does not check for this minimal 55AA signature you could insert any floppy into the computer containing no OS or no code whatsoever, even a blank formated floppy and the BIOS will try to launch THAT? Such actions are funny and stupid to say at least. If what you say is true... then your BIOS is faulty. OR maybe you do not have a BIOS, maybe it is an EFI computer or maybe you boot from HDD or Floppy or another device and you ar not aware of it... besides new computers and laptops do not have a floppy anymore... ...maybe... |
|||
17 Apr 2006, 01:22 |
|
Dex4u 17 Apr 2006, 10:49
bogdanontanu wrote: besides new computers and laptops do not have a floppy anymore... In the UK most PC, but not many laptops, still have floppy drives, just got a 64bit PC with floppy and card reader combind . PS: The thing that a lot of PC do not have anymore, is the cable from the CD drive to the sound card, this means that you waste CPU time, just to play a CD, we all know who's idea this is. |
|||
17 Apr 2006, 10:49 |
|
LocoDelAssembly 18 Apr 2006, 14:24
bogdanontanu, please note that no one of my computers is branded, I bought the components and made it by my own, so I don't have a Compaq nor HP no DELL...
About if I'm sure well, check the attached example of my abandoned project, I'd modified the include file to write 00 00 instead of 55 aa. My motherboard is a K8N SLI Platinum, the BIOS is a "Phoenix - AwardBIOS v6.00PG". At this moment I have flashed version "W7100NMS V3.7 090905". If you need more data ask Regards PS: Please take care, boot.com will replace the data at first sector of drive A: without prompting you anything.
|
|||||||||||
18 Apr 2006, 14:24 |
|
TDCNL 19 Apr 2006, 19:40
I think it's a good idea to include those bytes to be 100% sure your CD/Floppy is bootable,
but regardless, the BIOS will boot anyway if it finds the bootable sector for the type of media (sector 1 for floppy/hdd etc) _________________ :: The Dutch Cracker :: |
|||
19 Apr 2006, 19:40 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.