source: trunk/BOOTCODE/SPECIAL/CHARSET.ASM@ 47

Last change on this file since 47 was 45, checked in by Ben Rietbroek, 12 years ago

Now using compressed HidePartTable (auxdebug on) [2012-02-24]

WARNING!!

All commits upto and including the commit of [2012-05-13] contain
a severe bug!! Building from these sources and then disabling
the 'force LBA' feature while also using the drive-letter feature or
editing the label can DESTROY THE MBR on ALL ATTACHED DISKS!!
DO NOT DISABLE 'FORCE LBA USAGE' WHEN BUILT FROM THE THESE COMMITS!!

Fixes

o HidePartTabled now uses a 6-bit compressed format

Bitfield functions are used to manipulate the table.
Modifications mostly in PARTSCAN.ASM, PART_SET.ASM and PARTMAIN.ASM.
TODO: Determine impact on upgrading from previous versions.

Changes

o Changed LVM Label behavior

If they are the same, the LVM VolumeName is synced to LVM PartitionName
so they are the same again after the edit.
If they differ, only the LVM VolumeName is updated.

o Implemented stop scanning when partition limit of 45 is exceeded

User is presented with a warning pop-up.
Pressing a key will continue and the partitions that were found
so far are displayed in the menu.
The color of the selection bar is changed to red to indicate this
overflow situation.

o New overlap macro that works correctly with JWasm and Tasm

Now uses DB n DUP (<filler>) to fill space before a new ORG.
When overlap occurs n goes negative causing assembler error.

File size: 3.1 KB
Line 
1; AiR-BOOT (c) Copyright 1998-2008 M. Kiewitz
2;
3; This file is part of AiR-BOOT
4;
5; AiR-BOOT is free software: you can redistribute it and/or modify it under
6; the terms of the GNU General Public License as published by the Free
7; Software Foundation, either version 3 of the License, or (at your option)
8; any later version.
9;
10; AiR-BOOT is distributed in the hope that it will be useful, but WITHOUT ANY
11; WARRANTY: without even the implied warranty of MERCHANTABILITY or FITNESS
12; FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
13; details.
14;
15; You should have received a copy of the GNU General Public License along with
16; AiR-BOOT. If not, see <http://www.gnu.org/licenses/>.
17;
18;---------------------------------------------------------------------------
19; AiR-BOOT / CHARSET SUPPORT
20;---------------------------------------------------------------------------
21
22; This file is only included, when compiling versions that are meant to
23; contain special characters that are not included in the Video ROM charset.
24
25; May destroy all-purpose registers (AX,BX,CX,DX), will preserve all others
26CHARSET_IncludeCyrillic Proc Near Uses si di bp
27 ; First we get the ROM charset from BIOS...
28 mov ax, 1130h
29 mov bh, 6 ; Get ROM VGA 25x80 charset
30 int 10h ; VIDEO BIOS: Get charset table pointer
31 mov bx, ds ; ES:BP point to charset (in Video-ROM)
32 mov ax, es
33 mov es, bx
34 mov ds, ax
35 mov si, bp ; DS:SI - ROM Font 25x80 and ES==CS
36 mov di, offset CharsetTempBuffer
37 mov cx, 2048
38 rep movsw ; Copy ROM-charset to Temp-Buffer
39 mov ds, bx ; DS==CS
40 mov si, offset CHARSET_Cyrillic
41 mov di, offset CharsetTempBuffer+2048
42
43 mov dl, 64 ; Decode 64 character bitmaps
44 xor al, al
45 xor ch, ch
46 DecodeLoop: ; This is an uncompressing-loop
47 mov ah, ds:[si]
48 inc si
49 mov cl, ah
50 and cl, 0Fh
51 rep stosb ; Write NULs, count: lower 4 bits
52 mov cl, ah
53 shr cl, 4
54 or cl, cl
55 jz EndOfStream
56 rep movsb
57 jmp DecodeLoop
58 EndOfStream:
59 cmp di, offset CharsetTempBuffer+3840
60 jae DecodeDone
61 add di, 768 ; Skip 3x16 char blocks
62 jmp DecodeLoop
63 DecodeDone:
64 call FX_WaitRetrace ; Wait for retrace to reduce flickering
65 mov ax, 1110h
66 mov bh, 16
67 xor bl, bl
68 mov cx, 0FFh
69 xor dx, dx
70 mov bp, offset CharsetTempBuffer ; ES:BP - New charset
71 int 10h ; VIDEO BIOS: Set new charset table
72 mov ah, 12h
73 mov bl, 30h
74 mov al, 2 ; 400 ScanLines
75 int 10h ; VIDEO BIOS: Set Scanlines
76 ret
77CHARSET_IncludeCyrillic EndP
Note: See TracBrowser for help on using the repository browser.