Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 1017 → Rev 1018

/kernel/trunk/boot/bootcode.inc
423,13 → 423,16
; otherwise, set [preboot_device] to 1 (default value - boot from floppy)
mov byte [di], 1
.preboot_device_inited:
; following 6 lines set variables to 1 if its current value is 0
; following 4 lines set variables to 1 if its current value is 0
cmp byte [di+preboot_dma-preboot_device], 1
adc byte [di+preboot_dma-preboot_device], 0
cmp byte [di+preboot_biosdisk-preboot_device], 1
adc byte [di+preboot_biosdisk-preboot_device], 0
cmp byte [di+preboot_vrrm-preboot_device], 1
adc byte [di+preboot_vrrm-preboot_device], 0
; default value for VRR is OFF
cmp byte [di+preboot_vrrm-preboot_device], 0
jnz @f
mov byte [di+preboot_vrrm-preboot_device], 2
@@:
; notify user
_setcursor 5,2
 
/kernel/trunk/core/dll.inc
810,6 → 810,8
mov dword [edx+8], 'vers'
mov byte [edx+12], '/'
mov esi, [driver_name]
.redo:
lea edx, [file_name]
lea edi, [edx+13]
mov ecx, 16
@@:
926,6 → 928,15
jnz .ok
 
stdcall kernel_free, [img_base]
cmp dword [file_name+13], 'SOUN'
jnz @f
cmp dword [file_name+17], 'D.ob'
jnz @f
cmp word [file_name+21], 'j'
jnz @f
mov esi, aSis
jmp .redo
@@:
xor eax, eax
ret
.ok:
/kernel/trunk/data32.inc
80,6 → 80,7
msg_version db 'incompatible driver version',13,10,0
msg_www db 'please visit www.kolibrios.org',13,10,0
msg_CR db 13,10,0
aSis db 'SIS',0
 
intel_str db "GenuineIntel",0
AMD_str db "AuthenticAMD",0
/kernel/trunk/docs/sysfuncr.txt
1,4 → 1,4
‘ˆ‘’…Œ›… ”“Š–ˆˆ Ž…€–ˆŽŽ‰ ‘ˆ‘’…Œ› Kolibri 0.7.1.0
‘ˆ‘’…Œ›… ”“Š–ˆˆ Ž…€–ˆŽŽ‰ ‘ˆ‘’…Œ› Kolibri 0.7.5.0
 
®¬¥à ä㭪樨 ¯®¬¥é ¥âáï ¢ ॣ¨áâà eax.
‚맮¢ á¨á⥬­®© ä㭪樨 ®áãé¥á⢫ï¥âáï ª®¬ ­¤®© "int 0x40".
223,9 → 223,6
âॡã¥âáï ¯¥à¥¤ âì ã¯à ¢«¥­¨¥ á«¥¤ãî饬㠯à®æ¥ááã
(§ ª®­ç¨âì ⥪ã騩 ª¢ ­â ¢à¥¬¥­¨), ¨á¯®«ì§ã©â¥ ¯®¤äã­ªæ¨î 1
ä㭪樨 68.
* à¨ ⥪ã饩 ॠ«¨§ æ¨¨ ¯à®¨§®©¤¥â ­¥¬¥¤«¥­­ë© ¢®§¢à â ¨§ ä㭪樨,
¥á«¨ á«®¦¥­¨¥ ebx á ⥪ã騬 §­ ç¥­¨¥¬ áç¥â稪  ¢à¥¬¥­¨ ¢ë§®¢¥â
32-¡¨â­®¥ ¯¥à¥¯®«­¥­¨¥.
 
======================================================================
=============== ”ã­ªæ¨ï 6 - ¯à®ç¨â âì ä ©« á à ¬¤¨áª . ===============
621,16 → 618,22
* eax = 17 - ­®¬¥à ä㭪樨
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* ¥á«¨ ¡ãä¥à ¯ãáâ, ¢®§¢à é ¥âáï eax=1
* ¥á«¨ ¡ãä¥à ­¥ ¯ãáâ, ⮣¤  ¢®§¢à é ¥âáï: áâ à訥 24 ¡¨â  eax
ᮤ¥à¦ â ¨¤¥­â¨ä¨ª â®à ª­®¯ª¨ (¢ ç áâ­®áâ¨, ¢ ah ®ª §ë¢ ¥âáï
¬« ¤è¨© ¡ ©â ¨¤¥­â¨ä¨ª â®à ; ¥á«¨ ¢á¥ ª­®¯ª¨ ¨¬¥îâ ¨¤¥­â¨ä¨ª â®à,
¬¥­ì訩 256, â® ¤«ï à §«¨ç¥­¨ï ¤®áâ â®ç­® ah),
  ¢ al ¢®§¢à é ¥âáï 0 - ¥á«¨ ¨á¯®«ì§®¢ « áì «¥¢ ï ª­®¯ª  ¬ëè¨, ¨«¨ ¡¨â ⮩ ª­®¯ª¨ ¬ëè¨, ª®â®à ï ¨á¯®«ì§®¢ « áì.
* ¥á«¨ ¡ãä¥à ­¥¯ãáâ:
* áâ à訥 24 ¡¨â  eax ᮤ¥à¦ â ¨¤¥­â¨ä¨ª â®à ª­®¯ª¨
(¢ ç áâ­®áâ¨, ¢ ah ®ª §ë¢ ¥âáï ¬« ¤è¨© ¡ ©â ¨¤¥­â¨ä¨ª â®à ;
¥á«¨ ¢á¥ ª­®¯ª¨ ¨¬¥îâ ¨¤¥­â¨ä¨ª â®à, ¬¥­ì訩 256,
â® ¤«ï à §«¨ç¥­¨ï ¤®áâ â®ç­® ah)
* al = 0 - ª­®¯ª  ¡ë«  ­ ¦ â  «¥¢®© ª­®¯ª®© ¬ëè¨
* al = ¡¨â, ᮮ⢥âáâ¢ãî騩 ­ ¦ ¢è¥© ª­®¯ª¥ ¬ëè¨, ¥á«¨ ­¥ «¥¢®©
‡ ¬¥ç ­¨ï:
* "ãä¥à" åà ­¨â ⮫쪮 ®¤­ã ª­®¯ªã, ¯à¨ ­ ¦ â¨¨ ­®¢®© ª­®¯ª¨
¨­ä®à¬ æ¨ï ® áâ à®© â¥àï¥âáï.
* à¨ ¢ë§®¢¥ í⮩ ä㭪樨 ¯à¨«®¦¥­¨¥¬ á ­¥ ªâ¨¢­ë¬ ®ª­®¬
¢®§¢à é ¥âáï ®â¢¥â "¡ãä¥à ¯ãáâ".
* ‚®§¢à é ¥¬®¥ §­ ç¥­¨¥ al ᮮ⢥âáâ¢ã¥â á®áâ®ï­¨î ª­®¯®ª ¬ëè¨
¢ ä®à¬ â¥ ¯®¤ä㭪樨 2 ä㭪樨 37 ¢ ¬®¬¥­â ­ ç «  ­ ¦ â¨ï
­  ª­®¯ªã, §  ¨áª«î祭¨¥¬ ¬« ¤è¥£® ¡¨â  (ᮮ⢥âáâ¢ãî饣® «¥¢®©
ª­®¯ª¥ ¬ëè¨), ª®â®àë© á¡à á뢠¥âáï.
 
======================================================================
==== ”ã­ªæ¨ï 18, ¯®¤äã­ªæ¨ï 2 - § ¢¥àè¨âì ¯à®æ¥áá/¯®â®ª ¯® á«®âã. ====
735,7 → 738,7
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
 
======================================================================
======= ”ã­ªæ¨ï 18, ¯®¤äã­ªæ¨ï 9 - § ¢¥à襭¨¥ à ¡®âë á¨á⥬ë ========
= ”ã­ªæ¨ï 18, ¯®¤äã­ªæ¨ï 9 - § ¢¥à襭¨¥ à ¡®âë á¨á⥬ë á ¯ à ¬¥â஬. =
======================================================================
 à ¬¥âàë:
* eax = 18 - ­®¬¥à ä㭪樨
750,8 → 753,7
‡ ¬¥ç ­¨ï:
* ¥ á«¥¤ã¥â ¯®« £ âìáï ­  ¢®§¢à é ¥¬®¥ §­ ç¥­¨¥ ¯à¨ ­¥¢¥à­®¬
¢ë§®¢¥, ®­® ¬®¦¥â ¨§¬¥­¨âìáï ¢ ¯®á«¥¤ãîé¨å ¢¥àá¨ïå ï¤à .
* Œ®¦­® ¨á¯®«ì§®¢ âì ¯®¤äã­ªæ¨î 1, çâ®¡ë ­  ¯®á«¥¤­¥¬ è £¥
§ ¢¥à襭¨ï à ¡®âë ¯®«ì§®¢ â¥«ì á ¬ à¥è «, çâ® ¥¬ã ­ã¦­®.
 
======================================================================
======== ”ã­ªæ¨ï 18, ¯®¤äã­ªæ¨ï 10 - ᢥà­ãâì ®ª­® ¯à¨«®¦¥­¨ï. =======
======================================================================
1132,11 → 1134,6
¯®¤ä㭪樨 3 ä㭪樨 26.
 
======================================================================
== ”ã­ªæ¨ï 21, ¯®¤äã­ªæ¨ï 4 - ãáâ ­®¢¨âì ¡ §®¢ë© ¯®àâ Sound Blaster. =
======================================================================
“¤ «¥­ 
 
======================================================================
========= ”ã­ªæ¨ï 21, ¯®¤äã­ªæ¨ï 5 - ãáâ ­®¢¨âì ï§ëª á¨á⥬ë. ========
======================================================================
 à ¬¥âàë:
1200,11 → 1197,6
¯®¤ä㭪樥© 7.
 
