972
edits
[unchecked revision] | [unchecked revision] |
m (Bot: Replace deprecated source tag with syntaxhighlight) |
|||
Line 47:
'''Source in C'''
<
void enable_cursor(uint8_t cursor_start, uint8_t cursor_end)
{
Line 56:
outb(0x3D5, (inb(0x3D5) & 0xE0) | cursor_end);
}
</syntaxhighlight>
===Disabling the Cursor===
Line 62:
'''Source in C'''
<
void disable_cursor()
{
Line 68:
outb(0x3D5, 0x20);
}
</syntaxhighlight>
'''Source in Assembly'''
<
disable_cursor:
pushf
Line 90:
popf
ret
</syntaxhighlight>
===Moving the Cursor===
Line 98:
'''Source in C'''
<
void update_cursor(int x, int y)
{
Line 108:
outb(0x3D5, (uint8_t) ((pos >> 8) & 0xFF));
}
</syntaxhighlight>
'''Source in Assembly'''
<
Cursor:
VGA.Width equ 80
Line 144:
out dx, al
ret
</syntaxhighlight>
===Get Cursor Position===
|