bootsector.txt
What is a bootsector?
A boot sector is the sector of a persistent data storage device (e.g., hard disk, floppy disk, optical disc, etc.) which contains machine code to be loaded into random-access memory (RAM) and then executed by a computer system's built-in firmware (e.g., the BIOS).
Usually, the first sector of the hard disk is the boot sector, regardless of sector size (512 or 4096 bytes) and partitioning flavor (MBR or GPT).
The fun part about writing code that would run in a bootsector for a intel compatible processor that runs on the IMB PC and compatibles is that it only provides a 16bit real mode for the processor and 512bytes for the code itself
On an IBM PC compatible machine, the BIOS selects a boot device, then copies the first sector from the device (which may be a MBR, VBR or any executable code), into physical memory at memory address 0x7C00. On other systems, the process may be quite different.
We are however only concerned with the "default" which is the one that loads code at 0x7c00 and provides 512 bytes of data