======================================================================
===== ”ã­ªæ¨ï 21, ¯®¤äã­ªæ¨ï 10 - ãáâ ­®¢¨âì ª ­ « DMA ¤«ï §¢ãª . ====
======================================================================
“¤ «¥­ :
 
======================================================================
====================== ”ã­ªæ¨ï 21, ¯®¤äã­ªæ¨ï 11 =====================
===========  §à¥è¨âì/§ ¯à¥â¨âì ­¨§ª®ã஢­¥¢ë© ¤®áâ㯠ª HD. ==========
======================================================================
1498,11 → 1490,6
* à¨¬¥à®¬ ¨á¯®«ì§®¢ ­¨ï ä㭪樨 ï¥âáï ¯à¨«®¦¥­¨¥ CD_tray.
 
======================================================================
============== ”ã­ªæ¨ï 25 - ãáâ ­®¢¨âì £à®¬ª®áâì SBPro. ==============
======================================================================
“¤ «¥­ 
 
======================================================================
===== ”ã­ªæ¨ï 26, ¯®¤äã­ªæ¨ï 1 - ¯®«ãç¨âì ¡ §®¢ë© ¯®àâ MPU MIDI. =====
======================================================================
 à ¬¥âàë:
1565,11 → 1552,6
* “áâ ­®¢¨âì ¡ §ã CD ¬®¦­® ¢ë§®¢®¬ ¯®¤ä㭪樨 3 ä㭪樨 21.
 
======================================================================
=== ”ã­ªæ¨ï 26, ¯®¤äã­ªæ¨ï 4 - ¯®«ãç¨âì ¡ §®¢ë© ¯®àâ Sound Blaster. ==
======================================================================
“¤ «¥­ 
 
======================================================================
========== ”ã­ªæ¨ï 26, ¯®¤äã­ªæ¨ï 5 - ¯®«ãç¨âì ï§ëª á¨á⥬ë. =========
======================================================================
 à ¬¥âàë:
1634,11 → 1616,6
* ‘¨á⥬­®¥ ¢à¥¬ï ¬®¦­® ¯®«ãç¨âì ä㭪樥© 3.
 
======================================================================
====== ”ã­ªæ¨ï 26, ¯®¤äã­ªæ¨ï 10 - ¯®«ãç¨âì ª ­ « DMA ¤«ï §¢ãª . =====
======================================================================
“¤ «¥­ 
 
======================================================================
====================== ”ã­ªæ¨ï 26, ¯®¤äã­ªæ¨ï 11 =====================
=========== “§­ âì, à §à¥èñ­ «¨ ­¨§ª®ã஢­¥¢ë© ¤®áâ㯠ª HD. ==========
======================================================================
1668,11 → 1645,6
¯®¤ä㭪樨 12 ä㭪樨 21.
 
======================================================================
=============== ”ã­ªæ¨ï 28 - ãáâ ­®¢¨âì £à®¬ª®áâì SB16. ==============
======================================================================
“¤ «¥­ 
 
======================================================================
================ ”ã­ªæ¨ï 29 - ¯®«ãç¨âì á¨á⥬­ãî ¤ âã. ===============
======================================================================
 à ¬¥âàë:
1712,6 → 1684,56
¨ ¢ ª®­æ¥ áâ ¢¨âáï § ¢¥àè î騩 0.
 
======================================================================
================ ”ã­ªæ¨ï 32 - 㤠«¨âì ä ©« á à ¬¤¨áª . ===============
======================================================================
 à ¬¥âàë:
* eax = 32 - ­®¬¥à ä㭪樨
* ebx = 㪠§ â¥«ì ­  ¨¬ï ä ©« 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = 0 - ãᯥ譮; ¨­ ç¥ ª®¤ ®è¨¡ª¨ ä ©«®¢®© á¨á⥬ë
‡ ¬¥ç ­¨ï:
* â  äã­ªæ¨ï ãáâ à¥« ; äã­ªæ¨ï 58 ¯®§¢®«ï¥â ¢ë¯®«­ïâì
⥠¦¥ ¤¥©á⢨ï á à áè¨à¥­­ë¬¨ ¢®§¬®¦­®áâﬨ.
* ’¥ªãé ï ॠ«¨§ æ¨ï ¢®§¢à é ¥â ⮫쪮 §­ ç¥­¨ï 0(ãᯥå) ¨
5(ä ©« ­¥ ­ ©¤¥­).
* ˆ¬ï ä ©«  ¤®«¦­® ¡ëâì «¨¡® ¢ ä®à¬ â¥ 8+3 ᨬ¢®«®¢ (¯¥à¢ë¥
8 ᨬ¢®«®¢ - ᮡá⢥­­® ¨¬ï, ¯®á«¥¤­¨¥ 3 - à áè¨à¥­¨¥,
ª®à®âª¨¥ ¨¬¥­  ¨ à áè¨à¥­¨ï ¤®¯®«­ïîâáï ¯à®¡¥« ¬¨),
«¨¡® ¢ ä®à¬ â¥ 8.3 ᨬ¢®«®¢ "FILE.EXT"/"FILE.EX "
(¨¬ï ­¥ ¡®«¥¥ 8 ᨬ¢®«®¢, â®çª , à áè¨à¥­¨¥ 3 ᨬ¢®« ,
¤®¯®«­¥­­®¥ ¯à¨ ­¥®¡å®¤¨¬®á⨠¯à®¡¥« ¬¨).
ˆ¬ï ä ©«  ¤®«¦­® ¡ëâì § ¯¨á ­® § £« ¢­ë¬¨ ¡ãª¢ ¬¨.
‡ ¢¥àè î騩 ᨬ¢®« á ª®¤®¬ 0 ­¥ ­ã¦¥­ (­¥ ASCIIZ-áâப ).
* â  äã­ªæ¨ï ­¥ ¯®¤¤¥à¦¨¢ ¥â ¯ ¯®ª ­  à ¬¤¨áª¥.
 
======================================================================
=============== ”ã­ªæ¨ï 33 - § ¯¨á âì ä ©« ­  à ¬¤¨áª. ===============
======================================================================
 à ¬¥âàë:
* eax = 33 - ­®¬¥à ä㭪樨
* ebx = 㪠§ â¥«ì ­  ¨¬ï ä ©« 
* ecx = 㪠§ â¥«ì ­  ¤ ­­ë¥ ¤«ï § ¯¨á¨
* edx = ç¨á«® ¡ ©â ¤«ï § ¯¨á¨
* á«¥¤ã¥â ãáâ ­ ¢«¨¢ âì esi=0
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = 0 - ãᯥ譮, ¨­ ç¥ ª®¤ ®è¨¡ª¨ ä ©«®¢®© á¨á⥬ë
‡ ¬¥ç ­¨ï:
* â  äã­ªæ¨ï ãáâ à¥« ; äã­ªæ¨ï 70 ¯®§¢®«ï¥â ¢ë¯®«­ïâì
⥠¦¥ ¤¥©á⢨ï á à áè¨à¥­­ë¬¨ ¢®§¬®¦­®áâﬨ.
* …᫨ 㪠§ âì ­¥­ã«¥¢®¥ §­ ç¥­¨¥ ¢ esi ¨ ­  à ¬¤¨áª¥ 㦥 ¥áâì
㪠§ ­­ë© ä ©«, â® ¡ã¤¥â ᮧ¤ ­ ¥éñ ®¤¨­ ä ©« á ⥬ ¦¥ ¨¬¥­¥¬.
* ‚ ¯à®â¨¢­®¬ á«ãç ¥ ä ©« ¯¥à¥§ ¯¨á뢠¥âáï.
* ˆ¬ï ä ©«  ¤®«¦­® ¡ëâì «¨¡® ¢ ä®à¬ â¥ 8+3 ᨬ¢®«®¢
(¯¥à¢ë¥ 8 ᨬ¢®«®¢ - ᮡá⢥­­® ¨¬ï, ¯®á«¥¤­¨¥ 3 - à áè¨à¥­¨¥,
ª®à®âª¨¥ ¨¬¥­  ¨ à áè¨à¥­¨ï ¤®¯®«­ïîâáï ¯à®¡¥« ¬¨),
«¨¡® ¢ ä®à¬ â¥ 8.3 ᨬ¢®«®¢ "FILE.EXT"/"FILE.EX "
(¨¬ï ­¥ ¡®«¥¥ 8 ᨬ¢®«®¢, â®çª , à áè¨à¥­¨¥ 3 ᨬ¢®« ,
¤®¯®«­¥­­®¥ ¯à¨ ­¥®¡å®¤¨¬®á⨠¯à®¡¥« ¬¨).
ˆ¬ï ä ©«  ¤®«¦­® ¡ëâì § ¯¨á ­® § £« ¢­ë¬¨ ¡ãª¢ ¬¨.
‡ ¢¥àè î騩 ᨬ¢®« á ª®¤®¬ 0 ­¥ ­ã¦¥­ (­¥ ASCIIZ-áâப ).
* â  äã­ªæ¨ï ­¥ ¯®¤¤¥à¦¨¢ ¥â ¯ ¯®ª ­  à ¬¤¨áª¥.
 
======================================================================
============ ”ã­ªæ¨ï 35 - ¯à®ç¨â âì 梥â â®çª¨ ­  íªà ­¥. ============
======================================================================
 à ¬¥âàë:
1729,7 → 1751,7
¬®¦­® ¯®«ãç¨âì ä㭪樥© 61.
 
======================================================================
=============== ”ã­ªæ¨ï 36 - ¯à®ç¨â âì ®¡« áâì íªà ­ . ==============
=============== ”ã­ªæ¨ï 36 - ¯à®ç¨â âì ®¡« áâì íªà ­ . ===============
======================================================================
 à ¬¥âàë:
