some low level routines
some low level routines
Does anyone have assembler low level routines for reading a character from keyboard, displaying a character on the screen clearing the keyboard buffer, moving a cursor, etc.
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:some low level routines
for what environment ? plain hardware ? BIOS ? MS-DOS ?
-
- Member
- Posts: 1600
- Joined: Wed Oct 18, 2006 11:59 am
- Location: Vienna/Austria
- Contact:
Re:some low level routines
mov ax,0xb8000
mov gs,ax
mov [gs:2],'q'
simplest code to put a character on the screen.
mov gs,ax
mov [gs:2],'q'
simplest code to put a character on the screen.
... the osdever formerly known as beyond infinity ...
BlueillusionOS iso image
BlueillusionOS iso image
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:some low level routines
that's because at the lowest level, there's no keyboard buffer...
reading a character from the keyboard is done with
For the cursor (text) placement, check the VGA registers, and mainly the Cathod Ray Tube Controller (CRT controller) registers...
I've seen a reference to it in a 2-weeks old thread called something like "print function" ...
reading a character from the keyboard is done with
Code: Select all
in al,0x60
cmp al,128
jae .keyup
;; key with scancode <al> pressed
.keyup:
;; key with scancode <al&127> released.
I've seen a reference to it in a 2-weeks old thread called something like "print function" ...
Re:some low level routines
Are there any texts on the Web dealing with VGA registers and low level VGA programming ?
- Pype.Clicker
- Member
- Posts: 5964
- Joined: Wed Oct 18, 2006 2:31 am
- Location: In a galaxy, far, far away
- Contact:
Re:some low level routines
yep. try google, or search within the forum's archive ...