Real mode assembly appendix A: Difference between revisions

From OSDev.wiki
Jump to navigation Jump to search
[unchecked revision][unchecked revision]
Content added Content deleted
(added 80x60 text mode trick)
(use appropriate template)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{You}}
''This is the appendix of the real mode assembly bare bones series, containing nifty tidbits of information, code, and ideas.''
''This is the appendix of the real mode assembly bare bones series, containing nifty tidbits of information, code, and ideas.''


Line 10: Line 11:


===80x60 text mode===
===80x60 text mode===
As far as I can tell, there is no way to do this with standard VGA modes. If anyone has done this, please tell by emailing me at blasterman95 _AT_ gmail _DOT_ com or by PM'ing me on the forums! Thanks!
Follow the steps outlined above to set up 640x480 (8x16 font) "text mode" first. After that, use the following code snippet:

mov ax, 1123h ; 8x8 chars in graphics mode
mov bl, 0 ; Row = 0 (don't ask cause I don't know)
int 10h ; BIOS video interrupt

You should have 80x60 text mode in a 640x480 environment. Note that I haven't tested it (I'm writing it away from my dev box) on either emulated hardware or real hardware. So be careful.


[[Category:Assembly]]
[[Category:Real mode assembly]]
[[Category:Real mode assembly]]

Latest revision as of 08:29, 17 June 2024

This article refers to its readers using you in an unencyclopedic manner.
It should be edited to be in an encyclopedic tone.

This is the appendix of the real mode assembly bare bones series, containing nifty tidbits of information, code, and ideas.

Links to other articles with code

Code

Text in 640x480 16-colour graphics mode

VGA video mode 12h is a 640x480 resolution, in which (with a little tweaking) can be used with your string printing function. All you have to do is add a mov bh,07h to allow regular coloured printing in graphics mode. At the moment, the cursor is disabled. You must find a way to eliminate it or do up a function specifically for printing in graphics mode.

80x60 text mode

As far as I can tell, there is no way to do this with standard VGA modes. If anyone has done this, please tell by emailing me at blasterman95 _AT_ gmail _DOT_ com or by PM'ing me on the forums! Thanks!