bios_cursor_position.S 332 B

1234567891011121314151617181920212223
  1. /* https://github.com/cirosantilli/x86-bare-metal-examples#bios-examples */
  2. #include "common.h"
  3. BEGIN
  4. CLEAR
  5. /* Print "ab" */
  6. PUTC $'a
  7. PUTC $'b
  8. /* Move back to 0, 0.*/
  9. mov $0x02, %ah
  10. /* page number 0. TODO what is this? */
  11. mov $0x0, %bh
  12. /* DH=0 row, DL=0 col */
  13. mov $0x0, %dx
  14. int $0x10
  15. /* Overwrite 'a' with c'. */
  16. PUTC $'c
  17. hlt