This post is a continuation from the previous post [ Writting a Bootloader ] which was an attempt to build a Bootloader for the x86 architecture. Although the executable size is limited to 512 Bytes, there are several important tasks that can be accomplished during booting process. One of them is to read the Geometry from several storage devices. Interrupt 13h [ INT 13h ] provides sector-based disk access services using the CHS addressing method (Cylinder/Head/Sectors). This values provide the physical location of the data (although this is not completely true nowadays). The code below is an example of this interrupt. It reads the CHS from the first Hard Disk using Interrupt 13h. Briefly, interrupt parameters are set in AX and DX registers. After interrupt is completed, its values can be read from the appropriate registers (CX, DX). The rest of the code includes helper functions to print numbers and strings to present results properly. After booting our virtu...