* eax = 36 - ­®¬¥à ä㭪樨
1740,8 → 1762,8
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* Š®®à¤¨­ âë ¨§®¡à ¦¥­¨ï - íâ® ª®®à¤¨­ âë ¢¥àå­¥£® «¥¢®£® 㣫 
¨§®¡à ¦¥­¨ï ®â­®á¨â¥«ì­® íªà ­ .
* Š®®à¤¨­ âë ®¡« á⨠- íâ® ª®®à¤¨­ âë ¢¥àå­¥£® «¥¢®£® 㣫 
®¡« á⨠®â­®á¨â¥«ì­® íªà ­ .
*  §¬¥à ¨§®¡à ¦¥­¨ï ¢ ¡ ©â å ¥áâì 3*xsize*ysize.
 
======================================================================
1937,43 → 1959,35
* eax = -1 ¤«ï ­¥ª®à४⭮£® ebx
 
======================================================================
========== ”ã­ªæ¨ï 42 - à ¡®â  á ¤ ­­ë¬¨, ¯®«ã祭­ë¬¨ ¯® IRQ. =======
========= ”ã­ªæ¨ï 42 - à ¡®â  á ¤ ­­ë¬¨, ¯®«ã祭­ë¬¨ ¯® IRQ. =========
======================================================================
 
------------------------ —⥭¨¥ ¤ ­­ëå -------------------------------
à¨ ¢®§­¨ª­®¢¥­¨¨ IRQ á¨á⥬  ¬®¦¥â áç¨â뢠âì ¤ ­­ë¥ ¨§ 㪠§ ­­ëå
à ­¥¥ ä㭪樥© 44 ¯®à⮢ ¨ § ¯¨á뢠âì í⨠¤ ­­ë¥ ¢ ¡ãä¥à.
Ž¯¨á뢠¥¬ ï äã­ªæ¨ï áç¨â뢠¥â ¤ ­­ë¥ ¨§ í⮣® ¡ãä¥à  ¢ ¡ãä¥à
㪠§ ­­ë© ¢ ª ç¥á⢥ ¯ à ¬¥âà .
 
-------------------- ®¤äã­ªæ¨ï 0 - ç⥭¨¥ ¤ ­­ëå --------------------
 à ¬¥âàë:
* eax = 42 - ­®¬¥à ä㭪樨
* bl = ­®¬¥à IRQ, 0..15
* bh = ­®¬¥à ¯®¤ä㭪樨, 0
Žáâ «ì­ ï ç áâì ॣ¨áâà  ebx ¤®«¦­  ¡ëâì ®¡­ã«¥­ .
* ecx = 㪠§ â¥«ì ­  ¡ãä¥à, ªã¤  ¡ã¤ã⠯ਭ¨¬ âìáï ¤ ­­ë¥
* bh = 0 - ­®¬¥à ¯®¤ä㭪樨
* ®áâ «ì­ ï ç áâì ॣ¨áâà  ebx ¤®«¦­  ¡ëâì ®¡­ã«¥­ 
* ecx = 㪠§ â¥«ì ­  ¡ãä¥à à §¬¥à®¬ ­¥ ¬¥­¥¥ 4000 ¡ ©â
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥: (á¨âã æ¨î ¬®¦­® à §«¨ç¨âì ¯® §­ ç¥­¨î eax)
* ¥á«¨ ¯®â®ª ­¥ ï¥âáï ¢« ¤¥«ì楬 IRQ
(¨«¨ ­®¬¥à IRQ § ¤ ­ ­¥¢¥à­®):
* eax = -1
* ¥á«¨ ¤ ­­ëå ­¥â:
* eax = 0
(¨«¨ ­®¬¥à IRQ § ¤ ­ ­¥¢¥à­®): eax = -1
* ¥á«¨ ¤ ­­ëå ­¥â: eax = 0
* ¥á«¨ ¢áñ ¢ ¯®à浪¥ ¨ ¤ ­­ë¥ ¡ë«¨:
* eax = à §¬¥à ¤ ­­ëå, ¯à®ç¨â ­­ëå ¨§ ¡ãä¥à  (¢ ¡ ©â å)
eax = à §¬¥à ¤ ­­ëå, ¯à®ç¨â ­­ëå ¨§ ¡ãä¥à  (¢ ¡ ©â å)
 
‘¬®âà¨â¥ § ¬¥ç ­¨ï ­¨¦¥.
 
------------------------ “§­ âì à §¬¥à ¤ ­­ëå ¢ ¡ãä¥à¥ ---------------
------------ ®¤äã­ªæ¨ï 1 - 㧭 âì à §¬¥à ¤ ­­ëå ¢ ¡ãä¥à¥ ------------
 à ¬¥âàë:
* eax = 42 - ­®¬¥à ä㭪樨
* bl = ­®¬¥à IRQ, 0..15
* bh = ­®¬¥à ¯®¤ä㭪樨, 1
Žáâ «ì­ ï ç áâì ॣ¨áâà  ebx ¤®«¦­  ¡ëâì ®¡­ã«¥­ .
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥: (á¨âã æ¨î ¬®¦­® à §«¨ç¨âì ¯® §­ ç¥­¨î eax)
* bh = 1 - ­®¬¥à ¯®¤ä㭪樨
* ®áâ «ì­ ï ç áâì ॣ¨áâà  ebx ¤®«¦­  ¡ëâì ®¡­ã«¥­ 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* ¥á«¨ ¯®â®ª ­¥ ï¥âáï ¢« ¤¥«ì楬 IRQ
(¨«¨ ­®¬¥à IRQ § ¤ ­ ­¥¢¥à­®):
* eax = -1
* ¥á«¨ ¢áñ ¢ ¯®à浪¥, ¢ eax à §¬¥à ¤ ­­ëå
 
(¨«¨ ­®¬¥à IRQ § ¤ ­ ­¥¢¥à­®): eax = -1
* ¨­ ç¥ eax = à §¬¥à ¤ ­­ëå ¢ ¡ãä¥à¥
‡ ¬¥ç ­¨ï:
* à¥¤¢ à¨â¥«ì­® ¯®â®ª ¤®«¦¥­ § à¥§¥à¢¨à®¢ âì ¤«ï ᥡï 㪠§ ­­ë© IRQ
ä㭪樥© 45.
2597,9 → 2611,6
* ’¥ªãé ï ॠ«¨§ æ¨ï ­¥ § ªà뢠¥â  ¢â®¬ â¨ç¥áª¨ ¢á¥ ᮪¥âë ¯®â®ª 
¯à¨ ¥£® § ¢¥à襭¨¨. ‚ ç áâ­®áâ¨, ­¥ á«¥¤ã¥â ¯à¨¡¨¢ âì ¯®â®ª
á ªã祩 ®âªàëâëå ᮪¥â®¢ - ¡ã¤¥â ãâ¥çª  à¥áãàᮢ.
* ’¥ªãé ï ॠ«¨§ æ¨ï ­¥ ¤¥« ¥â ¯à®¢¥à®ª ­  ª®à४⭮áâì
(¥¤¨­á⢥­­®¥, ­  çâ® ¢®§¢à é ¥âáï ®è¨¡ª , - ¯®¯ë⪠ § ªàëâì
­¥®âªàëâë© á®ª¥â á ª®à४â­ë¬ åí­¤«®¬).
 
======================================================================
============== ”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 2 - ®¯à®á ᮪¥â . ==============
2609,10 → 2620,8
* ebx = 2 - ­®¬¥à ¯®¤ä㭪樨
* ecx = åí­¤« ᮪¥â 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = ç¨á«® ¯®«ã祭­ëå ¡ ©â
* eax = ç¨á«® ¯®«ã祭­ëå ¡ ©â, 0 ¤«ï ­¥¢¥à­®£® åí­¤« 
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* à®¢¥àª¨ ª®à४⭮á⨠­¥ ¤¥« ¥âáï.
 
======================================================================
======== ”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 3 - ¯à®ç¨â âì ¡ ©â ¨§ ᮪¥â . ========
2622,12 → 2631,10
* ebx = 3 - ­®¬¥à ¯®¤ä㭪樨
* ecx = åí­¤« ᮪¥â 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* ¥á«¨ ­¥â ¯à¨­ïâëå ¤ ­­ëå: eax=0, bl=0,
¯à®ç¨¥ ¡ ©âë ebx à §àãè îâáï
* ¥á«¨ ­¥â ¯à¨­ïâëå ¤ ­­ëå ¨«¨ 㪠§ ­ ­¥¢¥à­ë© åí­¤«:
eax=0, bl=0, ¯à®ç¨¥ ¡ ©âë ebx à §àãè îâáï
* ¥á«¨ ¡ë«¨ ¯à¨­ïâë¥ ¤ ­­ë¥: eax=ç¨á«® ®áâ ¢è¨åáï ¡ ©â
(¢®§¬®¦­®, 0), bl=¯à®ç¨â ­­ë© ¡ ©â, ¯à®ç¨¥ ¡ ©âë ebx à §àãè îâáï
‡ ¬¥ç ­¨ï:
* à®¢¥àª¨ ª®à४⭮á⨠­¥ ¯à®¨§¢®¤¨âáï.
 
======================================================================
========== ”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 4 - § ¯¨á âì ¢ UDP-᮪¥â. ==========
2639,13 → 2646,10
* edx = ç¨á«® ¡ ©â ¤«ï § ¯¨á¨
* esi = 㪠§ â¥«ì ­  ¤ ­­ë¥ ¤«ï § ¯¨á¨
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = 0xffffffff - ­¥¢¥à­ë© åí­¤«
* eax = 0xffff - ­¥¤®áâ â®ç­® ¯ ¬ïâ¨
* eax = 0xffffffff - ®è¨¡ª  (­¥¢¥à­ë© åí­¤« ¨«¨ ­¥¤®áâ â®ç­® ¯ ¬ïâ¨)
* eax = 0 - ãᯥ譮
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* à®¢¥àª  ­  ¯à ¢¨«ì­®áâì åí­¤«  ¬¨­¨¬ «ì­  - ¨áª«îç îâáï ⮫쪮
­¥ ®ç¥­ì ­¥¯à ¢¨«ì­ë¥ ­¥®âªàëâë¥ åí­¤«ë.
* —¨á«® ¡ ©â ¤«ï § ¯¨á¨ ­¥ ¬®¦¥â ¯à¥¢ëè âì 1500-28, å®âï
ᮮ⢥âáâ¢ãî饩 ¯à®¢¥àª¨ ­¥ ¤¥« ¥âáï.
 
