diff --git a/Graphisme/boot.png b/Graphisme/boot.png
new file mode 100644
index 0000000..55b85d0
Binary files /dev/null and b/Graphisme/boot.png differ
diff --git a/Graphisme/boot.svg b/Graphisme/boot.svg
new file mode 100644
index 0000000..b160d96
--- /dev/null
+++ b/Graphisme/boot.svg
@@ -0,0 +1,246 @@
+
+
+
+
diff --git a/Graphisme/fond.png b/Graphisme/fond.png
new file mode 100644
index 0000000..f6a7e1b
Binary files /dev/null and b/Graphisme/fond.png differ
diff --git a/Graphisme/fond.svg b/Graphisme/fond.svg
new file mode 100644
index 0000000..5429d97
--- /dev/null
+++ b/Graphisme/fond.svg
@@ -0,0 +1,567 @@
+
+
+
+
diff --git a/Graphisme/logo.svg b/Graphisme/logo.svg
new file mode 100644
index 0000000..9dee3f9
--- /dev/null
+++ b/Graphisme/logo.svg
@@ -0,0 +1,250 @@
+
+
+
+
diff --git a/Graphisme/screenshots/ansi.png b/Graphisme/screenshots/ansi.png
new file mode 100644
index 0000000..503481f
Binary files /dev/null and b/Graphisme/screenshots/ansi.png differ
diff --git a/SCREENSHOTS.md b/SCREENSHOTS.md
new file mode 100644
index 0000000..abea77c
--- /dev/null
+++ b/SCREENSHOTS.md
@@ -0,0 +1,4 @@
+![logo](https://github.com/dahut87/cos2000v2/raw/master/Graphisme/logo.png)
+
+## Copies d'écran de COS2000
+![screen](https://github.com/dahut87/cos2000v2/raw/develop/Graphisme/screenshots/ansi.png)
diff --git a/boot/boot12.asm b/boot/boot12.asm
old mode 100644
new mode 100755
index 6a68b40..6b2242f
--- a/boot/boot12.asm
+++ b/boot/boot12.asm
@@ -4,14 +4,14 @@
section .text
start:
- jmp near Boot
+ jmp near Boot
-Disk_ID db "COS2000A" ;Fabricant + n° de série Formatage
+Disk_ID db "COS2000A" ;Fabricant + n° de série Formatage
Sectors_Size dw 512 ;Nombre d'octets/secteur
Sectors_Per_Cluster db 1 ;Nombre de secteurs/cluster
Reserved_Sectors dw 1 ;Nombre de secteurs réservé
-Fats_Number db 2 ;Nombre de copies de la FAT
-Fits_Number dw 224 ;Taille du répertoire racine
+Fats_Number db 2 ;Nombre de copies de la FAT
+Fits_Number dw 224 ;Taille du répertoire racine
Sectors_Per_Disk dw 2880 ;Nombre secteurs du volume si < 32 Mo
Media_Descriptor db 0xF0 ;Descripteur de média
Sectors_Per_Fat dw 9 ;Nombre secteurs/FAT
@@ -19,131 +19,131 @@ Sectors_Per_Track dw 18 ;Nombre secteurs/piste
Heads_Number dw 2 ;Nombre de tete de lecture/écriture
Sectors_Hidden dd 0 ;Nombre de secteurs cachés
Sectors_Per_Disk2 dd 0 ;Nombre secteurs du volume si > 32 Mo
-Boot_Drive db 0 ;Lecteur de démarrage
-Reserved db 0 ;NA (pour NT seulement)
+Boot_Drive db 0 ;Lecteur de démarrage
+Reserved db 0 ;NA (pour NT seulement)
Extended_Boot_ID db 0x29 ;Signature Boot étendu 29h
Serial_Number dd 0x01020304 ;N° de série
-Disk_Name db "COS2000 " ;Nom de volume
-Fat_Type db "FAT12 " ;Type de système de fichiers
+Disk_Name db "COS2000 " ;Nom de volume
+Fat_Type db "FAT12 " ;Type de système de fichiers
-;Cpu_Message db "CPU test",0
-Boot_Message db "Booting ",0
-Finding_Message db "System ",0
-Loading_Message db "Loading ",0
-System_File db "SYSTEM SYS"
-Is_Ok db "[ OK ]",0x0A,0x0D,0
-Is_Failed db "[Failed]",0x0A,0x0D,"Press a key",0x0A,0x0D,0
-The_Dot db '.',0
+Boot_Message db "Cos2000",0
+Entre_Message db "Fichier",0
+Loading_Message db "Charger",0
+System_File db "Al",0,"o",0,"a",0,"d",0,"e",0,0x0F,0,0x38,"r",0,".",0,"s",0,"y",0,"s",0,0,0,0,0,0xFF,0xFF,0xFF,0xFF
+Is_Ok db " [ OK ]",0x0A,0x0D,0
+Is_Failed db " [ERREUR]",0x0A,0x0D,0
+The_Dot db '.',0
Boot_Error:
- mov si,Is_Failed
- call ShowString
- mov ah,0
- int 0x16
- int 0x19
+ mov si,Is_Failed
+ call ShowString
+ xor ax,ax
+ int 0x16
+ int 0x19
Boot_Ok:
- mov al,[Stage]
- cmp al,0
- jz No_Ok
- mov si,Is_Ok
+ mov si,Is_Ok
call ShowString
-No_Ok:
- xor ah,ah
- mov si,ax
- add si,Boot_Message ;Cpu_Message
- call ShowString
- add byte [Stage],0x09
- ret
-
-Stage db 0
+ ret
Boot:
- push cs
- push cs
- pop es
- pop ds
+ push cs
+ push cs
+ pop es
+ pop ds
mov [Boot_Drive],dl
- cli
- mov ax,0x9000
- mov ss,ax
- mov sp,0xFFFF
- sti
-; call Detect_Cpu
-; jc Boot_Error
- call Boot_Ok
- xor ax,ax
- int 0x13
- jc Boot_Error
+ cli
+ mov ax,0x9000
+ mov ss,ax
+ mov sp,0xFFFF
+ sti
+ mov si,Boot_Message
+ call ShowString
+ xor ax,ax
+ int 0x13
+ jc Boot_Error
mov cx,[Reserved_Sectors]
- add cx,[Sectors_Hidden]
- adc cx,[Sectors_Hidden+2]
- mov di,Fat_Buffer
- call ReadSector
- jc Boot_Error
- xor ax,ax
- mov al,[Fats_Number]
- mov bx,[Sectors_Per_Fat]
- mul bx
- add cx,ax
- mov ax,32
- mul word [Fits_Number]
- div word [Sectors_Size]
- add ax,cx
- sub ax,2
- mov word [Serial_Number],ax
- xor dx,dx
+ add cx,[Sectors_Hidden]
+ adc cx,[Sectors_Hidden+2]
+ mov bx,[Sectors_Per_Fat]
+ mov di,Fat_Buffer
+ push bx
+ push cx
+readfat:
+ call ReadSector
+ jc Boot_Error
+ inc cx
+ add di,[Sectors_Size]
+ dec bx
+ jnz readfat
+ pop cx
+ pop bx
+ xor ax,ax
+ mov al,[Fats_Number]
+ mul bx
+ add cx,ax
+ mov ax,32
+ mul word [Fits_Number]
+ div word [Sectors_Size]
+ add ax,cx
+ sub ax,2
+ mov word [Serial_Number],ax
+ xor dx,dx
call Boot_Ok
+ mov si,Loading_Message
+ call ShowString
Find_System:
- mov di,Buffer
- call ReadSector
- jc Near Boot_Error
- xor bx,bx
+ mov di,Buffer
+ call ReadSector
+ jc Near Boot_Error
+ xor bx,bx
Next_Root_Entrie:
- cmp byte [di],0
- je near Boot_Error
- push di
- push cx
- mov si,System_File
- mov cx,11
- rep cmpsb
- pop cx
- pop di
- je System_Found
- add di,32
- add bx,32
- inc dx
- cmp dx,[Fits_Number]
- ja near Boot_Error
- cmp bx,[Sectors_Size]
- jb Next_Root_Entrie
- inc cx
- jmp Find_System
+ cmp byte [di],0
+ je near Boot_Error
+ push di
+ push cx
+ mov si,System_File
+ mov cx,32
+ rep cmpsb
+ pop cx
+ pop di
+ je System_Found
+ add di,32
+ add bx,32
+ inc dx
+ cmp dx,[Fits_Number]
+ ja near Boot_Error
+ cmp bx,[Sectors_Size]
+ jb Next_Root_Entrie
+ inc cx
+ jmp Find_System
System_Found:
- mov cx,[di+26]
- mov ax,0x0071
- mov es,ax
- push es
- mov di,0x100
- push di
- call Boot_Ok
+ call Boot_Ok
+ mov si,Entre_Message
+ call ShowString
+ mov cx,[di+26+32]
+ mov ax,0x0080
+ mov es,ax
+ push es
+ mov di,0x0
+ push di
mov si,The_Dot
Resume_Loading:
- cmp cx,0x0FF0
- jae Finish_Loading
- push cx
- add cx,word [Serial_Number]
- call ReadSector
- pop cx
- jc near Boot_Error
- call ShowString
- add di,[Sectors_Size]
- call NextFatGroup
- jc near Boot_Error
- jmp Resume_Loading
+ cmp cx,0x0FF0
+ jae Finish_Loading
+ push cx
+ add cx,word [Serial_Number]
+ call ReadSector
+ pop cx
+ jc near Boot_Error
+ call ShowString
+ add di,[Sectors_Size]
+ call NextFatGroup
+ jc near Boot_Error
+ jmp Resume_Loading
Finish_Loading:
call Boot_Ok
- retf
+ retf
;====================READSECTOR=======================
;Lit le secteur logique LBA CX et le met en es:di
@@ -152,15 +152,15 @@ Finish_Loading:
;=====================================================
ReadSector:
pusha
- mov ax,cx
+ mov ax,cx
xor dx,dx
div word [Sectors_Per_Track]
inc dl
mov bl,dl
xor dx,dx
- div word [Heads_Number]
- mov dh, [Boot_Drive]
- xchg dl,dh
+ div word [Heads_Number]
+ mov dh, [Boot_Drive]
+ xchg dl,dh
mov cx,ax
xchg cl,ch
shl cl,6
@@ -187,30 +187,30 @@ NextFatGroup:
push bx
push dx
push di
- mov ax,cx
- mov bx,ax
- and bx,0000000000000001b
- shr ax,1
- mov cx,3
- mul cx
- mov di,Fat_Buffer
- add di,ax
- cmp bx,0
- jnz Even_Group
+ mov ax,cx
+ mov bx,ax
+ and bx,0000000000000001b
+ shr ax,1
+ mov cx,3
+ mul cx
+ mov di,Fat_Buffer
+ add di,ax
+ cmp bx,0
+ jnz Even_Group
Odd_Group:
- mov dx,[di]
- and dx,0x0FFF
- mov cx,dx
- jmp Next_Group_Found
+ mov dx,[di]
+ and dx,0x0FFF
+ mov cx,dx
+ jmp Next_Group_Found
Even_Group:
- mov dx,[di+1]
- and dx,0xFFF0
- shr dx,4
- mov cx,dx
+ mov dx,[di+1]
+ and dx,0xFFF0
+ shr dx,4
+ mov cx,dx
Next_Group_Found:
- pop di
- pop dx
- pop bx
+ pop di
+ pop dx
+ pop bx
ret
;======================SHOWSTR========================
@@ -219,7 +219,7 @@ Next_Group_Found:
;<- Flag Carry si erreur
;=====================================================
ShowString:
- pusha
+ pusha
Next_Char:
lodsb
or al,al
@@ -229,37 +229,8 @@ Next_Char:
int 0x10
jmp Next_Char
End_Show:
- popa
- ret
-
-;======================DETECTCPU======================
-;Detecte si le processeur est un 386 au mini
-;->
-;<- Flag Carry si erreur
-;=====================================================
-;Detect_Cpu:
-; push ax ; test if 8088/8086 is present (flag bits 12-15 will be set)
-; xor ah,ah ; ah = 0
-; push ax ; copy ax into the flags
-; popf ; with bits 12-15 clear
-; pushf ; Read flags back into ax
-; pop ax
-; and ah,0xF0 ; check if bits 12-15 are set
-; cmp ah,0xF0
-; je No_386 ; no 386 detected (8088/8086 present)
-; ; check for a 286 (bits 12-15 are clear)
-; mov ah,0xF0 ; set bits 12-15
-; push ax ; copy ax onto the flags
-; popf
-; pushf ; copy the flags into ax
-; pop ax
-; and ah,0xF0 ; check if bits 12-15 are clear
-; jz No_386 ; no 386 detected (80286 present)
-; clc
-; ret
-;No_386:
-; stc
-; ret
+ popa
+ ret
times 510-($-$$) db ' '
@@ -271,4 +242,4 @@ Fat_Buffer equ $+512
section .bss
;Buffer resb 512
-;Fat_Buffer resb 10000
\ No newline at end of file
+;Fat_Buffer resb 10000
diff --git a/boot/boot16.asm b/boot/boot16.asm
old mode 100644
new mode 100755
diff --git a/boot/bootcp.asm b/boot/bootcp.asm
deleted file mode 100644
index 6a32fa9..0000000
--- a/boot/bootcp.asm
+++ /dev/null
@@ -1,88 +0,0 @@
-[BITS 16]
-[ORG 0x100]
-
-section .text
-
-start:
- mov ah,09
- mov dx,msg
- int 0x21
- cmp byte [0x80],2
- jne near error
- mov ax,0x3D02
- mov dx,name
- int 0x21
- jc near error
- mov bx,ax
- mov ax,0x4202
- xor cx,cx
- xor dx,dx
- int 0x21
- jc error
- cmp dx,0
- jne error
- cmp ax,512
- jne error
- mov ax,0x4200
- xor cx,cx
- xor dx,dx
- int 0x21
- jc error
- mov ah,0x3F
- mov cx,512
- mov dx,buffer2
- int 0x21
- jc error
- cmp word [buffer2+510],0xAA55
- jne error
- mov al,[0x82]
- cmp al,'z'
- ja error
- cmp al,'a'
- jb verif
- sub al,'a'-'A'
-verif:
- cmp al,'Z'
- ja error
- cmp al,'A'
- jb error
- sub al,'A'
- mov bp,ax
- mov [segs],cs
- mov cx,0xFFFF
- mov bx,packet
- int 0x25
- pop ax
- mov si,buffer+3
- mov di,buffer2+3
- mov cx,59
- rep movsb
- mov ax,bp
- mov word [offs],buffer2
- mov cx,0xFFFF
- mov bx,packet
- int 0x26
- pop ax
- jc error
- mov ah,09
- mov dx,msgok
- int 0x21
- ret
-
-error:
- mov ah,09
- mov dx,msgerror
- int 0x21
- ret
-
-
-packet dd 0
- dw 1
-offs dw buffer
-segs dw 0
-name db "boot.bin",0
-msg db 0x0D,0x0A,"CopyBoot V1.0 by nico",0x0D,0x0A,"Copyright 2002",0x0D,0x0A,'$'
-msgok db "Installation of bootsector realized",0x0D,0x0A,'$'
-msgerror db "Installation of bootsector failed",0x0D,0x0A,'$'
-buffer equ $
-buffer2 equ $+512
\ No newline at end of file
diff --git a/boot/boottest.asm b/boot/boottest.asm
deleted file mode 100644
index 3e61ceb..0000000
--- a/boot/boottest.asm
+++ /dev/null
@@ -1,217 +0,0 @@
-[BITS 16]
-[ORG 0x7C00]
-
-section .text
-
-start:
- jmp near boot
-
-Disk_ID db "COS2000A" ;Fabricant + n° de série Formatage
-Sectors_Size dw 512 ;Nombre d"octets/secteur
-Sectors_Per_Cluster db 1 ;Nombre de secteurs/cluster
-Reserved_Sectors dw 1 ;Nombre de secteurs réservé
-Fats_Number db 2 ;Nombre de copies de la FAT
-Fits_Number dw 224 ;Taille du répertoire racine
-Sectors_Per_Disk dw 2880 ;Nombre secteurs du volume si < 32 Mo
-Media_Descriptor db 0xF0 ;Descripteur de média
-Sectors_Per_Fat dw 9 ;Nombre secteurs/FAT
-Sectors_Per_Track dw 18 ;Nombre secteurs/piste
-Heads_Number dw 2 ;Nombre de tete de lecture/écriture
-Sectors_Hidden dd 0 ;Nombre de secteurs cachés
-Sectors_Per_Disk2 dd 0 ;Nombre secteurs du volume si > 32 Mo
-Boot_Drive db 0 ;Lecteur de démarrage
-Reserved db 0 ;NA (pour NT seulement)
-Extended_Boot_ID db 0x29 ;Signature Boot étendu 29h
-Serial_Number dd 0x01020304 ;N° de série
-Disk_Name db "COS2000 " ;Nom de volume
-Fat_Type db "FAT12 " ;Type de système de fichiers
-
-Loading_Ok db "Secteur en execution",0x0A,0x0D,0
-Reg_Names db "cs ",0
- db "ds ",0
- db "es ",0
- db "fs ",0
- db "gs ",0
- db "ss ",0
- db "eax",0
- db "ebx",0
- db "ecx",0
- db "edx",0
- db "esi",0
- db "edi",0
- db "esp",0
- db "ebp",0
- db "eip",0
- db "FLG",0
- db "cr0",0
- db "cr1",0
- db "cr2",0
- db "cr3",0
-
-Return db 0x0A,0x0D,0
-
-Numbers equ 20
-
-boot:
- mov [cs:segms],cs
- mov [cs:segms+4],ds
- mov [cs:segms+8],es
- mov [cs:segms+12],fs
- mov [cs:segms+16],gs
- mov [cs:segms+20],ss
- mov [cs:segms+24],eax
- mov [cs:segms+28],ebx
- mov [cs:segms+32],ecx
- mov [cs:segms+36],edx
- mov [cs:segms+40],esi
- mov [cs:segms+44],edi
- mov [cs:segms+48],esp
- mov [cs:segms+52],ebp
-IP:
- mov word [cs:segms+56],IP
- mov word [cs:segms+58],0
- pushfd
- pop dword [cs:segms+60]
- mov eax,cr0
- mov [cs:segms+64],eax
- mov eax,cr0
- mov [cs:segms+68],eax
- mov eax,cr2
- mov [cs:segms+72],eax
- mov eax,cr3
- mov [cs:segms+76],eax
- cli
- mov ax,0x9000
- mov ss,ax
- mov sp,0xFFFF
- sti
- push cs
- push cs
- pop es
- pop ds
- mov si,Loading_Ok
- call ShowString
- xor bx,bx
-Show_All_Regs:
- mov si,Reg_Names
- shl bx,2
- add si,bx
- call ShowString
- mov al,":"
- call ShowChar
- mov si,segms
- mov edx,[bx+si]
- shr bx,2
- mov cx,32
- cmp bx,6
- jae Reg_Size_32
- mov cx,16
-Reg_Size_32:
- call ShowHex
- mov si,Return
- call ShowString
- inc bx
- cmp bx,Numbers
- jb Show_All_Regs
-Halting_Cpu:
- jmp Halting_Cpu
-
-;==================SHOWHEX==================
-;Affiche un nombre hexadécimal EDX de taille CX aprés le curseur
-;-> EDX un entier, CX la taille
-;<-
-;===========================================
-ShowHex:
- push ax
- push bx
- push cx
- push edx
- mov ax,cx
- shr ax,2
- sub cx,32
- neg cx
- shl edx,cl
- xchg ax,cx
-Hex_Decompose:
- rol edx,4
- mov bx,dx
- and bx,0x0F
- mov al,[cs:bx+Hex_Table]
- call ShowChar
- dec cl
- jnz Hex_Decompose
- pop edx
- pop cx
- pop bx
- pop ax
- ret
-Hex_Table db "0123456789ABCDEF"
-
-;===================CLS====================
-;Efface l"écran
-;->
-;<-
-;==========================================
-Cls:
- push ax
- mov ax,0x0003
- int 0x10
- pop ax
- ret
-
-;================SHOWCHAR==================
-;Affiche un caractère pointé dans AL
-;-> AL
-;<-
-;==========================================
-ShowChar:
- push ax
- push bx
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- pop bx
- pop ax
- ret
-
-;===================SHOWSTR================
-;Affiche une chaine de caractère pointé par SI
-;-> SI pointe une chaine
-;<-
-;==========================================
-ShowString:
- push ax
- push bx
- push si
- cld
-Show_Next_Char:
- lodsb
- or al,al
- jz String_Showed
- call ShowChar
- jmp Show_Next_Char
-String_Showed:
- pop si
- pop bx
- pop ax
- ret
-
-;=================WAITKEY=================
-;Attend l"appuie d"une touche et
-;renvoie en AL la touche appuyée
-;->
-;<- AL
-;=========================================
-WaitKey:
- mov ax,0x00
- int 0x16
- ret
-
-times 510-($-$$) db ' '
-
-dw 0xAA55
-
-section .bss
-
-segms resb 10000
-
diff --git a/boot/echs.h b/boot/echs.h
old mode 100644
new mode 100755
index fc1bba9..7309f47
--- a/boot/echs.h
+++ b/boot/echs.h
@@ -1,10 +1,10 @@
-struc echs
-Sizes resb 1
-Reserve resb 1
-NumSectors resw 1
-Adressoff resw 1
-Adressseg resw 1
-SectorLow resw 1
-SectorHigh resw 1
-Dummy resq 1
-endstuc
+struc echs
+Sizes resb 1
+Reserve resb 1
+NumSectors resw 1
+Adressoff resw 1
+Adressseg resw 1
+SectorLow resw 1
+SectorHigh resw 1
+Dummy resq 1
+endstuc
diff --git a/boot/elf.h b/boot/elf.h
new file mode 100755
index 0000000..bfb892f
--- /dev/null
+++ b/boot/elf.h
@@ -0,0 +1,116 @@
+struc ELFheader
+.Magic resb 1;"0x7F"
+.MagicStr resb 3;"ELF"
+.Computertype resb 1;1
+.Endianness resb 1;1
+.Original resb 1;1
+.OS resb 1;0
+.ABI resb 1;0
+.Dummy resb 7;0
+.Type resw 1;2
+.Target resw 1;3
+.Version resd 1;1
+.Entrypoint resd 1
+.Offsetprogram resd 1
+.Offsetsection resd 1
+.Flags resd 1
+.SizeELFheader resw 1
+.Sizeprogram resw 1
+.Nbprogram resw 1
+.Sizesection resw 1
+.Nbsection resw 1
+.Index resw 1
+.end equ $
+endstruc
+
+struc Program
+.Type resd 1
+.Offset resd 1
+.Vadress resd 1
+.PAdress resd 1
+.Size resd 1
+.Memsize resd 1
+.Flags resd 1
+.Align resd 1
+.end equ $
+endstruc
+
+struc Sections
+.Name resd 1
+.Type resd 1
+.Flags resd 1
+.Vadress resd 1
+.Offset resd 1
+.Size resd 1
+.Link resd 1
+.Info resd 1
+.Align resd 1
+.Entrysize resd 1
+.end equ $
+endstruc
+
+
+;type
+PT_NULL equ 0
+PT_LOAD equ 1
+PT_DYNAMIC equ 2
+PT_INTERP equ 3
+PT_NOTE equ 4
+PT_SHLIB equ 5
+PT_PHDR equ 6
+PT_TLS equ 7
+PT_LOOS equ 0x60000000
+PT_HIOS equ 0x6fffffff
+PT_LOPROC equ 0x70000000
+PT_HIPROC equ 0x7fffffff
+
+;flags
+PF_WRITE equ 0x1
+PF_ALLOC equ 0x2
+PF_X equ 0x1 ;Execute
+PF_W equ 0x2 ;Write
+PF_R equ 0x4 ;Read
+PF_MASKOS equ 0x0ff00000 ;Unspecified
+PF_MASKPROC equ 0xf0000000 ;Unspecified
+
+;type
+ST_EXIT equ 1
+ST_NULL equ 0
+ST_PROGBITS equ 1
+ST_SYMTAB equ 2
+ST_STRTAB equ 3
+ST_RELA equ 4
+ST_HASH equ 5
+ST_DYNAMIC equ 6
+ST_NOTE equ 7
+ST_NOBITS equ 8
+ST_REL equ 9
+ST_SHLIB equ 10
+ST_DYNSYM equ 11
+ST_INIT_ARRAY equ 14
+ST_FINI_ARRAY equ 15
+ST_PREINIT_ARRAY equ 16
+ST_GROUP equ 17
+ST_SYMTAB_SHNDX equ 18
+ST_LOOS equ 0x60000000
+ST_HIOS equ 0x6fffffff
+ST_LOPROC equ 0x70000000
+ST_HIPROC equ 0x7fffffff
+ST_LOUSER equ 0x80000000
+ST_HIUSER equ 0xffffffff
+
+;flags
+SF_WRITE equ 0x1
+SF_ALLOC equ 0x2
+SF_EXECINSTR equ 0x4
+SF_MERGE equ 0x10
+SF_STRINGS equ 0x20
+SF_INFO_LINK equ 0x40
+SF_LINK_ORDER equ 0x80
+SF_OS_NONCONFORMING equ 0x100
+SF_GROUP equ 0x200
+SF_TLS equ 0x400
+SF_COMPRESSED equ 0x800
+SF_MASKOS equ 0x0ff00000
+SF_MASKPROC equ 0xf0000000
+
diff --git a/boot/loader.asm b/boot/loader.asm
new file mode 100755
index 0000000..a7eb206
--- /dev/null
+++ b/boot/loader.asm
@@ -0,0 +1,852 @@
+[BITS 16]
+[ORG 0x0]
+
+ SECTION .text
+ push cs
+ push cs
+ pop ds
+ pop es
+ mov si,msg0
+ call showstr
+
+ mov si,msg1
+ call showstr
+ call initfat
+ call ok
+
+ mov si,msg2
+ call showstr
+ mov si,System_File
+ call search
+ call ok
+
+ mov si,msg3
+ call showstr
+ call EnableA20
+ call ok
+
+ mov si,msg4
+ call showstr
+ mov eax,cs
+ shl eax,4
+ mov [GDT.Entry1+2],ax
+ mov [GDT.Entry2+2],ax
+ shr eax,16
+ mov [GDT.Entry1+4],al
+ mov [GDT.Entry2+4],al
+ mov eax,cs
+ shl eax,4
+ add eax,gdt0
+ mov [GDTR.Address],eax
+ lgdt [GDTR]
+call ok
+
+ mov si,msg5
+ call showstr
+ cli
+ mov eax,cr0
+ or al,1
+ mov cr0,eax
+ jmp short $+2
+ mov bx,SYS_DATA_SEL
+ mov fs,bx
+ mov ds,bx
+ mov es,bx
+ mov gs,bx
+ and al,0FEh
+ mov cr0,eax
+ jmp short $+2
+ mov bx,cs
+ mov fs,bx
+ mov ds,bx
+ mov es,bx
+ mov gs,bx
+ sti
+call ok
+
+
+
+ mov si,msg6
+ call showstr
+ mov ebx,0x300000
+ call load
+call ok
+
+ mov si,msg7
+ call showstr
+ call initpe
+call ok
+ suite:
+ ;mov cx,suite
+ ;call debug
+ mov si,msg8
+ call showstr
+ cli
+ mov al,0x80
+ out 0x70,al
+ mov eax,cr0
+ or al,1
+ mov cr0,eax
+ jmp SYS_CODE_SEL:GoPMode32
+
+
+Boot_Error:
+ mov si,error
+ call showstr
+ xor ax,ax
+ int 16h
+ jmp 0xFFFF:0x0
+
+ok:
+ push si
+ push cx
+ mov cl,67
+ call eol
+ mov si,okay
+ call showstr
+ pop cx
+ pop si
+ ret
+
+;======================INITPE========================
+;Initialise le PE de l'adresse EBX
+;->
+;<- Flag Carry si erreur
+;=====================================================
+initpe:
+ pusha
+ push es
+ xor ax,ax
+ mov es,ax
+ mov [begin],ebx
+ cmp word [es:ebx+ELFheader.Magic],0x457F ; bien l'entete .elf ?
+ jne near errorelf
+ cmp word [es:ebx+ELFheader.Magic+2],"LF" ; bien l'entete .elf ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.Computertype],0x1 ; type ok ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.Endianness],0x1 ; type ok ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.Original],0x1 ; type ok ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.OS],0x0 ; type ok ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.ABI],0x0 ; type ok ?
+ jne near errorelf
+ cmp byte [es:ebx+ELFheader.Dummy],0x0 ; type ok ?
+ jne near errorelf
+ mov si,info1
+ call showstr
+ mov esi,[es:ebx+ELFheader.Entrypoint]
+ mov [entriepoint],esi
+ mov esi,[es:ebx+ELFheader.Offsetprogram]
+ add esi,ebx
+ mov [offsetheader],esi
+ mov esi,[es:ebx+ELFheader.Offsetsection]
+ add esi,ebx
+ mov [offsetsection],esi
+ mov cx,[es:ebx+ELFheader.Nbprogram]
+ mov [cs:nbprogram],cx
+ mov cx,[es:ebx+ELFheader.Nbsection]
+ mov [cs:nbsection],cx
+ xor eax,eax
+ mov ax,[es:ebx+ELFheader.Index]
+ xor edx,edx
+ mov dx,[es:ebx+ELFheader.Sizesection]
+ mul edx
+ add eax,esi
+ mov eax,[es:eax+Sections.Offset]
+ add eax,ebx
+ mov [cs:symbol],eax
+ xor eax,eax
+ add ax,[es:ebx+ELFheader.Sizesection]
+ add esi,eax
+sections:
+ mov edi,esi
+ cmp dword [es:edi+Sections.Type],0x00
+ jz nothing
+ mov esi,info2
+ call showstr
+ push ds
+ push es
+ pop ds
+ mov esi,[es:edi+Sections.Name]
+ add esi,[cs:symbol]
+ call showstr
+ pop ds
+ mov esi,info3
+ call showstr
+ mov edx,[es:edi+Sections.Offset]
+ push cx
+ mov cx,32
+ call ShowHex
+ pop cx
+ mov esi,info4
+ call showstr
+ mov edx,[es:edi+Sections.Size]
+ push cx
+ mov cx,32
+ call ShowHex
+ pop cx
+ mov esi,info5
+ call showstr
+ mov edx,[es:edi+Sections.Vadress]
+ push cx
+ mov cx,32
+ call ShowHex
+ pop cx
+ and dword [es:edi+Sections.Flags],SF_ALLOC
+ jne itsok
+ mov esi,info6
+ call showstr
+ jmp itsok2
+itsok:
+ mov esi,info10
+ call showstr
+call copy2mem
+ cmp dword [es:edi+Sections.Type],ST_NOBITS
+ jne itsok2
+ mov esi,info9
+ call showstr
+ mov esi,info10
+ call showstr
+call zero2mem
+itsok2:
+ push cx
+ xor cx,cx
+ mov edx,[es:edi+Sections.Align]
+ mov esi,info8
+ call showstr
+nextpower:
+ cmp edx,0
+ je powerok
+ cmp edx,1
+ je powerok
+ cmp cx,32
+ je powerok
+ inc cx
+ shr edx,1
+ jnc nextpower
+powerok:
+ mov edx,ecx
+ mov cx,4
+ call ShowHex
+ pop cx
+ call showrtn
+ mov esi,edi
+nothing:
+ add esi,eax
+ dec cx
+ jnz sections
+ mov esi,info7
+ call showstr
+ mov edx,[cs:entriepoint]
+ mov cx,32
+ call ShowHex
+ clc
+ pop es
+ popa
+ ret
+
+errorelf:
+ stc
+ pop es
+ popa
+ ret
+
+;==========DEBUG===========
+;CX adresse
+;->CX
+;<-
+;===========================================
+debug:
+ mov esi,info11
+ call showstr
+ xor edx,edx
+ mov dx,cs
+ shl edx,4
+ add edx,ecx
+ mov cx,32
+ call ShowHex
+infini:
+ jmp infini
+
+
+;==========COPY2MEM===========
+;Copie de es:esi vers es:edi
+;->ES:ESI ES:EDI CX
+;<- Flag
+;===========================================
+copy2mem:
+ push eax
+ push esi
+ push edi
+push ecx
+mov esi,[es:edi+Sections.Offset]
+add esi,[cs:begin]
+mov ecx,[es:edi+Sections.Size]
+shr ecx,2
+inc ecx
+mov edi,[es:edi+Sections.Vadress]
+copietomem:
+ mov eax,[es:esi]
+ mov [es:edi],eax
+ add edi,4
+ add esi,4
+ dec ecx
+ jnz copietomem
+pop ecx
+pop edi
+pop esi
+pop eax
+ret
+
+;==========ZERO2MEM===========
+;Remise à zero de es:edi
+;->ES:EDI CX
+;<- Flag
+;===========================================
+zero2mem:
+ push eax
+ push esi
+ push edi
+push ecx
+mov esi,[es:edi+Sections.Offset]
+add esi,[cs:begin]
+mov ecx,[es:edi+Sections.Size]
+shr ecx,2
+inc ecx
+mov edi,[es:edi+Sections.Vadress]
+ mov eax,0
+zerotomem:
+ mov [es:edi],eax
+ add edi,4
+ dec ecx
+ jnz zerotomem
+pop ecx
+pop edi
+pop esi
+pop eax
+ret
+
+begin dd 0
+entriepoint dd 0
+offsetheader dd 0
+offsetsection dd 0
+nbprogram dw 0
+nbsection dw 0
+symbol dd 0
+
+;==========SHOWHEX===========
+;Affiche un nombre hexadécimal EDX de taille CX aprés le curseur
+;-> EDX un entier, CX la taille
+;<-
+;===========================================
+ShowHex:
+ push ax
+ push bx
+ push cx
+ push edx
+ push si
+ mov ax,cx
+ shr ax,2
+ sub cx,32
+ neg cx
+ shl edx,cl
+ xor cx,cx
+ inc cx
+Hexaize:
+ rol edx,4
+ mov bx,dx
+ and bx,0fh
+ mov si,ax
+ mov al,[cs:bx+Tab]
+ xor bx,bx
+ mov ah,0x09
+ mov bl,[cs:thecolor]
+ int 0x10
+ mov ah,0x0E
+ int 0x10
+ mov ax,si
+ dec al
+ jnz Hexaize
+ pop si
+ pop edx
+ pop cx
+ pop bx
+ pop ax
+ ret
+Tab db '0123456789ABCDEF'
+
+;======================EOL========================
+;Va en colonne CX
+;->
+;<- Flag Carry si erreur
+;=====================================================
+eol:
+ pusha
+ mov bp,cx
+ mov ah,03
+ xor bx,bx
+ int 10h
+ mov ah,02
+ mov cx,bp
+ mov dl,cl
+ int 10h
+ popa
+ ret
+
+
+;======================LOAD========================
+;Charge le groupe en mémoire en ebx
+;->
+;<- Flag Carry si erreur
+;=====================================================
+load:
+ push ax
+ push ebx
+ push ecx
+ push edx
+ push esi
+ push edi
+ push fs
+ xor edx,edx
+ xor ax,ax
+ mov fs,ax
+ mov si,The_Dot
+ mov dx,[Sectors_Size]
+Resume_Loading:
+ cmp cx,0x0FF0
+ jae Finish_Loading
+ push cx
+ add cx,word [data]
+ mov edi,Buffer
+ call ReadSector
+ pop cx
+ jc near Boot_Error
+ call showstr
+ push esi
+ push ebx
+ push cx
+ mov esi,Buffer
+ mov cx,dx
+ shr cx,2
+copie:
+ mov eax,[ds:esi]
+ mov [fs:ebx],eax
+ add ebx,4
+ add esi,4
+ dec cx
+ jnz copie
+ pop cx
+ pop ebx
+ pop esi
+ add ebx,edx
+ call NextFatGroup
+ jc near Boot_Error
+ jmp Resume_Loading
+Finish_Loading:
+ pop fs
+ pop edi
+ pop esi
+ pop edx
+ pop ecx
+ pop ebx
+ pop ax
+ ret
+
+;======================INITFAT========================
+;Initialise les variables de la fat
+;->
+;<- Flag Carry si erreur
+;=====================================================
+initfat:
+ pusha
+ push ds
+ xor ax,ax
+ mov ds,ax
+ mov si,0x7C0B
+ mov di,bootsector
+ mov cx, 512
+ rep movsb
+ pop ds
+ mov cx,[Reserved_Sectors]
+ add cx,[Sectors_Hidden]
+ adc cx,[Sectors_Hidden+2]
+ mov bx,[Sectors_Per_Fat]
+ mov di,Fat_Buffer
+ push bx
+ push cx
+readfat:
+ call ReadSector
+ jc Boot_Error
+ inc cx
+ add di,[Sectors_Size]
+ dec bx
+ jnz readfat
+ pop cx
+ pop bx
+ xor ax,ax
+ mov al,[Fats_Number]
+ mul bx
+ add cx,ax
+ mov [entries],cx
+ mov ax,32
+ mul word [Fits_Number]
+ div word [Sectors_Size]
+ add cx,ax
+ sub cx,2
+ mov word [data],cx
+ popa
+ ret
+
+;======================SEARCH========================
+;Recherche le groupe d'un fichier
+;-> si nom du fichier
+;<- Flag Carry si erreur CX
+;=====================================================
+search:
+ push bx
+ push dx
+ push di
+ mov cx,[entries]
+ mov di,Buffer
+ call ReadSector
+ jc Boot_Error
+ xor bx,bx
+Next_Root_Entrie:
+ cmp byte [di],0
+ je Boot_Error
+ push si
+ push di
+ push cx
+ mov cx,32
+ rep cmpsb
+ pop cx
+ pop di
+ pop si
+ je Found
+ add di,32
+ add bx,32
+ inc dx
+ cmp dx,[Fits_Number]
+ ja Boot_Error
+ cmp bx,[Sectors_Size]
+ jb Next_Root_Entrie
+ inc cx
+Found:
+ mov cx,[di+26+32]
+ pop di
+ pop dx
+ pop bx
+ ret
+
+;======================SHOWRTN========================
+;Affiche la chaine de caractère return
+;->
+;<- Flag Carry si erreur
+;=====================================================
+showrtn:
+ push ds
+ push ax
+ push esi
+ mov esi,return
+ mov ax,cs
+ mov ds,ax
+ call showstr
+ pop esi
+ pop ax
+ pop ds
+ ret
+
+;======================SHOWSTR========================
+;Affiche la chaine de caractère pointé par ds:esi à l'écran
+;-> DS, SI
+;<- Flag Carry si erreur
+;=====================================================
+showstr:
+ pushad
+ xor bh,bh
+nextchar:
+ mov al,[ds:esi]
+ inc esi
+ or al,al
+ jz endshow
+ cmp al,' '
+ jb justchar
+ cmp al,'#'
+ jne nocolor
+ mov al,[ds:esi]
+ inc esi
+ sub al,'0'
+ shl al,3
+ mov [cs:thecolor],al
+ shr al,2
+ add [cs:thecolor],al
+ mov al,[ds:esi]
+ inc esi
+ sub al,'0'
+ add [cs:thecolor],al
+ jmp nextchar
+nocolor:
+ cmp al,'@'
+ jne nocolor2
+ mov al,[ds:esi]
+ inc esi
+ sub al,'0'
+ shl al,3
+ mov cl,al
+ shr al,2
+ add cl,al
+ mov al,[ds:esi]
+ inc esi
+ sub cl,'0'
+ add cl,al
+ call eol
+ jmp nextchar
+nocolor2:
+ xor bx,bx
+ mov ah,0x09
+ mov bl,[cs:thecolor]
+ xor cx,cx
+ inc cx
+ int 0x10
+justchar:
+ mov ah,0x0E
+ int 0x10
+ jmp nextchar
+endshow:
+ popad
+ ret
+
+
+;====================READSECTOR=======================
+;Lit le secteur logique LBA CX et le met en es:di
+;-> CX (limité à 65536 secteurs, soit 32 Mo avec secteur 512 octets)
+;<- Flag Carry si erreur
+;=====================================================
+ReadSector:
+ pusha
+ mov ax,cx
+ xor dx,dx
+ div word [Sectors_Per_Track]
+ inc dl
+ mov bl,dl
+ xor dx,dx
+ div word [Heads_Number]
+ mov dh, [Boot_Drive]
+ xchg dl,dh
+ mov cx,ax
+ xchg cl,ch
+ shl cl,6
+ or cl, bl
+ mov bx,di
+ mov si, 4
+ mov al, 1
+Read_Again:
+ mov ah, 2
+ int 0x13
+ jnc Read_Done
+ dec si
+ jnz Read_Again
+Read_Done:
+ popa
+ ret
+
+;===================NEXTFATGROUP======================
+;Renvoie en CX le groupe qui succède dans la FAT le groupe CX
+;-> CX
+;<-
+;=====================================================
+NextFatGroup:
+ push bx
+ push dx
+ push di
+ mov ax,cx
+ mov bx,ax
+ and bx,0000000000000001b
+ shr ax,1
+ mov cx,3
+ mul cx
+ mov di,Fat_Buffer
+ add di,ax
+ cmp bx,0
+ jnz Even_Group
+Odd_Group:
+ mov dx,[di]
+ and dx,0x0FFF
+ mov cx,dx
+ jmp Next_Group_Found
+Even_Group:
+ mov dx,[di+1]
+ and dx,0xFFF0
+ shr dx,4
+ mov cx,dx
+Next_Group_Found:
+ pop di
+ pop dx
+ pop bx
+ ret
+
+;***********************EnableA20*******************************
+;->
+;<-
+;Ouvre l'autoroute A20
+;***************************************************************
+EnableA20:
+ cli
+ call ClearKeybBuffer
+ call WaitKeybCommand
+ mov al,0xd1
+ out 0x64,al
+ call WaitKeybCommand
+ mov al,0xdf
+ out 0x60,al
+ call WaitKeybCommand
+ jmp A20Enabled
+WaitKeybCommand:
+ in al,0x64
+ test al,0x02
+ jnz WaitKeybCommand
+ ret
+ClearKeybBuffer:
+ in al,0x64
+ test al,0x01
+ jnz ReadKeyb
+ ret
+ReadKeyb:
+ in al,0x60
+ jmp ClearKeybBuffer
+A20Enabled:
+ sti
+ ret
+
+
+GoPMode32:
+[BITS 32]
+ mov ax,ALL_DATA_SEL
+ mov es,ax
+ mov gs,ax
+ mov fs,ax
+ mov ss,ax
+ mov ds,ax
+ mov esp,0x3fffff
+ push KERNEL_SEL
+ push dword [cs:entriepoint]
+ retf
+
+section .data
+
+thecolor db 0x07
+msg0 db '#12@20-=< Lancement du Chargeur ELF >=-',0x0A,0x0D,0x0A,0x0D,0
+msg1 db '#07Initialisation de la FAT',0
+msg2 db '#07Recherche du systeme',0
+msg3 db '#07Activation adressage 24 bits',0
+msg4 db '#07Chargement des descripteurs',0
+msg5 db '#07Passage en mode Flat real',0
+msg6 db '#07Chargement du systeme',0
+msg7 db '#07Mise en place format ELF',0
+msg8 db '#07Passage en mode protege',0
+
+
+info1 db 0x0A,0x0D,'Format ELF i386 reconnu, #08Sections :',0x0A,0x0D,0
+info2 db ' ',0
+info3 db '@12 | ',0
+info4 db ' - ',0
+info5 db ' -> ',0
+info6 db '@35#12NON ALLOUE #08',0
+info7 db 'Point entree en ',0
+info8 db '@48 2**',0
+info9 db '@15#12 VIDE #08',0
+info10 db '@70MEM',0
+info11 db 0x0A,0x0D,'#12Arret debug en ',0
+
+return db 0x0A,0x0D,0
+
+okay db ' #15[ #10OK #15]',0x0A,0x0D,0
+error db ' #15[#12Erreur#15]',0x0A,0x0D,0x0A,0x0D,' ',0
+The_Dot db '.',0
+System_File db "As",0,"y",0,"s",0,"t",0,"e",0,0x0F,0,0xB8,"m",0,".",0,"s",0,"y",0,"s",0,0,0,0,0,0xFF,0xFF,0xFF,0xFF
+entries dw 0
+data dw 0
+xy dw 0
+
+GDTR:
+.Size: dw GDT_END
+.Address: dd 0
+
+gdt0 equ $ ; null entry
+GDT:
+.Entry0: dw 0 ; limit 15:0
+ dw 0 ; base 15:0
+ db 0 ; base 23:16
+ db 0 ; type
+ db 0 ; limit 19:16, flags
+ db 0 ; base 31:24
+
+
+SYS_CODE_SEL equ $-gdt0 ; code segment descriptor
+
+.Entry1: dw 0xFFFF
+ dw 0x0 ; base
+ db 0x0 ; base
+ db 0x9A ; present, ring 0, code, non-conforming, readable
+ db 0xCF ; 32 bit
+ db 0
+
+
+SYS_DATA_SEL equ $-gdt0 ; data segment descriptor
+
+.Entry2: dw 0xFFFF
+ dw 0x0 ; base
+ db 0x0 ; base
+ db 0x92 ; present, ring 0, data, expand-up, writable
+ db 0xCF ; 32 bit
+ db 0
+
+
+ALL_DATA_SEL equ $-gdt0 ; 4meg data segment descriptor
+
+.Entry3: dw 0xFFFF
+ dw 0x0 ; base
+ db 0x0 ; base
+ db 0x92 ; present, ring 0, data, expand-up, writable
+ db 0xCF ; 4k pages, 32 bit
+ db 0
+
+
+KERNEL_SEL equ $-gdt0 ; 4g code segment descriptor
+
+.Entry4: dw 0xffff
+ dw 0x0 ; base
+ db 0x0 ; base
+ db 0x9A ; present, ring 0, code, non-conforming, readable
+ db 0xCF ; 4k pages, 32 bit
+ db 0
+
+GDT_END equ $-gdt0 -1
+
+bootsector equ $
+Sectors_Size dw 0 ;Nombre d'octets/secteur
+Sectors_Per_Cluster db 0 ;Nombre de secteurs/cluster
+Reserved_Sectors dw 0 ;Nombre de secteurs réservé
+Fats_Number db 0 ;Nombre de copies de la FAT
+Fits_Number dw 0 ;Taille du répertoire racine
+Sectors_Per_Disk dw 0 ;Nombre secteurs du volume si < 32 Mo
+Media_Descriptor db 0 ;Descripteur de média
+Sectors_Per_Fat dw 0 ;Nombre secteurs/FAT
+Sectors_Per_Track dw 0 ;Nombre secteurs/piste
+Heads_Number dw 0 ;Nombre de tete de lecture/écriture
+Sectors_Hidden dd 0 ;Nombre de secteurs cachés
+Sectors_Per_Disk2 dd 0 ;Nombre secteurs du volume si > 32 Mo
+Boot_Drive db 0 ;Lecteur de démarrage
+Reserved db 0 ;NA (pour NT seulement)
+Extended_Boot_ID db 0 ;Signature Boot étendu 29h
+
+Buffer equ $
+Fat_Buffer equ $+512
+
+ SECTION .bss
+
+%include "elf.h"
+
diff --git a/boot/makefile b/boot/makefile
old mode 100644
new mode 100755
index 10cbc4f..6f6f26a
--- a/boot/makefile
+++ b/boot/makefile
@@ -1,20 +1,18 @@
+CC=nasm -f bin -o
+
all: makall
-makall: boot12.bin boot16.bin boottest.bin bootcp.com
- sync
+makall: boot12.bin boot16.bin loader.sys
-boot12.bin:
- nasm -f bin -o boot12.bin boot12.asm
-
-boot16.bin:
- nasm -f bin -o boot16.bin boot16.asm
+boot12.bin: boot12.asm
+ $(CC) $@ $^
-boottest.bin:
- nasm -f bin -o boottest.bin boottest.asm
+boot16.bin: boot16.asm
+ $(CC) $@ $^
+
+loader.sys: loader.asm
+ $(CC) $@ $^
-bootcp.com:
- nasm -f bin -o bootcp.com bootcp.asm
-
clean:
rm -f *.o
rm -f *.bin
diff --git a/debug/boot.txt b/debug/boot.txt
new file mode 100644
index 0000000..79251d8
--- /dev/null
+++ b/debug/boot.txt
@@ -0,0 +1,8 @@
+target remote localhost:1234
+set disassembly-flavor intel
+set architecture i8086
+break *0x7c00
+cont
+clear *0x7c00
+layout asm
+layout regs
diff --git a/debug/loader.txt b/debug/loader.txt
new file mode 100644
index 0000000..25dfdc0
--- /dev/null
+++ b/debug/loader.txt
@@ -0,0 +1,7 @@
+target remote localhost:1234
+set disassembly-flavor intel
+set architecture i8086
+break *0x800
+cont
+display/20i $pc+$cs*16
+clear *0x800
diff --git a/debug/system.txt b/debug/system.txt
new file mode 100644
index 0000000..213fbf9
--- /dev/null
+++ b/debug/system.txt
@@ -0,0 +1,8 @@
+target remote localhost:1234
+set disassembly-flavor intel
+set architecture i386
+break *0x50000
+cont
+symbol-file ./system/system.sys
+clear *0x50000
+display/20i $pc
diff --git a/final/makefile b/final/makefile
new file mode 100755
index 0000000..b434092
--- /dev/null
+++ b/final/makefile
@@ -0,0 +1,13 @@
+all: cos2000.img
+
+cos2000.img:
+ (dd if=/dev/zero of=cos2000.img count=2880 bs=512)
+ (mkfs.msdos -F 12 -n "COS2000" cos2000.img)
+ (fusefat cos2000.img ./mnt -o rw+)
+ (cp ../boot/loader.sys ./mnt/)
+ (cp ../system/system.sys ./mnt/;sync)
+ (fusermount ./mnt -u)
+ (dd if=../boot/boot12.bin of=cos2000.img seek=0 count=1 conv=notrunc;sync)
+
+clean:
+ rm -f *.img
diff --git a/include/3d.h b/include/3d.h
new file mode 100755
index 0000000..e69de29
diff --git a/include/Kmemory.h b/include/Kmemory.h
new file mode 100755
index 0000000..66e72b4
--- /dev/null
+++ b/include/Kmemory.h
@@ -0,0 +1,26 @@
+/***********************************/
+/* Librairie Kmemory.h */
+/* 20 Mars 2007 */
+/***********************************/
+
+
+#ifndef JREKCED_KERNEL_MEMORY
+# define JREKCED_KERNEL_MEMORY
+
+# include "type.h"
+
+# define MEMORY_BLOC_SIZE (1024L) /* Taille des blocs */
+
+ // Initialise les gestionnaire de memoire.
+void Kernel_InitMemory (void *DataMemory, // DataMemory pointe vers la zone de memoire disponible.
+ UDWORD TotalMemorySize); // TotalMemorySize est la quantite total de memoire disponible.
+
+void * Kernel_mballoc(UDWORD Size); // Alloue SIZE blocs de memoire et retourne un pointeur sur la zone.
+ // Retourne un pointeur nul si l'allocation est impossible.
+
+int Kernel_mbfree (void *Adresse); // Libere le bloc memoire alloue a l'adresse ADRESSE.
+ // Retourne -1 si adresse incorrecte et 0 si tout s'est bien deroule.
+
+void * Kernel_mbrealloc (void *Adresse, UDWORD Size); // Redimensionne un bloc, retourne NULL si le bloc
+ // n'est pas redimensionne.
+#endif
diff --git a/include/LDT.h b/include/LDT.h
new file mode 100755
index 0000000..8a66458
--- /dev/null
+++ b/include/LDT.h
@@ -0,0 +1,85 @@
+/***********************************/
+/* Librairie LDT.h */
+/* 23 Mars 2007 */
+/***********************************/
+
+#ifndef JREKCED_LDT
+# define JREKCED_LDT
+
+# include "type.h"
+
+# define LDT_BLOC_SIZE (128) /* Nombre de descripteur LDT dans un bloc */
+
+// Types d'acces
+# define GLT_ACCESSED (0x1)
+
+# define LDT_DATA (0x0)
+# define LDT_DATA_WRITE (0x2)
+# define LDT_DATA_EXPAND (0x4)
+
+# define LDT_CODE (0x8)
+# define LDT_CODE_READ (0xA)
+# define LDT_CODE_CONFORMING (0xD)
+
+// Granularite
+# define LDT_BYTE (0x0)
+# define LDT_4KB (0x1)
+
+// Mode du CPU
+# define LDT_16BIT (0x0)
+# define LDT_32BIT (0x1)
+
+
+typedef struct
+{
+ UWORD Limite_0_15; // Bit 00-15 : Limite (0-15)
+ UWORD Adresse_0_15; // Bit 16-31 : Adresse (0-15)
+ UBYTE Adresse_16_23; // Bit 32-39 : Adresse (16-23)
+ UBYTE Acces : 1; // 0 = System
+ // 1 = Code ou data
+ UBYTE Type : 4; // Bit 41-44 : Type
+ UBYTE DPL : 2; // Spécifie le niveau de privilège du segment
+ UBYTE Present : 1; // Indique si le segment est en mémoire (bit a 1) ou non (bit a 0)
+ UBYTE Limite_16_19 : 4; // Bit 48-51 : Limite (16-19)
+ UBYTE UserDefine : 1; // Bit 52 : Utilisation libre
+ UBYTE Unused : 1; // Bit 53 : Non utilise (toujours = 0)
+ UBYTE CPUMode : 1; // Bit 54 : = 0 -> 16-Bit
+ // = 1 -> 32-Bit
+ UBYTE Granularite : 1; // Si = 0 : Limite = 1 octet -> 1 Mo
+ // Si = 1 : Limite = 4 Ko -> 4 Go
+ UBYTE Adresse_24_31; // Bit 56-63 : Adresse (24-31)
+} T_LDT;
+
+
+typedef struct
+{
+ UWORD Size; // Taille de la GDT
+ void * Adresse; // Adresse phisique de la GDT;
+ UWORD Empty;
+
+} T_LDT_reg;
+
+
+// T_LDT *GDT_BASE = ((T_LDT*)0x0800L); /* Addresse physique ou reside la GDT, le 1e element est toujours null */
+
+
+T_LDT * LDT_balloc (UWORD Size); // Alloue un bloc de Size LDT
+
+int LDT_bfree (void * Adresse); // Libere un bloc LDT
+
+T_LDT * LDT_brealloc (T_LDT * OldLDT, UWORD NewSize); // Redimensionne un bloc LDT, retourne NULL en cas d'erreur.
+
+T_LDT * LDT_AllocLDT (T_LDT *BaseLDT); // Cherche un LDT libre dans un bloc precedement
+ // alloue avec LDT_balloc.
+ // Retourne NULL si aucun bloc disponible.
+ // Si un bloc libre est trouve, il est marque comme
+ // utilise et un pointeur sur ce LDT est retourne.
+
+int LDT_FreeLDT (T_LDT *LDT); // Marque le LDT comme non utilise et le met a NULL.
+
+int LDT_MapMemory (T_LDT *LDT, void * Linear, // Met des donnees dans un LDT.
+ UDWORD Size, // Cette fonction est a tester.
+ UBYTE Granularite,
+ UBYTE DPL, UBYTE Type,
+ UBYTE CPUMode);
+#endif
diff --git a/include/asm.h b/include/asm.h
old mode 100644
new mode 100755
index 674f44f..5b77c6c
--- a/include/asm.h
+++ b/include/asm.h
@@ -8,8 +8,15 @@
#define nop() asm("nop"::)
-#define iret() asm("addl $0x0C, %esp; \
- iret;")
+#define pushad() asm("pushal"::)
+
+#define popad() asm("popal"::)
+
+#define pushf() asm("pushf"::)
+
+#define popf() asm("popf"::)
+
+#define iret() asm("iret"::)
#define irqendmaster() asm("movb $0x20,%al; \
outb %al,$0x20;")
diff --git a/include/cpu.h b/include/cpu.h
new file mode 100755
index 0000000..7885d50
--- /dev/null
+++ b/include/cpu.h
@@ -0,0 +1,31 @@
+typedef struct cpuinfo
+{
+u8 vendor[13];
+u8 names[32];
+u8 detectedname[48];
+u8 techs[48];
+u8 stepping;
+u8 models;
+u8 family;
+u8 types;
+u8 emodels;
+u8 efamily;
+u8 apicid;
+u8 count;
+u8 linesize;
+u8 brandid;
+bool mmx;
+bool mmx2;
+bool sse;
+bool sse2;
+bool sse3;
+bool fpu;
+bool now3d;
+bool now3d2;
+bool htt;
+bool apic;
+} cpuinfo __attribute__ ((packed));
+
+
+u8 getcpuinfos(cpuinfo *inf);
+
diff --git a/include/cpuid.h b/include/cpuid.h
new file mode 100755
index 0000000..0ecc299
--- /dev/null
+++ b/include/cpuid.h
@@ -0,0 +1,6 @@
+
+bool cansetflag (u32 flag);
+
+void cpuid(u32 op, u32 *eax, u32 *ebx,u32 *ecx, u32 *edx);
+
+void dump_regs();
diff --git a/include/ctype.h b/include/ctype.h
old mode 100644
new mode 100755
diff --git a/include/graph.h b/include/graph.h
new file mode 100755
index 0000000..949bbd3
--- /dev/null
+++ b/include/graph.h
@@ -0,0 +1 @@
+void line(u32 x1, u32 y1, u32 x2, u32 y2, u8 color);
diff --git a/include/idt.h b/include/idt.h
old mode 100644
new mode 100755
index 65f4cb9..b80dd6b
--- a/include/idt.h
+++ b/include/idt.h
@@ -24,7 +24,7 @@ typedef struct idtdes {
void initpic(void);
void enableirq(u8 irq);
void disableirq(u8 irq);
-
+ void cpuerror(const u8 *src);
diff --git a/include/keyboard.h b/include/keyboard.h
old mode 100644
new mode 100755
index 2739aa4..0684dd6
--- a/include/keyboard.h
+++ b/include/keyboard.h
@@ -28,35 +28,6 @@
#define STATUS_NUM 0x2000
#define STATUS_SCRL 0x4000
-/* "ASCII" values for non-ASCII keys. All of these are user-defined.*/
-
-#define KEY_F1 0x80
-#define KEY_F2 (KEY_F1 + 1)
-#define KEY_F3 (KEY_F2 + 1)
-#define KEY_F4 (KEY_F3 + 1)
-#define KEY_F5 (KEY_F4 + 1)
-#define KEY_F6 (KEY_F5 + 1)
-#define KEY_F7 (KEY_F6 + 1)
-#define KEY_F8 (KEY_F7 + 1)
-#define KEY_F9 (KEY_F8 + 1)
-#define KEY_F10 (KEY_F9 + 1)
-#define KEY_F11 (KEY_F10 + 1)
-#define KEY_F12 (KEY_F11 + 1)
-#define KEY_INS 0x90
-#define KEY_DEL (KEY_INS + 1)
-#define KEY_HOME (KEY_DEL + 1)
-#define KEY_END (KEY_HOME + 1)
-#define KEY_PGUP (KEY_END + 1)
-#define KEY_PGDN (KEY_PGUP + 1)
-#define KEY_LFT (KEY_PGDN + 1)
-#define KEY_UP (KEY_LFT + 1)
-#define KEY_DN (KEY_UP + 1)
-#define KEY_RT (KEY_DN + 1)
-#define KEY_PRNT (KEY_RT + 1)
-#define KEY_PAUSE (KEY_PRNT + 1)
-#define KEY_LWIN (KEY_PAUSE + 1)
-#define KEY_RWIN (KEY_LWIN + 1)
-#define KEY_MENU (KEY_RWIN + 1)
-
-
void keyboard();
+void outkbd(u8 port, u8 data);
+u8 waitascii();
diff --git a/include/math.h b/include/math.h
new file mode 100755
index 0000000..661e588
--- /dev/null
+++ b/include/math.h
@@ -0,0 +1,3 @@
+#define sgn(x) ((x<0)?-1:((x>0)?1:0));
+
+u32 abs(int x);
diff --git a/include/memory.h b/include/memory.h
old mode 100644
new mode 100755
index 7f679f9..c766129
--- a/include/memory.h
+++ b/include/memory.h
@@ -3,3 +3,4 @@
void memset(void *dst, u8 val, u32 count,u32 size);
void memcpy(void *src, void *dst, u32 count, u32 size);
u32 memcmp(void *src, void *dst, u32 count, u32 size);
+
diff --git a/include/mouse.h b/include/mouse.h
new file mode 100755
index 0000000..14487af
--- /dev/null
+++ b/include/mouse.h
@@ -0,0 +1,4 @@
+bool initmouse();
+void mouse();
+void outmseack(u8 value);
+void outmsecmd(u8 command);
diff --git a/include/port.h b/include/port.h
old mode 100644
new mode 100755
index 2a2caf0..e81042a
--- a/include/port.h
+++ b/include/port.h
@@ -3,4 +3,4 @@
void outreg(u16 port,u8 *src,u16 num);
void outregsame(u16 port,u8 *src,u16 num);
void inreg(u16 port,u8 *src,u16 num);
-void inregsame(u16 port,u8 *src,u16 num);
\ No newline at end of file
+void inregsame(u16 port,u8 *src,u16 num);
diff --git a/include/stdarg.h b/include/stdarg.h
new file mode 100755
index 0000000..6e44647
--- /dev/null
+++ b/include/stdarg.h
@@ -0,0 +1,21 @@
+#ifndef _VA_LIST_T_H
+#define _VA_LIST_T_H
+
+#define __GNUC_VA_LIST
+
+typedef void *__gnuc_va_list;
+
+#define __va_rounded_size(TYPE) (((sizeof (TYPE) + sizeof (int) - 1) / sizeof (int)) * sizeof (int))
+
+#define va_start(AP, LASTARG) (AP = ((__gnuc_va_list) __builtin_next_arg (LASTARG)))
+
+void va_end (__gnuc_va_list);
+#define va_end(AP) ((void)0)
+
+#define va_arg(AP, TYPE) (AP = (__gnuc_va_list) ((char *) (AP) + __va_rounded_size (TYPE)), *((TYPE *) (void *) ((char *) (AP) - __va_rounded_size (TYPE))))
+
+#define __va_copy(dest, src) (dest) = (src)
+
+typedef __gnuc_va_list va_list;
+
+#endif
diff --git a/include/string.h b/include/string.h
new file mode 100755
index 0000000..2db80d1
--- /dev/null
+++ b/include/string.h
@@ -0,0 +1,8 @@
+#include "types.h"
+
+s8 strcmp(const u8 *src,const u8 *des);
+u32 strlen(const u8 *src);
+u8 *strchr(const u8 *src, u8 achar);
+u8 *strncpy(const u8 *src,u8 *des,u32 count);
+u8 *strcat(const u8 *src,u8 *des);
+u8* strcpy(const u8 *src, u8 *des);
diff --git a/include/timer.h b/include/timer.h
old mode 100644
new mode 100755
diff --git a/include/type.h b/include/type.h
new file mode 100755
index 0000000..b9d0b12
--- /dev/null
+++ b/include/type.h
@@ -0,0 +1,31 @@
+/***********************************/
+/* Librairie Type.h */
+/* 20 Mars 2007 */
+/***********************************/
+
+#ifndef JREKCED_TYPE
+# define JREKCED_TYPE
+
+# define NULL (0x0LL)
+
+typedef char int8;
+typedef short int16;
+typedef int int32;
+typedef long long int64;
+
+typedef char BYTE;
+typedef short WORD;
+typedef long DWORD;
+typedef long long QWORD;
+
+typedef signed char SBYTE;
+typedef signed short SWORD;
+typedef signed long SDWORD;
+typedef signed long long SQWORD;
+
+typedef unsigned char UBYTE;
+typedef unsigned short UWORD;
+typedef unsigned long UDWORD;
+typedef unsigned long long UQWORD;
+
+#endif
diff --git a/include/types.h b/include/types.h
old mode 100644
new mode 100755
index c38a738..be5b73d
--- a/include/types.h
+++ b/include/types.h
@@ -4,9 +4,16 @@
typedef unsigned char u8;
typedef unsigned short u16;
typedef unsigned int u32;
-typedef unsigned char uchar;
+typedef char s8;
+typedef short s16;
+typedef int s32;
typedef int bool;
+
+#define true -1;
+#define false 0;
+#define NULL 0x0000;
+
struct dtr {
u16 limite;
@@ -15,10 +22,6 @@ struct dtr {
} __attribute__ ((packed));
-#define true 1;
-#define false 0;
-#define NULL 0x0000;
-
#ifdef __cplusplus
extern "C"
{
diff --git a/include/vga.h b/include/vga.h
old mode 100644
new mode 100755
index 6195a27..b8c9eec
--- a/include/vga.h
+++ b/include/vga.h
@@ -10,7 +10,7 @@ u32 setvmode(u8);
u32 loadfont(u8* def,u8 size,u8 font);
void gotoscr(u16 x,u16 y);
void useplane(u8 plan);
-u8 getfont(u8 num);
+u8 getfont();
void setfont(u8 num);
void waitvretrace (void);
void waithretrace (void);
@@ -22,8 +22,16 @@ void (*writepxl)(u16 x, u16 y, u32 c);
void (*showchar)(u16 coordx,u16 coordy,u8 thechar,u8 attrib);
void (*fill)(u8 attrib);
void (*scroll)(u8 lines,u8 attrib);
-
-
-
-
-
+void split(u16 x);
+void showpage(u8 page);
+u8 getpage();
+void setpage(u8 page);
+u16 getnbpages();
+u16 getyres();
+u8 getdepth();
+u16 getxres();
+u8 getfont2();
+void enableblink();
+void disableblink();
+u8 (*getchar)(u16 coordx,u16 coordy);
+u8 (*getattrib)(u16 coordx,u16 coordy);
diff --git a/include/video.h b/include/video.h
old mode 100644
new mode 100755
index f6129fe..f0b5816
--- a/include/video.h
+++ b/include/video.h
@@ -1,4 +1,19 @@
+
+typedef struct console {
+ u8 attrib;
+ s16 cursX;
+ s16 cursY;
+ u8 ansi;
+ u8 param1;
+ u8 param2;
+ u8 param3;
+ u8 page;
+} console __attribute__ ((packed));
+
+
void showhex(u8 src);
void putchar(u8 thechar);
void print(u8* string);
+void printf (const u8 *string, ...);
+void changevc(u8 vc);
diff --git a/install/iflop/iflop.asm b/install/iflop/iflop.asm
deleted file mode 100644
index d01f2e9..0000000
--- a/install/iflop/iflop.asm
+++ /dev/null
@@ -1,375 +0,0 @@
-;ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
-;³ COS 2000 ³
-;³ http://www.multimania.com/cos2000 ³
-;ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
-;³ D I S K I M A G E ³
-;ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
-;³ Fonction : Programme permettant de r‚aliser des images dique dur d'³
-;³ une disquettes. ³
-;³ ³
-;³ Appel : Diskimge [Nom du fichier][/r][/s][/h] ³
-;³ /r restaure l'image /s sauve l'image /h aide ³
-;³ ³
-;³ Compilation : TASM boot /m4 /x ³
-;³ TLINK boot /t /x ³
-;ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´
-;³ Programmeur : Nico ³
-;³ Con‡us le : 15/07/2001 ³
-;³ Modifi‚ le : 15/07/2001 ³
-;³ Site Web : http://www.multimania.com/cos2000 ³
-;³ Copyright : libre distribution ³
-;³ E-Mail : COS2000@multimania.com ³
-;ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
-
-;==========================Directive d'assemblages============================
-[BITS 16] ;Directive qui autorise la g‚n‚ration de code 16 bits
-[ORG 0x100] ;Directive pour indiquer le d‚but du code
-
-section .text
-
-
-;=============================Debut du programmes=============================
-
-start: ;Label du d‚but.
- mov ah,0x09
- mov dx,msg ;
- int 0x21
- mov ah,'r'
- call Check
- jnc restitute
- mov ah,'s'
- call Check
- jnc save
-help:
- mov ah,0x09
- mov dx,helpmsg
- int 0x21
- mov ax,0
- int 0x16
- ret
-restitute:
- mov ah,'n'
- call Check
- jnc nospl
- mov ah,0x09
- mov dx,msg2
- int 21h
- mov ax,0x00
- int 16h
-nospl:
- mov ah,0x09
- mov dx,res
- int 0x21
- call OpenCmdLine
- jc error
- mov si,buffer
- mov di,si
- xor cx,cx
-restoring:
- call Read18432
- jc error
- call WriteTrack ;Ecrit la piste CX sur les 2 tˆtes depuis ds:di
- jc error
- call ShowDot
- inc cx
- cmp cx,80
- jb restoring
- mov ah,0x09
- mov dx,msgok
- int 0x21
- ret
-save:
- mov ah,'n'
- call Check
- jnc nospl2
- mov ah,0x09
- mov dx,msg2
- int 0x21
- mov ax,0
- int 0x16
-nospl2:
- mov ah,0x09
- mov dx,sav
- int 0x21
- call CreateCmdLine
- jc error
- mov si,buffer
- mov di,si
- xor cx,cx
-saving:
- call ReadTrack ;Lit la piste CX sur 2 tˆte en es:di
- jc error
- call Write18432
- jc error
- call ShowDot
- inc cx
- cmp cx,80
- jb saving
- mov ah,09
- mov dx,msgok
- int 0x21
- ret
-error:
- push cs
- pop ds
- call CloseCmdLine
- mov ah,09
- mov dx,errormsg
- int 0x21
- ret
-
-;Affiche un point
-ShowDot:
- push ax
- push bx
- push cx
- mov bx,cx
- shr bx,4
- mov al,[bx+dot]
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- pop cx
- pop bx
- pop ax
- ret
-
-;Ecrit une piste CX 2 Tˆte, depuis le buffer DS:SI
-ReadTrack:
- push ax
- push bx
- push cx
- push dx
- push si
- push es
- push ds
- pop es
- xchg ch,cl
- xor dx,dx
- xor cl,cl
- inc cl
- mov bx,si
- mov si,3
-retry:
- mov ax,0x0212
- int 13h
- jnc done
- dec si
- jnz retry
- jmp dead
-done:
- add bx,9216
- inc dh
- cmp dh,1
- je retry
-dead:
- pop es
- pop si
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;Lit une piste CX sur deux tˆte dans le buffer ES:DI
-WriteTrack:
- push ax
- push bx
- push cx
- push dx
- push si
- xchg ch,cl
- xor dx,dx
- xor cl,cl
- inc cl
- mov bx,di
- mov si,3
-retry2:
- mov ax,0x0312
- int 0x13
- jnc done2
- dec si
- jnz retry2
-done2:
- add bx,9216
- inc dh
- cmp dh,1
- je retry2
-dead2:
- pop si
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;Ecrit 18432 octets depuis DS:SI dans le fichier ouvert par OpenCmdline
-Write18432:
- push ax
- push bx
- push cx
- push dx
- mov ah,0x40
- mov cx,18432
- mov bx,[handle]
- mov dx,si
- int 0x21
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;Lit 18432 octets vers ES:DI depuis le fichier ouvert par OpenCmdline
-Read18432:
- push ax
- push bx
- push cx
- push dx
- mov ah,0x3F
- mov cx,18432
- mov bx,[handle]
- mov dx,si
- int 0x21
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;Ouvre la ligne de commande
-OpenCmdLine:
- push ax
- push bx
- push dx
- mov bl,[0x80]
- xor bh,bh
- add bx,0x80
- mov byte [bx],0
- mov ax,0x3D00
- mov dx,0x82
- int 0x21
- mov [handle],ax
- pop dx
- pop bx
- pop ax
- ret
-
-;Cr‚e un fichier du nom de la ligne de commande
-CreateCmdLine:
- push ax
- push bx
- push cx
- push dx
- mov bl,[0x80]
- xor bh,bh
- add bx,0x80
- mov byte [bx],0
- mov ah,0x3C
- xor cx,cx
- mov dx,0x82
- int 0x21
- mov [handle],ax
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;Ferme le fichier pr‚c‚damment ouvert avec OpenCmdline
-CloseCmdLine:
- push ax
- push bx
- mov bx,[handle]
- mov ah,0x3E
- int 0x21
- pop bx
- pop ax
- ret
-
-;Recherche le commutateur AH dans la ligne de commande si existant retourne FC=True.
-Check:
- push ax
- push cx
- push di
- mov di,0x80
- mov cl,[di]
- cmp cl,0
- je notfound2
- xor ch,ch
- mov al,'/'
-search:
- cmp cx,0
- je notfound
- repne scasb
- cmp [di],ah
- jnz search
- jmp okfound
-notfound:
- sub ah,'a'-'A'
- mov di,0x80
- mov cl,[di]
-search2:
- cmp cx,0
- je notfound2
- repne scasb
- cmp [di],ah
- jnz search2
-okfound:
- mov word [di-2],0
- clc
- pop di
- pop cx
- pop ax
- ret
-notfound2:
- stc
- pop di
- pop cx
- pop ax
- ret
-
-res db "Restauration en cours",0x0A,0x0D,0x0A,0x0D,'$'
-sav db "Sauvegarde en cours",0x0A,0x0D,0x0A,0x0D,'$'
-dot db " °±²Û"
-handle dw 0
-msg db 0x0A,0x0D,"IFlop V1.0",0x0A,0x0D
- db "Ecrit par Nico",0x0A,0x0D
- db "http://www.multimania.com/cos2000",0Ah,0Dh
- db "Copyright 2000",0Ah,0Dh,'$'
-msg2 db "Ins‚rez une disquette de 1.44 Mo dans le lecteur et appuyez sur une touche...",0x0A,0x0D,'$'
-errormsg db 0Ah,0Dh,"Une erreur est apparue lors de la copie !",0x0A,0x0D,'$'
-msgok db 0Ah,0Dh,"La copie de l'image a ‚t‚ correctement r‚alis‚e",0x0A,0x0D,'$'
-
-SectorsPerTrack dw 18 ;Nombre de secteur par pistes.
-HeadsPerDrive dw 2 ;Nombre de t‚tes par disque.
-
-helpmsg:
-db "ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿"
-db "³ COS 2000 ³"
-db "³ http://www.multimania.com/cos2000 ³"
-db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´"
-db "³ I F L O P ³"
-db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´"
-db "³ Fonction : Programme permettant de r‚aliser des images disque dur ³"
-db "³ d'une disquettes. ³"
-db "³ ³"
-db "³ Appel : Iflop [Nom du fichier][/r][/s][/h] ³"
-db "³ /r restaure l'image /s sauve l'image /h aide ³"
-db "³ ³"
-db "³ Compilation : TASM boot /m4 /x ³"
-db "³ TLINK boot /t /x ³"
-db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ´"
-db "³ Programmeur : Nico ³"
-db "³ Con‡us le : 15/07/2001 ³"
-db "³ Modifi‚ le : 15/07/2001 ³"
-db "³ Site Web : http://www.multimania.com/cos2000 ³"
-db "³ Copyright : libre distribution ³"
-db "³ E-Mail : COS2000@multimania.com ³"
-db "ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ$"
-
-section .bss
-
-[org 0x5000]
-
-buffer resb 512 ;Allocation de 512 octets pour contenir le secteur lu.
\ No newline at end of file
diff --git a/install/iflop/makefile b/install/iflop/makefile
deleted file mode 100644
index 84d3c6c..0000000
--- a/install/iflop/makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-all: makall
-
-makall: iflop.com
-
-
-iflop.com:
- nasm -f bin -o iflop.com iflop.asm
-
-clean:
- rm -f *.o
- rm -f *.bin
- rm -f *.sys
- rm -f *.com
-
-
-
diff --git a/install/makefile b/install/makefile
deleted file mode 100644
index 21dc04f..0000000
--- a/install/makefile
+++ /dev/null
@@ -1,18 +0,0 @@
-all: makall
-
-makall: iflop/iflop.com mbrol/mbrol.com
- sync
-
-clean:
- (cd iflop; make clean)
- (cd mbrol; make clean)
-
-iflop/iflop.com:
- (cd iflop; make)
-
-mbrol/mbrol.com:
- (cd mbrol; make)
-
-
-
-
diff --git a/install/mbrol/echs.h b/install/mbrol/echs.h
deleted file mode 100644
index fc1bba9..0000000
--- a/install/mbrol/echs.h
+++ /dev/null
@@ -1,10 +0,0 @@
-struc echs
-Sizes resb 1
-Reserve resb 1
-NumSectors resw 1
-Adressoff resw 1
-Adressseg resw 1
-SectorLow resw 1
-SectorHigh resw 1
-Dummy resq 1
-endstuc
diff --git a/install/mbrol/loader.asm b/install/mbrol/loader.asm
deleted file mode 100644
index de1af90..0000000
--- a/install/mbrol/loader.asm
+++ /dev/null
@@ -1,897 +0,0 @@
-[BITS 16]
-[ORG 0x0100]
-
-section .text
-
-start:
- push eax
- push ebx
- push edi
- push ebp
- mov di, disk
- call detectdisk
- call cls
- mov si,di
- mov di, thepart
- call getdriveinfos
- mov [numbers],cx
- mov si,di
- call showdriveinfos
- mov al,3
- call selection
- mov word [sel],0
-waitafter:
- call waitkey
- cmp ah,0x50
- jne tre1
- mov ax,[sel]
- inc al
- cmp ax,[numbers]
- jz waitafter
- mov [sel],ax
- add al,3
- call selection
- jmp waitafter
-tre1:
- cmp ah,0x48
- jne tre2
- mov ax,[sel]
- cmp ax,0
- jz waitafter
- dec al
- mov [sel],ax
- add al,3
- call selection
- jmp waitafter
-tre2:
- cmp al,0x0D
- jne waitafter
- mov bx,[sel]
- shl bx,6
- add bx,thepart
- mov si,mmp
- call showstr
- mov si,bx
- add si,28
- call showstr
- mov bp,[bx+26]
- call initdisk
- xor ax,ax
- mov es,ax
- mov ds,ax
- mov di,0x0600
- mov ecx,[cs:bx+16]
- call readsector
- mov di,0x7C00
- mov ecx,[cs:bx+22]
- call readsector
- mov dx,bp
- mov si,[cs:bx+20]
- add si,0x0600
- pop ebp
- pop edi
- pop ebx
- pop eax
- jmp 0x0000:0x7C00
-
-;=============================================================================
-
-; DONNEES FIXES
-
-;=============================================================================
-mmp db "Chargement du disque ",0
-msg db "ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄ¿"
- db "³ Letter:Name ³ Type ³ Boot ³ Statut ³ Size MByte ³ StartSector ³"
- db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄ´",0
-tab db "ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÙ",0
-sep db " ³ ",0
-
-partkind db 001h,"FAT12 ",0
- db 004h,"FAT16 ",0
- db 005h,"Extended ",0
- db 006h,"FAT16B ",0
- db 007h,"IFS ",0
- db 00Bh,"FAT32 ",0
- db 00Ch,"FAT32X ",0
- db 00Eh,"FAT16X ",0
- db 00Fh,"ExtendedX ",0
- db 081h,"Linux 1.4b",0
- db 082h,"Linux SWAP",0
- db 083h,"Linux EXT2",0
- db 011h,"FAT12 Hid ",0
- db 014h,"FAT16 Hid",0
- db 016h,"FAT16B Hid",0
- db 017h,"IFS Hid ",0
- db 01Bh,"FAT32 Hid ",0
- db 01Ch,"FAT32X Hid",0
- db 01Eh,"FAT16X Hid",0
- db 0FFh,"Unknowed ",0
-
-noname db "Unknowed ","Unkowned ",0
-unknowed db "Movable ",0
-primary db "Primary ",0
-secondary db "Secondary",0
-yes db "Yes ",0
-no db "No ",0
-mo db " MB",0
-
-;=============================================================================
-
-; ROUTINES PARTICULIERES
-
-;=============================================================================
-;Affiche des infos sur le volume
-showdriveinfos:
- push ax
- push bx
- push cx
- push edx
- push si
- mov si, msg
- call showstr
- mov bx,thepart
- mov cx,[numbers]
-showall:
- mov al,'³'
- call showchar
- mov al,' '
- call showchar
- mov al,[bx+51]
- call showchar
- mov al,':'
- call showchar
- mov si,bx
- add si,28
- call showstr
- mov si, sep
- call showstr
- mov al,[bx+4]
- cmp al,0xFF
- je useboot
- mov si, partkind+1
-search:
- cmp byte[si-1],0x0FF
- je notboot
- cmp [si-1],al
- je notboot
- add si,12
- jmp search
-useboot:
- mov si,bx
- add si,40
-notboot:
- call showstr
- mov si, sep
- call showstr
- mov si, yes
- cmp byte [bx],0x80
- je okboot
- mov si, no
-okboot:
- call showstr
- mov si, sep
- call showstr
- mov si, primary
- cmp dword [bx+16],0
- je okprimary
- mov si, secondary
-okprimary:
- cmp byte [bx+4],0x0FF
- jne wasno
- mov si, unknowed
-wasno:
- call showstr
- mov si, sep
- call showstr
- mov edx,[bx+12]
- shr edx,11
- call showint
- mov si, mo
- call showstr
- mov si, sep
- call showstr
- mov edx,[bx+22]
- call showint
- mov al,' '
- call showchar
- mov al,'³'
- call showchar
- add bx,64
- dec cx
- jnz near showall
- mov si, tab
- call showstr
- pop si
- pop edx
- pop cx
- pop bx
- pop ax
- ret
-
-;met en surlign‚e la ligne al et seulement al
-selection:
- push cx
- mov ch,0x70
- call selectline
- xchg al,[cs:old]
- mov ch,0x07
- call selectline
- pop cx
- ret
-
-old db 20
-
-;selectionne la ligne al de couleur ch
-selectline:
- push ax
- push bx
- push cx
- push ds
- mov bh,160
- mul bh
- mov bx,ax
- mov ax,0xB800
- mov ds,ax
- inc bx
- mov cl,80
-select:
- mov [bx],ch
- add bx,2
- dec cl
- jnz select
- pop ds
- pop cx
- pop bx
- pop ax
- ret
-
-;=============================================================================
-
-; ROUTINES UNIVERSELLES INSPIREE DE COS2000
-
-;=============================================================================
-
-
-;=========GETDRIVEINFOS==============
-;Envoie en es:di les lecteurs logiques sur les volumes point‚ par ds:si
-;-> BP, ES:DI
-;<- CX leur nombre
-;====================================
-getdriveinfos:
- push ax
- push bx
- push dx
- push si
- push di
- push bp
- push di
- xor bx,bx
-show:
- xor dh,dh
- mov dl,[si]
- inc si
- cmp dl,0xFF
- je endofshow
- mov bp,dx
- call initdisk
- call IsMbr
- je okmbr
- call getvolume
- inc bx
- add di,64
- jmp show
-okmbr:
- call getpartitions
- mov ax,cx
- shl ax,6
- add di,ax
- add bx,cx
- jmp show
-endofshow:
- pop si
- mov al,'C'
- mov cx,bx
- push cx
- push si
-checkp:
- cmp byte [si+4],5
- je notprim
- cmp byte [si+4],0x0F
- je notprim
- cmp byte [si+16],0
- jnz notprim
- cmp byte [si+26],0x80
- jb notprim
- mov [si+51],al
- inc al
-notprim:
- add si,64
- dec cx
- jnz checkp
- pop si
- pop cx
- push cx
- push si
-checkl:
- cmp byte [si+4],5
- je notext
- cmp byte [si+4],0x0F
- je notext
- cmp byte [si+16],0x00
- jz notext
- cmp byte [si+26],0x80
- jb notext
- mov [si+51],al
- inc al
-notext:
- add si,64
- dec cx
- jnz checkl
- pop si
- pop cx
- mov al,'A'
- push cx
- push si
-checkn:
- cmp byte [si+26],0x80
- jae notlec
- mov [si+51],al
- inc al
-notlec:
- add si,64
- dec cx
- jnz checkn
- pop si
- pop cx
- mov al,'*'
- push cx
- push si
-checko:
- cmp byte [si+4],5
- je ext2
- cmp byte [si+4],0x0F
- jne notext2
-ext2:
- mov [si+51],al
-notext2:
- add si,64
- dec cx
- jnz checko
- pop si
- pop cx
- pop bp
- pop di
- pop si
- pop dx
- pop bx
- pop ax
- ret
-
-;=============GETVOLUME==============
-;Envoie en es:di les infos disque EBP
-;-> BP, ES:DI
-;<-
-;====================================
-getvolume:
- push ax
- push ecx
- push edx
- push di
- push di
- mov cx,64
- mov al,0
- cld
- rep stosb
- pop di
- mov byte [es:di+4],0xFF
- mov ecx,0
- mov [di+26],bp
- push di
- add di,28
- call getbootinfos
- pop di
- mov [di+12],edx
- pop di
- pop edx
- pop ecx
- pop ax
- ret
-
-;==========GETBOOTINFOS==============
-;Envoie en es:di le nom du volume & le FS d'adresse LBA ECX sur disque EBP
-;-> BP, ES:DI, ECX
-;<-
-;====================================
-getbootinfos:
- push ax
- push cx
- push si
- push di
- push di
- push es
- push cs
- pop es
- mov di,buffer
- mov si,di
- call readsector
- pop es
- pop di
- cmp byte [si+0x13],0
- je more32
- xor edx,edx
- mov dx,[si+0x13]
- jmp more16
-more32:
- mov edx,[si+0x20]
-more16:
- cmp byte [si+0x42],0x29
- je fat32
- cmp byte [si+0x26],0x29
- je fat16
-unk:
- mov si,noname
- jmp rel
-fat32:
- add si,0x47
- jmp rel
-fat16:
- add si,0x2B
-rel:
- mov cx,11
- cld
- rep movsb
- mov al,0
- stosb
- mov cx,8
- rep movsb
- mov ax,' '
- stosw
- mov al,0
- stosb
- pop di
- pop si
- pop cx
- pop ax
- ret
-
-;==========GETPARTITION==============
-;Envoie en es:di la liste des partitions du disque BP
-;-> BP, ES:DI
-;<- renvoie leur nombre en CX
-;====================================
-getpartitions:
- push eax
- push ebx
- push edx
- push si
- push di
- mov ecx,0
- mov word [wheres],0
- mov [theprimary],ecx
-againpart:
- xor eax,eax
- mov ebx,ecx
- push di
- mov di,partition
- CALL readsector
- mov si, di
- pop di
- add si,0x01BE
- mov cl,4
-showevery:
- cmp dword [si+NumSector],0x00000000
- je nothings
- mov edx,[si+StartSector]
- cmp byte [si+Kind],0x05
- je is
- cmp byte [si+Kind],0x0F
- jne isnot
-is:
- mov eax,[theprimary]
- add eax,edx
- cmp dword [theprimary],0
- jne nothings
-isnot:
- push ecx
- push di
- push si
- mov cx,[wheres]
- shl cx,6
- add di,cx
- mov ecx,16/4
- rep movsd
- pop si
- mov [di],ebx
- mov [di+4],si
- sub word [di+4],partition
- mov [di+6],ebx
- add [di+6],edx
- mov ecx,[di+6]
- mov [di+10],bp
- add di,12
- push edx
- call getbootinfos
- pop edx
- pop di
- pop ecx
- inc word [wheres]
-nothings:
- add si,16
- dec cl
- jnz showevery
- mov ecx,eax
- cmp dword [theprimary],0x00000000
- jne noth
- mov [theprimary],eax
-noth:
- cmp ecx,0
- jnz near againpart
- mov cx,[wheres]
- pop di
- pop si
- pop edx
- pop ebx
- pop eax
- ret
-
-;==============ISMBR=================
-;Zero si Mbr sur le premier secteur du support BP
-;-> BP
-;<-
-;====================================
-IsMbr:
- push ax
- push ecx
- push di
- push es
- mov ecx,0
- mov di,buffer
- push cs
- pop es
- call readsector
- add di,0x01BE
- mov cl,4
-isgood:
- mov al,[cs:di]
- and al,0x7F
- cmp al,0
- jne noMbr
- add di,16
- dec cl
- jne isgood
- cmp word [cs:di],0xAA55
-noMbr:
- pop es
- pop di
- pop ecx
- pop ax
- ret
-
-;=============DETECTDISK=============
-;Renvoie en ES:DI les disques d‚tect‚s fini par 0FFh
-;-> ES:DI
-;<-
-;====================================
-detectdisk:
- push ax
- push bx
- push cx
- push dx
- push si
- push di
- mov si,PossibleDisks
-DetectAllDisk:
- mov dl,[cs:si]
- inc si
- cmp dl,0xFF
- je EndOfDetection
- mov cl,4
-retry:
- push cx
- mov ax,0x0201
- mov cx,0x0101
- mov dh,0x00
- mov bx,buffer
- int 0x13
- pop cx
- jnc isdetected
- dec cl
- jnz retry
- jmp DetectAllDisk
-isdetected:
- mov [es:di],dl
- inc di
- jmp DetectAllDisk
-EndOfDetection:
- mov byte [di],0xFF
- pop di
- pop si
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-PossibleDisks db 0x00,0x01,0x02,0x03,0x04,0x05,0x80,0x81,0x82,0x83,0x84,0x85,0xFF
-
-;=============INITDISK===============
-;Initialise le p‚riph‚rique BP pour une utilisation ult‚rieure
-;-> BP
-;<-
-;====================================
-initdisk:
- push ax
- push bx
- push cx
- push dx
- push di
- push es
- mov dx,bp
- mov ah,8
- int 0x13
- and cx,0x3F
- mov [cs:sectorspertrack],cx
- mov cl,dh
- inc cl
- mov [cs:headsperdrive],cx
- pop es
- pop di
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;=============READSECTOR===============
-;Lit le secteur ECX du disque BP et le met en es:di
-;->
-;<-
-;======================================
-readsector:
- push ax
- push bx
- push ecx
- push dx
- push si
- mov ax,bp
- mov [cs:temp],al
- mov ax, cx
- ror ecx, 16
- mov dx, cx
- rol ecx,16
- cmp ecx,4128705
- ja extended
- div word [cs:sectorspertrack]
- inc dl
- mov bl, dl
- xor dx,dx
- div word [cs:headsperdrive]
- mov dh, [cs:temp]
- xchg dl, dh
- mov cx, ax
- xchg cl, ch
- shl cl, 6
- or cl, bl
- mov bx, di
- mov si, 4
- mov al, 1
-TryAgain:
- mov ah, 2
- int 0x13
- jnc Done
- dec si
- jnz TryAgain
-Done:
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-extended:
- push di
- push ds
- push cs
- pop ds
- mov si,block
- mov byte [si+Sizes],0x10
- mov byte [si+Reserve],0x01
- mov word [si+NumSectors],0x0001
- mov [si+Adressseg],es
- mov [si+Adressoff],di
- mov [si+SectorLow],ax
- mov [si+SectorHigh],dx
- mov di,4
- mov dl,[temp]
-TryAgainX:
- mov ah, 0x42
- int 0x13
- jnc DoneX
- dec di
- jnz TryAgainX
-DoneX:
- pop ds
- pop di
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-
-headsperdrive dw 16
-sectorspertrack dw 38
-block times 24 db 0
-temp db 0
-
-;============CLS==============
-;Efface l'‚cran
-;->
-;<-
-;=============================
-cls:
- push ax
- mov ax,0x0003
- int 0x10
- pop ax
- ret
-
-;==========SHOWSTR============
-;Affiche une chaine de caractŠre point‚ par SI
-;-> SI pointe une chaine
-;<-
-;=============================
-showstr:
- push ax
- push bx
- push si
- cld
-again:
- lodsb
- or al,al
- jz fin
- call showchar
- jmp again
-fin:
- pop si
- pop bx
- pop ax
- ret
-
-;==========SHOWPASSTR============
-;Affiche une chaine de caractŠre point‚ par SI
-;-> SI pointe une chaine
-;<-
-;=============================
-showpasstr:
- push ax
- push bx
- push cx
- push si
- mov cl,[si]
- inc si
- cld
-again2:
- lodsb
- call showchar
- dec cl
- jnz again2
-fin2:
- pop si
- pop cx
- pop bx
- pop ax
- ret
-
-;==========WAITKEY=============
-;Attend l'appuie d'une toouche et
-;renvoie en AL la touche appuyer
-;->
-;<- AL
-;==============================
-waitkey:
- mov ax,0
- int 0x16
- ret
-
-;==========SHOWCHAR============
-;Affiche un caractŠre point‚ dans AL
-;-> AL
-;<-
-;==============================
-showchar:
- push ax
- push bx
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- pop bx
- pop ax
- ret
-
-;==========SHOWINT============
-;Affiche un entier EDX apr‚s le curseur
-;-> EDX un entier
-;<-
-;=============================
-showint:
- push eax
- push bx
- push cx
- push edx
- push esi
- push di
- push ds
- push es
-
- push cs
- push cs
- pop ds
- pop es
- mov cx,10
- mov di, showbuffer
- mov al,' '
- cld
- rep stosb
- xor cx,cx
- mov eax, edx
- mov esi, 10
- mov bx,di
- mov byte [cs:di+1],0
-decint:
- xor edx,edx
- div esi
- add dl,'0'
- inc cx
- mov [cs:bx],dl
- dec bx
- cmp ax, 0
- jne decint
-showinteger:
- mov si, showbuffer
- call showstr
- pop es
- pop ds
- pop di
- pop esi
- pop edx
- pop cx
- pop bx
- pop eax
- ret
-
-;=============================================================================
-
-; VARIABLES INITIALISEE
-
-;=============================================================================
-
-sel dw 0
-wheres dw 0
-numbers dw 0
-
-;=============================================================================
-
-; VARIABLES NON INITIALISEE
-
-;=============================================================================
-
-theprimary equ $
-showbuffer equ $+1
-disk equ $+1+12
-partition equ $+1+12+26
-buffer equ $+1+12+26+512
-thepart equ $+1+12+26+512+512
-
-section .bss
-
-%include "partition.h"
-%include "echs.h"
-
-;theprimary resd 1
-;showbuffer resb 12
-;disk resb 26
-;partition resb 512
-;buffer resb 512
-;thepart resb 10000
-
diff --git a/install/mbrol/makefile b/install/mbrol/makefile
deleted file mode 100644
index 21ce4c0..0000000
--- a/install/mbrol/makefile
+++ /dev/null
@@ -1,17 +0,0 @@
-all: makall
-
-makall: mbrol.com
-
-mbrol.com:
- nasm -f bin -o mbr.bin mbr.asm
- nasm -f bin -o loader.bin loader.asm
- sync
- nasm -f bin -o mbrol.com mbrol.asm
-
-clean:
- rm -f *.o
- rm -f *.bin
- rm -f *.sys
- rm -f *.com
-
-
diff --git a/install/mbrol/mbr.asm b/install/mbrol/mbr.asm
deleted file mode 100644
index ef31b01..0000000
--- a/install/mbrol/mbr.asm
+++ /dev/null
@@ -1,214 +0,0 @@
-[BITS 16]
-[ORG 0x7C00]
-
-start:
- jmp short falsereal ;vers debut programme
- db "MBROL" ;Signature MBROL
-falsereal:
- cli ;inhibation interruptions
- xor ax,ax
- mov ss,ax ;Reloge pile en 0000h:9000h
- mov sp,0x9000
- push ax
- pop ds ;DS=0000h
- add ah,0x10
- push ax
- pop es ;ES=1000h
- sti ;Reactivation des interruptions
- cld
- mov [sitemp],si ;sauvegarde si (adresse partition active)
- mov di,0x7C00
- mov si,di
- mov cx,512/4
- rep movsd ;On reloge le programme en 1000h:7C00h
- push es
- pop ds ;DS=1000h
- jmp 0x1000:RealStart
-
-RealStart:
- xor dh,dh
- mov bp,dx ;R‚cupŠre en BP le nølecteur de d‚marrage
- call initdisk ;Initialisation du p‚riph‚rique
- ;call cls ;Efface l'‚cran
- mov si, msg
- call showstr ;Affiche le splatch de boot
- call getkey ;R‚cupŠre la touche press‚ par l'utilisateur
- cmp al,' ' ;touche = espace
- jne normal ;si autre touche on démarre normalement
- mov si, msgmbrol
- call showstr ;Message de chargement de Cos loader
- xor ecx,ecx
- inc ecx
- mov di,0x0100
-readload:
- inc ecx
- call readsector ;Charge le secteur LBA ecx en es:di
- add di,512
- cmp ecx,7
- jb readload ;Charge les secteurs LBA 2 … 6 en 1000h:0100h
-
- jmp 0x1000:0x0100 ;Execute Cos loader
- ;saut FAR vers 1000h:0100h
-
-normal:
- mov si,msgnorm
- call showstr ;Affiche le d‚marrage normal
- mov ecx,1
- xor ax,ax
- mov es,ax
- mov ds,ax
- mov di,0x7C00 ;Charge le secteur LBA 1 en 0000h:7C00h
- call readsector ;qui est le MBR d'origine sauvegard‚ par MBROL
- mov dx,bp ;Renvoie dans DL le lecteur de d‚marrage
- mov si,[sitemp] ;restaure si (adresse de la partition)
- jmp 0x0000:0x7C00 ;Une op‚ration normalement r‚alis‚e par le BIOS
- ;Saut vers le MBR en 0000h:7C00h
-
-temp db 0
-sitemp dw 0
-HeadsPerDrive dw 16
-SectorsPerTrack dw 38
-msg db "Cos2000 MBROL V1.0",0x0A,0x0D,"Press [SPACE] to execute Cos Loader",0x0A,0x0D,0
-point db '.',0
-msgmbrol db "Cos Loader is loading",0
-msgnorm db "Booting...",0
-
-;=============INITDISK===============
-;Initialise le p‚riph‚rique BP pour une utilisation ult‚rieure
-;-> BP
-;<-
-;====================================
-initdisk:
- push ax
- push bx
- push cx
- push dx
- push di
- push es
- mov dx,bp
- mov ah,8
- int 0x13
- and cx,111111b
- mov [cs:SectorsPerTrack],cx
- mov cl,dh
- inc cl
- mov [cs:HeadsPerDrive],cx
- pop es
- pop di
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;=============READSECTOR (Fonction 01H)===============
-;Lit le secteur ECX du disque BP et le met en es:di
-;-> AH=1
-;<- Flag Carry si erreur
-;=====================================================
-readsector:
- push ax
- push bx
- push ecx
- push dx
- push si
- mov ax,bp
- mov [cs:temp],al
- mov ax, cx
- ror ecx, 16
- mov dx, cx
- rol ecx,16
- div word [cs: SectorsPerTrack]
- inc dl
- mov bl, dl
- xor dx,dx
- div word [cs: HeadsPerDrive]
- mov dh, [cs:temp]
- xchg dl, dh
- mov cx, ax
- xchg cl, ch
- shl cl, 6
- or cl, bl
- mov bx, di
- mov si, 4
- mov al, 1
-TryAgain:
- mov ah, 2
- int 13h
- push si
- mov si,point
- call showstr
- pop si
- jnc Done
- dec si
- jnz TryAgain
-Done:
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-
-;============CLS==============
-;Efface l'‚cran
-;->
-;<-
-;=============================
-cls:
- push ax
- mov ax,0x0003
- int 0x10
- pop ax
- ret
-
-;==========SHOWSTR============
-;Affiche une chaine de caractŠre point‚ par SI
-;-> SI pointe une chaine
-;<-
-;=============================
-showstr:
- push ax
- push bx
- push si
-again:
- lodsb
- or al,al
- jz fin
- CALL showchar
- jmp again
-fin:
- pop si
- pop bx
- pop ax
- ret
-
-;===========GETKEY=============
-;N'Attend l'appuie d'une touche et
-;renvoie en AL la touche appuyer
-;->
-;<- AL
-;==============================
-getkey:
- mov ah,0x01
- int 0x16
- ret
-
-;==========SHOWCHAR============
-;Affiche un caractŠre point‚ dans AL
-;-> AL
-;<-
-;==============================
-showchar:
- push ax
- push bx
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- pop bx
- pop ax
- ret
-
-times 510-($-$$) db 0
-
- dw 0xAA55
\ No newline at end of file
diff --git a/install/mbrol/mbrol.asm b/install/mbrol/mbrol.asm
deleted file mode 100644
index 8cec9bd..0000000
--- a/install/mbrol/mbrol.asm
+++ /dev/null
@@ -1,1343 +0,0 @@
-[BITS 16]
-[ORG 0x0100]
-
-section .text
-
-start:
- mov di,disk
- call detectdisk
- mov si,di
- mov di,thedrive
- call getalldriveinfos
- mov [numbers],cx
- mov al,3
- mov word [sel],0
-main:
- call cls
- mov si,thedrive
- call showalldriveinfos
- call selection
-waitafter:
- call waitkey
- call lower
- cmp ah,0x50
- jne tre1
- mov ax,[sel]
- inc al
- cmp ax,[numbers]
- jz waitafter
- mov [sel],ax
- add al,3
- call selection
- jmp waitafter
-tre1:
- cmp ah,0x48
- jne tre2
- mov ax,[sel]
- cmp ax,0
- jz waitafter
- dec al
- mov [sel],ax
- add al,3
- call selection
- jmp waitafter
-tre2:
- cmp al,0x0D
- jne tre3
- mov bx,[sel]
- shl bx,4
- add bx,thedrive
- mov bp,[bx]
- call initdisk
- mov di,thepart
- call IsMbr
- je okmbr2
- call getvolume
- mov cx,1
- jmp nombr2
-okmbr2:
- call getpartitions
-nombr2:
- call cls
- mov si,di
- call showdriveinfos
- call waitkey
- call lower
- mov al,[cs:old]
- jmp main
-tre3:
- cmp al,'i'
- jne tre4
- mov bx,[sel]
- shl bx,4
- add bx,thedrive
- mov bp,[bx]
- call initdisk
- mov al,[cs:old]
- cmp byte [bx+1],1
- je noerase
- mov si,erasing
- call showstr
- call choice
- jnz near main
-noerase:
- cmp byte [bx+2],1
- jne noreinst
- mov si,remplacing
- call showstr
- call choice
- jnz near main
-noreinst:
- cmp byte [bx+3],0
- jne nolbas
- cmp dword [bx+4],8300
- jb nolbas
- mov si,nowereLBA
- call showstr
- call choice
- jnz near main
-nolbas:
- mov si,really
- call showstr
- call choice
- jnz near main
- call install
- mov si,installed
- call showstr
- mov si,disk
- mov di,thedrive
- call getalldriveinfos
- push ax
- call waitkey
- pop ax
- jmp main
-tre4:
- cmp al,0x1B
- jne tre5
- call cls
- ret
-tre5:
- cmp al,'u'
- jne tre6
- mov bx,[sel]
- shl bx,4
- add bx,thedrive
- mov bp,[bx]
- mov al,[cs:old]
- cmp byte [bx+2],1
- je letsgo
- mov si,noinst
- call showstr
- push ax
- call waitkey
- pop ax
- jmp main
-letsgo:
- mov si,uninst
- call showstr
- call choice
- jnz near main
- call uninstall
- mov si,uninstalled
- call showstr
- mov si,disk
- mov di,thedrive
- call getalldriveinfos
- push ax
- call waitkey
- pop ax
- jmp main
-tre6:
- cmp al,'r'
- jne near waitafter
- call reboot
-
-;=============================================================================
-
-; DONNEES FIXES
-
-;=============================================================================
-msg2 db "ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄ¿"
- db "³ Volume ³ Type ³ Installed ³ LBA ³ Size MByte ³ Partitions ³"
- db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄ´",0
-tab2 db "ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÙ"
- db "[ENTER] informations [ESC] quit [R] reboot [I] install MBROL [U] uninstall MBROL",0
-noinst db 0x0A,0x0D,"MBROL is not yet installed, press a key...",0
-really db 0x0A,0x0D,"Do you really want to install MBROL ?",0
-erasing db 0x0A,0x0D,"Mbrol need a partionned disk, on this disk data will be erased, do it ?",0
-remplacing db 0x0A,0x0D,"Mbrol is already installed, do you want to replace old installation ?",0
-nowereLBA db 0x0A,0x0D,"BIOS or this drive don''t support LBA and it necessite LBA adressing, install ?",0
-installed db 0x0A,0x0D,"MBROL is installed, press a key to continue...",0
-uninstalled db 0x0A,0x0D,"MBROL is uninstalled, press a key to continue...",0
-uninst db 0x0A,0x0D,"Do you really want to uninstall MBROL ?",0
-processing db 0x0A,0x0D,"Processing",0
-
-floppy db "Floppy Disk",0
-hard db "Hard Disk",0
-boot db " Boot ",0
-mbr db " Mbr ",0
-yes1 db " Yes ",0
-no1 db " No ",0
-yes2 db " Yes ",0
-no2 db " No ",0
-choiced db 0x0A,0x0D,"[y/n]:",0
-
-msg db "ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÂÄÄÄÄÄÄÄÄÄÄÄÄÄ¿"
- db "³ Name ³ Type ³ Boot ³ Statut ³ Size MByte ³ StartSector ³"
- db "ÃÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄ´",0
-tab db "ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÁÄÄÄÄÄÄÄÄÄÄÄÄÄÙ"
- db "Press any key to close...",0
-sep db " ³ ",0
-
-partkind db 0x01,"FAT12 ",0
- db 0x04,"FAT16 ",0
- db 0x05,"Extended ",0
- db 0x06,"FAT16B ",0
- db 0x07,"IFS ",0
- db 0x0B,"FAT32 ",0
- db 0x0C,"FAT32X ",0
- db 0x0E,"FAT16X ",0
- db 0x0F,"ExtendedX ",0
- db 0x81,"Linux 1.4b",0
- db 0x82,"Linux SWAP",0
- db 0x83,"Linux EXT2",0
- db 0x11,"FAT12 Hid ",0
- db 0x14,"FAT16 Hid",0
- db 0x16,"FAT16B Hid",0
- db 0x17,"IFS Hid ",0
- db 0x1B,"FAT32 Hid ",0
- db 0x1C,"FAT32X Hid",0
- db 0x1E,"FAT16X Hid",0
- db 0xFF,"Unknowed ",0
-
-noname db "Unknowed ","Unkowned ",0
-unknowed db "Movable ",0
-primary db "Primary ",0
-secondary db "Secondary",0
-yes db "Yes ",0
-no db "No ",0
-mo db " MB",0
-
-;=============================================================================
-
-; ROUTINES PARTICULIERES
-
-;=============================================================================
-;converti al en lowercase
-lower:
- cmp al,'A'
- jb noupper
- cmp al,'Z'
- ja noupper
- add al,'a'-'A'
-noupper:
- ret
-
-;redemarrage … chaud
-reboot:
- mov ax,0x40
- mov ds,ax
- mov bx,0x1234
- mov [ds:0x0072],bx
- jmp 0xFFFF:0x0000
-
-;Dialogue qui demande si Yes or No et Renvoie zero si YES et
-choice:
- push ax
- push si
- mov si,choiced
- call showstr
-waiter:
- call waitkey
- call lower
- cmp al,'y'
- je iyes
- cmp al,'n'
- je ino
- jmp waiter
-iyes:
- call showchar
- cmp al,al
- jmp endof
-ino:
- call showchar
- cmp al,' '
- jmp endof
-endof:
- pop si
- pop ax
- ret
-
-;install MBROL sur le disque BP
-install:
- push ax
- push ecx
- push si
- push di
- mov si,processing
- call showstr
- call initdisk
- mov ecx,0
- mov di,buffer
- call readsector
- inc ecx
- mov si,di
- cmp dword [di+2],"MBRO"
- je nosave
- call writesector
-nosave:
- add si,0x01BE
- mov di,prog+0x01BE
- mov cx,16*4/4
- cld
- rep movsd
- mov ecx,0
- mov si,prog
- call writesector
- inc ecx
-copying:
- inc ecx
- add si,512
- call writesector
- mov al,'.'
- call showchar
- cmp ecx,7
- jb copying
- pop di
- pop si
- pop ecx
- pop ax
- ret
-
-;desinstalle MBROL sur le disque BP
-uninstall:
- push ecx
- push si
- push di
- call initdisk
- mov ecx,1
- mov di,buffer
- call readsector
- dec ecx
- mov si,di
- call writesector
- pop di
- pop si
- pop ecx
- ret
-
-;Affiche des infos sur le volume
-showalldriveinfos:
- push ax
- push bx
- push cx
- push edx
- push si
- mov si,msg2
- call showstr
- mov bx,thedrive
- mov cx,[numbers]
-showall:
- mov al,'³'
- call showchar
- mov al,' '
- call showchar
- mov al,[bx]
- mov si,floppy
- cmp al,0x80
- jb disks
- mov si,hard
-disks:
- call showstr
- and al,0xF
- push ax
- mov al,' '
- call showchar
- mov al,'0'
- call showchar
- pop ax
- add al,'0'
- call showchar
- mov si,sep
- call showstr
- mov si,boot
- cmp byte [bx+1],1
- jne booter
- mov si,mbr
-booter:
- call showstr
- mov si,sep
- call showstr
- mov si,no1
- cmp byte [bx+2],1
- jne noinsts
- mov si,yes1
-noinsts:
- call showstr
- mov si,sep
- call showstr
- mov si,no2
- cmp byte [bx+3],1
- jne lbas
- mov si,yes2
-lbas:
- call showstr
- mov si,sep
- call showstr
- mov edx,[bx+4]
- call showint
- mov si,mo
- call showstr
- mov si,sep
- call showstr
- mov dx,[bx+8]
- call showint
- mov al,' '
- call showchar
- mov al,'³'
- call showchar
- add bx,16
- dec cx
- jnz near showall
- mov si,tab2
- call showstr
- pop di
- pop edx
- pop cx
- pop bx
- pop ax
- ret
-
-;renvoie en ES:DI les infos sur les disques DS:SI et Nb dans CX
-getalldriveinfos:
- push ax
- push bx
- push dx
- push si
- push di
- push bp
- xor bx,bx
- xor cx,cx
-show2:
- xor dh,dh
- mov dl,[si]
- inc si
- cmp dl,0xFF
- je endofshow2
- inc cx
- mov bp,dx
- call initdisk
- mov [es:di],dl
- call IsMbr
- sete [es:di+1]
- call IsInstalled
- sete [es:di+2]
- call IsLBA
- setnc [es:di+3]
- push cx
- call getcapacity
- mov [es:di+4],ecx
- mov cx,1
- cmp byte [si-1],0x80
- jb noone
- push es
- push di
- push cs
- pop es
- mov di,dummys
- call getpartitions
- pop di
- pop es
-noone:
- mov [es:di+8],cx
- add di,16
- pop cx
- jmp show2
-endofshow2:
- pop bp
- pop di
- pop si
- pop dx
- pop bx
- pop ax
- ret
-
-;===========ISInstalled==============
-;Zero si Mbr sur le premier secteur du support BP
-;-> BP
-;<-
-;====================================
-IsInstalled:
- push ax
- push ecx
- push di
- push es
- mov ecx,0
- mov di,buffer
- push cs
- pop es
- call readsector
- cmp dword [di+2],"MBRO"
- pop es
- pop di
- pop ecx
- pop ax
- ret
-
-;Affiche des infos sur le volume
-showdriveinfos:
- push ax
- push bx
- push cx
- push edx
- push si
- mov si,msg
- call showstr
- mov bx,thepart
-showall2:
- mov al,'³'
- call showchar
- mov al,' '
- call showchar
- mov al,'-'
- call showchar
- mov al,'>'
- call showchar
- mov si,bx
- add si,28
- call showstr
- mov si,sep
- call showstr
- mov al,[bx+4]
- cmp al,0xFF
- je useboot
- mov si,partkind+1
-search:
- cmp byte [si-1],0xFF
- je notboot
- cmp [si-1],al
- je notboot
- add si,12
- jmp search
-useboot:
- mov si,bx
- add si,40
-notboot:
- call showstr
- mov si,sep
- call showstr
- mov si,yes
- cmp byte [bx],0x80
- je okboot
- mov si,no
-okboot:
- call showstr
- mov si,sep
- call showstr
- mov si,primary
- cmp dword [bx+16],0
- je okprimary
- mov si,secondary
-okprimary:
- cmp byte [bx+4],0xFF
- jne wasno
- mov si,unknowed
-wasno:
- call showstr
- mov si,sep
- call showstr
- mov edx,[bx+12]
- shr edx,11
- call showint
- mov si,mo
- call showstr
- mov si,sep
- call showstr
- mov edx,[bx+22]
- call showint
- mov al,' '
- call showchar
- mov al,'³'
- call showchar
- add bx,64
- dec cx
- jnz near showall2
- mov si,tab
- call showstr
- pop si
- pop edx
- pop cx
- pop bx
- pop ax
- ret
-
-;met en surlign‚e la ligne al et seulement al
-selection:
- push cx
- mov ch,0x70
- call selectline
- xchg al,[cs:old]
- cmp al,[cs:old]
- je nochange
- mov ch,0x07
- call selectline
-nochange:
- pop cx
- ret
-
-old db 20
-
-;selectionne la ligne al de couleur ch
-selectline:
- push ax
- push bx
- push cx
- push ds
- mov bh,160
- mul bh
- mov bx,ax
- mov ax,0xb800
- mov ds,ax
- inc bx
- mov cl,80
-select:
- mov [bx],ch
- add bx,2
- dec cl
- jnz select
- pop ds
- pop cx
- pop bx
- pop ax
- ret
-
-;=============================================================================
-
-; ROUTINES UNIVERSELLES INSPIREE DE COS2000
-
-;=============================================================================
-
-;============Getcapacity=============
-;Renvoie la capacit‚ du disque Bp dans ECX
-;-> BP
-;<-
-;====================================
-getcapacity:
- mov ecx,0
- ret
-
-;===============IsLBA================
-;Renvoie zero = 1 si LBA
-;-> BP
-;<-
-;====================================
-IsLBA:
- push ax
- push bx
- push cx
- push dx
- mov dx,bp
- mov ah,0x41
- mov bx,0x55AA
- int 0x13
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;=========GETDRIVEINFOS==============
-;Envoie en es:di les lecteurs logiques sur les volumes point‚ par ds:si
-;-> BP, ES:DI
-;<- CX leur nombre
-;====================================
-getdriveinfos:
- push ax
- push bx
- push dx
- push si
- push di
- push bp
- push di
- xor bx,bx
-show:
- xor dh,dh
- mov dl,[si]
- inc si
- cmp dl,0xFF
- je endofshow
- mov bp,dx
- call initdisk
- call IsMbr
- je okmbr
- call getvolume
- inc bx
- add di,64
- jmp show
-okmbr:
- call getpartitions
- mov ax,cx
- shl ax,6
- add di,ax
- add bx,cx
- jmp show
-endofshow:
- pop si
- mov al,'C'
- mov cx,bx
- push cx
- push si
-checkp:
- cmp byte [si+4],5
- je notprim
- cmp byte [si+4],0x0F
- je notprim
- cmp byte [si+16],0
- jnz notprim
- cmp byte [si+26],0x80
- jb notprim
- mov [si+51],al
- inc al
-notprim:
- add si,64
- dec cx
- jnz checkp
- pop si
- pop cx
- push cx
- push si
-checkl:
- cmp byte [si+4],5
- je notext
- cmp byte [si+4],0x0F
- je notext
- cmp byte [si+16],0x00
- jz notext
- cmp byte [si+26],0x80
- jb notext
- mov [si+51],al
- inc al
-notext:
- add si,64
- dec cx
- jnz checkl
- pop si
- pop cx
- mov al,'A'
- push cx
- push si
-checkn:
- cmp byte [si+26],0x80
- jae notlec
- mov [si+51],al
- inc al
-notlec:
- add si,64
- dec cx
- jnz checkn
- pop si
- pop cx
- mov al,'*'
- push cx
- push si
-checko:
- cmp byte [si+4],5
- je ext2
- cmp byte [si+4],0x0F
- jne notext2
-ext2:
- mov [si+51],al
-notext2:
- add si,64
- dec cx
- jnz checko
- pop si
- pop cx
- pop bp
- pop di
- pop si
- pop dx
- pop bx
- pop ax
- ret
-
-;=============GETVOLUME==============
-;Envoie en es:di les infos disque EBP
-;-> BP, ES:DI
-;<-
-;====================================
-getvolume:
- push ax
- push ecx
- push edx
- push di
- push di
- mov cx,64
- mov al,0
- cld
- rep stosb
- pop di
- mov byte [es:di+4],0xFF
- mov ecx,0
- mov [di+26],bp
- push di
- add di,28
- call getbootinfos
- pop di
- mov [di+12],edx
- pop di
- pop edx
- pop ecx
- pop ax
- ret
-
-;==========GETBOOTINFOS==============
-;Envoie en es:di le nom du volume & le FS d'adresse LBA ECX sur disque EBP
-;-> BP, ES:DI, ECX
-;<-
-;====================================
-getbootinfos:
- push ax
- push cx
- push si
- push di
- push di
- push es
- push cs
- pop es
- mov di,buffer
- mov si,di
- call readsector
- pop es
- pop di
- cmp byte [si+0x13],0
- je more32
- xor edx,edx
- mov dx,[si+0x13]
- jmp more16
-more32:
- mov edx,[si+0x20]
-more16:
- cmp byte [si+0x42],0x29
- je fat32
- cmp byte [si+0x26],0x29
- je fat16
-unk:
- mov si,noname
- jmp rel
-fat32:
- add si,0x47
- jmp rel
-fat16:
- add si,0x2B
-rel:
- mov cx,11
- cld
- rep movsb
- mov al,0
- stosb
- mov cx,8
- rep movsb
- mov ax,' '
- stosw
- mov al,0
- stosb
- pop di
- pop si
- pop cx
- pop ax
- ret
-
-;==========GETPARTITION==============
-;Envoie en es:di la liste des partitions du disque BP
-;-> BP, ES:DI
-;<- renvoie leur nombre en CX
-;====================================
-getpartitions:
- push eax
- push ebx
- push edx
- push si
- push di
- mov ecx,0
- mov word [wheres],0
- mov [theprimary],ecx
-againpart:
- xor eax,eax
- mov ebx,ecx
- push di
- mov di,partition
- CALL readsector
- mov si, di
- pop di
- add si,0x01BE
- mov cl,4
-showevery:
- cmp dword [si+NumSector],0x00000000
- je nothings
- mov edx,[si+StartSector]
- cmp byte [si+Kind],0x05
- je is
- cmp byte [si+Kind],0x0F
- jne isnot
-is:
- mov eax,[theprimary]
- add eax,edx
- cmp dword [theprimary],0
- jne nothings
-isnot:
- push ecx
- push di
- push si
- mov cx,[wheres]
- shl cx,6
- add di,cx
- mov ecx,16/4
- rep movsd
- pop si
- mov [di],ebx
- mov [di+4],si
- sub word [di+4],partition
- mov [di+6],ebx
- add [di+6],edx
- mov ecx,[di+6]
- mov [di+10],bp
- add di,12
- push edx
- call getbootinfos
- pop edx
- pop di
- pop ecx
- inc word [wheres]
-nothings:
- add si,16
- dec cl
- jnz showevery
- mov ecx,eax
- cmp dword [theprimary],0x00000000
- jne noth
- mov [theprimary],eax
-noth:
- cmp ecx,0
- jnz near againpart
- mov cx,[wheres]
- pop di
- pop si
- pop edx
- pop ebx
- pop eax
- ret
-
-;==============ISMBR=================
-;Zero si Mbr sur le premier secteur du support BP
-;-> BP
-;<-
-;====================================
-IsMbr:
- push ax
- push ecx
- push di
- push es
- mov ecx,0
- mov di,buffer
- push cs
- pop es
- call readsector
- add di,0x01BE
- mov cl,4
-isgood:
- mov al,[cs:di]
- and al,0x7F
- cmp al,0
- jne noMbr
- add di,16
- dec cl
- jne isgood
- cmp word [cs:di],0xAA55
-noMbr:
- pop es
- pop di
- pop ecx
- pop ax
- ret
-
-;=============DETECTDISK=============
-;Renvoie en ES:DI les disques d‚tect‚s fini par 0FFh
-;-> ES:DI
-;<-
-;====================================
-detectdisk:
- push ax
- push bx
- push cx
- push dx
- push si
- push di
- mov si,PossibleDisks
-DetectAllDisk:
- mov dl,[cs:si]
- inc si
- cmp dl,0xFF
- je EndOfDetection
- mov cl,4
-retry:
- push cx
- mov ax,0x0201
- mov cx,0x0101
- mov dh,0x00
- mov bx,buffer
- int 0x13
- pop cx
- jnc isdetected
- dec cl
- jnz retry
- jmp DetectAllDisk
-isdetected:
- mov [es:di],dl
- inc di
- jmp DetectAllDisk
-EndOfDetection:
- mov byte [di],0xFF
- pop di
- pop si
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-PossibleDisks db 0x00,0x01,0x02,0x03,0x04,0x05,0x80,0x81,0x82,0x83,0x84,0x85,0xFF
-
-;=============INITDISK===============
-;Initialise le p‚riph‚rique BP pour une utilisation ult‚rieure
-;-> BP
-;<-
-;====================================
-initdisk:
- push ax
- push bx
- push cx
- push dx
- push di
- push es
- mov dx,bp
- mov ah,8
- int 0x13
- and cx,0x3F
- mov [cs:sectorspertrack],cx
- mov cl,dh
- inc cl
- mov [cs:headsperdrive],cx
- pop es
- pop di
- pop dx
- pop cx
- pop bx
- pop ax
- ret
-
-;=============WRITESECTOR (Fonction 01H)===============
-;Ecrit le secteur ECX du disque BP depuis ds:si
-;-> AH=1
-;<- Flag Carry si erreur
-;=====================================================
-writesector:
- push ax
- push bx
- push ecx
- push dx
- push si
- push di
- mov ax,bp
- mov [cs:temp],al
- mov ax, cx
- ror ecx, 16
- mov dx, cx
- rol ecx,16
- div word [cs:sectorspertrack]
- inc dl
- mov bl, dl
- xor dx,dx
- div word [cs:headsperdrive]
- mov dh, [cs:temp]
- xchg dl, dh
- mov cx, ax
- xchg cl, ch
- shl cl, 6
- or cl, bl
- mov bx, si
- mov si, 4
- mov al, 1
-TryAgain2:
- mov ah, 3
- int 0x13
- jnc Done2
- dec si
- jnz TryAgain2
-Done2:
- pop di
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-
-;=============READSECTOR===============
-;Lit le secteur ECX du disque BP et le met en es:di
-;->
-;<-
-;======================================
-readsector:
- push ax
- push bx
- push ecx
- push dx
- push si
- mov ax,bp
- mov [cs:temp],al
- mov ax, cx
- ror ecx, 16
- mov dx, cx
- rol ecx,16
- cmp ecx,4128705
- ja extended
- div word [cs:sectorspertrack]
- inc dl
- mov bl, dl
- xor dx,dx
- div word [cs:headsperdrive]
- mov dh, [cs:temp]
- xchg dl, dh
- mov cx, ax
- xchg cl, ch
- shl cl, 6
- or cl, bl
- mov bx, di
- mov si, 4
- mov al, 1
-TryAgain:
- mov ah, 2
- int 0x13
- jnc Done
- dec si
- jnz TryAgain
-Done:
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-extended:
- push di
- push ds
- push cs
- pop ds
- mov si,block
- mov byte [si+Sizes],0x10
- mov byte [si+Reserve],0x01
- mov word [si+NumSectors],0x0001
- mov [si+Adressseg],es
- mov [si+Adressoff],di
- mov [si+SectorLow],ax
- mov [si+SectorHigh],dx
- mov di,4
- mov dl,[temp]
-TryAgainX:
- mov ah, 0x42
- int 0x13
- jnc DoneX
- dec di
- jnz TryAgainX
-DoneX:
- pop ds
- pop di
- pop si
- pop dx
- pop ecx
- pop bx
- pop ax
- ret
-
-headsperdrive dw 16
-sectorspertrack dw 38
-block times 24 db 0
-temp db 0
-
-;============CLS==============
-;Efface l'‚cran
-;->
-;<-
-;=============================
-cls:
- push ax
- mov ax,0x0003
- int 0x10
- pop ax
- ret
-
-;==========SHOWSTR============
-;Affiche une chaine de caractŠre point‚ par SI
-;-> SI pointe une chaine
-;<-
-;=============================
-showstr:
- push ax
- push bx
- push si
- cld
-again:
- lodsb
- or al,al
- jz fin
- call showchar
- jmp again
-fin:
- pop si
- pop bx
- pop ax
- ret
-
-;==========SHOWPASSTR============
-;Affiche une chaine de caractŠre point‚ par SI
-;-> SI pointe une chaine
-;<-
-;=============================
-showpasstr:
- push ax
- push bx
- push cx
- push si
- mov cl,[si]
- inc si
- cld
-again2:
- lodsb
- call showchar
- dec cl
- jnz again2
-fin2:
- pop si
- pop cx
- pop bx
- pop ax
- ret
-
-;==========WAITKEY=============
-;Attend l'appuie d'une toouche et
-;renvoie en AL la touche appuyer
-;->
-;<- AL
-;==============================
-waitkey:
- mov ax,0
- int 0x16
- ret
-
-;==========SHOWCHAR============
-;Affiche un caractŠre point‚ dans AL
-;-> AL
-;<-
-;==============================
-showchar:
- push ax
- push bx
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- pop bx
- pop ax
- ret
-
-;==========SHOWINT============
-;Affiche un entier EDX apr‚s le curseur
-;-> EDX un entier
-;<-
-;=============================
-showint:
- push eax
- push bx
- push cx
- push edx
- push esi
- push di
- push ds
- push es
- push cs
- push cs
- pop ds
- pop es
- mov cx,10
- mov di,showbuffer
- mov al,' '
- cld
- rep stosb
- xor cx,cx
- mov eax, edx
- mov esi, 10
- mov bx,di
- mov byte [cs:di+1],0
-decint:
- xor edx,edx
- div esi
- add dl,'0'
- inc cx
- mov [cs:bx],dl
- dec bx
- cmp ax, 0
- jne decint
-showinteger:
- mov si,showbuffer
- call showstr
- pop es
- pop ds
- pop di
- pop esi
- pop edx
- pop cx
- pop bx
- pop eax
- ret
-
-;=============================================================================
-
-; VARIABLES INITIALISEE
-
-;=============================================================================
-
-sel dw 0
-wheres dw 0
-numbers dw 0
-theprimary dd 0
-prog:
-
-incbin "mbr.bin"
-incbin "loader.bin"
-;=============================================================================
-
-; VARIABLES NON INITIALISEE
-
-;=============================================================================
-
-showbuffer equ $
-disk equ $+12
-partition equ $+12+26
-buffer equ $+12+26+512
-thepart equ $+12+26+512+512
-thedrive equ $+12+26+512+512+10000
-dummys equ $+12+26+512+512+10000+10000
-
-section .bss
-
-%include "partition.h"
-%include "echs.h"
-
-;showbuffer resb 12
-;disk resb 26
-;partition resb 512
-;buffer resb 512
-;thepart resb 10000
-;thedrive resb 10000
-;dummys resb 10000
-
diff --git a/install/mbrol/partition.h b/install/mbrol/partition.h
deleted file mode 100644
index 96800f8..0000000
--- a/install/mbrol/partition.h
+++ /dev/null
@@ -1,10 +0,0 @@
-struc part
-Active resb 1
-StartH resb 1
-StartCS resw 1
-Kind resb 1
-EndH resb 1
-EndCS resw 1
-StartSector resd 1
-NumSector resd 1
-endstruc
diff --git a/lib/3d.c b/lib/3d.c
new file mode 100755
index 0000000..1e51ac1
--- /dev/null
+++ b/lib/3d.c
@@ -0,0 +1,5 @@
+#include "3d.h"
+#include "vga.h"
+#include "types.h"
+#include "video.h"
+#include "graph.h"
diff --git a/lib/8x16fnt.c b/lib/8x16fnt.c
old mode 100644
new mode 100755
index dbb91d0..c084bb9
--- a/lib/8x16fnt.c
+++ b/lib/8x16fnt.c
@@ -1,259 +1,259 @@
-/* Police de caractère fine 8x16 */
-static u8 font8x16 [4096] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7E, 0x81, 0xA5, 0x81, 0x81, 0xBD, 0x99, 0x81, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7E, 0xFF, 0xDB, 0xFF, 0xFF, 0xC3, 0xE7, 0xFF, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x36, 0x7F, 0x7F, 0x7F, 0x7F, 0x3E, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x08, 0x1C, 0x3E, 0x7F, 0x3E, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x3C, 0x3C, 0xE7, 0xE7, 0xE7, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x7E, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xC3, 0xC3, 0xE7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3C, 0x66, 0x42, 0x42, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0xFF, 0xFF, 0xFF, 0xFF, 0xC3, 0x99, 0xBD, 0xBD, 0x99, 0xC3, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
- 0x00, 0x00, 0x0F, 0x07, 0x0D, 0x19, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x3F, 0x33, 0x3F, 0x30, 0x30, 0x30, 0x70, 0xF0, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7F, 0x63, 0x7F, 0x63, 0x63, 0x63, 0x67, 0xE7, 0xE6, 0xC0, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0xDB, 0x3C, 0xE7, 0x3C, 0xDB, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x40, 0x60, 0x70, 0x7C, 0x7F, 0x7C, 0x70, 0x60, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x01, 0x03, 0x07, 0x1F, 0x7F, 0x1F, 0x07, 0x03, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x33, 0x33, 0x33, 0x33, 0x33, 0x33, 0x00, 0x33, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7F, 0xDB, 0xDB, 0xDB, 0x7B, 0x1B, 0x1B, 0x1B, 0x1B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3E, 0x63, 0x30, 0x1C, 0x36, 0x63, 0x63, 0x36, 0x1C, 0x06, 0x63, 0x3E, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x7F, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x0C, 0x06, 0x7F, 0x06, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x18, 0x30, 0x7F, 0x30, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x60, 0x60, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x08, 0x1C, 0x1C, 0x3E, 0x3E, 0x7F, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x7F, 0x7F, 0x3E, 0x3E, 0x1C, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x24, 0x24, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x42, 0x42, 0x42, 0xFF, 0x42, 0x42, 0x42, 0xFF, 0x42, 0x42, 0x42, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x10, 0x7E, 0x90, 0x90, 0x90, 0x7C, 0x12, 0x12, 0x12, 0xFC, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x61, 0x91, 0x92, 0x64, 0x08, 0x10, 0x26, 0x49, 0x89, 0x86, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x70, 0x88, 0x88, 0x88, 0x50, 0x60, 0x91, 0x8A, 0x84, 0x4A, 0x31, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x06, 0x18, 0x20, 0x40, 0x40, 0x40, 0x40, 0x40, 0x20, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x60, 0x18, 0x04, 0x02, 0x02, 0x02, 0x02, 0x02, 0x04, 0x18, 0x60, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x10, 0x92, 0x54, 0x38, 0xFE, 0x38, 0x54, 0x92, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x01, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x83, 0x85, 0x89, 0x91, 0xA1, 0xC1, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x10, 0x30, 0x50, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x7C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x01, 0x02, 0x3C, 0x40, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x01, 0x02, 0x3C, 0x02, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x02, 0x06, 0x0A, 0x12, 0x22, 0x42, 0x82, 0xFF, 0x02, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFF, 0x80, 0x80, 0x80, 0xFC, 0x02, 0x01, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFF, 0x81, 0x01, 0x02, 0x04, 0x08, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x42, 0x3C, 0x42, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00,
- 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x38, 0x44, 0x82, 0x82, 0x04, 0x08, 0x10, 0x10, 0x00, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x99, 0xA5, 0xA5, 0xA5, 0x9E, 0x80, 0x41, 0x3E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x24, 0x42, 0x81, 0x81, 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFC, 0x42, 0x41, 0x41, 0x42, 0x7C, 0x42, 0x41, 0x41, 0x42, 0xFC, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x80, 0x80, 0x80, 0x80, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFC, 0x42, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x42, 0xFC, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFF, 0x80, 0x80, 0x80, 0x80, 0xFC, 0x80, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFF, 0x80, 0x80, 0x80, 0x80, 0xFC, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x80, 0x9F, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x38, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x38, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x07, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x82, 0x82, 0x44, 0x38, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x82, 0x84, 0x88, 0x90, 0xE0, 0x90, 0x88, 0x84, 0x82, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0xC3, 0xA5, 0x99, 0x99, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0xC1, 0xA1, 0x91, 0x89, 0x85, 0x83, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFC, 0x82, 0x81, 0x81, 0x82, 0xFC, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x81, 0x81, 0x89, 0x85, 0x42, 0x3D, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFC, 0x82, 0x81, 0x81, 0x82, 0xFC, 0x90, 0x88, 0x84, 0x82, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x42, 0x81, 0x80, 0x40, 0x3C, 0x02, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFE, 0x92, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x42, 0x24, 0x24, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x99, 0x99, 0xA5, 0xA5, 0x42, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x81, 0x81, 0x81, 0x42, 0x24, 0x18, 0x24, 0x42, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x82, 0x82, 0x82, 0x82, 0x44, 0x28, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFF, 0x01, 0x01, 0x02, 0x04, 0x18, 0x20, 0x40, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x7E, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x7E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x80, 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x7E, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x7E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x24, 0x42, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00,
- 0x00, 0x08, 0x04, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x02, 0x02, 0x7E, 0x82, 0x82, 0x7D, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x80, 0x80, 0x80, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0xC2, 0xBC, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x80, 0x80, 0x80, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x01, 0x01, 0x01, 0x01, 0x3D, 0x43, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x81, 0xFF, 0x80, 0x40, 0x3E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0E, 0x11, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3D, 0x43, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x02, 0x7C, 0x00, 0x00,
- 0x00, 0x80, 0x80, 0x80, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x08, 0x08, 0x00, 0x38, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x02, 0x02, 0x00, 0x06, 0x02, 0x02, 0x02, 0x02, 0x02, 0x82, 0x44, 0x38, 0x00, 0x00,
- 0x00, 0x80, 0x80, 0x80, 0x80, 0x82, 0x84, 0x88, 0x90, 0xA8, 0xC4, 0x82, 0x00, 0x00, 0x00, 0x00,
- 0x38, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xEC, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xB8, 0xC4, 0x82, 0x82, 0x82, 0x82, 0x82, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0xC2, 0xBC, 0x80, 0x80, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3D, 0x43, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x01, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xBE, 0xC1, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x81, 0x80, 0x7E, 0x01, 0x81, 0x7E, 0x00, 0x00, 0x00, 0x00,
- 0x10, 0x10, 0x10, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x10, 0x11, 0x0E, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x42, 0x24, 0x18, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x82, 0x82, 0x92, 0x92, 0x92, 0xAA, 0x44, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x42, 0x24, 0x18, 0x24, 0x42, 0x81, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x02, 0x7C, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x02, 0x04, 0x18, 0x20, 0x40, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x04, 0x08, 0x10, 0x10, 0x10, 0x20, 0x10, 0x10, 0x10, 0x08, 0x04, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x40, 0x20, 0x10, 0x10, 0x10, 0x08, 0x10, 0x10, 0x10, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x70, 0x99, 0x0E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x08, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1E, 0x33, 0x61, 0x60, 0x60, 0x61, 0x33, 0x1E, 0x06, 0x03, 0x3E, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x66, 0x66, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x06, 0x0C, 0x18, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x66, 0x66, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x1C, 0x36, 0x1C, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3C, 0x66, 0x60, 0x66, 0x3C, 0x0C, 0x06, 0x3C, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x66, 0x66, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x66, 0x66, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x3C, 0x66, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x60, 0x30, 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x63, 0x63, 0x08, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x1C, 0x36, 0x1C, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x0C, 0x18, 0x30, 0x00, 0x7F, 0x33, 0x30, 0x3E, 0x30, 0x33, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x6E, 0x3B, 0x1B, 0x7E, 0xD8, 0xDC, 0x77, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1F, 0x36, 0x66, 0x66, 0x7F, 0x66, 0x66, 0x66, 0x67, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x63, 0x63, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x3C, 0x66, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x30, 0x18, 0x0C, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x63, 0x63, 0x00, 0x63, 0x63, 0x63, 0x63, 0x3F, 0x03, 0x06, 0x3C, 0x00, 0x00, 0x00,
- 0x00, 0x63, 0x63, 0x1C, 0x36, 0x63, 0x63, 0x63, 0x63, 0x36, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x63, 0x63, 0x00, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x18, 0x18, 0x7E, 0xC3, 0xC0, 0xC0, 0xC3, 0x7E, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x1C, 0x36, 0x32, 0x30, 0x78, 0x30, 0x30, 0x30, 0x73, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0xC3, 0x66, 0x3C, 0x18, 0xFF, 0x18, 0xFF, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xFC, 0x66, 0x66, 0x7C, 0x62, 0x66, 0x6F, 0x66, 0x66, 0xF3, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0E, 0x1B, 0x18, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x18, 0x18, 0xD8, 0x70, 0x00, 0x00, 0x00,
- 0x00, 0x0C, 0x18, 0x30, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0C, 0x18, 0x30, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0C, 0x18, 0x30, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0C, 0x18, 0x30, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x3B, 0x6E, 0x00, 0x6E, 0x33, 0x33, 0x33, 0x33, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x3B, 0x6E, 0x00, 0x63, 0x73, 0x7B, 0x7F, 0x6F, 0x67, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x3C, 0x6C, 0x6C, 0x3E, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x7C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x30, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x03, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x60, 0xE0, 0x63, 0x66, 0x6C, 0x18, 0x30, 0x6E, 0xC3, 0x06, 0x0C, 0x1F, 0x00, 0x00, 0x00,
- 0x00, 0x60, 0xE0, 0x63, 0x66, 0x6C, 0x18, 0x33, 0x67, 0xCF, 0x1F, 0x03, 0x03, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x3C, 0x3C, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x1B, 0x36, 0x6C, 0x36, 0x1B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x6C, 0x36, 0x1B, 0x36, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x00, 0x00,
- 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x00, 0x00,
- 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x06, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xF7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xF7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
- 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00,
- 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00,
- 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x6C, 0x6C, 0x6E, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3E, 0x63, 0x7E, 0x63, 0x63, 0x7E, 0x60, 0x60, 0x20, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7F, 0x63, 0x63, 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x7F, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7F, 0x63, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x63, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x6C, 0x6C, 0x6C, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x33, 0x33, 0x33, 0x33, 0x3E, 0x30, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x7E, 0x18, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x36, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x63, 0x36, 0x36, 0x36, 0x77, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1E, 0x30, 0x18, 0x0C, 0x3E, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0xDB, 0xDB, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x03, 0x06, 0x7E, 0xDB, 0xDB, 0xF3, 0x7E, 0x60, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x1C, 0x30, 0x60, 0x60, 0x7C, 0x60, 0x60, 0x30, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x30, 0x18, 0x0C, 0x06, 0x0C, 0x18, 0x30, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x0C, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0C, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x0E, 0x1B, 0x1B, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
- 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xD8, 0xD8, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x00, 0x3B, 0x6E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x0F, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0xEC, 0x6C, 0x3C, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xD8, 0x6C, 0x6C, 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x70, 0xD8, 0x30, 0x60, 0xC8, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x3E, 0x3E, 0x3E, 0x3E, 0x3E, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
-};
+/* Police de caractère fine 8x16 */
+static u8 font8x16 [4096] = {
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7E, 0x81, 0xA5, 0x81, 0x81, 0xBD, 0x99, 0x81, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7E, 0xFF, 0xDB, 0xFF, 0xFF, 0xC3, 0xE7, 0xFF, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x36, 0x7F, 0x7F, 0x7F, 0x7F, 0x3E, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x08, 0x1C, 0x3E, 0x7F, 0x3E, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x3C, 0x3C, 0xE7, 0xE7, 0xE7, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x7E, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xE7, 0xC3, 0xC3, 0xE7, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3C, 0x66, 0x42, 0x42, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0xFF, 0xFF, 0xFF, 0xFF, 0xC3, 0x99, 0xBD, 0xBD, 0x99, 0xC3, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
+ 0x00, 0x00, 0x0F, 0x07, 0x0D, 0x19, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x3F, 0x33, 0x3F, 0x30, 0x30, 0x30, 0x70, 0xF0, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7F, 0x63, 0x7F, 0x63, 0x63, 0x63, 0x67, 0xE7, 0xE6, 0xC0, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0xDB, 0x3C, 0xE7, 0x3C, 0xDB, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x40, 0x60, 0x70, 0x7C, 0x7F, 0x7C, 0x70, 0x60, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x01, 0x03, 0x07, 0x1F, 0x7F, 0x1F, 0x07, 0x03, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x33, 0x33, 0x33, 0x33, 0x33, 0x33, 0x00, 0x33, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7F, 0xDB, 0xDB, 0xDB, 0x7B, 0x1B, 0x1B, 0x1B, 0x1B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3E, 0x63, 0x30, 0x1C, 0x36, 0x63, 0x63, 0x36, 0x1C, 0x06, 0x63, 0x3E, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x7F, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x0C, 0x06, 0x7F, 0x06, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x18, 0x30, 0x7F, 0x30, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x60, 0x60, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x08, 0x1C, 0x1C, 0x3E, 0x3E, 0x7F, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x7F, 0x7F, 0x3E, 0x3E, 0x1C, 0x1C, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x24, 0x24, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x42, 0x42, 0x42, 0xFF, 0x42, 0x42, 0x42, 0xFF, 0x42, 0x42, 0x42, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x10, 0x7E, 0x90, 0x90, 0x90, 0x7C, 0x12, 0x12, 0x12, 0xFC, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x61, 0x91, 0x92, 0x64, 0x08, 0x10, 0x26, 0x49, 0x89, 0x86, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x70, 0x88, 0x88, 0x88, 0x50, 0x60, 0x91, 0x8A, 0x84, 0x4A, 0x31, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x06, 0x18, 0x20, 0x40, 0x40, 0x40, 0x40, 0x40, 0x20, 0x18, 0x06, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x60, 0x18, 0x04, 0x02, 0x02, 0x02, 0x02, 0x02, 0x04, 0x18, 0x60, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x10, 0x92, 0x54, 0x38, 0xFE, 0x38, 0x54, 0x92, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x01, 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x83, 0x85, 0x89, 0x91, 0xA1, 0xC1, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x10, 0x30, 0x50, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x7C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x01, 0x02, 0x3C, 0x40, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x01, 0x02, 0x3C, 0x02, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x02, 0x06, 0x0A, 0x12, 0x22, 0x42, 0x82, 0xFF, 0x02, 0x02, 0x02, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFF, 0x80, 0x80, 0x80, 0xFC, 0x02, 0x01, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFF, 0x81, 0x01, 0x02, 0x04, 0x08, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x42, 0x3C, 0x42, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x10, 0x20, 0x00, 0x00,
+ 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x38, 0x44, 0x82, 0x82, 0x04, 0x08, 0x10, 0x10, 0x00, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x99, 0xA5, 0xA5, 0xA5, 0x9E, 0x80, 0x41, 0x3E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x24, 0x42, 0x81, 0x81, 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFC, 0x42, 0x41, 0x41, 0x42, 0x7C, 0x42, 0x41, 0x41, 0x42, 0xFC, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x80, 0x80, 0x80, 0x80, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFC, 0x42, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x41, 0x42, 0xFC, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFF, 0x80, 0x80, 0x80, 0x80, 0xFC, 0x80, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFF, 0x80, 0x80, 0x80, 0x80, 0xFC, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x80, 0x9F, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0xFF, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x38, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x38, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x07, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x82, 0x82, 0x44, 0x38, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x82, 0x84, 0x88, 0x90, 0xE0, 0x90, 0x88, 0x84, 0x82, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0xC3, 0xA5, 0x99, 0x99, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0xC1, 0xA1, 0x91, 0x89, 0x85, 0x83, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFC, 0x82, 0x81, 0x81, 0x82, 0xFC, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x81, 0x81, 0x89, 0x85, 0x42, 0x3D, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFC, 0x82, 0x81, 0x81, 0x82, 0xFC, 0x90, 0x88, 0x84, 0x82, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x42, 0x81, 0x80, 0x40, 0x3C, 0x02, 0x01, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFE, 0x92, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x42, 0x42, 0x24, 0x24, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x81, 0x99, 0x99, 0xA5, 0xA5, 0x42, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x81, 0x81, 0x81, 0x42, 0x24, 0x18, 0x24, 0x42, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x82, 0x82, 0x82, 0x82, 0x44, 0x28, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFF, 0x01, 0x01, 0x02, 0x04, 0x18, 0x20, 0x40, 0x80, 0x80, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x7E, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x7E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x80, 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x7E, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x02, 0x7E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x24, 0x42, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00,
+ 0x00, 0x08, 0x04, 0x02, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x7C, 0x02, 0x02, 0x7E, 0x82, 0x82, 0x7D, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x80, 0x80, 0x80, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0xC2, 0xBC, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x80, 0x80, 0x80, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x01, 0x01, 0x01, 0x01, 0x3D, 0x43, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x81, 0xFF, 0x80, 0x40, 0x3E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0E, 0x11, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3D, 0x43, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x02, 0x7C, 0x00, 0x00,
+ 0x00, 0x80, 0x80, 0x80, 0x80, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0x81, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x08, 0x08, 0x00, 0x38, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x02, 0x02, 0x00, 0x06, 0x02, 0x02, 0x02, 0x02, 0x02, 0x82, 0x44, 0x38, 0x00, 0x00,
+ 0x00, 0x80, 0x80, 0x80, 0x80, 0x82, 0x84, 0x88, 0x90, 0xA8, 0xC4, 0x82, 0x00, 0x00, 0x00, 0x00,
+ 0x38, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x08, 0x3E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xEC, 0x92, 0x92, 0x92, 0x92, 0x92, 0x92, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xB8, 0xC4, 0x82, 0x82, 0x82, 0x82, 0x82, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3C, 0x42, 0x81, 0x81, 0x81, 0x42, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xBC, 0xC2, 0x81, 0x81, 0x81, 0xC2, 0xBC, 0x80, 0x80, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3D, 0x43, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x01, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xBE, 0xC1, 0x80, 0x80, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x81, 0x80, 0x7E, 0x01, 0x81, 0x7E, 0x00, 0x00, 0x00, 0x00,
+ 0x10, 0x10, 0x10, 0x10, 0x10, 0xFE, 0x10, 0x10, 0x10, 0x10, 0x11, 0x0E, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x42, 0x24, 0x18, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x82, 0x82, 0x92, 0x92, 0x92, 0xAA, 0x44, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x42, 0x24, 0x18, 0x24, 0x42, 0x81, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0x81, 0x81, 0x81, 0x43, 0x3D, 0x01, 0x02, 0x7C, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x02, 0x04, 0x18, 0x20, 0x40, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x04, 0x08, 0x10, 0x10, 0x10, 0x20, 0x10, 0x10, 0x10, 0x08, 0x04, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x40, 0x20, 0x10, 0x10, 0x10, 0x08, 0x10, 0x10, 0x10, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x70, 0x99, 0x0E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x08, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1E, 0x33, 0x61, 0x60, 0x60, 0x61, 0x33, 0x1E, 0x06, 0x03, 0x3E, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x66, 0x66, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x06, 0x0C, 0x18, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x66, 0x66, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x1C, 0x36, 0x1C, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3C, 0x66, 0x60, 0x66, 0x3C, 0x0C, 0x06, 0x3C, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x66, 0x66, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3E, 0x63, 0x7F, 0x60, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x66, 0x66, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x3C, 0x66, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x60, 0x30, 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x63, 0x63, 0x08, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x1C, 0x36, 0x1C, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x0C, 0x18, 0x30, 0x00, 0x7F, 0x33, 0x30, 0x3E, 0x30, 0x33, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x6E, 0x3B, 0x1B, 0x7E, 0xD8, 0xDC, 0x77, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1F, 0x36, 0x66, 0x66, 0x7F, 0x66, 0x66, 0x66, 0x67, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x08, 0x1C, 0x36, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x63, 0x63, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x30, 0x18, 0x0C, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x3C, 0x66, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x30, 0x18, 0x0C, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x63, 0x63, 0x00, 0x63, 0x63, 0x63, 0x63, 0x3F, 0x03, 0x06, 0x3C, 0x00, 0x00, 0x00,
+ 0x00, 0x63, 0x63, 0x1C, 0x36, 0x63, 0x63, 0x63, 0x63, 0x36, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x63, 0x63, 0x00, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x18, 0x18, 0x7E, 0xC3, 0xC0, 0xC0, 0xC3, 0x7E, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x1C, 0x36, 0x32, 0x30, 0x78, 0x30, 0x30, 0x30, 0x73, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0xC3, 0x66, 0x3C, 0x18, 0xFF, 0x18, 0xFF, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xFC, 0x66, 0x66, 0x7C, 0x62, 0x66, 0x6F, 0x66, 0x66, 0xF3, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0E, 0x1B, 0x18, 0x18, 0x18, 0x7E, 0x18, 0x18, 0x18, 0x18, 0xD8, 0x70, 0x00, 0x00, 0x00,
+ 0x00, 0x0C, 0x18, 0x30, 0x00, 0x3C, 0x06, 0x3E, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0C, 0x18, 0x30, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0C, 0x18, 0x30, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0C, 0x18, 0x30, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x3B, 0x6E, 0x00, 0x6E, 0x33, 0x33, 0x33, 0x33, 0x33, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x3B, 0x6E, 0x00, 0x63, 0x73, 0x7B, 0x7F, 0x6F, 0x67, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x3C, 0x6C, 0x6C, 0x3E, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x7C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x30, 0x63, 0x63, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x03, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x60, 0xE0, 0x63, 0x66, 0x6C, 0x18, 0x30, 0x6E, 0xC3, 0x06, 0x0C, 0x1F, 0x00, 0x00, 0x00,
+ 0x00, 0x60, 0xE0, 0x63, 0x66, 0x6C, 0x18, 0x33, 0x67, 0xCF, 0x1F, 0x03, 0x03, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x3C, 0x3C, 0x3C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x1B, 0x36, 0x6C, 0x36, 0x1B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x6C, 0x36, 0x1B, 0x36, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x00, 0x00,
+ 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x00, 0x00,
+ 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0xDD, 0x77, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x06, 0xF6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0xF6, 0x06, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x18, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xF7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0xF7, 0x00, 0xF7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x1F, 0x18, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xFF, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0xFF, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00,
+ 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0xF0, 0x00, 0x00,
+ 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x0F, 0x00, 0x00,
+ 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x6C, 0x6C, 0x6E, 0x3B, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3E, 0x63, 0x7E, 0x63, 0x63, 0x7E, 0x60, 0x60, 0x20, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7F, 0x63, 0x63, 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x7F, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7F, 0x63, 0x30, 0x18, 0x0C, 0x18, 0x30, 0x63, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x6C, 0x6C, 0x6C, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x33, 0x33, 0x33, 0x33, 0x3E, 0x30, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x7E, 0x18, 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x7F, 0x63, 0x63, 0x36, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1C, 0x36, 0x63, 0x63, 0x63, 0x36, 0x36, 0x36, 0x77, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1E, 0x30, 0x18, 0x0C, 0x3E, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0xDB, 0xDB, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x03, 0x06, 0x7E, 0xDB, 0xDB, 0xF3, 0x7E, 0x60, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x1C, 0x30, 0x60, 0x60, 0x7C, 0x60, 0x60, 0x30, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x3E, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x63, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0x18, 0xFF, 0x18, 0x18, 0x18, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x30, 0x18, 0x0C, 0x06, 0x0C, 0x18, 0x30, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x0C, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0C, 0x00, 0x7E, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x0E, 0x1B, 0x1B, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00,
+ 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xD8, 0xD8, 0x70, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3B, 0x6E, 0x00, 0x3B, 0x6E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x38, 0x6C, 0x6C, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x0F, 0x0C, 0x0C, 0x0C, 0x0C, 0x0C, 0xEC, 0x6C, 0x3C, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0xD8, 0x6C, 0x6C, 0x6C, 0x6C, 0x6C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x70, 0xD8, 0x30, 0x60, 0xC8, 0xF8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x3E, 0x3E, 0x3E, 0x3E, 0x3E, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
+};
diff --git a/lib/8x8fnt.c b/lib/8x8fnt.c
old mode 100644
new mode 100755
index da2e3d7..c8a8e38
--- a/lib/8x8fnt.c
+++ b/lib/8x8fnt.c
@@ -1,131 +1,131 @@
-/* Police de caractère fine 8x8 */
-static u8 font8x8 [2048] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x81, 0xA5, 0x81, 0xBD, 0x99, 0x81, 0x7E,
- 0x7E, 0xFF, 0xDB, 0xFF, 0xC3, 0xE7, 0xFF, 0x7E, 0x6C, 0xFE, 0xFE, 0xFE, 0x7C, 0x38, 0x10, 0x00,
- 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x10, 0x00, 0x38, 0x7C, 0x38, 0xFE, 0xFE, 0x7C, 0x38, 0x7C,
- 0x10, 0x10, 0x38, 0x7C, 0xFE, 0x7C, 0x38, 0x7C, 0x00, 0x00, 0x18, 0x3C, 0x3C, 0x18, 0x00, 0x00,
- 0xFF, 0xFF, 0xE7, 0xC3, 0xC3, 0xE7, 0xFF, 0xFF, 0x00, 0x3C, 0x66, 0x42, 0x42, 0x66, 0x3C, 0x00,
- 0xFF, 0xC3, 0x99, 0xBD, 0xBD, 0x99, 0xC3, 0xFF, 0x0F, 0x07, 0x0F, 0x7D, 0xCC, 0xCC, 0xCC, 0x78,
- 0x3C, 0x66, 0x66, 0x66, 0x3C, 0x18, 0x7E, 0x18, 0x3F, 0x33, 0x3F, 0x30, 0x30, 0x70, 0xF0, 0xE0,
- 0x7F, 0x63, 0x7F, 0x63, 0x63, 0x67, 0xE6, 0xC0, 0x99, 0x5A, 0x3C, 0xE7, 0xE7, 0x3C, 0x5A, 0x99,
- 0x80, 0xE0, 0xF8, 0xFE, 0xF8, 0xE0, 0x80, 0x00, 0x02, 0x0E, 0x3E, 0xFE, 0x3E, 0x0E, 0x02, 0x00,
- 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x66, 0x66, 0x66, 0x66, 0x66, 0x00, 0x66, 0x00,
- 0x7F, 0xDB, 0xDB, 0x7B, 0x1B, 0x1B, 0x1B, 0x00, 0x3E, 0x63, 0x38, 0x6C, 0x6C, 0x38, 0xCC, 0x78,
- 0x00, 0x00, 0x00, 0x00, 0x7E, 0x7E, 0x7E, 0x00, 0x18, 0x3C, 0x7E, 0x18, 0x7E, 0x3C, 0x18, 0xFF,
- 0x18, 0x3C, 0x7E, 0x18, 0x18, 0x18, 0x18, 0x00, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00,
- 0x00, 0x18, 0x0C, 0xFE, 0x0C, 0x18, 0x00, 0x00, 0x00, 0x30, 0x60, 0xFE, 0x60, 0x30, 0x00, 0x00,
- 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xFE, 0x00, 0x00, 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00,
- 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x7E, 0x3C, 0x18, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x40, 0x00,
- 0x90, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x50, 0xF8, 0x50, 0xF8, 0x50, 0x50, 0x00,
- 0x20, 0x78, 0xA0, 0x70, 0x28, 0xF0, 0x20, 0x00, 0xC8, 0xC8, 0x10, 0x20, 0x40, 0x98, 0x98, 0x00,
- 0x70, 0x88, 0x50, 0x20, 0x54, 0x88, 0x74, 0x00, 0x60, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x20, 0x40, 0x80, 0x80, 0x80, 0x40, 0x20, 0x00, 0x20, 0x10, 0x08, 0x08, 0x08, 0x10, 0x20, 0x00,
- 0x00, 0x20, 0xA8, 0x70, 0x70, 0xA8, 0x20, 0x00, 0x00, 0x00, 0x20, 0x20, 0xF8, 0x20, 0x20, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x60, 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x00,
- 0x70, 0x88, 0x98, 0xA8, 0xC8, 0x88, 0x70, 0x00, 0x40, 0xC0, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00,
- 0x70, 0x88, 0x08, 0x10, 0x20, 0x40, 0xF8, 0x00, 0x70, 0x88, 0x08, 0x10, 0x08, 0x88, 0x70, 0x00,
- 0x08, 0x18, 0x28, 0x48, 0xFC, 0x08, 0x08, 0x00, 0xF8, 0x80, 0x80, 0xF0, 0x08, 0x88, 0x70, 0x00,
- 0x20, 0x40, 0x80, 0xF0, 0x88, 0x88, 0x70, 0x00, 0xF8, 0x08, 0x10, 0x20, 0x40, 0x40, 0x40, 0x00,
- 0x70, 0x88, 0x88, 0x70, 0x88, 0x88, 0x70, 0x00, 0x70, 0x88, 0x88, 0x78, 0x08, 0x08, 0x70, 0x00,
- 0x00, 0x00, 0x60, 0x60, 0x00, 0x60, 0x60, 0x00, 0x00, 0x00, 0x60, 0x60, 0x00, 0x60, 0x60, 0x20,
- 0x10, 0x20, 0x40, 0x80, 0x40, 0x20, 0x10, 0x00, 0x00, 0x00, 0xF8, 0x00, 0xF8, 0x00, 0x00, 0x00,
- 0x80, 0x40, 0x20, 0x10, 0x20, 0x40, 0x80, 0x00, 0x78, 0x84, 0x04, 0x08, 0x10, 0x00, 0x10, 0x00,
- 0x70, 0x88, 0x88, 0xA8, 0xB8, 0x80, 0x78, 0x00, 0x20, 0x50, 0x88, 0x88, 0xF8, 0x88, 0x88, 0x00,
- 0xF0, 0x88, 0x88, 0xF0, 0x88, 0x88, 0xF0, 0x00, 0x70, 0x88, 0x80, 0x80, 0x80, 0x88, 0x70, 0x00,
- 0xF0, 0x88, 0x88, 0x88, 0x88, 0x88, 0xF0, 0x00, 0xF8, 0x80, 0x80, 0xE0, 0x80, 0x80, 0xF8, 0x00,
- 0xF8, 0x80, 0x80, 0xE0, 0x80, 0x80, 0x80, 0x00, 0x70, 0x88, 0x80, 0x80, 0x98, 0x88, 0x78, 0x00,
- 0x88, 0x88, 0x88, 0xF8, 0x88, 0x88, 0x88, 0x00, 0xE0, 0x40, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00,
- 0x38, 0x10, 0x10, 0x10, 0x10, 0x90, 0x60, 0x00, 0x88, 0x90, 0xA0, 0xC0, 0xA0, 0x90, 0x88, 0x00,
- 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xF8, 0x00, 0x82, 0xC6, 0xAA, 0x92, 0x82, 0x82, 0x82, 0x00,
- 0x84, 0xC4, 0xA4, 0x94, 0x8C, 0x84, 0x84, 0x00, 0x70, 0x88, 0x88, 0x88, 0x88, 0x88, 0x70, 0x00,
- 0xF0, 0x88, 0x88, 0xF0, 0x80, 0x80, 0x80, 0x00, 0x70, 0x88, 0x88, 0x88, 0xA8, 0x90, 0x68, 0x00,
- 0xF0, 0x88, 0x88, 0xF0, 0xA0, 0x90, 0x88, 0x00, 0x70, 0x88, 0x80, 0x70, 0x08, 0x88, 0x70, 0x00,
- 0xF8, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x00, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x70, 0x00,
- 0x88, 0x88, 0x88, 0x50, 0x50, 0x20, 0x20, 0x00, 0x82, 0x82, 0x82, 0x82, 0x92, 0x92, 0x6C, 0x00,
- 0x88, 0x88, 0x50, 0x20, 0x50, 0x88, 0x88, 0x00, 0x88, 0x88, 0x88, 0x50, 0x20, 0x20, 0x20, 0x00,
- 0xF8, 0x08, 0x10, 0x20, 0x40, 0x80, 0xF8, 0x00, 0xE0, 0x80, 0x80, 0x80, 0x80, 0x80, 0xE0, 0x00,
- 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0xE0, 0x20, 0x20, 0x20, 0x20, 0x20, 0xE0, 0x00,
- 0x20, 0x50, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00,
- 0x40, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x08, 0x78, 0x88, 0x74, 0x00,
- 0x80, 0x80, 0xB0, 0xC8, 0x88, 0xC8, 0xB0, 0x00, 0x00, 0x00, 0x70, 0x88, 0x80, 0x88, 0x70, 0x00,
- 0x08, 0x08, 0x68, 0x98, 0x88, 0x98, 0x68, 0x00, 0x00, 0x00, 0x70, 0x88, 0xF8, 0x80, 0x70, 0x00,
- 0x30, 0x48, 0x40, 0xE0, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00, 0x34, 0x48, 0x48, 0x38, 0x08, 0x30,
- 0x80, 0x80, 0xB0, 0xC8, 0x88, 0x88, 0x88, 0x00, 0x20, 0x00, 0x60, 0x20, 0x20, 0x20, 0x70, 0x00,
- 0x10, 0x00, 0x30, 0x10, 0x10, 0x10, 0x90, 0x60, 0x80, 0x80, 0x88, 0x90, 0xA0, 0xD0, 0x88, 0x00,
- 0xC0, 0x40, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00, 0x00, 0x00, 0xEC, 0x92, 0x92, 0x92, 0x92, 0x00,
- 0x00, 0x00, 0xB0, 0xC8, 0x88, 0x88, 0x88, 0x00, 0x00, 0x00, 0x70, 0x88, 0x88, 0x88, 0x70, 0x00,
- 0x00, 0x00, 0xB0, 0xC8, 0xC8, 0xB0, 0x80, 0x80, 0x00, 0x00, 0x68, 0x98, 0x98, 0x68, 0x08, 0x08,
- 0x00, 0x00, 0xB0, 0xC8, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x78, 0x80, 0x70, 0x08, 0xF0, 0x00,
- 0x40, 0x40, 0xE0, 0x40, 0x40, 0x50, 0x20, 0x00, 0x00, 0x00, 0x88, 0x88, 0x88, 0x98, 0x68, 0x00,
- 0x00, 0x00, 0x88, 0x88, 0x88, 0x50, 0x20, 0x00, 0x00, 0x00, 0x82, 0x82, 0x92, 0x92, 0x6C, 0x00,
- 0x00, 0x00, 0x88, 0x50, 0x20, 0x50, 0x88, 0x00, 0x00, 0x00, 0x88, 0x88, 0x98, 0x68, 0x08, 0x70,
- 0x00, 0x00, 0xF8, 0x10, 0x20, 0x40, 0xF8, 0x00, 0x10, 0x20, 0x20, 0x40, 0x20, 0x20, 0x10, 0x00,
- 0x40, 0x40, 0x40, 0x00, 0x40, 0x40, 0x40, 0x00, 0x40, 0x20, 0x20, 0x10, 0x20, 0x20, 0x40, 0x00,
- 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x6C, 0xC6, 0xC6, 0xFE, 0x00,
- 0x3E, 0x60, 0xC0, 0x60, 0x3E, 0x08, 0x04, 0x18, 0x00, 0x48, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
- 0x18, 0x20, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x10, 0x28, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76,
- 0x00, 0x48, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x30, 0x08, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76,
- 0x48, 0x30, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x78, 0xCC, 0xC0, 0xCC, 0x78, 0x10, 0x08, 0x30,
- 0x30, 0x48, 0x84, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, 0x48, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78,
- 0x30, 0x08, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, 0x48, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
- 0x30, 0x48, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30, 0x60, 0x10, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
- 0x48, 0x00, 0x30, 0x78, 0xCC, 0xCC, 0xFC, 0xCC, 0x30, 0x48, 0x30, 0x48, 0x84, 0xFC, 0x84, 0x84,
- 0x18, 0x20, 0x00, 0xF8, 0x80, 0xF0, 0x80, 0xF8, 0x00, 0x00, 0x00, 0x66, 0x19, 0x77, 0x88, 0x77,
- 0x00, 0x00, 0x00, 0x0F, 0x14, 0x3E, 0x44, 0x87, 0x30, 0x48, 0x84, 0x78, 0xCC, 0xCC, 0xCC, 0x78,
- 0x00, 0x48, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x60, 0x10, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78,
- 0x30, 0x48, 0x84, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x60, 0x10, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
- 0x48, 0x00, 0xCC, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, 0x44, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0x6C, 0x38,
- 0x24, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x08, 0x1C, 0x28, 0x28, 0x1C, 0x08, 0x00,
- 0x1C, 0x22, 0x20, 0x70, 0x20, 0x22, 0x5C, 0x00, 0x44, 0x28, 0x10, 0x10, 0x38, 0x10, 0x38, 0x10,
- 0xF0, 0x88, 0x8A, 0xF7, 0x82, 0x82, 0x83, 0x00, 0x06, 0x08, 0x08, 0x3C, 0x10, 0x10, 0x60, 0x00,
- 0x18, 0x20, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x18, 0x20, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
- 0x18, 0x20, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x18, 0x20, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
- 0x80, 0x78, 0x04, 0xF8, 0xCC, 0xCC, 0xCC, 0xCC, 0x80, 0x7E, 0x01, 0xC6, 0xE6, 0xD6, 0xCE, 0xC6,
- 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, 0xFE, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x00, 0xFC,
- 0x00, 0x00, 0x18, 0x18, 0x30, 0x60, 0x66, 0x3C, 0xFF, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
- 0xFF, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0xC4, 0x48, 0x50, 0x26, 0x49, 0x82, 0x07,
- 0x40, 0xC4, 0x48, 0x50, 0x26, 0x4A, 0x9F, 0x02, 0x00, 0x30, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
- 0x00, 0x12, 0x24, 0x48, 0x90, 0x48, 0x24, 0x12, 0x00, 0x48, 0x24, 0x12, 0x09, 0x12, 0x24, 0x48,
- 0x49, 0x00, 0x92, 0x00, 0x49, 0x00, 0x92, 0x00, 0x6D, 0x00, 0xB6, 0x00, 0x6D, 0x00, 0xB6, 0x00,
- 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10,
- 0x10, 0x10, 0x10, 0x10, 0xF0, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0xF0, 0x10, 0xF0, 0x10, 0x10,
- 0x28, 0x28, 0x28, 0x28, 0xE8, 0x28, 0x28, 0x28, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x28, 0x28, 0x28,
- 0x00, 0x00, 0x00, 0xF0, 0x10, 0xF0, 0x10, 0x10, 0x28, 0x28, 0x28, 0xE8, 0x08, 0xE8, 0x28, 0x28,
- 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x00, 0x00, 0x00, 0xF8, 0x08, 0xE8, 0x28, 0x28,
- 0x28, 0x28, 0x28, 0xE8, 0x08, 0xF8, 0x00, 0x00, 0x28, 0x28, 0x28, 0x28, 0xF8, 0x00, 0x00, 0x00,
- 0x10, 0x10, 0x10, 0xF0, 0x10, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x10, 0x10, 0x10,
- 0x10, 0x10, 0x10, 0x10, 0x1F, 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0xFF, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0xFF, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x1F, 0x10, 0x10, 0x10,
- 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0xFF, 0x10, 0x10, 0x10,
- 0x10, 0x10, 0x10, 0x1F, 0x10, 0x1F, 0x10, 0x10, 0x28, 0x28, 0x28, 0x28, 0x3F, 0x28, 0x28, 0x28,
- 0x28, 0x28, 0x28, 0x2F, 0x20, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x20, 0x2F, 0x28, 0x28,
- 0x28, 0x28, 0x28, 0xEF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xEF, 0x28, 0x28,
- 0x28, 0x28, 0x28, 0x2F, 0x20, 0x2F, 0x28, 0x28, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0x00,
- 0x28, 0x28, 0x28, 0xEF, 0x00, 0xEF, 0x28, 0x28, 0x10, 0x10, 0x10, 0xFF, 0x00, 0xFF, 0x00, 0x00,
- 0x28, 0x28, 0x28, 0x28, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x10, 0x10,
- 0x00, 0x00, 0x00, 0x00, 0xFF, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x3F, 0x00, 0x00, 0x00,
- 0x10, 0x10, 0x10, 0x1F, 0x10, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x10, 0x1F, 0x10, 0x10,
- 0x00, 0x00, 0x00, 0x00, 0x3F, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0xFF, 0x28, 0x28, 0x28,
- 0x10, 0x10, 0x10, 0xFF, 0x10, 0xFF, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0xF0, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x1F, 0x10, 0x10, 0x10, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
- 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0x00, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0,
- 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x02, 0x34, 0x4C, 0x4C, 0x32, 0x00, 0x5C, 0x22, 0x22, 0x3C, 0x44, 0x44, 0x78,
- 0x7E, 0x42, 0x42, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00, 0x02, 0x7C, 0xA8, 0x28, 0x28, 0x44,
- 0x00, 0x7E, 0x61, 0x30, 0x18, 0x08, 0x10, 0x20, 0x00, 0x00, 0x08, 0x7F, 0x88, 0x88, 0x88, 0x70,
- 0x00, 0x00, 0x00, 0x22, 0x44, 0x44, 0x7A, 0x80, 0x00, 0x00, 0x00, 0x7C, 0x10, 0x10, 0x10, 0x10,
- 0x00, 0x1C, 0x08, 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, 0x00, 0x38, 0x44, 0x44, 0x7C, 0x44, 0x44,
- 0x3C, 0x66, 0xC3, 0xC3, 0xC3, 0x66, 0x24, 0x66, 0x0C, 0x10, 0x08, 0x1C, 0x22, 0x22, 0x22, 0x1C,
- 0x00, 0x00, 0x00, 0x00, 0x6C, 0x92, 0x92, 0x6C, 0x00, 0x01, 0x1A, 0x26, 0x2A, 0x32, 0x2C, 0x40,
- 0x00, 0x18, 0x20, 0x20, 0x30, 0x20, 0x20, 0x18, 0x00, 0x3C, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42,
- 0x00, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, 0x3E,
- 0x00, 0x10, 0x08, 0x04, 0x08, 0x10, 0x00, 0x3E, 0x00, 0x04, 0x08, 0x10, 0x08, 0x04, 0x00, 0x3E,
- 0x00, 0x06, 0x09, 0x09, 0x08, 0x08, 0x08, 0x00, 0x00, 0x00, 0x08, 0x08, 0x08, 0x48, 0x48, 0x30,
- 0x00, 0x00, 0x08, 0x00, 0x3E, 0x00, 0x08, 0x00, 0x00, 0x60, 0x92, 0x0C, 0x60, 0x92, 0x0C, 0x00,
- 0x60, 0x90, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x78, 0x30, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x03, 0x04, 0x04, 0xC8, 0x28, 0x10, 0x00,
- 0x00, 0x00, 0x00, 0x7C, 0x42, 0x42, 0x42, 0x00, 0x18, 0x24, 0x08, 0x10, 0x3C, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x3E, 0x3E, 0x3E, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
-};
+/* Police de caractère fine 8x8 */
+static u8 font8x8 [2048] = {
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x81, 0xA5, 0x81, 0xBD, 0x99, 0x81, 0x7E,
+ 0x7E, 0xFF, 0xDB, 0xF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x18, 0x00, 0x18, 0x18, 0x18, 0x18, 0x7E, 0x3C, 0x18, 0x00,
+ 0x00, 0x18, 0x0C, 0xFE, 0x0C, 0x18, 0x00, 0x00, 0x00, 0x30, 0x60, 0xFE, 0x60, 0x30, 0x00, 0x00,
+ 0x00, 0x00, 0xC0, 0xC0, 0xC0, 0xFE, 0x00, 0x00, 0x00, 0x24, 0x66, 0xFF, 0x66, 0x24, 0x00, 0x00,
+ 0x00, 0x18, 0x3C, 0x7E, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x7E, 0x3C, 0x18, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x40, 0x00,
+ 0x90, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x50, 0x50, 0xF8, 0x50, 0xF8, 0x50, 0x50, 0x00,
+ 0x20, 0x78, 0xA0, 0x70, 0x28, 0xF0, 0x20, 0x00, 0xC8, 0xC8, 0x10, 0x20, 0x40, 0x98, 0x98, 0x00,
+ 0x70, 0x88, 0x50, 0x20, 0x54, 0x88, 0x74, 0x00, 0x60, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00,
+ 0x20, 0x40, 0x80, 0x80, 0x80, 0x40, 0x20, 0x00, 0x20, 0x10, 0x08, 0x08, 0x08, 0x10, 0x20, 0x00,
+ 0x00, 0x20, 0xA8, 0x70, 0x70, 0xA8, 0x20, 0x00, 0x00, 0x00, 0x20, 0x20, 0xF8, 0x20, 0x20, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x20, 0x40, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x60, 0x00, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x00,
+ 0x70, 0x88, 0x98, 0xA8, 0xC8, 0x88, 0x70, 0x00, 0x40, 0xC0, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00,
+ 0x70, 0x88, 0x08, 0x10, 0x20, 0x40, 0xF8, 0x00, 0x70, 0x88, 0x08, 0x10, 0x08, 0x88, 0x70, 0x00,
+ 0x08, 0x18, 0x28, 0x48, 0xFC, 0x08, 0x08, 0x00, 0xF8, 0x80, 0x80, 0xF0, 0x08, 0x88, 0x70, 0x00,
+ 0x20, 0x40, 0x80, 0xF0, 0x88, 0x88, 0x70, 0x00, 0xF8, 0x08, 0x10, 0x20, 0x40, 0x40, 0x40, 0x00,
+ 0x70, 0x88, 0x88, 0x70, 0x88, 0x88, 0x70, 0x00, 0x70, 0x88, 0x88, 0x78, 0x08, 0x08, 0x70, 0x00,
+ 0x00, 0x00, 0x60, 0x60, 0x00, 0x60, 0x60, 0x00, 0x00, 0x00, 0x60, 0x60, 0x00, 0x60, 0x60, 0x20,
+ 0x10, 0x20, 0x40, 0x80, 0x40, 0x20, 0x10, 0x00, 0x00, 0x00, 0xF8, 0x00, 0xF8, 0x00, 0x00, 0x00,
+ 0x80, 0x40, 0x20, 0x10, 0x20, 0x40, 0x80, 0x00, 0x78, 0x84, 0x04, 0x08, 0x10, 0x00, 0x10, 0x00,
+ 0x70, 0x88, 0x88, 0xA8, 0xB8, 0x80, 0x78, 0x00, 0x20, 0x50, 0x88, 0x88, 0xF8, 0x88, 0x88, 0x00,
+ 0xF0, 0x88, 0x88, 0xF0, 0x88, 0x88, 0xF0, 0x00, 0x70, 0x88, 0x80, 0x80, 0x80, 0x88, 0x70, 0x00,
+ 0xF0, 0x88, 0x88, 0x88, 0x88, 0x88, 0xF0, 0x00, 0xF8, 0x80, 0x80, 0xE0, 0x80, 0x80, 0xF8, 0x00,
+ 0xF8, 0x80, 0x80, 0xE0, 0x80, 0x80, 0x80, 0x00, 0x70, 0x88, 0x80, 0x80, 0x98, 0x88, 0x78, 0x00,
+ 0x88, 0x88, 0x88, 0xF8, 0x88, 0x88, 0x88, 0x00, 0xE0, 0x40, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00,
+ 0x38, 0x10, 0x10, 0x10, 0x10, 0x90, 0x60, 0x00, 0x88, 0x90, 0xA0, 0xC0, 0xA0, 0x90, 0x88, 0x00,
+ 0x80, 0x80, 0x80, 0x80, 0x80, 0x80, 0xF8, 0x00, 0x82, 0xC6, 0xAA, 0x92, 0x82, 0x82, 0x82, 0x00,
+ 0x84, 0xC4, 0xA4, 0x94, 0x8C, 0x84, 0x84, 0x00, 0x70, 0x88, 0x88, 0x88, 0x88, 0x88, 0x70, 0x00,
+ 0xF0, 0x88, 0x88, 0xF0, 0x80, 0x80, 0x80, 0x00, 0x70, 0x88, 0x88, 0x88, 0xA8, 0x90, 0x68, 0x00,
+ 0xF0, 0x88, 0x88, 0xF0, 0xA0, 0x90, 0x88, 0x00, 0x70, 0x88, 0x80, 0x70, 0x08, 0x88, 0x70, 0x00,
+ 0xF8, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x00, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88, 0x70, 0x00,
+ 0x88, 0x88, 0x88, 0x50, 0x50, 0x20, 0x20, 0x00, 0x82, 0x82, 0x82, 0x82, 0x92, 0x92, 0x6C, 0x00,
+ 0x88, 0x88, 0x50, 0x20, 0x50, 0x88, 0x88, 0x00, 0x88, 0x88, 0x88, 0x50, 0x20, 0x20, 0x20, 0x00,
+ 0xF8, 0x08, 0x10, 0x20, 0x40, 0x80, 0xF8, 0x00, 0xE0, 0x80, 0x80, 0x80, 0x80, 0x80, 0xE0, 0x00,
+ 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x00, 0xE0, 0x20, 0x20, 0x20, 0x20, 0x20, 0xE0, 0x00,
+ 0x20, 0x50, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00,
+ 0x40, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x08, 0x78, 0x88, 0x74, 0x00,
+ 0x80, 0x80, 0xB0, 0xC8, 0x88, 0xC8, 0xB0, 0x00, 0x00, 0x00, 0x70, 0x88, 0x80, 0x88, 0x70, 0x00,
+ 0x08, 0x08, 0x68, 0x98, 0x88, 0x98, 0x68, 0x00, 0x00, 0x00, 0x70, 0x88, 0xF8, 0x80, 0x70, 0x00,
+ 0x30, 0x48, 0x40, 0xE0, 0x40, 0x40, 0x40, 0x00, 0x00, 0x00, 0x34, 0x48, 0x48, 0x38, 0x08, 0x30,
+ 0x80, 0x80, 0xB0, 0xC8, 0x88, 0x88, 0x88, 0x00, 0x20, 0x00, 0x60, 0x20, 0x20, 0x20, 0x70, 0x00,
+ 0x10, 0x00, 0x30, 0x10, 0x10, 0x10, 0x90, 0x60, 0x80, 0x80, 0x88, 0x90, 0xA0, 0xD0, 0x88, 0x00,
+ 0xC0, 0x40, 0x40, 0x40, 0x40, 0x40, 0xE0, 0x00, 0x00, 0x00, 0xEC, 0x92, 0x92, 0x92, 0x92, 0x00,
+ 0x00, 0x00, 0xB0, 0xC8, 0x88, 0x88, 0x88, 0x00, 0x00, 0x00, 0x70, 0x88, 0x88, 0x88, 0x70, 0x00,
+ 0x00, 0x00, 0xB0, 0xC8, 0xC8, 0xB0, 0x80, 0x80, 0x00, 0x00, 0x68, 0x98, 0x98, 0x68, 0x08, 0x08,
+ 0x00, 0x00, 0xB0, 0xC8, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x78, 0x80, 0x70, 0x08, 0xF0, 0x00,
+ 0x40, 0x40, 0xE0, 0x40, 0x40, 0x50, 0x20, 0x00, 0x00, 0x00, 0x88, 0x88, 0x88, 0x98, 0x68, 0x00,
+ 0x00, 0x00, 0x88, 0x88, 0x88, 0x50, 0x20, 0x00, 0x00, 0x00, 0x82, 0x82, 0x92, 0x92, 0x6C, 0x00,
+ 0x00, 0x00, 0x88, 0x50, 0x20, 0x50, 0x88, 0x00, 0x00, 0x00, 0x88, 0x88, 0x98, 0x68, 0x08, 0x70,
+ 0x00, 0x00, 0xF8, 0x10, 0x20, 0x40, 0xF8, 0x00, 0x10, 0x20, 0x20, 0x40, 0x20, 0x20, 0x10, 0x00,
+ 0x40, 0x40, 0x40, 0x00, 0x40, 0x40, 0x40, 0x00, 0x40, 0x20, 0x20, 0x10, 0x20, 0x20, 0x40, 0x00,
+ 0x76, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x6C, 0xC6, 0xC6, 0xFE, 0x00,
+ 0x3E, 0x60, 0xC0, 0x60, 0x3E, 0x08, 0x04, 0x18, 0x00, 0x48, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
+ 0x18, 0x20, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x10, 0x28, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76,
+ 0x00, 0x48, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x30, 0x08, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76,
+ 0x48, 0x30, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x78, 0xCC, 0xC0, 0xCC, 0x78, 0x10, 0x08, 0x30,
+ 0x30, 0x48, 0x84, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, 0x48, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78,
+ 0x30, 0x08, 0x00, 0x78, 0xCC, 0xFC, 0xC0, 0x78, 0x00, 0x48, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
+ 0x30, 0x48, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30, 0x60, 0x10, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
+ 0x48, 0x00, 0x30, 0x78, 0xCC, 0xCC, 0xFC, 0xCC, 0x30, 0x48, 0x30, 0x48, 0x84, 0xFC, 0x84, 0x84,
+ 0x18, 0x20, 0x00, 0xF8, 0x80, 0xF0, 0x80, 0xF8, 0x00, 0x00, 0x00, 0x66, 0x19, 0x77, 0x88, 0x77,
+ 0x00, 0x00, 0x00, 0x0F, 0x14, 0x3E, 0x44, 0x87, 0x30, 0x48, 0x84, 0x78, 0xCC, 0xCC, 0xCC, 0x78,
+ 0x00, 0x48, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x60, 0x10, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78,
+ 0x30, 0x48, 0x84, 0x00, 0xCC, 0xCC, 0xCC, 0x76, 0x60, 0x10, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
+ 0x48, 0x00, 0xCC, 0xCC, 0xCC, 0x7C, 0x0C, 0xF8, 0x44, 0x00, 0x38, 0x6C, 0xC6, 0xC6, 0x6C, 0x38,
+ 0x24, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x3C, 0x00, 0x08, 0x1C, 0x28, 0x28, 0x1C, 0x08, 0x00,
+ 0x1C, 0x22, 0x20, 0x70, 0x20, 0x22, 0x5C, 0x00, 0x44, 0x28, 0x10, 0x10, 0x38, 0x10, 0x38, 0x10,
+ 0xF0, 0x88, 0x8A, 0xF7, 0x82, 0x82, 0x83, 0x00, 0x06, 0x08, 0x08, 0x3C, 0x10, 0x10, 0x60, 0x00,
+ 0x18, 0x20, 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x18, 0x20, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
+ 0x18, 0x20, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x18, 0x20, 0x00, 0xCC, 0xCC, 0xCC, 0xCC, 0x76,
+ 0x80, 0x78, 0x04, 0xF8, 0xCC, 0xCC, 0xCC, 0xCC, 0x80, 0x7E, 0x01, 0xC6, 0xE6, 0xD6, 0xCE, 0xC6,
+ 0x00, 0x78, 0x0C, 0x7C, 0xCC, 0x76, 0x00, 0xFE, 0x00, 0x78, 0xCC, 0xCC, 0xCC, 0x78, 0x00, 0xFC,
+ 0x00, 0x00, 0x18, 0x18, 0x30, 0x60, 0x66, 0x3C, 0xFF, 0x80, 0x80, 0x80, 0x00, 0x00, 0x00, 0x00,
+ 0xFF, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x40, 0xC4, 0x48, 0x50, 0x26, 0x49, 0x82, 0x07,
+ 0x40, 0xC4, 0x48, 0x50, 0x26, 0x4A, 0x9F, 0x02, 0x00, 0x30, 0x00, 0x30, 0x30, 0x30, 0x30, 0x30,
+ 0x00, 0x12, 0x24, 0x48, 0x90, 0x48, 0x24, 0x12, 0x00, 0x48, 0x24, 0x12, 0x09, 0x12, 0x24, 0x48,
+ 0x49, 0x00, 0x92, 0x00, 0x49, 0x00, 0x92, 0x00, 0x6D, 0x00, 0xB6, 0x00, 0x6D, 0x00, 0xB6, 0x00,
+ 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0xAA, 0x55, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10,
+ 0x10, 0x10, 0x10, 0x10, 0xF0, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0xF0, 0x10, 0xF0, 0x10, 0x10,
+ 0x28, 0x28, 0x28, 0x28, 0xE8, 0x28, 0x28, 0x28, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x28, 0x28, 0x28,
+ 0x00, 0x00, 0x00, 0xF0, 0x10, 0xF0, 0x10, 0x10, 0x28, 0x28, 0x28, 0xE8, 0x08, 0xE8, 0x28, 0x28,
+ 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x00, 0x00, 0x00, 0xF8, 0x08, 0xE8, 0x28, 0x28,
+ 0x28, 0x28, 0x28, 0xE8, 0x08, 0xF8, 0x00, 0x00, 0x28, 0x28, 0x28, 0x28, 0xF8, 0x00, 0x00, 0x00,
+ 0x10, 0x10, 0x10, 0xF0, 0x10, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x10, 0x10, 0x10,
+ 0x10, 0x10, 0x10, 0x10, 0x1F, 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0xFF, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0xFF, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0x1F, 0x10, 0x10, 0x10,
+ 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x10, 0x10, 0x10, 0x10, 0xFF, 0x10, 0x10, 0x10,
+ 0x10, 0x10, 0x10, 0x1F, 0x10, 0x1F, 0x10, 0x10, 0x28, 0x28, 0x28, 0x28, 0x3F, 0x28, 0x28, 0x28,
+ 0x28, 0x28, 0x28, 0x2F, 0x20, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3F, 0x20, 0x2F, 0x28, 0x28,
+ 0x28, 0x28, 0x28, 0xEF, 0x00, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xEF, 0x28, 0x28,
+ 0x28, 0x28, 0x28, 0x2F, 0x20, 0x2F, 0x28, 0x28, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x00, 0x00,
+ 0x28, 0x28, 0x28, 0xEF, 0x00, 0xEF, 0x28, 0x28, 0x10, 0x10, 0x10, 0xFF, 0x00, 0xFF, 0x00, 0x00,
+ 0x28, 0x28, 0x28, 0x28, 0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0x00, 0xFF, 0x10, 0x10,
+ 0x00, 0x00, 0x00, 0x00, 0xFF, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x3F, 0x00, 0x00, 0x00,
+ 0x10, 0x10, 0x10, 0x1F, 0x10, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1F, 0x10, 0x1F, 0x10, 0x10,
+ 0x00, 0x00, 0x00, 0x00, 0x3F, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0x28, 0xFF, 0x28, 0x28, 0x28,
+ 0x10, 0x10, 0x10, 0xFF, 0x10, 0xFF, 0x10, 0x10, 0x10, 0x10, 0x10, 0x10, 0xF0, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x1F, 0x10, 0x10, 0x10, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
+ 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0xFF, 0x00, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0, 0xE0,
+ 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0x07, 0xFF, 0xFF, 0xFF, 0xFF, 0x00, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x02, 0x34, 0x4C, 0x4C, 0x32, 0x00, 0x5C, 0x22, 0x22, 0x3C, 0x44, 0x44, 0x78,
+ 0x7E, 0x42, 0x42, 0x40, 0x40, 0x40, 0x40, 0x40, 0x00, 0x00, 0x02, 0x7C, 0xA8, 0x28, 0x28, 0x44,
+ 0x00, 0x7E, 0x61, 0x30, 0x18, 0x08, 0x10, 0x20, 0x00, 0x00, 0x08, 0x7F, 0x88, 0x88, 0x88, 0x70,
+ 0x00, 0x00, 0x00, 0x22, 0x44, 0x44, 0x7A, 0x80, 0x00, 0x00, 0x00, 0x7C, 0x10, 0x10, 0x10, 0x10,
+ 0x00, 0x1C, 0x08, 0x3E, 0x41, 0x41, 0x41, 0x3E, 0x00, 0x00, 0x38, 0x44, 0x44, 0x7C, 0x44, 0x44,
+ 0x3C, 0x66, 0xC3, 0xC3, 0xC3, 0x66, 0x24, 0x66, 0x0C, 0x10, 0x08, 0x1C, 0x22, 0x22, 0x22, 0x1C,
+ 0x00, 0x00, 0x00, 0x00, 0x6C, 0x92, 0x92, 0x6C, 0x00, 0x01, 0x1A, 0x26, 0x2A, 0x32, 0x2C, 0x40,
+ 0x00, 0x18, 0x20, 0x20, 0x30, 0x20, 0x20, 0x18, 0x00, 0x3C, 0x42, 0x42, 0x42, 0x42, 0x42, 0x42,
+ 0x00, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x7E, 0x00, 0x00, 0x08, 0x08, 0x3E, 0x08, 0x08, 0x00, 0x3E,
+ 0x00, 0x10, 0x08, 0x04, 0x08, 0x10, 0x00, 0x3E, 0x00, 0x04, 0x08, 0x10, 0x08, 0x04, 0x00, 0x3E,
+ 0x00, 0x06, 0x09, 0x09, 0x08, 0x08, 0x08, 0x00, 0x00, 0x00, 0x08, 0x08, 0x08, 0x48, 0x48, 0x30,
+ 0x00, 0x00, 0x08, 0x00, 0x3E, 0x00, 0x08, 0x00, 0x00, 0x60, 0x92, 0x0C, 0x60, 0x92, 0x0C, 0x00,
+ 0x60, 0x90, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x78, 0x30, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x03, 0x04, 0x04, 0xC8, 0x28, 0x10, 0x00,
+ 0x00, 0x00, 0x00, 0x7C, 0x42, 0x42, 0x42, 0x00, 0x18, 0x24, 0x08, 0x10, 0x3C, 0x00, 0x00, 0x00,
+ 0x00, 0x00, 0x00, 0x3E, 0x3E, 0x3E, 0x3E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
+};
diff --git a/lib/Kmemory.c b/lib/Kmemory.c
new file mode 100755
index 0000000..4658bd9
--- /dev/null
+++ b/lib/Kmemory.c
@@ -0,0 +1,156 @@
+/***********************************/
+/* Librairie Kmemory.c */
+/* 20 Mars 2007 */
+/***********************************/
+
+#include
+#include
+
+/* Structure table d'allocation memoire */
+typedef struct
+{
+ UBYTE Used : 1; // = 0 -> La zone memoire est libre.
+ // = 1 -> La zone memoire est utilisee.
+ UBYTE Expand : 1; // = 0 -> Fin du bloc.
+ // = 1 -> Le bloc se prolonge sur le bloc suivant.
+ UBYTE UnUsed : 6; // Zone libre.
+} T_KernelMemoryMap;
+
+
+T_KernelMemoryMap * BlocAllocate = NULL; // Table d'allocation des blocs memoire.
+void * BaseDynAlloc = NULL; // Pointeur sur la zone memoire allouable.
+UDWORD MaxMemoryBlocs;
+
+
+// Initialisation du gestionnaire de memoire.
+void Kernel_InitMemory (void *DataMemory, UDWORD TotalMemorySize)
+{
+ UDWORD Boucle;
+ UDWORD TableBlocs;
+ UDWORD TotalBlocs;
+
+ // Alignement des bloc de memoire a un multiple de MEMORY_BLOC_SIZE
+ if ( (UDWORD)DataMemory % MEMORY_BLOC_SIZE != 0)
+ { DataMemory = ((void*) ((((UDWORD)DataMemory) / MEMORY_BLOC_SIZE) * MEMORY_BLOC_SIZE) + MEMORY_BLOC_SIZE ); };
+
+ TotalBlocs = (((void*)TotalMemorySize) - DataMemory) / MEMORY_BLOC_SIZE;
+ TableBlocs = TotalBlocs / MEMORY_BLOC_SIZE;
+ MaxMemoryBlocs = TotalBlocs - TableBlocs;
+ BlocAllocate = (T_KernelMemoryMap *)DataMemory;
+ BaseDynAlloc = DataMemory + (TableBlocs * MEMORY_BLOC_SIZE);
+
+ for (Boucle = 0; Boucle < MaxMemoryBlocs; Boucle++)
+ {
+ BlocAllocate [Boucle].Used = 0;
+ BlocAllocate [Boucle].Expand = 0;
+ }
+}
+
+
+// Alloue SIZE blocs de memoire
+void * Kernel_mballoc(UDWORD Size)
+{
+ UDWORD Counter = 0;
+ UDWORD Base = 0;
+ UDWORD Boucle, Boucle2;
+
+ if (Size == 0) return NULL;
+
+ for (Boucle = 0; Boucle < MaxMemoryBlocs; Boucle++)
+ {
+ if (BlocAllocate[Boucle].Used == 0) { Counter++; }
+ else { Counter = 0; Base = Boucle + 1; }
+
+ if (Counter >= Size)
+ {
+ if (Base+Size > MaxMemoryBlocs) return NULL;
+ for (Boucle2=Base; Boucle2 < (Base+Size); Boucle2++)
+ {
+ BlocAllocate[Boucle2].Used = 1;
+ if (Boucle2+1 < (Base+Size) ) { BlocAllocate[Boucle2].Expand = 1; }
+ else { BlocAllocate[Boucle2].Expand = 0; }
+ }
+ return ((void*) (BaseDynAlloc + (Base * MEMORY_BLOC_SIZE) ));
+ }
+ }
+ return NULL;
+}
+
+// Libere un bloc memoire
+int Kernel_mbfree (void *Adresse)
+{
+ UDWORD Bloc;
+
+ if (((Adresse - BaseDynAlloc) % MEMORY_BLOC_SIZE) != 0) return -1;
+ if ((((UDWORD)Adresse) % MEMORY_BLOC_SIZE) != 0) return -1;
+
+ Bloc = (Adresse - BaseDynAlloc) / MEMORY_BLOC_SIZE;
+
+ for (; BlocAllocate[Bloc].Expand == 1; Bloc++)
+ {
+ BlocAllocate[Bloc].Used = 0;
+ BlocAllocate[Bloc].Expand = 0;
+ }
+
+ BlocAllocate[Bloc].Used = 0;
+ BlocAllocate[Bloc].Expand = 0;
+
+ return 0;
+};
+
+void * Kernel_mbrealloc (void *Adresse, UDWORD Size)
+{
+ UDWORD Bloc, Boucle, OldSize, CopySize;
+ void * NewAdresse;
+
+ if (((Adresse - BaseDynAlloc) % MEMORY_BLOC_SIZE) != 0) return NULL;
+ Bloc = (Adresse - BaseDynAlloc) / MEMORY_BLOC_SIZE;
+ if (BlocAllocate[Bloc].Used == 0) return NULL;
+
+ for (Boucle = Bloc; BlocAllocate[Boucle].Expand == 1; Boucle++)
+ { if (Boucle >= MaxMemoryBlocs) break; };
+
+ OldSize = Boucle - Bloc + 1;
+
+ // Si pas de changement de taille de bloc, ...
+ if ( Size == OldSize) return Adresse;
+
+ // Si on reduit le nombre de bloc, ...
+ if ( Size < OldSize)
+ {
+ for (Boucle = (Bloc + Size); Boucle < (Bloc + OldSize) ; Boucle++)
+ {
+ BlocAllocate[Boucle].Used = 0;
+ BlocAllocate[Boucle].Expand = 0;
+ }
+ BlocAllocate[Size-1].Expand = 0;
+ return Adresse;
+ }
+
+ // Si on augmente le nombre de bloc
+ for (Boucle = (Bloc + OldSize); Boucle < (Bloc + Size) ; Boucle++)
+ {
+ // Si le bloc ne peut etre simplement agrandit, ...
+ if ( BlocAllocate[Boucle].Used == 1 )
+ {
+ NewAdresse = Kernel_mballoc (Size);
+ if (NewAdresse == NULL) return NULL;
+ CopySize = (OldSize * MEMORY_BLOC_SIZE) / sizeof (int64);
+ for (Boucle = 0; Boucle < CopySize; Boucle++)
+ { ((int64*) NewAdresse)[Boucle] = ((int64*) Adresse)[Boucle]; };
+ Kernel_mbfree (Adresse);
+ return NewAdresse;
+ }
+ }
+
+ // Le bloc est simplement agrandit
+ for (Boucle = (Bloc + OldSize - 1); Boucle < (Bloc + Size) ; Boucle++)
+ {
+ BlocAllocate[Boucle].Used = 1;
+ BlocAllocate[Boucle].Expand = 1;
+ }
+ BlocAllocate[Size-1].Expand = 0;
+ return Adresse;
+}
+
+#undef MAX_MEMORY_BLOCS
diff --git a/lib/LDT.c b/lib/LDT.c
new file mode 100755
index 0000000..18b90df
--- /dev/null
+++ b/lib/LDT.c
@@ -0,0 +1,236 @@
+/***********************************/
+/* Librairie LDT.c */
+/* 23 Mars 2007 */
+/***********************************/
+
+#include "LDT.h"
+#include "Kmemory.h"
+
+# define LDT_MANAGER_SIZE (127)
+
+typedef struct // Structure de gestion des bloc LDT
+{
+ void * Next; // Pointeur de chainage
+ UDWORD Empty;
+ T_LDT_reg LDTdesc [LDT_MANAGER_SIZE]; // Nombre de blocs LDT
+} T_LDT_Manager;
+
+void LDT_initalloc (void *AllocTable, UDWORD Index, UDWORD SetSize, UDWORD TotalSize);
+T_LDT_Manager * LDT_mballoc (UWORD Size);
+
+/////////////////////////////////////////////////////////////////////////
+
+T_LDT_Manager * LDT_Manager = NULL;
+
+/////////////////////////////////////////////////////////////////////////
+
+T_LDT * LDT_balloc (UWORD Size) // Alloue un bloc de Size LDT
+{
+ UWORD Boucle;
+ UDWORD Blocs, Boucle2;
+ T_LDT_Manager * * ptr_Manager = &LDT_Manager;
+ T_LDT_Manager * Manager = LDT_Manager;
+
+ do
+ {
+ if (* ptr_Manager == NULL)
+ {
+ * ptr_Manager = Kernel_mballoc (1);
+ Manager = * ptr_Manager;
+ Manager->Next = NULL;
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ Manager->LDTdesc [Boucle].Adresse = NULL;
+ Manager->LDTdesc [Boucle].Size = NULL;
+ }
+ }
+
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ if (Manager->LDTdesc [Boucle].Adresse == NULL)
+ {
+
+ Blocs = Size * sizeof(T_LDT);
+ if (Blocs % MEMORY_BLOC_SIZE == 0)
+ { Blocs /= MEMORY_BLOC_SIZE; } else { Blocs = (Blocs / MEMORY_BLOC_SIZE) + 1; }
+ Manager->LDTdesc [Boucle].Adresse = Kernel_mballoc (Blocs);
+ if (Manager->LDTdesc [Boucle].Adresse == NULL) return NULL;
+ Manager->LDTdesc [Boucle].Size = (Blocs * MEMORY_BLOC_SIZE) / sizeof(T_LDT);
+
+ // Mise a zero de la LDT
+ for (Boucle2 = 0; Boucle2 < Manager->LDTdesc [Boucle].Size; Boucle2++)
+ { ((int64*) Manager->LDTdesc [Boucle].Adresse)[Boucle2] = NULL; }
+
+ return Manager->LDTdesc [Boucle].Adresse;
+ }
+ }
+
+ *ptr_Manager = Manager;
+ Manager = Manager->Next;
+ } while (1);
+}
+
+
+int LDT_bfree (void * Adresse) // Libere un bloc LDT
+{
+ UWORD Boucle, Boucle2;
+ int RetVal;
+ T_LDT_Manager * * ptr_Manager = &LDT_Manager;
+ T_LDT_Manager * Manager = LDT_Manager;
+
+ do
+ {
+ if (*ptr_Manager == NULL) { return -1; }
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ if (Manager->LDTdesc [Boucle].Adresse == Adresse)
+ {
+
+ RetVal = Kernel_mbfree(Manager->LDTdesc [Boucle].Adresse);
+ if (Boucle == 0)
+ {
+ Kernel_mbfree (*ptr_Manager);
+ *ptr_Manager = NULL;
+ return RetVal;
+ }
+ else
+ {
+ for (Boucle2 = Boucle; Boucle2 < LDT_MANAGER_SIZE-1; Boucle2++)
+ { Manager->LDTdesc [Boucle2] = Manager->LDTdesc [Boucle2+1]; }
+
+ Manager->LDTdesc [Boucle2+1].Size = NULL;
+ Manager->LDTdesc [Boucle2+1].Adresse = NULL;
+ }
+
+ Manager->LDTdesc [LDT_MANAGER_SIZE-1].Size = NULL;
+ Manager->LDTdesc [LDT_MANAGER_SIZE-1].Adresse = NULL;
+
+ return RetVal;
+ }
+ }
+
+ *ptr_Manager = Manager;
+ Manager = Manager->Next;
+ } while (1);
+
+}
+
+T_LDT * LDT_brealloc (T_LDT * OldLDT, UWORD NewSize)
+{
+ T_LDT * NewLDT;
+ UDWORD Blocs;
+ UWORD Boucle;
+
+ T_LDT_Manager * * ptr_Manager = &LDT_Manager;
+ T_LDT_Manager * Manager = LDT_Manager;
+ Blocs = NewSize * sizeof(T_LDT);
+
+ if (Blocs % MEMORY_BLOC_SIZE == 0)
+ { Blocs /= MEMORY_BLOC_SIZE; } else { Blocs = (Blocs / MEMORY_BLOC_SIZE) + 1; }
+
+ do
+ {
+ if (*ptr_Manager == NULL) { return NULL; }
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ if (Manager->LDTdesc [Boucle].Adresse == OldLDT)
+ {
+ NewLDT = Kernel_mbrealloc (OldLDT, Blocs);
+ if (NewLDT == NULL) return NULL;
+ Manager->LDTdesc [Boucle].Adresse = NewLDT;
+ Manager->LDTdesc [Boucle].Size = NewSize;
+ return NewLDT;
+ }
+ }
+
+ *ptr_Manager = Manager;
+ Manager = Manager->Next;
+ } while (1);
+}
+
+///////////////////////////////////////////////////////////////////////
+
+T_LDT * LDT_AllocLDT (T_LDT *BaseLDT)
+{
+ UWORD Boucle;
+ UDWORD Boucle2;
+ UDWORD Size;
+ T_LDT_Manager * Manager = LDT_Manager;
+
+ if (BaseLDT == NULL) return NULL;
+
+ do
+ {
+ if (Manager == NULL) { return NULL; }
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ Size = Manager->LDTdesc [Boucle].Size;
+ if (Manager->LDTdesc [Boucle].Adresse == ((void*)BaseLDT) )
+ {
+ for (Boucle2 = 1; Boucle2 < Size; Boucle2++) // Le 1e LDT reste null
+ {
+ if ( BaseLDT[Boucle2].UserDefine == 0 )
+ {
+ BaseLDT[Boucle2].UserDefine = 1;
+ return BaseLDT+Boucle2;
+ };
+ }
+ return NULL;
+ }
+ }
+ Manager = Manager->Next;
+ } while (1);
+}
+
+int LDT_FreeLDT (T_LDT *LDT) // Marque le LDT comme non utilise et le met a NULL
+{
+ if ( ((UDWORD)LDT & 0x07L) != NULL) { return -2; }
+ if (LDT->UserDefine == 0) { return -1; }
+ *((int64*)LDT) = NULL;
+ return 0;
+}
+
+///////////////////////////////////////////////////////////////////////
+
+int LDT_MapMemory (T_LDT *LDT, void * Linear, UDWORD Size, UBYTE Granularite, UBYTE DPL, UBYTE Type, UBYTE CPUMode)
+{
+ if ( ((UDWORD)LDT & 0x07L) != NULL) { return -2; }
+
+ LDT->Adresse_0_15 = (DWORD)Linear & 0x0000FFFFL;
+ LDT->Adresse_16_23 = ((DWORD)Linear >> 16) & 0x000000FFL;
+ LDT->Adresse_24_31 = ((DWORD)Linear >> 24) & 0x000000FFL;
+ LDT->Limite_0_15 = Size & 0x0000FFFFL;
+ LDT->Limite_16_19 = (Size >> 16) & 0x0000000FL;
+ LDT->Granularite = Granularite;
+ LDT->Type = Type;
+ LDT->DPL = DPL;
+ LDT->CPUMode = CPUMode;
+ LDT->Present = 1;
+ LDT->UserDefine = 1;
+ return 0;
+}
+
+int LDT_load (T_LDT *LDT)
+{
+ UWORD Boucle;
+ T_LDT_Manager * * ptr_Manager = &LDT_Manager;
+ T_LDT_Manager * Manager = LDT_Manager;
+
+ do
+ {
+ if (*ptr_Manager == NULL) { return -1; }
+ for (Boucle = 0; Boucle < LDT_MANAGER_SIZE; Boucle++)
+ {
+ if (Manager->LDTdesc [Boucle].Adresse == LDT)
+ {
+ asm("lgdt %0\n" : : "m" (Manager->LDTdesc [Boucle]));
+ return 0;
+ }
+ }
+
+ *ptr_Manager = Manager;
+ Manager = Manager->Next;
+ } while (1);
+}
+
+
diff --git a/lib/cpu.c b/lib/cpu.c
new file mode 100755
index 0000000..1d23680
--- /dev/null
+++ b/lib/cpu.c
@@ -0,0 +1,217 @@
+#include "types.h"
+#include "cpu.h"
+#include "cpuid.h"
+#include "memory.h"
+#include "string.h"
+
+
+
+static u8 *msg[] =
+{
+ "mmx",
+ "mmx2",
+ "sse",
+ "sse2",
+ "sse3",
+ "fpu",
+ "3dNow!",
+ "3dNow Extended!",
+ "HyperThreading",
+ "apic",
+};
+
+static u8 space[]=" ";
+
+bool cansetflag (u32 flag)
+{
+u32 r1, r2;
+asm("pushfl\n"
+"popl %0\n"
+"movl %0, %1\n"
+"xorl %2, %0\n"
+"pushl %0\n"
+"popfl\n"
+"pushfl\n"
+"popl %0\n"
+"pushl %1\n"
+"popfl\n"
+: "=&r" (r1), "=&r" (r2)
+: "ir" (flag)
+);
+return ((r1 ^ r2) & flag) != 0;
+}
+
+void cpuid(u32 op, u32 *eax, u32 *ebx,u32 *ecx, u32 *edx)
+{
+ asm("cpuid" : "=a" (*eax), "=b" (*ebx), "=c" (*ecx), "=d" (*edx) : "a" (op) : "cc");
+}
+
+u8 getcpuinfos(cpuinfo *proc)
+{
+u32 i,maxfunction,maxextended,unused,regeax,regebx,regecx,regedx;
+bool *boolean;
+
+if (!cansetflag (0x00040000)) return 1; /*386 processor - no cpuid*/
+if (!cansetflag (0x00200000)) return 2; /*486 processor with no cpuid*/
+
+ cpuid(0, &maxfunction, &unused, &unused, &unused);
+ maxfunction &= 0xffff;
+ cpuid(0x80000000, &maxextended, &unused, &unused, &unused);
+ maxextended &= 0xffff;
+ if (maxfunction >= 1)
+ {
+ cpuid(1, ®eax, ®ebx, ®ecx, ®edx);
+ proc->stepping = (regeax & 0x0000000F);
+ proc->models = ((regeax>>4) & 0x0000000F);
+ proc->family = ((regeax>>8) & 0x0000000F);
+ proc->types = ((regeax>>12) & 0x00000003);
+ proc->emodels = ((regeax>>16) & 0x0000000F);
+ proc->efamily = ((regeax>>20) & 0x000000FF);
+
+ proc->brandid = (regeax & 0xF);
+ proc->linesize = ((regeax>>8) & 0xF);
+ proc->count = ((regeax>>16) & 0xF);
+ proc->apicid = ((regeax>>24) & 0xF);
+
+ proc->mmx=((regedx>>23) & 0x00000001);
+ proc->sse=((regedx>>25) & 0x00000001);
+ proc->sse2=((regedx>>26) & 0x00000001);
+ proc->sse3=(regecx & 0x00000001);
+ proc->fpu=(regedx & 0x00000001);
+ proc->htt=((regedx>>28) & 0x00000001);
+
+ }
+ if (maxextended >= 1)
+ {
+ cpuid(0x80000001, ®eax, ®ebx, ®ecx, ®edx);
+ proc->mmx2=((regedx>>22) & 0x00000001);
+ proc->apic=((regedx>>9) & 0x00000001);
+ proc->now3d=((regedx>>30) & 0x00000001);
+ proc->now3d2=((regedx>>31) & 0x00000001);
+ }
+ if (maxextended >= 4)
+ {
+ int i;
+ for(i=0;i<3;i++)
+ {
+ cpuid(0x80000002+i, ®eax, ®ebx, ®ecx, ®edx);
+ memcpy(®eax,&proc->detectedname[0+i*16],4,1);
+ memcpy(®ebx,&proc->detectedname[4+i*16],4,1);
+ memcpy(®ecx,&proc->detectedname[8+i*16],4,1);
+ memcpy(®edx,&proc->detectedname[12+i*16],4,1);
+ }
+ }
+ boolean=&proc->mmx;
+ i=0;
+
+ for(i=0;i<10;i++)
+ if (*(boolean++)==1)
+ {
+ strcat(msg[i],&proc->techs);
+ strcat(space,&proc->techs);
+ }
+ return 0;
+}
+
+u32 viewstack(u32 number)
+{
+ u32 stack = 0;
+ asm (
+ "movl %[a1],%%esi;"
+ "addl %%esp,%%esi;"
+ "movl (%%esi), %[a1] ;"
+ :[result] "=r" (stack)
+ :[a1] "r" (number)
+ :"%esi"
+ );
+ return stack;
+}
+
+void dump_regs()
+{
+ u32 eax = 0;
+ u32 ebx = 0;
+ u32 ecx = 0;
+ u32 edx = 0;
+ u32 esi = 0;
+ u32 edi = 0;
+ u32 ebp = 0;
+ u32 esp = 0;
+ u16 cs = 0;
+ u16 ds = 0;
+ u16 es = 0;
+ u16 fs = 0;
+ u16 gs = 0;
+ u16 ss = 0;
+ u32 flags = 0;
+ asm (
+ "movl %%eax, %[a1] ;"
+ "movl %%ebx, %[b1] ;"
+ "movl %%ecx, %[c1] ;"
+ "movl %%edx, %[d1] ;"
+ "movl %%esi, %[e1] ;"
+ "movl %%edi, %[f1] ;"
+ "movl %%esp, %[g1] ;"
+ "movl %%ebp, %[h1] ;"
+ "movw %%cs, %[i1] ;"
+ "movw %%ds, %[j1] ;"
+ "movw %%es, %[k1] ;"
+ "movw %%fs, %[l1] ;"
+ "movw %%gs, %[m1] ;"
+ "movw %%ss, %[n1] ;"
+ :
+ [a1] "=m" (eax), [b1] "=m" (ebx), [c1] "=m" (ecx), [d1] "=m" (edx), [e1] "=m" (esi), [f1] "=m" (edi),
+ [g1] "=m" (ebp), [h1] "=m" (esp), [i1] "=m" (cs), [j1] "=m" (ds), [k1] "=m" (es), [l1] "=m" (fs), [m1] "=m" (gs), [n1] "=m" (ss)
+ );
+
+ printf("eax=%x ebx=%x ecx=%x eax=%x\r\n", eax,ebx,ecx,edx);
+ printf("esi=%x edi=%x\r\n", esi,edi);
+ printf("cs=%x ds=%x es=%x fs=%x gs=%x\r\n", cs,ds,es,fs,gs);
+ printf("ss=%x esp=%x ebp=%x\r\n",ss,esp,ebp);
+
+ asm (
+ "pushf ;"
+ "pop %[f1] ;"
+ :
+ [f1] "=m" (flags)
+ );
+
+ printf("FLAGS");
+
+ if(flags & (1 << 0)) // Carry
+ printf(" (C1");
+ else
+ printf(" (C0");
+
+ if(flags & (1 << 2)) // Parity
+ printf(" P1");
+ else
+ printf(" P0");
+
+ if(flags & (1 << 4)) // Adjust
+ printf(" A1");
+ else
+ printf(" A0");
+
+ if(flags & (1 << 6)) // Zero
+ printf(" Z1");
+ else
+ printf(" Z0");
+
+ if(flags & (1 << 7)) // Sign
+ printf(" S1");
+ else
+ printf(" S0");
+
+ if(flags & (1 << 11)) // Overflow
+ printf(" O1)\n");
+ else
+ printf(" O0)\n");
+
+ printf("STACK\r\n");
+ for(u8 i=0;i<25;i++)
+ printf("+%d\t\t%x\r\n",i,viewstack(i*4));
+
+
+}
+
diff --git a/lib/graph.c b/lib/graph.c
new file mode 100755
index 0000000..8856668
--- /dev/null
+++ b/lib/graph.c
@@ -0,0 +1,58 @@
+#include "types.h"
+#include "vga.h"
+#include "video.h"
+#include "graph.h"
+#include "math.h"
+
+/******************************************************************************/
+
+/* Affiche une ligne entre les points spécifiés */
+
+void line(u32 x1, u32 y1, u32 x2, u32 y2, u8 color)
+{
+ s32 dx,dy,sdx,sdy;
+ u32 i,dxabs,dyabs,x,y,px,py;
+
+ dx=x2-x1; /* distance horizontale de la line */
+ dy=y2-y1; /* distance verticale de la line **/
+ dxabs=abs(dx);
+ dyabs=abs(dy);
+ sdx=sgn(dx);
+ sdy=sgn(dy);
+ x=dyabs>>1;
+ y=dxabs>>1;
+ px=x1;
+ py=y1;
+
+ writepxl(px,py,color);
+
+ if (dxabs>=dyabs) /* la ligne est plus horizontale que verticale */
+ {
+ for(i=0;i=dxabs)
+ {
+ y-=dxabs;
+ py+=sdy;
+ }
+ px+=sdx;
+ writepxl(px,py,color);
+ }
+ }
+ else /* la ligne est plus verticale que horizontale */
+ {
+ for(i=0;i=dyabs)
+ {
+ x-=dyabs;
+ px+=sdx;
+ }
+ py+=sdy;
+ writepxl(px,py,color);
+ }
+ }
+}
+
diff --git a/lib/idt.c b/lib/idt.c
old mode 100644
new mode 100755
index 06466da..cf2b084
--- a/lib/idt.c
+++ b/lib/idt.c
@@ -34,7 +34,7 @@ void initpic(void)
outb(0xA0,0x11);
nop();
/* Initialisation de ICW2 - vecteur de depart = 96 */
- outb(0xA1,0x70);
+ outb(0xA1,0x60);
nop();
/* Initialisation de ICW3 */
outb(0xA1,0x02);
@@ -97,261 +97,343 @@ makeidtdes(offset,select,type,&temp);
idt[index]=temp;
}
+void cpuerror(const u8 *src)
+{
+ print("\033[31m***** ERREUR CPU ****\r\n -");
+ print(src);
+ dump_regs();
+ while(1)
+ {
+ nop();
+ }
+}
+
void interruption()
{
- cli();
- print("Appel d'une interruption");
- sti();
+ cli();
+ pushf();
+ pushad();
+ print("Appel d'une interruption\r\n");
+ popad();
+ popf();
+ sti();
iret();
}
void exception0()
{
- print("divide error");
- iret();
+ print("divide error\r\n");
}
void exception1()
{
- print("debug exception");
- iret();
+ cpuerror("debug exception\r\n");
}
void exception2()
{
- print("non-maskable hardware interrupt");
- iret();
+ cpuerror("non-maskable hardware interrupt\r\n");
}
void exception3()
{
- print("INT3 instruction");
- iret();
+ cpuerror("INT3 instruction\r\n");
}
void exception4()
{
- print("INTO instruction detected overflow");
- iret();
+ cpuerror("INTO instruction detected overflow\r\n");
}
void exception5()
{
- print("BOUND instruction detected overrange");
- iret();
+ print("BOUND instruction detected overrange\r\n");
}
void exception6()
{
- print("invalid instruction opcode");
- iret();
+ cpuerror("invalid instruction opcode\r\n");
}
void exception7()
{
- print("no coprocessor");
- iret();
+ cpuerror("no coprocessor\r\n");
}
void exception8()
{
- print("double fault");
- iret();
+ cpuerror("double fault\r\n");
}
void exception9()
{
- print("coprocessor segment overrun");
- iret();
+ cpuerror("coprocessor segment overrun\r\n");
}
void exception10()
{
- print("invalid task state segment (TSS)");
- iret();
+ cpuerror("invalid task state segment (TSS)\r\n");
}
void exception11()
{
- print("segment not present");
- iret();
+ cpuerror("segment not present\r\n");
}
void exception12()
{
- print("stack fault");
- iret();
+ cpuerror("stack fault");
}
void exception13()
{
- print("general protection fault (GPF)");
- iret();
+ cpuerror("general protection fault (GPF)\r\n");
}
void exception14()
{
- print("page fault");
- iret();
+ cpuerror("page fault\r\n");
}
void exception15()
{
- print("(reserved)");
- iret();
+ cpuerror("(reserved)\r\n");
}
void exception16()
{
- print("coprocessor error");
- iret();
+ cpuerror("coprocessor error\r\n");
}
void exception17()
{
- print("alignment check");
- iret();
+ cpuerror("alignment check\r\n");
}
void exception18()
{
- print("machine check");
- iret();
+ cpuerror("machine check");
}
void irq0()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 0");
irqendmaster();
+ popad();
+ popf();
sti();
- iret();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq1()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 1");
+ while ((inb(0x64)&1)==0);
+ inb(0x60);
irqendmaster();
+ popad();
+ popf();
sti();
- iret();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq2()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 2");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq3()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 3");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq4()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 4");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq5()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 5");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq6()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 6");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq7()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 7");
irqendmaster();
- sti();
- iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq8()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 8");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq9()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 9");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq10()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 10");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq11()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 11");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq12()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 12");
- irqendslave();
- sti();
- iret();
+ while ((inb(0x64)&1)==0);
+ inb(0x60);
+ irqendslave();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq13()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 13");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq14()
{
- cli();
+ cli();
+ pushf();
+ pushad();
print("irq 14");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void irq15()
@@ -359,59 +441,63 @@ void irq15()
cli();
print("irq 15");
irqendslave();
- sti();
- iret();
+ irqendmaster();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
void initidt(void)
{
u16 i;
- putidt((u32)exception0, 0x30, INTGATE, 0);
- putidt((u32)exception1, 0x30, INTGATE, 1);
- putidt((u32)exception2, 0x30, INTGATE, 2);
- putidt((u32)exception3, 0x30, INTGATE, 3);
- putidt((u32)exception4, 0x30, INTGATE, 4);
- putidt((u32)exception5, 0x30, INTGATE, 5);
- putidt((u32)exception6, 0x30, INTGATE, 6);
- putidt((u32)exception7, 0x30, INTGATE, 7);
- putidt((u32)exception8, 0x30, INTGATE, 8);
- putidt((u32)exception9, 0x30, INTGATE, 9);
- putidt((u32)exception10, 0x30, INTGATE, 10);
- putidt((u32)exception11, 0x30, INTGATE, 11);
- putidt((u32)exception12, 0x30, INTGATE, 12);
- putidt((u32)exception13, 0x30, INTGATE, 13);
- putidt((u32)exception14, 0x30, INTGATE, 14);
- putidt((u32)exception15, 0x30, INTGATE, 15);
- putidt((u32)exception16, 0x30, INTGATE, 16);
- putidt((u32)exception17, 0x30, INTGATE, 17);
- putidt((u32)exception18, 0x30, INTGATE, 18);
+ putidt((u32)exception0, 0x20, INTGATE, 0);
+ putidt((u32)exception1, 0x20, INTGATE, 1);
+ putidt((u32)exception2, 0x20, INTGATE, 2);
+ putidt((u32)exception3, 0x20, INTGATE, 3);
+ putidt((u32)exception4, 0x20, INTGATE, 4);
+ putidt((u32)exception5, 0x20, INTGATE, 5);
+ putidt((u32)exception6, 0x20, INTGATE, 6);
+ putidt((u32)exception7, 0x20, INTGATE, 7);
+ putidt((u32)exception8, 0x20, INTGATE, 8);
+ putidt((u32)exception9, 0x20, INTGATE, 9);
+ putidt((u32)exception10, 0x20, INTGATE, 10);
+ putidt((u32)exception11, 0x20, INTGATE, 11);
+ putidt((u32)exception12, 0x20, INTGATE, 12);
+ putidt((u32)exception13, 0x20, INTGATE, 13);
+ putidt((u32)exception14, 0x20, INTGATE, 14);
+ putidt((u32)exception15, 0x20, INTGATE, 15);
+ putidt((u32)exception16, 0x20, INTGATE, 16);
+ putidt((u32)exception17, 0x20, INTGATE, 17);
+ putidt((u32)exception18, 0x20, INTGATE, 18);
for(i=19;i<32;i++)
{
- putidt((u32)interruption, 0x30, INTGATE, i);
+ putidt((u32)interruption, 0x20, INTGATE, i);
}
- putidt((u32)irq0, 0x30, INTGATE, 32);
- putidt((u32)irq1, 0x30, INTGATE, 33);
- putidt((u32)irq2, 0x30, INTGATE, 34);
- putidt((u32)irq3, 0x30, INTGATE, 35);
- putidt((u32)irq4, 0x30, INTGATE, 36);
- putidt((u32)irq5, 0x30, INTGATE, 37);
- putidt((u32)irq6, 0x30, INTGATE, 38);
- putidt((u32)irq7, 0x30, INTGATE, 39);
- for(i=40;i<112;i++)
+ putidt((u32)irq0, 0x20, INTGATE, 32);
+ putidt((u32)irq1, 0x20, INTGATE, 33);
+ putidt((u32)irq2, 0x20, INTGATE, 34);
+ putidt((u32)irq3, 0x20, INTGATE, 35);
+ putidt((u32)irq4, 0x20, INTGATE, 36);
+ putidt((u32)irq5, 0x20, INTGATE, 37);
+ putidt((u32)irq6, 0x20, INTGATE, 38);
+ putidt((u32)irq7, 0x20, INTGATE, 39);
+ for(i=40;i<96;i++)
{
- putidt((u32)interruption, 0x30, INTGATE, i);
+ putidt((u32)interruption, 0x20, INTGATE, i);
}
- putidt((u32)irq8, 0x30, INTGATE, 112);
- putidt((u32)irq9, 0x30, INTGATE, 113);
- putidt((u32)irq10, 0x30, INTGATE, 114);
- putidt((u32)irq11, 0x30, INTGATE, 115);
- putidt((u32)irq12, 0x30, INTGATE, 116);
- putidt((u32)irq13, 0x30, INTGATE, 117);
- putidt((u32)irq14, 0x30, INTGATE, 118);
- putidt((u32)irq15, 0x30, INTGATE, 119);
- for(i=120;i<255;i++)
+ putidt((u32)irq8, 0x20, INTGATE, 96);
+ putidt((u32)irq9, 0x20, INTGATE, 97);
+ putidt((u32)irq10, 0x20, INTGATE, 98);
+ putidt((u32)irq11, 0x20, INTGATE, 99);
+ putidt((u32)irq12, 0x20, INTGATE, 100);
+ putidt((u32)irq13, 0x20, INTGATE, 101);
+ putidt((u32)irq14, 0x20, INTGATE, 102);
+ putidt((u32)irq15, 0x20, INTGATE, 103);
+ for(i=104;i<255;i++)
{
- putidt((u32)interruption, 0x30, INTGATE, i);
+ putidt((u32)interruption, 0x20, INTGATE, i);
}
/* initialise le registre idt */
idtreg.limite = 256*8;
diff --git a/lib/keyboard.c b/lib/keyboard.c
old mode 100644
new mode 100755
index 7696e54..c345022
--- a/lib/keyboard.c
+++ b/lib/keyboard.c
@@ -6,7 +6,7 @@
#include "video.h"
-static u8 bufferscan[256];
+static u8 bufferscan[256]={0};
static u8 bufferascii[256]={0};
static u8 ptrscan=0;
static u8 ptrascii=0;
@@ -92,7 +92,15 @@ static const u8 set1_ctrl[] =
'2', '3','0','.',0, 0, 0, 0,
0
};
-
+/******************************************************************************/
+
+u8 waitascii()
+{
+u8 oldptrscan=ptrscan;
+u8 oldptrascii=ptrascii;
+while((oldptrascii==ptrascii));/*(oldptrscan==ptrscan)&&*/
+return bufferascii[ptrascii];
+}
/******************************************************************************/
@@ -136,7 +144,6 @@ static void reboot(void)
/******************************************************************************/
unsigned convert(u32 keypressed)
{
-
u8 temp,key,lastscan;
/* garde le dernier pointeur du buffer scan */
lastscan=ptrscan;
@@ -182,6 +189,11 @@ unsigned convert(u32 keypressed)
return 0;
}
+ if ((key >= SCAN_F1) && (key <= SCAN_F8))
+ {
+ changevc(key-SCAN_F1);
+ }
+
/* Scroll Lock, Num Lock, and Caps Lock mise a jour des leds */
if(key == SCAN_SCROLLLOCK)
{
@@ -259,7 +271,7 @@ if ((bufferscan[lastscan]==0xE0)||((kbdstatus & STATUS_NUM)&&(key>=0x47)&&(key<=
if(temp == 0) return temp;
/* Appuie de CRTL + ALT + SUPR ? */
if((kbdstatus & STATUS_CTRL) && (kbdstatus & STATUS_ALT) &&
- (temp == KEY_DEL))
+ (key == 76))
{
print("redemarrage du systeme");
reboot();
@@ -272,7 +284,10 @@ if ((bufferscan[lastscan]==0xE0)||((kbdstatus & STATUS_NUM)&&(key>=0x47)&&(key<=
/******************************************************************************/
void keyboard()
-{
+{
+cli();
+pushf();
+pushad();
u8 scancode,ascii;
cli();
while ((inb(0x64)&1)==0);
@@ -280,14 +295,16 @@ scancode=inb(0x60);
ascii = convert(scancode);
if(ascii != 0)
{
-putchar(ascii);
ptrascii++;
if (ptrascii==255) ptrascii==0;
bufferascii[ptrascii]=ascii;
}
irqendmaster();
-sti();
-iret();
+ popad();
+ popf();
+ sti();
+ asm("addl $0x01C, %esp;");
+ iret();
}
/******************************************************************************/
diff --git a/lib/keymap.c b/lib/keymap.c
old mode 100644
new mode 100755
diff --git a/lib/makefile b/lib/makefile
old mode 100644
new mode 100755
index 393d055..96ec60e
--- a/lib/makefile
+++ b/lib/makefile
@@ -1,37 +1,16 @@
-FREEC=gcc -O2 -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -I ../Include -c
-PARTIAL=ld -r -o
-OBJS= memory.o vga.o port.o video.o idt.o timer.o keyboard.o types.o
+CC=gcc -O0 -g -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -w -m32 -F pe-i386 -I ../include
+LINK=ld -m elf_i386 -r -o
+OBJS=memory.o vga.o port.o video.o mouse.o idt.o timer.o keyboard.o types.o string.o graph.o 3d.o math.o cpu.o
all: makeall
makeall: libs.o
libs.o:$(OBJS)
- $(PARTIAL) libs.o $(OBJS)
+ $(LINK) libs.o $(OBJS)
-vga.o:vga.c
- $(FREEC) $^
-
-types.o:types.c
- $(FREEC) $^
-
-idt.o:idt.c
- $(FREEC) $^
-
-keyboard.o:keyboard.c
- $(FREEC) $^
-
-timer.o:timer.c
- $(FREEC) $^
-
-video.o:video.c
- $(FREEC) $^
-
-port.o:port.c
- $(FREEC) $^
-
-memory.o:memory.c
- $(FREEC) $^
+.o: .c
+ $(CC) $^
clean:
rm -f *.o
diff --git a/lib/math.c b/lib/math.c
new file mode 100755
index 0000000..a83d8f1
--- /dev/null
+++ b/lib/math.c
@@ -0,0 +1,7 @@
+#include "types.h"
+
+u32 abs(int x)
+{
+if (x<0) x=-x;
+return (u32)x;
+}
diff --git a/lib/memory.c b/lib/memory.c
old mode 100644
new mode 100755
index 4fa9bb9..fc4a75b
--- a/lib/memory.c
+++ b/lib/memory.c
@@ -1,46 +1,46 @@
-#include "types.h"
-
-/*******************************************************************************/
-
-/* Copie un octet une ou plusieurs fois en mémoire */
-void memset(void *dst, u8 val, u32 count,u32 size)
-{
- u8 *temp;
- for(temp = (u8 *)dst; count != 0; count--)
- {
- temp+=size;
- *temp = val;
- }
-}
-
-/*******************************************************************************/
-
-/* Copie une portion de mémoire vers une autre */
-void memcpy(void *src, void *dst, u32 count, u32 size)
-{
- char *s, *d;
- u32 i;
- s = (u8*) src;
- d = (u8*) dst;
- for(i=0;i0) if (inb(0x60)==250) return 1;
+return 0;
+}
+
+static u8 bytepos=0,mousereplies=0;
+static u8 mpacket[3];
+static s32 mousex=40, mousey=12;
+static u16 oldx=0, oldy=0;
+static u8 oldchar=0x00,oldattr=0x07;
+static bool mousebut1=0,mousebut2=0,mousebut3=0;
+static u8 speed=6;
+
+
+void outmseack(u8 value)
+{
+outkbd(0x64,0xD4); /* ecriture vers souris */
+outb(0x60,value);
+mousereplies++;
+}
+
+void outmsecmd(u8 command)
+{
+outkbd(0x64,0x60); /* ecriture vers mode */
+outb(0x60,command);
+}
+
+void mouse()
+{
+u8 mbyte=inb(0x60);
+s8 changex,changey;
+cli();
+
+ if (mousereplies > 0)
+ {
+ if (mbyte == 0xFA)
+ {
+ mousereplies--;
+ goto endofint;
+ }
+ mousereplies = 0;
+ }
+
+ mpacket[bytepos]=mbyte;
+ bytepos++;
+
+if(bytepos==3) {
+bytepos=0;
+if ( mpacket[1] == 0)
+ {
+ changex = 0;
+ }
+ else
+ {
+ changex = (mpacket[0] & 0x10) ?
+ mpacket[1] - 256 :
+ mpacket[1];
+ }
+ if (mpacket[2] == 0)
+ {
+ changey = 0;
+ }
+ else
+ {
+ changey = -((mpacket[0] & 0x20) ?
+ mpacket[2] - 256 :
+ mpacket[2]);
+ }
+
+ mousex+= (changex<=65535) { mousex=65535; }
+ if(mousey<0) { mousey=0; }
+ if(mousey>=65535) { mousey=65535; }
+
+ u16 newx=(u32)mousex*getxres()/65536;
+ u16 newy=(u32)mousey*getyres()/65536;
+
+ // Retrieve mouse button status from packet
+ mousebut1=mpacket[0] & 1;
+ mousebut2=mpacket[0] & 2;
+ mousebut3=mpacket[0] & 4;
+
+// printf("RX:%d\tRY:%d\tX:%d\tY:%d\tB1:%d\tB2:%d\tB3:%d\t\r\n",changex,changey,mousex,mousey,mousebut1,mousebut2,mousebut3);
+
+if ((newx!=oldx)||(newy!=oldy))
+{
+ showchar(oldx,oldy,oldchar,oldattr);
+ oldx=newx;
+ oldy=newy;
+ oldchar=getchar(oldx,oldy);
+ oldattr=getattrib(oldx,oldy);
+ showchar(newx,newy,0xDB,0x0F);
+}
+}
+endofint:
+irqendmaster();
+irqendslave();
+sti();
+//asm("movl 0x2C(%esp), %ebx;movl 0x30(%esp), %esi;movl 0x34(%esp), %edi;movl 0x38(%esp), %ebp;addl $0x3C, %esp;iret;");
+asm(
+"addl $0x18,%esp;\
+popl %bx;\
+iret;");
+}
+
+
+
+
+
+
+
diff --git a/lib/port.c b/lib/port.c
old mode 100644
new mode 100755
index 9d47102..bf5fe3c
--- a/lib/port.c
+++ b/lib/port.c
@@ -1,68 +1,68 @@
-#include "types.h"
-#include "asm.h"
-
-/*******************************************************************************/
-
-/* Envoie une série d'octet a destination d'une portion de mémoire
-vers le registre video spécifié */
-
-void outreg(u16 port,u8 *src,u16 num)
-{
-int i;
-for(i=0;i
+
+/* Compare 2 chaines de caractère et renvoie la premiere distance (diff) */
+s8 strcmp(const u8 *src,const u8 *des)
+{
+ register s8 result;
+ do
+ {
+ if ((result = *src - *des++) != 0) break;
+ }
+ while (*src++!=0);
+ return result;
+}
+
+
+/* Trouve la premiere occurence d'un caractère dans une chaine */
+
+u8 * strchr(const u8 *src, u8 achar)
+{
+ for(; *src!= achar; ++src)
+ if (*src == 0) return 0;
+ return (u8*)src;
+}
+
+/* Renvoie la taille de la chaine */
+
+u32 strlen(const u8 *src)
+{
+ u32 size;
+
+ for (size = 0; *(src+size) != 0; size++);
+ return size;
+}
+
+
+/* copie une chaine dans une autre */
+u8* strcpy(const u8 *src, u8 *des)
+{
+ u8 *temp = des;
+ while ((*des++ = *src++) != 0);
+ return temp;
+}
+
+
+/* copie une portion limité d'une chaine asciiZ*/
+
+u8 *strncpy(const u8 *src,u8 *des,u32 count)
+{
+ u8 *temp = des;
+ while (count) {
+ if ((*temp = *src) != 0) src++;
+ temp++;
+ count--;
+ }
+ return des;
+}
+
+/* concatene 2 chaines de caractère */
+u8 *strcat( const u8 *src,u8 *des)
+{
+ u8 *temp = des;
+ while (*des!=0) des++;
+ while ((*des++ = *src++) != 0);
+ return temp;
+}
diff --git a/lib/timer.c b/lib/timer.c
old mode 100644
new mode 100755
index 0a284a3..8d19346
--- a/lib/timer.c
+++ b/lib/timer.c
@@ -13,10 +13,15 @@ static u8 curspos=0;
void timer()
{
- cli();
+cli();
+pushf();
+pushad();
showchar(0,0,curs[curspos],7);
curspos=(curspos+1)&0x3;
- irqendmaster();
+irqendmaster();
+ popad();
+ popf();
sti();
- asm("addl $0x1C,%esp;iret;");
+ asm("addl $0x0C, %esp;");
+ iret();
}
diff --git a/lib/types.c b/lib/types.c
old mode 100644
new mode 100755
diff --git a/lib/vga.c b/lib/vga.c
old mode 100644
new mode 100755
index da946e6..ad9d48e
--- a/lib/vga.c
+++ b/lib/vga.c
@@ -20,14 +20,130 @@
#define planesize 0x10000
-u16 resX,resY; /* resolution x,y en caractères*/
+static u16 resX,resY,color,splitY; /* resolution x,y en caractères et profondeur */
-static u8 pages,activepage; /* nombre de pages disponibles N° de la page active*/
+static u8 pages,activepage,showedpage; /* nombre de pages disponibles N° de la page active*/
static u32 linesize,pagesize;/* Taille d'une ligne et d'une page */
-static u8 vmode=0xFF,color; /* mode en cours d'utilisation et profondeur */
+static u8 vmode=0xFF; /* mode en cours d'utilisation */
static u32 basemem; /* Adresse de la mémoire vidéo */
-static bool scrolling=0x1,graphic;/* Activation du défilement, Flag du mode graphique */
-static u8 font; /* n° font active */
+static bool scrolling,graphic,blink;/* Activation du défilement, Flag du mode graphique */
+
+/*******************************************************************************/
+
+/* Donne la resolution max horizontale */
+
+u16 getxres()
+{
+return resX;
+}
+
+/*******************************************************************************/
+
+/* Donne la profondeur en bit */
+
+u8 getdepth()
+{
+return color;
+}
+
+/*******************************************************************************/
+
+/* Donne la resolution max verticale */
+
+u16 getyres()
+{
+return resY-splitY;
+}
+
+/*******************************************************************************/
+
+/* Donne le nombre max de page ecran dispo */
+
+u16 getnbpages()
+{
+return pages;
+}
+
+/*******************************************************************************/
+
+/* Fixe la page ecran de travail */
+
+void setpage(u8 page)
+{
+if (page>8));
+ outb(ccrt, 0x0D);
+ outb(ccrt+1,(addr&0xFF));
+ showedpage=page;
+}
+}
+/*******************************************************************************/
+
+/* Sépare l'écran en 2 a partir de la ligne Y */
+
+void split(u16 y)
+{
+u16 addr;
+if (graphic==0)
+ addr=(y<<3);
+else
+ addr=y;
+ /* line compare pour ligne atteinte */
+ outb(ccrt, 0x18);
+ outb(ccrt+1,(addr&0xFF));
+ /* overflow pour le bit 8 */
+
+ outb(ccrt, 0x07);
+ outb(ccrt+1,(inb(ccrt+1) & ~16)|((addr>>4)&16));
+
+ /* Maximum Scan Line pour le bit 9 */
+
+ outb(ccrt, 0x09);
+ outb(ccrt+1,(inb(ccrt+1) & ~64)|((addr>>3)&64));
+ splitY=y;
+}
+/*******************************************************************************/
+
+/* Sépare l'écran en 2 a partir de la ligne Y */
+
+void unsplit()
+{
+ /* line compare pour ligne atteinte */
+ outb(ccrt, 0x18);
+ outb(ccrt+1,0);
+ /* overflow pour le bit 8 */
+
+ outb(ccrt, 0x07);
+ outb(ccrt+1,inb(ccrt+1) & ~16);
+
+ /* Maximum Scan Line pour le bit 9 */
+
+ outb(ccrt, 0x09);
+ outb(ccrt+1,inb(ccrt+1) & ~64);
+ splitY=0;
+}
/*******************************************************************************/
@@ -145,20 +261,17 @@ void (*fill)(u8 attrib);
void fill_text (u8 attrib)
{
- gotoscr(0,0);
memset((u8 *)(basemem+activepage*pagesize),' ',pagesize/2,2);
memset((u8 *)(basemem+activepage*pagesize+1),attrib,pagesize/2,2);
}
void fill_chain (u8 attrib)
{
- gotoscr(0,0);
memset((u8 *)(basemem+activepage*pagesize),attrib&0x0F,pagesize,1);
}
void fill_unchain (u8 attrib)
{
- gotoscr(0,0);
int i;
for(i=0;i<4;i++)
{
@@ -174,8 +287,11 @@ void fill_unchain (u8 attrib)
void gotoscr(u16 x,u16 y)
{
u16 pos;
- pos=(x+y*resX);
- outb(ccrt,0x0F);
+ if (splitY==0)
+ pos=(showedpage*pagesize/2+x+y*resX);
+ else
+ pos=(x+y*resX);
+ outb(ccrt,0x0F);
outb(ccrt+1,(u8)(pos&0x00FF));
outb(ccrt,0x0E);
outb(ccrt+1,(u8)((pos&0xFF00)>>8));
@@ -195,8 +311,8 @@ if (scrolling)
for(i=0;i<4;i++)
{
useplane(i);
- memcpy((u8*)(basemem+linesize*8*lines),(u8*)basemem,pagesize-linesize*8*lines,1);
- memset((u8*)(basemem+pagesize-linesize*8*lines),attrib&0x0F,linesize*8*lines,1);
+ memcpy((u8*)(basemem+activepage*pagesize+linesize*8*lines),(u8*)basemem,pagesize-linesize*8*lines,1);
+ memset((u8*)(basemem+activepage*pagesize+pagesize-linesize*8*lines),attrib&0x0F,linesize*8*lines,1);
}
}
}
@@ -205,8 +321,8 @@ void scroll_chain(u8 lines,u8 attrib)
{
if (scrolling)
{
- memcpy((u8*)basemem+linesize*8*lines,(u8*)basemem,pagesize-linesize*8*lines,1);
- memset((u8*)(basemem+pagesize-linesize*8*lines),attrib&0x0F,linesize*8*lines,1);
+ memcpy((u8*)basemem+activepage*pagesize+linesize*8*lines,(u8*)basemem+activepage*pagesize,pagesize-linesize*8*lines,1);
+ memset((u8*)(basemem+activepage*pagesize+pagesize-linesize*8*lines),attrib&0x0F,linesize*8*lines,1);
}
}
@@ -214,9 +330,9 @@ void scroll_text(u8 lines,u8 attrib)
{
if (scrolling)
{
- memcpy((u8*)basemem+linesize*lines,(u8*)basemem,pagesize-linesize*lines,1);
- memset((u8*)(basemem+pagesize-linesize*lines-2),' ',(linesize*lines)/2,2);
- memset((u8*)(basemem+pagesize-linesize*lines-1),attrib,(linesize*lines)/2,2);
+ memcpy((u8*)basemem+activepage*pagesize+linesize*lines,(u8*)basemem+activepage*pagesize,pagesize-linesize*lines,1);
+ memset((u8*)(basemem+activepage*pagesize+pagesize-linesize*lines-2),' ',(linesize*lines)/2,2);
+ memset((u8*)(basemem+activepage*pagesize+pagesize-linesize*lines-1),attrib,(linesize*lines)/2,2);
}
}
@@ -254,6 +370,33 @@ void showchar_text(u16 coordx,u16 coordy,u8 thechar,u8 attrib)
*(++screen) =attrib;
}
+/*******************************************************************************/
+
+/* Recupere le caractère a l'écran */
+
+u8 (*getchar)(u16 coordx,u16 coordy);
+
+u8 getchar_text(u16 coordx,u16 coordy)
+
+{
+ u8 *screen;
+ screen = (u8 *)basemem+activepage*pagesize+2*(coordx+coordy*resX);
+ return *screen;
+}
+
+/*******************************************************************************/
+
+/* Recupere les attributs a l'écran */
+
+u8 (*getattrib)(u16 coordx,u16 coordy);
+
+u8 getattrib_text(u16 coordx,u16 coordy)
+
+{
+ u8 *screen;
+ screen = (u8 *)basemem+activepage*pagesize+2*(coordx+coordy*resX)+1;
+ return *screen;
+}
/*******************************************************************************/
@@ -324,7 +467,7 @@ void writepxl_8bitsunchain(u16 x, u16 y, u32 c)
u32 setvmode(u8 mode)
{
- u8 *def,i,gmode;
+ u8 *def,gmode;
/* Récupere la definition des registres VGA en fonction du mode
graphique : >0x80
text : 0x00 - 0x7F
@@ -378,6 +521,8 @@ variables en fonction de la profondeur et du mode*/
scroll=scroll_text;
fill=fill_text;
pagesize=resY*linesize;
+ getchar=getchar_text;
+ getattrib=getattrib_text;
}
else
{
@@ -431,7 +576,10 @@ variables en fonction de la profondeur et du mode*/
}
/* calcul des variables d'état video */
activepage=0;
+ showedpage=0;
+ splitY=0;
vmode=mode;
+ scrolling=1;
pages=(planesize/pagesize);
basemem=(def[20]<<8)+def[21]+getbase();
return 0;
@@ -503,25 +651,70 @@ u32 loadfont(u8* def,u8 size,u8 font)
/* Récupere le N° de la police de caractère en cours d'utilisation */
-u8 getfont(u8 num)
+u8 getfont()
{
- return font;
+ u8 num,tmp;
+ outb(sequencer,3);
+ tmp=inb(sequencer+1);
+ num=(tmp&0x03)|((tmp&0x10)>>2);
+ return num;
}
+/*******************************************************************************/
+
+/* Récupere le N° de la police de caractère en cours d'utilisation */
+
+u8 getfont2()
+{
+ u8 num,tmp;
+ outb(sequencer,3);
+ tmp=inb(sequencer+1);
+ num=((tmp&0x0C)>>2)|((tmp&0x20)>>3);
+ return num;
+}
+
+
/*******************************************************************************/
/* Fixe le N° de la police de caractère a utiliser */
void setfont(u8 num)
{
- font=num&0x07;
+ num&=0x07;
outb(sequencer,3);
- outb(sequencer+1,(num&0x03)+((num&0x04)<<2));
+ outb(sequencer+1,(inb(sequencer+1)&0xEC)|((num&0x03)+((num&0x04)<<2)));
}
/*******************************************************************************/
+/* Fixe le N° de la police de caractère a utiliser */
+void setfont2(u8 num)
+{
+ num&=0x07;
+ outb(sequencer,3);
+ outb(sequencer+1,(inb(sequencer+1)&0xD3)|(((num&0x03)<<2)+((num&0x04)<<3)));
+}
+/*******************************************************************************/
+/* Fixe le N° de la police de caractère a utiliser */
+
+void enableblink()
+{
+ outb(ccrt,0x10);
+ outb(ccrt+1,(inb(sequencer+1)|0x04));
+}
+
+/*******************************************************************************/
+
+/* Fixe le N° de la police de caractère a utiliser */
+
+void disableblink()
+{
+ outb(ccrt,0x10);
+ outb(ccrt+1,(inb(sequencer+1)&~0x04));
+}
+
+/*******************************************************************************/
diff --git a/lib/video.c b/lib/video.c
old mode 100644
new mode 100755
index 4fa6130..2d29345
--- a/lib/video.c
+++ b/lib/video.c
@@ -1,10 +1,19 @@
#include "vga.h"
#include "video.h"
+#include "stdarg.h"
-u8 attrib=0x07;
-u16 cursX,cursY; /* position du curseur */
-extern u16 resX,resY; /* resolution x,y en caractères*/
-u8 ansi,param1,param2,param3;
+
+console vc[8]={
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0},
+{0x07,0,0,0,0,0,0,0}};
+
+u8 usedvc=0;
/*******************************************************************************/
@@ -19,10 +28,16 @@ void setattrib(u8 att)
};
u8 tempattr;
- tempattr = attrib;
+ tempattr = vc[usedvc].attrib;
if(att == 0)
- tempattr &= ~0x08; /* Faible intensité */
- else if(att == 1)
+ tempattr = 0x07; /* Couleur Grise sur fond noir */
+ else if (att == 5)
+ tempattr |= 0x80;
+ else if (att == 7)
+ tempattr = ((tempattr&0x0F)<<4)+((tempattr&0xF0)>>4);
+ else if (att == 8)
+ tempattr = 0;
+ else if (att == 1)
tempattr |= 0x08; /* Forte intensité */
else if(att >= 30 && att <= 37)
{
@@ -34,7 +49,7 @@ void setattrib(u8 att)
att = ansitovga[att - 40] << 4;
tempattr = (tempattr & ~0x70) | att;/* couleur de fond */
}
- attrib = tempattr;
+ vc[usedvc].attrib = tempattr;
}
/*******************************************************************************/
@@ -44,13 +59,13 @@ void setattrib(u8 att)
bool makeansi(u8 c)
{
/* state machine to handle the escape sequences */
- switch(ansi)
+ switch(vc[usedvc].ansi)
{
case 0:
/* ESC -- next state */
if(c == 0x1B)
{
- ansi++;
+ vc[usedvc].ansi++;
return 1; /* "I handled it" */
}
break;
@@ -58,8 +73,8 @@ bool makeansi(u8 c)
case 1:
if(c == '[')
{
- ansi++;
- param1 = 0;
+ vc[usedvc].ansi++;
+ vc[usedvc].param1 = 0;
return 1;
}
break;
@@ -67,62 +82,69 @@ bool makeansi(u8 c)
case 2:
if(isdigit(c))
{
- param1 = param1 * 10 + c - '0';
+ vc[usedvc].param1 = vc[usedvc].param1 * 10 + c - '0';
return 1;
}
else if(c == ';')
{
- ansi++;
- param2 = 0;
+ vc[usedvc].ansi++;
+ vc[usedvc].param2 = 0;
return 1;
}
/* ESC[2J -- efface l'ecran */
else if(c == 'J')
{
- if(param1 == 2)
+ if(vc[usedvc].param1 == 2)
{
- fill(attrib);
- ansi = 0;
+ fill(vc[usedvc].attrib);
+ vc[usedvc].cursX=0;
+ vc[usedvc].cursY=0;
+ gotoscr(0,0);
+ vc[usedvc].ansi = 0;
return 1;
}
}
/* ESC[num1m -- met l'attribut num1 */
else if(c == 'm')
{
- setattrib(param1);
- ansi = 0;
+ setattrib(vc[usedvc].param1);
+ vc[usedvc].ansi = 0;
return 1;
}
/* ESC[num1A -- bouge le curseur de num1 vers le haut */
else if(c == 'A')
{
- cursY-=param1;
- ansi = 0;
- gotoscr(cursX,cursY);
+ vc[usedvc].cursY-=vc[usedvc].param1;
+ if (vc[usedvc].cursY<0) vc[usedvc].cursY=0;
+ vc[usedvc].ansi = 0;
+ gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
return 1;
}
/* ESC[num1B -- bouge le curseur de num1 vers le bas */
else if(c == 'B')
{
- cursY+=param1;
- ansi = 0;
- gotoscr(cursX,cursY);
+ vc[usedvc].cursY+=vc[usedvc].param1;
+ if (vc[usedvc].cursY>=getyres()-1) vc[usedvc].cursY=getyres();
+ vc[usedvc].ansi = 0;
+ gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
return 1;
}
-/* ESC[num1C -- bouge le curseur de num1 vers la gauche */
- else if(c == 'C')
- {
- cursX-=param1;
- ansi = 0;
- gotoscr(cursX,cursY);
- return 1;
- }
-/* ESC[num1D -- bouge le curseur de num1 vers la droite */
+/* ESC[num1D -- bouge le curseur de num1 vers la gauche */
else if(c == 'D')
{
- cursX+=param1;
- ansi = 0;
- gotoscr(cursX,cursY);
+ vc[usedvc].cursX-=vc[usedvc].param1;
+ if (vc[usedvc].cursX<0) vc[usedvc].cursX=0;
+ vc[usedvc].ansi = 0;
+ gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
+ return 1;
+ }
+/* ESC[num1C -- bouge le curseur de num1 vers la droite */
+ else if(c == 'C')
+ {
+ vc[usedvc].cursX+=vc[usedvc].param1;
+ if (vc[usedvc].cursX>=getxres()-1) vc[usedvc].cursX=getxres();
+ vc[usedvc].ansi = 0;
+ gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
return 1;
}
break;
@@ -130,32 +152,32 @@ bool makeansi(u8 c)
case 3:
if(isdigit(c))
{
- param2 = param2 * 10 + c - '0';
+ vc[usedvc].param2 = vc[usedvc].param2 * 10 + c - '0';
return 1;
}
else if(c == ';')
{
- ansi++;
- param3 = 0;
+ vc[usedvc].ansi++;
+ vc[usedvc].param3 = 0;
return 1;
}
/* ESC[num1;num2H ou ESC[num1;num2f-- bouge le curseur en num1,num2 */
else if((c == 'H')||(c == 'f'))
{
/* Remet la position du curseur matériel a num1,num2 */
- gotoscr(param2,param1);
+ gotoscr(vc[usedvc].param2,vc[usedvc].param1);
/* Remet la position du curseur logiciel a num1,num2 */
- cursX=param2;
- cursY=param1;
- ansi = 0;
+ vc[usedvc].cursX=vc[usedvc].param2;
+ vc[usedvc].cursY=vc[usedvc].param1;
+ vc[usedvc].ansi = 0;
return 1;
}
/* ESC[num1;num2m -- met les attributs num1,num2 */
else if(c == 'm')
{
- setattrib(param1);
- setattrib(param2);
- ansi = 0;
+ setattrib(vc[usedvc].param1);
+ setattrib(vc[usedvc].param2);
+ vc[usedvc].ansi = 0;
return 1;
}
break;
@@ -163,104 +185,118 @@ bool makeansi(u8 c)
case 4:
if(isdigit(c))
{
- param3 = param3 * 10 + c - '0';
+ vc[usedvc].param3 = vc[usedvc].param3 * 10 + c - '0';
return 1;
}
/* ESC[num1;num2;num3m -- met les attributs num1,num2,num3 */
else if(c == 'm')
{
- setattrib(param1);
- setattrib(param2);
- setattrib(param3);
- ansi = 0;
+ setattrib(vc[usedvc].param1);
+ setattrib(vc[usedvc].param2);
+ setattrib(vc[usedvc].param3);
+ vc[usedvc].ansi = 0;
return 1;
}
break;
/* Mauvais etat >> reset */
default:
- ansi = 0;
+ vc[usedvc].ansi = 0;
break;
}
- ansi = 0;
+ vc[usedvc].ansi = 0;
return 0; /* Ansi fini ;)*/
}
/*******************************************************************************/
+/* Change la console en cours d'utilisation */
+
+void changevc(u8 avc)
+{
+usedvc=avc;
+showpage(usedvc);
+setpage(usedvc);
+gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
+}
+
+/*******************************************************************************/
+
/* affiche un caractère a l'écran */
void putchar(u8 thechar)
{
+showpage(usedvc);
+setpage(usedvc);
if(makeansi(thechar)) return;
switch (thechar)
{
case 0x11:
-if (cursY>0) cursY--;
+if (vc[usedvc].cursY>0) vc[usedvc].cursY--;
break;
case 0x12:
-if (cursY0) cursX--;
+if (vc[usedvc].cursX>0) vc[usedvc].cursX--;
break;
case 0x14:
-if (cursX0)
+if (vc[usedvc].cursY>0)
{
-cursX=resX-1;
-cursY--;
+vc[usedvc].cursX=getxres()-1;
+vc[usedvc].cursY--;
}
}
else
{
-cursX--;
+vc[usedvc].cursX--;
}
-showchar(cursX,cursY,' ',attrib);
+showchar(vc[usedvc].cursX,vc[usedvc].cursY,' ',vc[usedvc].attrib);
break;
case '\t':
-cursX=(cursX + 8) & ~(8 - 1);
+vc[usedvc].cursX=(vc[usedvc].cursX + 8) & ~(8 - 1);
break;
case '\n':
-cursX=0;
+vc[usedvc].cursX=0;
break;
case '\r':
-cursX=0;
-cursY++;
+vc[usedvc].cursX=0;
+vc[usedvc].cursY++;
break;
default:
if (thechar>=' ')
{
-showchar(cursX,cursY,thechar,attrib);
-cursX++;
+showchar(vc[usedvc].cursX,vc[usedvc].cursY,thechar,vc[usedvc].attrib);
+vc[usedvc].cursX++;
}
break;
}
-if (cursX>=resX)
+if (vc[usedvc].cursX>=getxres())
{
- cursX=0;
- cursY++;
+ vc[usedvc].cursX=0;
+ vc[usedvc].cursY++;
}
-if (cursY>=resY)
+if (vc[usedvc].cursY>=getyres())
{
- scroll(1,attrib);
- cursY=resY-1;
+ scroll(1,vc[usedvc].attrib);
+ vc[usedvc].cursY=getyres()-1;
}
- gotoscr(cursX,cursY);
+ gotoscr(vc[usedvc].cursX,vc[usedvc].cursY);
}
/*******************************************************************************/
@@ -271,7 +307,7 @@ void print(u8* string)
{
u8 *source;
source = string;
- while(*source!=0x00)
+ while(*source!=0)
{
putchar(*source++);
}
@@ -279,13 +315,87 @@ void print(u8* string)
/*******************************************************************************/
-/* affiche un octet sous forme hexadécimale a l'ecran */
+/* affiche une chaine de caractère formaté a l'ecran */
-void showhex(u8 src)
+void printf (const u8 *string, ...)
{
- static u8 hexadigit[16] = "0123456789ABCDEF";
- putchar(hexadigit[(src&0xF0)>>4]);
- putchar(hexadigit[src&0x0F]);
+ va_list ap;
+ u8 buffer[50];
+ u8 *pointer;
+
+ u8 radix;
+ bool signe;
+ long num;
+
+
+ va_start(ap, string);
+ while(*string!= 0)
+ {
+ if (*string != '%')
+ putchar (*string);
+ else
+ {
+ switch (*++string)
+ {
+ case 'c':
+ putchar (va_arg(ap, int));
+ break;
+ case 'u':
+ radix=10;
+ signe=0;
+showstring:
+ num=va_arg(ap, int);
+ pointer = buffer + 50 - 1;
+ *pointer = '\0';
+ if ((signe==1)&&(num<0))
+ {
+ num = -num;
+ signe++;
+ }
+ do
+ {
+ unsigned long temp;
+ temp = (unsigned long)num % radix;
+ pointer--;
+ if(temp < 10)
+ *pointer = temp + '0';
+ else
+ *pointer = temp - 10 + 'a';
+ num = (unsigned long)num / radix;
+ }
+ while(num != 0);
+ if (signe>1) *(--pointer)='-';
+ while (*pointer!=0) putchar(*pointer++);
+ break;
+ case 'o':
+ radix = 8;
+ signe=0;
+ goto showstring;
+ case 'd':
+ case 'i':
+ radix=10;
+ signe=1;
+ goto showstring;
+ case 'x':
+ radix=16;
+ signe=0;
+ goto showstring;
+ case 's':
+ pointer=va_arg(ap, u8*);
+ if (!pointer) pointer="(null)";
+ while (*pointer!=0) putchar(*pointer++);
+ break;
+ case '%':
+ putchar ('%');
+ break;
+ default:
+ putchar (va_arg(ap, int));
+ break;
+ }
+ }
+ string++;
+ }
+ va_end(ap);
}
/*******************************************************************************/
diff --git a/makefile b/makefile
old mode 100644
new mode 100755
index 34a9474..1fc204c
--- a/makefile
+++ b/makefile
@@ -3,25 +3,41 @@ all: makall
makall: boot/boot12.bin lib/libs.o system/system.sys
sync
+install:
+ (sudo apt-get install nasm gcc qemu fusefat cgdb)
+
clean:
(cd system; make clean)
(cd boot; make clean)
(cd lib;make clean)
+ (cd final;make clean)
sync
backup: clean
(cd .. ; tar cf - cosc | gzip -f - > backup.tar.gz ; cd cosc)
-
-allbackup: backup
- (echo Inserez une disquette; sleep ; cp ../backup.tar.bz2 /dev/fd0)
copy:
- (cp system/system.sys /cygdrive/a)
+ (cd final; make)
-copy2:
- (cp system/system.sys /cygdrive/b)
-
-test: clean all copy2
+test: all copy qemu
+
+view:
+ (hexdump -C ./final/cos2000.img|head -c10000)
+
+debug-boot: all copy qemu-debug
+ (sleep 2;cgdb -x ./debug/boot.txt)
+
+debug-loader: all copy qemu-debug
+ (sleep 2;cgdb -x ./debug/loader.txt)
+
+debug-system: all copy qemu-debug
+ (sleep 2;cgdb -x ./debug/system.txt)
+
+qemu-debug:
+ (qemu-system-i386 -m 1G -fda ./final/cos2000.img -s -S &)
+
+qemu:
+ (qemu-system-i386 -m 1G -fda ./final/cos2000.img -s)
system/system.sys:
(cd system; make)
diff --git a/system/ansi.c b/system/ansi.c
new file mode 100755
index 0000000..5dca50f
--- /dev/null
+++ b/system/ansi.c
@@ -0,0 +1,318 @@
+u8 ansilogo[5056] = {
+ 0x1B, 0x5B, 0x30, 0x6D, 0x1B, 0x5B, 0x31, 0x6D, 0xDA, 0x1B, 0x5B, 0x30, 0x6D, 0xC4, 0xC4, 0x1B,
+ 0x5B, 0x31, 0x3B, 0x33, 0x30, 0x6D, 0xC4, 0x1B, 0x5B, 0x30, 0x6D, 0xC4, 0x1B, 0x5B, 0x31, 0x3B,
+ 0x33, 0x30, 0x6D, 0xC4, 0x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, 0x36, 0x43, 0xB3, 0x1B, 0x5B, 0x31, 0x3B, 0x33, 0x30, 0x6D, 0xC0, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4,
+ 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0xC4, 0x1B, 0x5B, 0x30, 0x6D, 0xC4, 0x1B, 0x5B, 0x31, 0x3B,
+ 0x33, 0x30, 0x6D, 0xC4, 0x1B, 0x5B, 0x30, 0x6D, 0xC4, 0xC4, 0x1B, 0x5B, 0x31, 0x6D, 0xD9, 0x00
+};
diff --git a/system/linker.lds b/system/linker.lds
new file mode 100644
index 0000000..3c125f5
--- /dev/null
+++ b/system/linker.lds
@@ -0,0 +1,20 @@
+OUTPUT_FORMAT("elf32-i386", "elf32-i386",
+ "elf32-i386")
+OUTPUT_ARCH(i386)
+
+ENTRY(mymain)
+
+SECTIONS
+{
+ . = 0x50000;
+ .text ALIGN(16): {
+ *(.text)
+ }
+ . = 0x200000;
+ .data ALIGN(16): {
+ *(.data)
+ }
+ .bss ALIGN(16): {
+ *(.bss)
+ }
+}
diff --git a/system/loader.asm b/system/loader.asm
deleted file mode 100644
index 7b9deef..0000000
--- a/system/loader.asm
+++ /dev/null
@@ -1,227 +0,0 @@
-[BITS 16]
-[ORG 0x100]
-
- SECTION .text
- push cs
- push cs
- pop ds
- pop es
- call EnableA20
- mov si,msgpmode
- call showstr
- mov ax,cs
- mov [RealCS],ax
- lea ax,[Real]
- mov [RealIP],ax
-
- xor eax,eax
- mov ax,cs
- shl eax,4
- mov [GDT.Entry1+2],ax
- mov [GDT.Entry2+2],ax
- mov [GDT.Entry4+2],ax
- mov [GDT.Entry5+2],ax
- shr eax,16
- mov [GDT.Entry1+4],al
- mov [GDT.Entry2+4],al
- mov [GDT.Entry4+4],al
- mov [GDT.Entry5+4],al
-
- xor eax,eax
- mov ax,cs
- shl eax,4
- add eax,gdt0
- mov [GDTR.Address],eax
- lgdt [GDTR]
-
- cli
- ;mov al,0xFF
- ;out 0x21,al
- mov al,0x80
- out 0x70,al
-
- mov eax,cr0
- or al,1
- mov cr0,eax
-
- jmp SYS_CODE_SEL:GoPMode32
-
-GoPMode32:
-[BITS 32]
- mov ax,SYS_DATA_SEL
- mov ds,ax
- mov ecx,50000/4
- cld
- mov esi,kernel
- mov edi,0x100000
- mov ax,ALL_DATA_SEL
- mov es,ax
- mov gs,ax
- mov fs,ax
- mov ss,ax
- rep movsd
- mov ds,ax
- mov esp,0x3fffff
- call KERNEL_SEL:0x100000
- jmp REAL_CODE_SEL:GoReal
-
-GoReal:
-[BITS 16]
- mov ax,REAL_DATA_SEL
- mov ds,ax
- mov es,ax
- mov ss,ax
- mov gs,ax
- mov fs,ax
- mov esp,0xffff
-
- mov eax,cr0
- and al,0xFE
- mov cr0,eax
-
- jmp far [RealIP]
-
-Real:
- jmp Real
-
-msgpmode db 'Pmode loader is loading',0
-
-;======================SHOWSTR========================
-;Affiche la chaine de caractère pointé par ds:si à l'écran
-;-> DS, SI
-;<- Flag Carry si erreur
-;=====================================================
-showstr:
- pusha
-Next_Char:
- lodsb
- or al,al
- jz End_Show
- mov ah,0x0E
- mov bx,0x07
- int 0x10
- jmp Next_Char
-End_Show:
- popa
- ret
-
-
-;***********************EnableA20*******************************
-;->
-;<-
-;Ouvre l'autoroute A20
-;***************************************************************
-EnableA20:
- cli
- call ClearKeybBuffer
- call WaitKeybCommand
- mov al,0xd1
- out 0x64,al
- call WaitKeybCommand
- mov al,0xdf
- out 0x60,al
- call WaitKeybCommand
- jmp A20Enabled
-WaitKeybCommand:
- in al,0x64
- test al,0x02
- jnz WaitKeybCommand
- ret
-ClearKeybBuffer:
- in al,0x64
- test al,0x01
- jnz ReadKeyb
- ret
-ReadKeyb:
- in al,0x60
- jmp ClearKeybBuffer
-A20Enabled:
- sti
- ret
-
-section .data
-
-RealIP: dw 0
-RealCS: dw 0
-
-GDTR:
-.Size: dw GDT_END
-.Address: dd 0
-
-
-
-gdt0 equ $ ; null entry
-GDT:
-.Entry0: dw 0 ; limit 15:0
- dw 0 ; base 15:0
- db 0 ; base 23:16
- db 0 ; type
- db 0 ; limit 19:16, flags
- db 0 ; base 31:24
-
-
-SYS_CODE_SEL equ $-gdt0 ; code segment descriptor
-
-.Entry1: dw 0xFFFF
- dw 0x0 ; base
- db 0x0 ; base
- db 0x9A ; present, ring 0, code, non-conforming, readable
- db 0x40 ; 32 bit
- db 0
-
-
-SYS_DATA_SEL equ $-gdt0 ; data segment descriptor
-
-.Entry2: dw 0xFFFF
- dw 0x0 ; base
- db 0x0 ; base
- db 0x92 ; present, ring 0, data, expand-up, writable
- db 0x40 ; 32 bit
- db 0
-
-
-ALL_DATA_SEL equ $-gdt0 ; 4meg data segment descriptor
-
-.Entry3: dw 0x03ff
- dw 0x0 ; base
- db 0x0 ; base
- db 0x92 ; present, ring 0, data, expand-up, writable
- db 0xcf ; 4k pages, 32 bit
- db 0
-
-
-REAL_CODE_SEL equ $-gdt0 ; code segment descriptor for 16 bit mode
-
-.Entry4: dw 0xFFFF
- dw 0x0 ; base
- db 0x0 ; base
- db 0x9A ; present, ring 0, code, non-conforming, readable
- db 0x00 ; 16 bit
- db 0
-
-
-REAL_DATA_SEL equ $-gdt0 ; data segment descriptor for 16 bit mode
-
-.Entry5: dw 0xFFFF
- dw 0x0 ; base
- db 0x0 ; base
- db 0x92 ; present, ring 0, data, expand-up, writable
- db 0x00 ; 16 bit
- db 0
-
-
-KERNEL_SEL equ $-gdt0 ; 4meg code segment descriptor
-
-.Entry6: dw 0x03ff
- dw 0x0 ; base
- db 0x0 ; base
- db 0x9A ; present, ring 0, code, non-conforming, readable
- db 0xcf ; 4k pages, 32 bit
- db 0
-
-GDT_END equ $-gdt0 -1
-
- kernel:
-
- SECTION .bss
-
diff --git a/system/makefile b/system/makefile
old mode 100644
new mode 100755
index 74d3e0f..270d3a1
--- a/system/makefile
+++ b/system/makefile
@@ -1,25 +1,21 @@
-FREEC=gcc -O2 -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -I ../Include -c -o
+FINALCC=gcc -O4 -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -w -I ../include -m32 -c -o
+GCC=gcc -O0 -g -nostdinc -ffreestanding -fno-builtin -fomit-frame-pointer -Wall -w -I ../include -m32 -c -o
-
-LINK=ld -Ttext 0x100000 -e __main -o
+LINK=ld -m elf_i386 -T linker.lds -e main -o
all: system.sys
sync
system.sys:
- nasm -f bin -o loader.bin loader.asm
nasm -f elf -o system.o system.asm
-
- $(FREEC) systemc.o system.c
- $(LINK) system.out systemc.o system.o ../lib/libs.o
- objcopy -O binary system.out system.bin
- cat loader.bin>system.sys
- cat system.bin>>system.sys
+ $(GCC) systemc.o system.c
+ $(LINK) system.sys systemc.o system.o ../lib/libs.o
clean:
rm -f *.o
rm -f *.out
rm -f *.bin
rm -f *.sys
+ rm -f *.s
diff --git a/system/system.asm b/system/system.asm
old mode 100644
new mode 100755
diff --git a/system/system.c b/system/system.c
old mode 100644
new mode 100755
index e656776..dbb9a36
--- a/system/system.c
+++ b/system/system.c
@@ -3,38 +3,88 @@
#include "idt.h"
#include "timer.h"
#include "keyboard.h"
+#include "mouse.h"
#include "asm.h"
+#include "cpu.h"
+#include "string.h"
-u8 printok[]=" \033[37m\033[1m[ \033[32mOK\033[37m ]\033[0m\r\n";
+#include "ansi.c"
+
+static cpuinfo cpu;
+static u8 noproc[]="\033[31mInconnu\033[0m\000";
+static u8 okmsg[]="\033[99C\033[8D\033[37m\033[1m[ \033[32mOK\033[37m ]\033[0m\000";
+static u8 key=0;
+
+void ok()
+{
+ print(okmsg);
+ return;
+}
+
+int main(void) {
+
+ cli();
+ setvmode(0x02);
+ /* Efface l'ecran */
+ print("\033[2J\000");
+ printf(ansilogo);
+ print("\033[0mNoyau charge en memoire\000");
+ ok();
+
+ print("Initilisation de la table d'interruption\000");
+ initidt();
+ ok();
+
+ print("Initialisation du controleur d'interruption\000");
+ initpic();
+ sti();
+ ok();
+
+ print("Installation du handler timer\000");
+ setidt((u32)timer, 0x20, INTGATE, 32);
+ ok();
+
+ print("Activation de l'IRQ 0\000");
+ enableirq(0);
+ ok();
+
+ print("Installation du handler clavier\000");
+ setidt((u32)keyboard, 0x20, INTGATE, 33);
+ ok();
+
+ print("Activation de l'IRQ 1\000");
+ enableirq(1);
+ ok();
+
+ print("Installation du handler souris\000");
+ setidt((u32)mouse, 0x20, INTGATE, 100);
+ ok();
+
+ print("Initialisation du controleur souris :\000");
+ if (initmouse()==1)
+ print(" \033[1m\033[32mSouris Presente\033[0m\000");
+ else
+ print(" \033[1m\033[31mSouris non detecte\033[0m\000");
+ ok();
+
+ print("Activation de l'IRQ 2 (Controleur esclave)\000");
+ enableirq(2);
+ ok();
+
+ print("Activation de l'IRQ 12\000");
+ enableirq(12);
+ ok();
+
+ strcpy(&noproc,&cpu.detectedname);
+ getcpuinfos(&cpu);
+
+ printf("Processeur detecte\r Revision \t:%d\r Modele \t:%d\r Famille \t:%d\r Nom cpuid\t:%s\rJeux\t:%s\000",cpu.stepping,cpu.models,cpu.family,&cpu.detectedname,&cpu.techs);
+ ok();
+ while(1)
+ {
+ key=waitascii();
+ putchar(key);
+ }
-int _main(void) {
- cli();
- setvmode(0x02);
- /* Efface l'ecran */
- print("\033[2J");
- print("Noyau charge en memoire");
- print(printok);
- print("Initilisation de la table d'interruption");
- initidt();
- print(printok);
- print("Initialisation du controleur d'interruption");
- initpic();
- print(printok);
- print("Activation logicielle des interruptions");
- sti();
- print(printok);
- print("Installation du handler timer");
- setidt((u32)timer, 0x30, INTGATE, 32);
- print(printok);
- print("Activation de l'IRQ 0");
- enableirq(0);
- print(printok);
- print("Installation du handler clavier");
- setidt((u32)keyboard, 0x30, INTGATE, 33);
- print(printok);
- print("Activation de l'IRQ 1");
- enableirq(1);
- print(printok);
- while(1);
}