Real Mode Assembly: Print Char to Screen without INT Instruction on Boot

前端 未结 3 1946
夕颜
夕颜 2021-02-09 17:50

The following site \"Writing Boot Sector Code\" provides a sample of code that prints \'A\' to the screen when the system boots. From what I have been reading don\'t you have to

3条回答
  •  抹茶落季
    2021-02-09 18:42

    At boot, you're in a default screen mode - in this case a text screen mode. Your example program is writing directly into the character buffer that's displayed on the screen for that text screen mode. Setting the data segment register to 0xb800 is getting things set up to point at that buffer. Check out this tutorial for more information.

提交回复
热议问题