2673,7 → 2677,7
* ebx = 6 - ­®¬¥à ¯®¤ä㭪樨
* ecx = åí­¤« ᮪¥â 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = áâ âãá ᮪¥â : ®¤­® ¨§
* eax = 0 ¤«ï ­¥¢¥à­®£® ᮪¥â  ¨«¨ áâ âãá: ®¤­® ¨§
* TCB_LISTEN = 1
* TCB_SYN_SENT = 2
* TCB_SYN_RECEIVED = 3
2686,8 → 2690,6
* TCB_TIME_WAIT = 10
* TCB_CLOSED = 11
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* à®¢¥à®ª ª®à४⭮á⨠­¥ ¯à®¨§¢®¤¨âáï.
 
======================================================================
========== ”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 7 - § ¯¨á âì ¢ TCP-᮪¥â. ==========
2699,13 → 2701,10
* edx = ç¨á«® ¡ ©â ¤«ï § ¯¨á¨
* esi = 㪠§ â¥«ì ­  ¤ ­­ë¥ ¤«ï § ¯¨á¨
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = 0xffffffff - ®è¨¡ª 
* eax = 0xffff - ­¥¤®áâ â®ç­® ¯ ¬ïâ¨
* eax = 0xffffffff - ®è¨¡ª  (­¥¢¥à­ë© åí­¤« ¨«¨ ­¥¤®áâ â®ç­® ¯ ¬ïâ¨)
* eax = 0 - ãᯥ譮
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* à®¢¥àª  ­  ¯à ¢¨«ì­®áâì åí­¤«  ¬¨­¨¬ «ì­  - ¨áª«îç îâáï ⮫쪮
­¥ ®ç¥­ì ­¥¯à ¢¨«ì­ë¥ ­¥®âªàëâë¥ åí­¤«ë.
* —¨á«® ¡ ©â ¤«ï § ¯¨á¨ ­¥ ¬®¦¥â ¯à¥¢ëè âì 1500-40,
å®âï ᮮ⢥âáâ¢ãî饩 ¯à®¢¥àª¨ ­¥ ¤¥« ¥âáï.
 
2717,19 → 2716,14
* ebx = 8 - ­®¬¥à ¯®¤ä㭪樨
* ecx = åí­¤« ᮪¥â 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = -1 - ­¥¢¥à­ë© åí­¤«
* eax = 0xffff - ­¥¤®áâ â®ç­® ¯ ¬ï⨠¤«ï ¯ ª¥â  § ªàëâ¨ï ᮪¥â 
* eax = -1 - ®è¨¡ª  (­¥¢¥à­ë© åí­¤« ¨«¨
­¥¤®áâ â®ç­® ¯ ¬ï⨠¤«ï ¯ ª¥â  § ªàëâ¨ï ᮪¥â )
* eax = 0 - ãᯥ譮
* ¢® ¬­®£¨å á«ãç ïå eax à §àãè ¥âáï (¢®§¢à é ¥âáï १ã«ìâ â ä㭪樨
queue) - ¢¨¤¨¬®, íâ® ¡ £, ª®â®àë© ¡ã¤¥â ¨á¯à ¢«¥­
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* ’¥ªãé ï ॠ«¨§ æ¨ï ­¥ § ªà뢠¥â  ¢â®¬ â¨ç¥áª¨ ¢á¥ ᮪¥âë ¯®â®ª 
¯à¨ ¥£® § ¢¥à襭¨¨. ‚ ç áâ­®áâ¨, ­¥ á«¥¤ã¥â ¯à¨¡¨¢ âì ¯®â®ª
á ªã祩 ®âªàëâëå ᮪¥â®¢ - ¡ã¤¥â ãâ¥çª  à¥áãàᮢ.
* ’¥ªãé ï ॠ«¨§ æ¨ï ­¥ ¤¥« ¥â ¯à®¢¥à®ª ­  ª®à४⭮áâì
(¥¤¨­á⢥­­®¥, ­  çâ® ¢®§¢à é ¥âáï ®è¨¡ª , - ¯®¯ë⪠ § ªàëâì
­¥®âªàëâë© á®ª¥â á ª®à४â­ë¬ åí­¤«®¬).
 
======================================================================
== ”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 9 - ¯à®¢¥à¨âì, ᢮¡®¤¥­ «¨ «®ª «ì­ë© ¯®àâ. =
2770,10 → 2764,8
* esi = ç¨á«® ¡ ©â ¤«ï ç⥭¨ï;
* esi = 0 - ç¨â âì ¢á¥ ¤ ­­ë¥ (¬ ªá¨¬ã¬ 4096 ¡ ©â)
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = ç¨á«® ¯à®ç¨â ­­ëå ¡ ©â
* eax = ç¨á«® ¯à®ç¨â ­­ëå ¡ ©â (0 ¯à¨ ­¥¢¥à­®¬ åí­¤«¥)
* ebx à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* à®¢¥àª¨ ­  ¯à ¢¨«ì­®áâì åí­¤«  ­¥ ¤¥« ¥âáï.
 
======================================================================
”ã­ªæ¨ï 53, ¯®¤äã­ªæ¨ï 255 - ®â« ¤®ç­ ï ¨­ä®à¬ æ¨ï á¥â¥¢®£® ¤à ©¢¥à .
2808,59 → 2800,6
­¥­ã«¥¢®¥ §­ ç¥­¨¥= ªâ¨¢¥­
 
======================================================================
======== ”ã­ªæ¨ï 55, ¯®¤äã­ªæ¨ï 0 - § £à㧨âì ¤ ­­ë¥ ¤«ï SB16. =======
======================================================================
 à ¬¥âàë:
* eax = 55 - ­®¬¥à ä㭪樨
* ebx = 0 - ­®¬¥à ¯®¤ä㭪樨
* ecx = 㪠§ â¥«ì ­  ¤ ­­ë¥ (ª®¯¨àã¥âáï 64 ª¨«®¡ ©â , ¨á¯®«ì§ã¥âáï
á⮫쪮, ᪮«ìª® ãáâ ­®¢«¥­® ¯®¤ä㭪樥© 2)
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* ”®à¬ â ¨ à §¬¥à ¤ ­­ëå ãáâ ­ ¢«¨¢ îâáï ¯®¤ä㭪樥© 2.
 
======================================================================
==== ”ã­ªæ¨ï 55, ¯®¤äã­ªæ¨ï 1 - ­ ç âì ¯à®¨£à뢠âì ¤ ­­ë¥ ­  SB16. ===
======================================================================
 à ¬¥âàë:
* eax = 55 - ­®¬¥à ä㭪樨
* ebx = 1 - ­®¬¥à ¯®¤ä㭪樨
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* à¥¤¢ à¨â¥«ì­® ¤ ­­ë¥ ¤®«¦­ë ¡ëâì § £à㦥­ë ¯®¤ä㭪樥© 0 ¨
®¯à¥¤¥«ñ­ ¨å ä®à¬ â ¯®¤ä㭪樥© 2.
* ”ã­ªæ¨ï ¢®§¢à é ¥â ã¯à ¢«¥­¨¥, ª®£¤  ­ ç «®áì ¯à®¨£à뢠­¨¥ ¤ ­­ëå;
¯®á«¥ í⮣® ¯à®¨£à뢠­¨¥ ¨¤ñâ ­¥§ ¢¨á¨¬® ®â ¯à¨«®¦¥­¨ï (¨ ¢®®¡é¥
­¥ âॡã¥â § £à㧪¨ ¯à®æ¥áá®à ).
* à¥¤¢ à¨â¥«ì­® ¤®«¦­ë ¡ëâì ®¯à¥¤¥«¥­ë ¡ §®¢ë© ¯®àâ SB16
(¯®¤ä㭪樥© 4 ä㭪樨 21) ¨ ª ­ « DMA
(¯®¤ä㭪樥© 10 ä㭪樨 21).
 
======================================================================
====== ”ã­ªæ¨ï 55, ¯®¤äã­ªæ¨ï 2 - ãáâ ­®¢¨âì ä®à¬ â ¤ ­­ëå SB16. =====
======================================================================
 à ¬¥âàë:
* eax = 55 - ­®¬¥à ä㭪樨
* ebx = 2 - ­®¬¥à ¯®¤ä㭪樨
* ecx = 0 - ãáâ ­®¢¨âì à §à來®áâì
* edx = 1 - 8¡¨â ¬®­®
* edx = 2 - 8¡¨â áâ¥à¥®
* ecx = 1 - ãáâ ­®¢¨âì à §¬¥à ¤ ­­ëå
* edx = à §¬¥à ¢ ¡ ©â å
* ecx = 2 - ãáâ ­®¢¨âì ç áâ®â㠯ந£à뢠­¨ï
* edx = ç áâ®â 
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* à¨ § £à㧪¥ á¨á⥬ë ãáâ ­ ¢«¨¢ îâáï á«¥¤ãî騥 ¯ à ¬¥âàë
¯® 㬮«ç ­¨î: à §à來®áâì - 8 ¡¨â ¬®­®, à §¬¥à - 64 Š¡,
ç áâ®â  44100 ƒæ. ’¥¬ ­¥ ¬¥­¥¥ ४®¬¥­¤ã¥âáï ® ãáâ ­ ¢«¨¢ âì
­¥®¡å®¤¨¬ë¥ §­ ç¥­¨ï, ¯®áª®«ìªã ®­¨ ¬®£«¨ ¡ëâì ¯¥à¥ãáâ ­®¢«¥­ë
ª ª®©-­¨¡ã¤ì ¯à®£à ¬¬®©.
 
======================================================================
====================== ”ã­ªæ¨ï 55, ¯®¤äã­ªæ¨ï 55 =====================
==========  ç âì ¯à®¨£à뢠âì ¤ ­­ë¥ ­  ¢áâ஥­­®¬ ᯨª¥à¥. ==========
======================================================================
3418,7 → 3357,7
* ebx = 㪠§ â¥«ì ­  ¨§®¡à ¦¥­¨¥
* ecx = [à §¬¥à ¯® ®á¨ x]*65536 + [à §¬¥à ¯® ®á¨ y]
* edx = [ª®®à¤¨­ â  ¯® ®á¨ x]*65536 + [ª®®à¤¨­ â  ¯® ®á¨ y]
* esi = ç¨á«® ¡¨â ­  ¯¨ªá¥«ì, ¤®«¦­® ¡ëâì 1, 4, 8, 15, 16, 24 ¨«¨ 32
* esi = ç¨á«® ¡¨â ­  ¯¨ªá¥«ì, ¤®«¦­® ¡ëâì 1,2,4,8,15,16,24 ¨«¨ 32
* edi = 㪠§ â¥«ì ­  ¯ «¨âàã (2 ¢ á⥯¥­¨ esi 梥⮢ 0x00RRGGBB);
¨£­®à¨àã¥âáï ¯à¨ esi > 8
* ebp = ᬥ饭¨¥ ¤ ­­ëå ª ¦¤®© á«¥¤ãî饩 áâப¨ ¨§®¡à ¦¥­¨ï
3428,11 → 3367,14
‡ ¬¥ç ­¨ï:
* Š®®à¤¨­ âë ¨§®¡à ¦¥­¨ï - íâ® ª®®à¤¨­ âë ¢¥àå­¥£® «¥¢®£® 㣫 
¨§®¡à ¦¥­¨ï ®â­®á¨â¥«ì­® ®ª­ .
*  §¬¥à ¨§®¡à ¦¥­¨ï ¢ ¡ ©â å ¥áâì xsize*ysize.
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 1 ¡¨â®¬ ­  ¯¨ªá¥«ì: ª ¦¤ë© ¡ ©â ¨§®¡à ¦¥­¨ï,
§  ¨áª«î祭¨¥¬, ¡ëâì ¬®¦¥â, ¯®á«¥¤­¨å ¡ ©â®¢ áâப, ᮤ¥à¦¨â
¨­ä®à¬ æ¨î ® 梥⥠8 ¯¨ªá¥«¥©, áâ à訩 ¡¨â ᮮ⢥âáâ¢ã¥â ¯¥à¢®¬ã
¯¨ªá¥«î.
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 2 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: ª ¦¤ë© ¡ ©â ¨§®¡à ¦¥­¨ï,
§  ¨áª«î祭¨¥¬, ¡ëâì ¬®¦¥â, ¯®á«¥¤­¨å ¡ ©â®¢ áâப, ᮤ¥à¦¨â
¨­ä®à¬ æ¨î ® 梥⥠4 ¯¨ªá¥«¥©, áâ à訥 ¤¢  ¡¨â  ᮮ⢥âáâ¢ãîâ
¯¥à¢®¬ã ¯¨ªá¥«î.
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 4 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: ª ¦¤ë© ¡ ©â ¨§®¡à ¦¥­¨ï,
§  ¨áª«î祭¨¥¬ ¯®á«¥¤­¨å ¡ ©â®¢ áâப (¥á«¨ è¨à¨­  ¨§®¡à ¦¥­¨ï
­¥çñâ­ ), ᮤ¥à¦¨â ¨­ä®à¬ æ¨î ® 梥⥠2 ¯¨ªá¥«¥©, áâ àè ï â¥âà ¤ 
3439,8 → 3381,6
ᮮ⢥âáâ¢ã¥â ¯¥à¢®¬ã ¯¨ªá¥«î.
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 8 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: ª ¦¤ë© ¡ ©â ¨§®¡à ¦¥­¨ï
à áᬠâਢ ¥âáï ª ª ¨­¤¥ªá ¢ ¯ «¨âà¥.
* …᫨ ¨§®¡à ¦¥­¨¥ ¨á¯®«ì§ã¥â ­¥ ¢á¥ 256 梥⮢,   ¬¥­ìè¥,
à §¬¥à ¯ «¨âàë ¬®¦¥â ¡ëâì ¬¥­ìè¥ 256.
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 15 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: 梥⠪ ¦¤®£® ¯¨ªá¥«ï
ª®¤¨àã¥âáï ª ª (¢ ¡¨â®¢®¬ ¯à¥¤áâ ¢«¥­¨¨) 0RRRRRGGGGGBBBBB -
¯® 5 ¯¨ªá¥«¥© ­  ª ¦¤ë© 梥â.
3447,8 → 3387,8
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 16 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: 梥⠪ ¦¤®£® ¯¨ªá¥«ï
ª®¤¨àã¥âáï ª ª RRRRRGGGGGGBBBBB (á奬  5+6+5).
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 24 ¡¨â ¬¨ ­  ¯¨ªá¥«ì: 梥⠪ ¦¤®£® ¯¨ªá¥«ï
ª®¤¨àã¥âáï âà¥¬ï ¡ ©â ¬¨ - ¯®á«¥¤®¢ â¥«ì­® ᨭïï, §¥«ñ­ ï,
ªà á­ ï á®áâ ¢«ïî騥 梥â .
ª®¤¨àã¥âáï âà¥¬ï ¡ ©â ¬¨ - ¯®á«¥¤®¢ â¥«ì­® ᨭïï, §¥«ñ­ ï, ªà á­ ï
á®áâ ¢«ïî騥 梥â .
* ”®à¬ â ¨§®¡à ¦¥­¨ï á 32 ¡¨â ¬¨ ­  ¯¨ªá¥«ì:  ­ «®£¨ç­® 24, ⮫쪮
¥áâì ¥éñ ¨£­®à¨àã¥¬ë© ç¥â¢ñàâë© ¡ ©â.
* ‚맮¢ ä㭪樨 7 íª¢¨¢ «¥­â¥­ ¢ë§®¢ã í⮩ ä㭪樨 á ¯ à ¬¥âà ¬¨
3814,66 → 3754,59
* ‘®¤¥à¦¨¬®¥ ¯ ¬ï⨠¢¯«®âì ¤® ­ ¨¬¥­ì襣® ¨§ áâ à®£® ¨ ­®¢®£®
à §¬¥à®¢ á®åà ­ï¥âáï.
 
===========================================================================
====== ”ã­ªæ¨ï 68, ¯®¤äã­ªæ¨ï 22 - ®âªàëâì ¨¬¥­®¢ ­ãî ®¡« áâì ¯ ¬ïâ¨. =====
===========================================================================
 
 à ¬¥âàë
======================================================================
=== ”ã­ªæ¨ï 68, ¯®¤äã­ªæ¨ï 22 - ®âªàëâì ¨¬¥­®¢ ­­ãî ®¡« áâì ¯ ¬ïâ¨. ==
======================================================================
 à ¬¥âàë:
* eax = 68 - ­®¬¥à ä㭪樨
* ebx = 22 - ­®¬¥à ¯®¤ä㭪樨
* ecx = ¨¬ï ®¡« áâ¨. Œ ªá¨¬ã¬ 32 ᨬ¢®«  ¢ª«îç ï § ¢¥àè î騩 ­®«ì
* ecx = ¨¬ï ®¡« áâ¨. Œ ªá¨¬ã¬ 31 ᨬ¢®«, ¢ª«îç ï § ¢¥àè î騩 ­®«ì
* edx = à §¬¥à ®¡« á⨠¢ ¡ ©â å ¤«ï SHM_CREATE ¨ SHM_OPEN_ALWAYS
* esi = ä« £¨ ®âªàëâ¨ï ¨ ¤®áâ㯠
 
SHM_OPEN = 0x00
SHM_OPEN_ALWAYS = 0x04
SHM_CREATE = 0x08
SHM_READ = 0x00
SHM_WRITE = 0x01
 
SHM_CREATE - ᮧ¤ âì ­®¢ãî ®¡« áâì ¯ ¬ïâ¨. …᫨ ®¡« áâì á
â ª¨¬ ¨¬¥­¥¬ 㦥 áãé¥áâ¢ã¥â äã­ªæ¨ï ¢¥à­ñâ ª®¤ ®è¨¡ª¨ E_ACCESS
SHM_OPEN_ALWAYS - ®âªà뢠¥â áãé¥áâ¢ãîéãî ¨«¨ ᮧ¤ ñâ ­®¢ãî
* esi = ä« £¨ ®âªàëâ¨ï ¨ ¤®áâ㯠:
* SHM_OPEN = 0x00 - ®âªàëâì áãé¥áâ¢ãîéãî ®¡« áâì ¯ ¬ïâ¨.
…᫨ ®¡« áâì á â ª¨¬ ¨¬¥­¥¬ ­¥ áãé¥áâ¢ã¥â,
äã­ªæ¨ï ¢¥à­ñâ ª®¤ ®è¨¡ª¨ 5.
* SHM_OPEN_ALWAYS = 0x04 - ®âªàëâì áãé¥áâ¢ãîéãî ¨«¨ ᮧ¤ âì ­®¢ãî
®¡« áâì ¯ ¬ïâ¨.
SHM_OPEN - ®âªà뢠¥â áãé¥áâ¢ãîéãî ®¡« áâì ¯ ¬ïâ¨. …᫨
®¡« áâì á â ª¨¬ ¨¬¥­¥¬ ­¥ áãé¥áâ¢ã¥â äã­ªæ¨ï ¢¥à­ñâ ª®¤
®è¨¡ª¨ E_NOTFOUND.
 
SHM_READ - ¤®áâ㯠⮫쪮 ­  ç⥭¨¥.
SHM_WRITE - ¤®áâ㯠­  ç⥭¨¥ ¨ § ¯¨áì.
 
‚®§¢à é ¥¬ë¥ §­ ç¥­¨ï:
* eax = 㪠§ â¥«ì ­  ®¡« áâì ¯ ¬ï⨠¨«¨ ­®«ì ¢ á«ãç ¥ ®è¨¡ª¨
* edx = ¥á«¨ ­®¢ ï ®¡« áâì ᮧ¤ ñâáï SHM_CREATE ¨«¨ SHM_OPEN_ALWAYS
­®«ì ¢ á«ãç ¥ ãá¯¥å  ¨«¨ ª®¤ ®è¨¡ª¨.
¥á«¨ áãé¥áâ¢ãîé ï ®¡« áâì ®âªà뢠¥âáï SHM_OPEN ¨«¨ SHM_OPEN_ALWAYS
à §¬¥à ®¡« á⨠¢ ¡ ©â å ¨«¨ ª®¤ ®è¨¡ª¨
 
* SHM_CREATE = 0x08 - ᮧ¤ âì ­®¢ãî ®¡« áâì ¯ ¬ïâ¨.
…᫨ ®¡« áâì á â ª¨¬ ¨¬¥­¥¬ 㦥 áãé¥áâ¢ã¥â,
äã­ªæ¨ï ¢¥à­ñâ ª®¤ ®è¨¡ª¨ 10.
* SHM_READ = 0x00 - ¤®áâ㯠⮫쪮 ­  ç⥭¨¥
* SHM_WRITE = 0x01 - ¤®áâ㯠­  ç⥭¨¥ ¨ § ¯¨áì
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* eax = 㪠§ â¥«ì ­  ®¡« áâì ¯ ¬ïâ¨, 0 ¯à¨ ®è¨¡ª¥
* ¯à¨ ᮧ¤ ­¨¨ ­®¢®© ®¡« á⨠(SHM_CREATE ¨«¨ SHM_OPEN_ALWAYS):
edx = 0 - ãᯥå, ¨­ ç¥ - ª®¤ ®è¨¡ª¨
* ¯à¨ ®âªàë⨨ áãé¥áâ¢ãî饩 ®¡« á⨠(SHM_OPEN ¨«¨ SHM_OPEN_ALWAYS):
edx = ª®¤ ®è¨¡ª¨ (¯à¨ eax=0) ¨«¨ à §¬¥à ®¡« á⨠¢ ¡ ©â å
Š®¤ë ®è¨¡®ª:
* E_NOTFOUND = 5
* E_ACCESS = 10
* E_NOMEM = 30
* E_PARAM = 33
 
‡ ¬¥ç ­¨ï:
* …᫨ ᮧ¤ ñâáï ­®¢ ï ®¡« áâì â® ä« £¨ ¤®áâ㯠 ãáâ ­ ¢«¨¢ îâ
¬ ªá¨¬ «ì­ë¥ ¯à ¢  ¤®áâ㯠 ¤«ï ®áâ «ì­ëå ¯à®æ¥áᮢ.
* ®¤¨â¥«ì᪨© ¯à®æ¥áá ¢á¥£¤  ¨¬¥¥â ¤®áâ㯠­  § ¯¨áì.
* …᫨ ᮧ¤ ñâáï ­®¢ ï ®¡« áâì, â® ä« £¨ ¤®áâ㯠 ãáâ ­ ¢«¨¢ îâ
¬ ªá¨¬ «ì­ë¥ ¯à ¢  ¤®áâ㯠 ¤«ï ®áâ «ì­ëå ¯à®æ¥áᮢ. ®¯ë⪠
®âªàëâ¨ï ¤à㣨¬ ¯®â®ª®¬ á ­¥à §à¥èñ­­ë¬¨ ¯à ¢ ¬¨ ¯à®¢ «¨âáï
á ª®¤®¬ ®è¨¡ª¨ E_ACCESS.
* à®æ¥áá, ᮧ¤ ¢è¨© ®¡« áâì, ¢á¥£¤  ¨¬¥¥â ¤®áâ㯠­  § ¯¨áì.
 
 
===========================================================================
====== ”ã­ªæ¨ï 68, ¯®¤äã­ªæ¨ï 23 - § ªàëâì ¨¬¥­®¢ ­ãî ®¡« áâì ¯ ¬ïâ¨. =====
===========================================================================
 
 à ¬¥âàë
======================================================================
=== ”ã­ªæ¨ï 68, ¯®¤äã­ªæ¨ï 23 - § ªàëâì ¨¬¥­®¢ ­­ãî ®¡« áâì ¯ ¬ïâ¨. ==
======================================================================
 à ¬¥âàë:
* eax = 68 - ­®¬¥à ä㭪樨
* ebx = 23 - ­®¬¥à ¯®¤ä㭪樨
* ecx = ¨¬ï ®¡« áâ¨. Œ ªá¨¬ã¬ 32 ᨬ¢®«  ¢ª«îç ï § ¢¥àè î騩 ­®«ì
 
* ecx = ¨¬ï ®¡« áâ¨. Œ ªá¨¬ã¬ 31 ᨬ¢®«, ¢ª«îç ï § ¢¥àè î騩 ­®«ì
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* ­¥ ®¯à¥¤¥«¥­®
* eax à §àãè ¥âáï
‡ ¬¥ç ­¨ï:
* Ž¡« áâì ¯ ¬ï⨠䨧¨ç¥áª¨ ®á¢®¡®¦¤ ¥âáï (á § ¡ë¢ ­¨¥¬ ¢á¥å ¤ ­­ëå
¨ ¢ë᢮¡®¦¤¥­¨¥¬ 䨧¨ç¥áª®© ¯ ¬ïâ¨), ª®£¤  ¥ñ § ªà®îâ
¢á¥ ®âªàë¢è¨¥ ¯®â®ª¨.
* à¨ § ¢¥à襭¨¨ ¯®â®ª  ®á¢®¡®¦¤ îâáï ¢á¥ ®âªàëâë¥ ¨¬
®¡« á⨠¯ ¬ïâ¨.
 
 
======================================================================
======================== ”ã­ªæ¨ï 69 - ®â« ¤ª . =======================
======================================================================
3907,8 → 3840,8
…᫨ ®â« ¤ç¨ª í⮣® ­¥ å®ç¥â, ®­ ¤®«¦¥­ ¯à¥¤¢ à¨â¥«ì­® ®âª«îç¨âìáï
¯®¤ä㭪樥© 3.
 
‚ᥠ¯®¤ä㭪樨, ªà®¬¥ 4 ¨ 5, ¯à¨¬¥­¨¬ë ⮫쪮 ª ¯à®æ¥áá ¬/¯®â®ª ¬,
§ ¯ã饭­ë¬ ¨§ ⥪ã饣® ä㭪樥© 70 á ãáâ ­®¢«¥­­ë¬ ä« £®¬ ®â« ¤ª¨.
‚ᥠ¯®¤ä㭪樨 ¯à¨¬¥­¨¬ë ⮫쪮 ª ¯à®æ¥áá ¬/¯®â®ª ¬, § ¯ã饭­ë¬
¨§ ⥪ã饣® ä㭪樥© 70 á ãáâ ­®¢«¥­­ë¬ ä« £®¬ ®â« ¤ª¨.
Žâ« ¤ª  ¬­®£®¯®â®ç­ëå ¯à®£à ¬¬ ¯®ª  ­¥ ¯®¤¤¥à¦¨¢ ¥âáï.
®«­ë© ᯨ᮪ ¯®¤ä㭪権:
* ¯®¤äã­ªæ¨ï 0 - ®¯à¥¤¥«¨âì ®¡« áâì ¤ ­­ëå ¤«ï ®â« ¤®ç­ëå á®®¡é¥­¨©
4006,7 → 3939,7
* …᫨ ¯à®æ¥áá ¡ë« ¯à¨®áâ ­®¢«¥­, ®­ ¢®§®¡­®¢«ï¥â ¢ë¯®«­¥­¨¥.
 
======================================================================
=========== ”ã­ªæ¨ï 69, ¯®¤äã­ªæ¨ï 4 - ¯à¨®áâ ­®¢¨âì ¯®â®ª. ==========
==== ”ã­ªæ¨ï 69, ¯®¤äã­ªæ¨ï 4 - ¯à¨®áâ ­®¢¨âì ®â« ¦¨¢ ¥¬ë© ¯®â®ª. ====
======================================================================
 à ¬¥âàë:
* eax = 69 - ­®¬¥à ¯à®æ¥áá 
4014,10 → 3947,13
* ecx = ¨¤¥­â¨ä¨ª â®à
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* à®æ¥áá ¤®«¦¥­ ¡ëâì § £à㦥­ ¤«ï ®â« ¤ª¨ (ª ª 㪠§ ­® ¢
®¡é¥¬ ®¯¨á ­¨¨).
 
======================================================================
====================== ”ã­ªæ¨ï 69, ¯®¤äã­ªæ¨ï 5 ======================
=================== ‚®§®¡­®¢¨âì ¢ë¯®«­¥­¨¥ ¯®â®ª . ===================
============ ‚®§®¡­®¢¨âì ¢ë¯®«­¥­¨¥ ®â« ¦¨¢ ¥¬®£® ¯®â®ª . ============
======================================================================
 à ¬¥âàë:
* eax = 69 - ­®¬¥à ä㭪樨
4025,6 → 3961,9
* ecx = ¨¤¥­â¨ä¨ª â®à
‚®§¢à é ¥¬®¥ §­ ç¥­¨¥:
* äã­ªæ¨ï ­¥ ¢®§¢à é ¥â §­ ç¥­¨ï
‡ ¬¥ç ­¨ï:
* à®æ¥áá ¤®«¦¥­ ¡ëâì § £à㦥­ ¤«ï ®â« ¤ª¨ (ª ª 㪠§ ­® ¢
®¡é¥¬ ®¯¨á ­¨¨).
 
======================================================================
====================== ”ã­ªæ¨ï 69, ¯®¤äã­ªæ¨ï 6 ======================
/kernel/trunk/docs/sysfuncs.txt
1,4 → 1,4
SYSTEM FUNCTIONS of OS Kolibri 0.7.1.0
SYSTEM FUNCTIONS of OS Kolibri 0.7.5.0
 
Number of the function is located in the register eax.
The call of the system function is executed by "int 0x40" command.
219,9 → 219,6
and does not make any operations at all. If it is really required
to transfer control to the next process (to complete a current
time slice), use subfunction 1 of function 68.
* At current implementation there will be an immediate return from
the function, if the addition of ebx with current value of
time counter will call 32-bit overflow.
 
======================================================================
============== Function 6 - read the file from ramdisk. ==============
613,16 → 610,20
* eax = 17 - function number
Returned value:
* if the buffer is empty, function returns eax=1
* if the buffer is not empty, function returns:
high 24 bits of eax contain button identifier (in particular, ah
contains low byte of the identifier; if all buttons have
the identifier less than 256, ah is enough to distinguish),
and al contain 0 - if used left mouse button or bit of the used another mouse button
* if the buffer is not empty:
* high 24 bits of eax contain button identifier (in particular,
ah contains low byte of the identifier; if all buttons have
the identifier less than 256, ah is enough to distinguish)
* al = 0 - the button was pressed with left mouse button
* al = bit corresponding to used mouse button otherwise
Remarks:
* "Buffer" keeps only one button, at pressing the new button the
information about old is lost.
* The call of this function by an application with inactive window
will return answer "buffer is empty".
* Returned value for al corresponds to the state of mouse buttons
as in subfunction 2 of function 37 at the beginning
of button press, excluding lower bit, which is cleared.
 
======================================================================
= Function 18, subfunction 2 - terminate process/thread by the slot. =
731,7 → 732,7
* function does not return value
 
======================================================================
============ Function 18, subfunction 9 - system shutdown. ===========
== Function 18, subfunction 9 - system shutdown with the parameter. ==
======================================================================
Parameters:
* eax = 18 - function number
747,8 → 748,7
Remarks:
* Do not rely on returned value by incorrect call, it can be
changed in future versions of the kernel.
* It is possible to use subfunction 1, that on the last step
the user makes choice himself.
 
======================================================================
===== Function 18, subfunction 10 - minimize application window. =====
======================================================================
1127,11 → 1127,6
* To get CD base use subfunction 3 of function 26.
 
======================================================================
====== Function 21, subfunction 4 - set Sound Blaster base port. =====
======================================================================
Removed
 
======================================================================
========== Function 21, subfunction 5 - set system language. =========
======================================================================
Parameters:
1192,11 → 1187,6
* It is also necessary to define used HD base by subfunction 7.
 
======================================================================
======== Function 21, subfunction 10 - set sound DMA channel. ========
======================================================================
Removed
 
======================================================================
Function 21, subfunction 11 - enable/disable low-level access to HD.
======================================================================
Parameters:
1484,11 → 1474,6
* An example of usage of the function is the application CD_tray.
 
======================================================================
=================== Function 25 - set SBPro volume. ==================
======================================================================
Removed
 
======================================================================
======== Function 26, subfunction 1 - get MPU MIDI base port. ========
======================================================================
Parameters:
1548,11 → 1533,6
* To set CD base use subfunction 3 of function 21.
 
======================================================================
====== Function 26, subfunction 4 - get Sound Blaster base port. =====
======================================================================
Removed
 
======================================================================
========== Function 26, subfunction 5 - get system language. =========
======================================================================
Parameters:
1615,11 → 1595,6
* To get system time use function 3.
 
======================================================================
======== Function 26, subfunction 10 - get sound DMA channel. ========
======================================================================
Removed
 
======================================================================
===================== Function 26, subfunction 11 ====================
========== Find out whether low-level HD access is enabled. ==========
======================================================================
1647,11 → 1622,6
* To set the current state use subfunction 12 of function 21.
 
======================================================================
=================== Function 28 - set SB16 volume. ===================
======================================================================
Removed
 
======================================================================
=================== Function 29 - get system date. ===================
======================================================================
Parameters:
1690,6 → 1660,56
bytes are copied and than terminating 0 is inserted.
 
======================================================================
=============== Function 32 - delete file from ramdisk. ==============
======================================================================
Parameters:
* eax = 32 - function number
* ebx = pointer to the filename
Returned value:
* eax = 0 - success; otherwise file system error code
Remarks:
* This function is obsolete; function 58 allows to fulfill
the same operations with the extended possibilities.
* The current implementation returns only values 0(success) and
5(file not found).
* The filename must be either in the format 8+3 characters
(first 8 characters - name itself, last 3 - extension,
the short names and extensions are supplemented with spaces),
or in the format 8.3 characters "FILE.EXT"/"FILE.EX "
(name no more than 8 characters, dot, extension 3 characters
supplemented if necessary by spaces).
The filename must be written with capital letters. The terminating
character with code 0 is not necessary (not ASCIIZ-string).
* This function does not support folders on the ramdisk.
 
======================================================================
================ Function 33 - write file to ramdisk. ================
======================================================================
Parameters:
* eax = 33 - function number
* ebx = pointer to the filename
* ecx = pointer to data for writing
* edx = number of bytes for writing
* should be set esi=0
Returned value:
* eax = 0 - success, otherwise file system error code
Remarks:
* This function is obsolete; function 70 allows to fulfil
the same operations with extended possibilities.
* If esi contains non-zero value and selected file already exists,
one more file with the same name will be created.
* Otherwise file will be overwritten.
* The filename must be either in the format 8+3 characters
(first 8 characters - name itself, last 3 - extension,
the short names and extensions are supplemented with spaces),
or in the format 8.3 characters "FILE.EXT"/"FILE.EX "
(name no more than 8 characters, dot, extension 3 characters
supplemented if necessary by spaces).
The filename must be written with capital letters. The terminating
character with code 0 is not necessary (not ASCIIZ-string).
* This function does not support folders on the ramdisk.
 
======================================================================
======= Function 35 - read the color of a pixel on the screen. =======
======================================================================
Parameters:
1707,11 → 1727,11
the current videomode, use function 61.
 
======================================================================
=============== Function 36 - read screen area. ===============
=================== Function 36 - read screen area. ==================
======================================================================
Paramters:
* eax = 36 - function number
* ebx = pointer on the previously allocated area of memory,
* ebx = pointer to the previously allocated memory area,
where will be placed the image in the format BBGGRRBBGGRR...
* ecx = [size on axis x]*65536 + [size on axis y]
* edx = [coordinate on axis x]*65536 + [coordinate on axis y]
1915,45 → 1935,36
* eax = -1 for incorrect ebx
 
======================================================================
==================== Function 42 - work with IRQ data. ===============
================== Function 42 - work with IRQ data. =================
======================================================================
 
------------------------ Reading data --------------------------------
 
When an IRQ occurs, the system reads data from ports indicated
earlier by function 44 and writes this data to
internal buffer. This function reads out data from that buffer
to the buffer specified as parameter.
internal buffer. This function reads out data from that buffer.
 
--------------------- Subfunction 0 - read data ----------------------
Parameters:
* eax = 42 - function number
* bl = IRQ number, 0..15
* bh = subfunction number, 0
Other part of register ebx, must be zero.
* ecx = pointer to the receive buffer
* bh = 0 - subfunction number
* rest of ebx must be zeroed
* ecx = pointer to a buffer with size not less than 4000 bytes
Returned value: (use value of eax to distinguish)
* if the thread is not IRQ owner (or IRQ number is incorrect):
* eax = -1
* if there is no data:
* eax = 0
* if the thread is not IRQ owner
(or IRQ number is incorrect): eax = -1
* if there is no data: eax = 0
* if all is ok:
* eax = byte size of data, read from buffer
eax = size of data read (in bytes)
 
See remarks below.
 
------------------------ Get data size -------------------------------
 
------------- Subfunction 1 - get size of data in buffer -------------
Parameters:
* eax = 42 - function number
* bl = IRQ number, 0..15
* bh = subfunction number, 0
Other part of register ebx, must be zero.
* ecx = pointer to receive buffer
Returned value: (use value of eax to distinguish)
* if the thread is not IRQ owner (or IRQ number is incorrect):
* eax = -1
* if all is ok:
* eax = byte size of data in buffer
 
* bh = 0 - subfunction number
* rest of ebx must be zeroed
Returned value:
* if the thread is not IRQ owner
(or IRQ number is incorrect): eax = -1
* otherwise eax = size of data in buffer
Remarks:
* Previously the thread must reserve indicated IRQ for itself
by function 45.
2578,9 → 2589,6
sockets of a thread at termination. In particular, one should not
kill a thread with many opened sockets - there will be an outflow
of resources.
* The current implementation does no checks on correctness
(function returns error only if thread tries to close not opened
socket with correct handle).
 
======================================================================
============== Function 53, subfunction 2 - poll socket. =============
2590,10 → 2598,8
* ebx = 2 - subfunction number
* ecx = socket handle
Returned value:
* eax = number of read bytes
* eax = number of read bytes, 0 for incorrect handle
* ebx destroyed
Remarks:
* There is no checks for correctness.
 
======================================================================
========= Function 53, subfunction 3 - read byte from socket. ========
2603,12 → 2609,10
* ebx = 3 - subfunction number
* ecx = socket handle
Returned value:
* if there is no read data: eax=0, bl=0,
* if there is no read data or handle is incorrect: eax=0, bl=0,
other bytes of ebx are destroyed
* if there are read data: eax=number of rest bytes
(possibly 0), bl=read byte, other bytes of ebx are destroyed
Remarks:
* There is no checks for correctness.
 
======================================================================
========== Function 53, subfunction 4 - write to UDP-socket. =========
2620,13 → 2624,10
* edx = number of bytes to write
* esi = pointer to data to write
Returned value:
* eax = 0xffffffff - invalid handle
* eax = 0xffff - not enough memory
* eax = 0xffffffff - error (invalid handle or not enough memory)
* eax = 0 - success
* ebx destroyed
Remarks:
* Check on validity of handle is minimal - only not very incorrect
not opened handles are eliminated.
* Number of bytes to write must not exceed 1500-28, though
the appropriate check is not made.
 
2654,7 → 2655,7
* ebx = 6 - subfunction number
* ecx = socket handle
Returned value:
* eax = socket status: one of
* eax = 0 for incorrect handle or socket status: one of
* TCB_LISTEN = 1
* TCB_SYN_SENT = 2
* TCB_SYN_RECEIVED = 3
2666,9 → 2667,7
* TCB_LAST_ASK = 9
* TCB_TIME_WAIT = 10
* TCB_CLOSED = 11
* ebx destroys
Remarks:
* There is no checks for correctness.
* ebx destroyed
 
======================================================================
========== Function 53, subfunction 7 - write to TCP-socket. =========
2680,13 → 2679,10
* edx = number of bytes to write
* esi = pointer to data to write
Returned value:
* eax = 0xffffffff - error
* eax = 0xffff - not enough memory
* eax = 0xffffffff - error (invalid handle or not enough memory)
* eax = 0 - success
* ebx destroyed
Remarks:
* Check on validity of handle is minimal - only not very incorrect
not opened handles are eliminated.
* Number of bytes to write must not exceed 1500-40, though
the appropriate check is not made.
 
2698,11 → 2694,9
* ebx = 8 - subfunction number
* ecx = socket handle
Returned value:
* eax = -1 - invalid handle
* eax = 0xffff - not enough memory for socket close packet
* eax = -1 - error (invalid handle or
not enough memory for socket close packet)
* eax = 0 - success
* in many cases eax is destroyed (the result of function 'queue'
is returned) - probably this is bug, which will be corrected
* ebx destroyed
Remarks:
* The current implementation does not close automatically all
2709,9 → 2703,6
sockets of a thread at termination. In particular, one should not
kill a thread with many opened sockets - there will be an outflow
of resources.
* The current implementation does no checks on correctness
(function returns error only if thread tries to close not opened
socket with correct handle).
 
======================================================================
=== Function 53, subfunction 9 - check whether local port is free. ===
2752,10 → 2743,8
* esi = number of bytes to read;
* esi = 0 - read all data (maximum 4096 bytes)
Returned value:
* eax = number of bytes read
* eax = number of bytes read (0 for incorrect handle)
* ebx destroyed
Remakrs:
* There is no check on handle correctness.
 
======================================================================
= Function 53, subfunction 255 - debug information of network driver.
2789,58 → 2778,6
* 6: status of packet driver, 0=inactive, nonzero=active
 
======================================================================
========== Function 55, subfunction 0 - load data for SB16. ==========
======================================================================
Parameters:
* eax = 55 - function number
* ebx = 0 - subfunction number
* ecx = pointer to data (is copied 64 kilobytes, is used as much as
set by subfunction 2)
Returned value:
* function does not return value
Remarks:
* Format and size of data are set by subfunction 2.
 
======================================================================
======== Function 55, subfunction 1 - begin play data on SB16. =======
======================================================================
Parameters:
* eax = 55 - function number
* ebx = 1 - subfunction number
Returned value:
* function does not return value
Remarks:
* Previously data must be loaded by subfunction 0 and
their format must be defined by subfunction 2.
* Function returns control, when playing of data began; after that
play goes independently from application (and does not use
processor time at all).
* Previously must be defined SB16 base port
(by subfunction 4 of function 21) and DMA channel
(by subfunction 10 of function 21).
 
======================================================================
======== Function 55, subfunction 2 - set format of SB16 data. =======
======================================================================
Parameters:
* eax = 55 - function number
* ebx = 2 - subfunction number
* ecx = 0 - set digit capacity
* edx = 1 - 8bit mono
* edx = 2 - 8bit stereo
* ecx = 1 - set data size
* edx = size in bytes
* ecx = 2 - set play frequency
* edx = frequency
Returned value:
* function does not return value
Remarks:
* When the system boots, it sets following default parameters:
digit capacity - 8bit mono, size - 64 Kb, frequency - 44100 Hz.
Nevertheless it is recommended to set necessary values obviously
as they could be reset by some application.
 
======================================================================
Function 55, subfunction 55 - begin to play data on built-in speaker.
======================================================================
Parameters:
3391,9 → 3328,9
* ebx = pointer to the image
* ecx = [size on axis x]*65536 + [size on axis y]
* edx = [coordinate on axis x]*65536 + [coordinate on axis y]
* esi = number of bits per pixel, must be 8, 24 or 32
* edi = pointer to palette (256 colors 0x00RRGGBB);
ignored when esi = 24 and 32
* esi = number of bits per pixel, must be 1,2,4,8,15,16,24 or 32
* edi = pointer to palette (2 to the power esi colors 0x00RRGGBB);
ignored when esi > 8
* ebp = offset of next row data relative to previous row data
Returned value:
* function does not return value
3400,10 → 3337,27
Remarks:
* Coordinates of the image are coordinates of the upper left corner
of the image relative to the window.
* Size of the image in bytes is xsize*ysize.
* Each byte of image is index in the palette.
* If the image uses less than 256 colors, palette size may be
less than 256 too.
* Format of image with 1 bit per pixel: each byte of image
(possibly excluding last bytes in rows), contains information on
the color of 8 pixels, MSB corresponds to first pixel.
* Format of image with 2 bits per pixel: each byte of image
(possibly excluding last bytes in rows), contains information on
the color of 4 pixels, two MSBs correspond to first pixel.
* Format of image with 4 bits per pixel: each byte of image
excluding last bytes in rows (if width is odd) contains
information on the color of 2 pixels, high-order tetrad
corresponds to first pixel.
* Format of image with 8 bits per pixel: each byte of image is
index in the palette.
* Format of image with 15 bits per pixel: the color of each pixel
is coded as (bit representation) 0RRRRRGGGGGBBBBB - 5 bits per
each color.
* Format of image with 16 bits per pixel: the color of each pixel
is coded as RRRRRGGGGGGBBBBB (5+6+5).
* Format of image with 24 bits per pixel: the color of each pixel
is coded as 3 bytes - sequentially blue, green, red components.
* Format of image with 32 bits per pixel: similar to 24, but
one additional ignored byte is present.
* The call to function 7 is equivalent to call to this function
with esi=24, ebp=0.
 
3770,43 → 3724,6
the new and old sizes.
 
======================================================================
======= Function 68, subfunction 22 - open memory block. =======
======================================================================
Parameters:
* eax = 68 - function number
* ebx = 22 - subfunction number
* ecx = pointer to already allocated block (max 32 symbols)
* edx = block's size in bytes for SHM_CREATE and SHM_OPEN_ALWAYS
* esi = flags for opening and getting access
SHM_OPEN = 0x00
SHM_OPEN_ALWAYS = 0x04
SHM_CREATE = 0x08
SHM_READ = 0x00
SHM_WRITE = 0x01
Returned value:
* eax = pointer to the readed block, 0 = error
* edx = if SHM_CREATE, SHM_OPEN, or SHM_OPEN_ALWAYS active
Error codes:
* E_NOTFOUND = 5
* E_ACCESS = 10
* E_NOMEM = 30
* E_PARAM = 33
Remarks:
*
*
 
======================================================================
======= Function 68, subfunction 22 - close memory block. =======
======================================================================
Parameters:
* eax = 68 - function number
* ebx = 23 - subfunction number
* ecx = pointer to already allocated block (max 32 symbols)
 
Returned value:
* not defined
 
======================================================================
====================== Fucntion 69 - debugging. ======================
======================================================================
A process can load other process as debugged by set of corresponding
3837,9 → 3754,8
If debugger does not want this, it must previously detach by
subfunction 3.
 
All subfunctions except 4 and 5 are applicable only to
processes/threads started from the current by function 70
with set debugging flag.
All subfunctions are applicable only to processes/threads started
from the current by function 70 with set debugging flag.
Debugging of multithreaded programs is not supported yet.
The full list of subfunctions:
* subfunction 0 - define data area for debug messages
3937,7 → 3853,7
* If the process was suspended, it resumes execution.
 
======================================================================
============= Function 69, subfunction 4 - suspend thread. ===========
======== Function 69, subfunction 4 - suspend debugged thread. =======
======================================================================
Parameters:
* eax = 69 - function number
3945,9 → 3861,12
* ecx = thread identifier
Returned value:
* function does not return value
Remarks:
* Process must be loaded for debugging (as is shown in
general description).
 
======================================================================
============= Function 69, subfunction 5 - resume thread. ============
======== Function 69, subfunction 5 - resume debugged thread. ========
======================================================================
Parameters:
* eax = 69 - function number
3955,6 → 3874,9
* ecx = thread identifier
Returned value:
* function does not return value
Remarks:
* Process must be loaded for debugging (as is shown in
general description).
 
======================================================================
= Fucntion 69, subfunction 6 - read from memory of debugged process. =
/kernel/trunk/kernel.asm
113,7 → 113,7
org 0x0
jmp start_of_code
 
version db 'Kolibri OS version 0.7.1.0 ',13,10,13,10,0
version db 'Kolibri OS version 0.7.5.0 ',13,10,13,10,0
 
include "boot/bootstr.inc" ; language-independent boot messages
include "boot/preboot.inc"
2186,7 → 2186,7
 
iglobal
version_inf:
db 0,7,1,0 ; version 0.7.1.0
db 0,7,5,0 ; version 0.7.5.0
db UID_KOLIBRI
dd __REV__
version_end:
4297,7 → 4297,9
 
align 16
putimage_get24bpp:
mov eax, [esi]
movzx eax, byte [esi+2]
shl eax, 16
mov ax, [esi]
add esi, 3
ret 4
align 16