Subversion Repositories Kolibri OS

Rev

Rev 746 | Rev 750 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1.  
  2. struc VBE_VGAInfo {
  3.   .VESASignature          dd ?    ; char
  4.   .VESAVersion            dw ?    ; short
  5.   .OemStringPtr           dd ?    ; char *
  6.   .Capabilities           dd ?    ; ulong
  7.   .VideoModePtr           dd ?    ; ulong
  8.   .TotalMemory            dw ?    ; short
  9.   ; VBE 2.0+
  10.   .OemSoftwareRev         db ?    ; short
  11.   .OemVendorNamePtr       dw ?    ; char *
  12.   .OemProductNamePtr      dw ?    ; char *
  13.   .OemProductRevPtr       dw ?    ; char *
  14.   .reserved               rb 222  ; char
  15.   .OemData                rb 256  ; char
  16. }
  17.  
  18. struc VBE_ModeInfo {
  19.   .ModeAttributes         dw ?    ; short
  20.   .WinAAttributes         db ?    ; char
  21.   .WinBAttributes         db ?    ; char
  22.   .WinGranularity         dw ?    ; short
  23.   .WinSize                dw ?    ; short
  24.   .WinASegment            dw ?    ; ushort
  25.   .WinBSegment            dw ?    ; ushort
  26.   .WinFuncPtr             dd ?    ; void *
  27.   .BytesPerScanLine       dw ?    ; short
  28.   .XRes                   dw ?    ; short
  29.   .YRes                   dw ?    ; short
  30.   .XCharSize              db ?    ; char
  31.   .YCharSize              db ?    ; char
  32.   .NumberOfPlanes         db ?    ; char
  33.   .BitsPerPixel           db ?    ; char
  34.   .NumberOfBanks          db ?    ; char
  35.   .MemoryModel            db ?    ; char
  36.   .BankSize               db ?    ; char
  37.   .NumberOfImagePages     db ?    ; char
  38.   .res1                   db ?    ; char
  39.   .RedMaskSize            db ?    ; char
  40.   .RedFieldPosition       db ?    ; char
  41.   .GreenMaskSize          db ?    ; char
  42.   .GreenFieldPosition     db ?    ; char
  43.   .BlueMaskSize           db ?    ; char
  44.   .BlueFieldPosition      db ?    ; char
  45.   .RsvedMaskSize          db ?    ; char
  46.   .RsvedFieldPosition     db ?    ; char
  47.   .DirectColorModeInfo    db ?    ; char ; MISSED IN THIS TUTORIAL!! SEE ABOVE
  48.   ; VBE 2.0+
  49.   .PhysBasePtr            dd ?    ; ulong
  50.   .OffScreenMemOffset     dd ?    ; ulong
  51.   .OffScreenMemSize       dw ?    ; short
  52.   ; VBE 3.0+
  53.   .LinbytesPerScanLine    dw ?    ; short
  54.   .BankNumberOfImagePages db ?    ; char
  55.   .LinNumberOfImagePages  db ?    ; char
  56.   .LinRedMaskSize         db ?    ; char
  57.   .LinRedFieldPosition    db ?    ; char
  58.   .LingreenMaskSize       db ?    ; char
  59.   .LinGreenFieldPosition  db ?    ; char
  60.   .LinBlueMaskSize        db ?    ; char
  61.   .LinBlueFieldPosition   db ?    ; char
  62.   .LinRsvdMaskSize        db ?    ; char
  63.   .LinRsvdFieldPosition   db ?    ; char
  64.   .MaxPixelClock          dd ?    ; ulong
  65.   .res2                   rb 190  ; char
  66. }
  67.  
  68. virtual at $A000
  69.   vi VBE_VGAInfo
  70.   mi VBE_ModeInfo
  71. modes_table:
  72. end virtual
  73. cursor_pos  dw 0         ;âðåìåííîå õðàíåíèå êóðñîðà.
  74. home_cursor dw 0    ;current shows rows a table
  75. end_cursor  dw 0     ;end of position current shows rows a table
  76. long_v_table equ 9   ;long of visible video table
  77. size_of_step equ 10
  78. scroll_area_size equ (long_v_table-2)
  79. int2str:
  80.         dec     bl
  81.         jz      @f
  82.         xor     edx,edx
  83.         div     ecx
  84.         push    edx
  85.         call    int2str
  86.         pop     eax
  87.     @@: or      al,0x30
  88.         mov     [ds:di],al
  89.         inc     di
  90.         ret
  91.  
  92. int2strnz:
  93.         cmp     eax,ecx
  94.         jb      @f
  95.         xor     edx,edx
  96.         div     ecx
  97.         push    edx
  98.         call    int2strnz
  99.         pop     eax
  100.     @@: or      al,0x30
  101.         mov     [es:di],al
  102.         inc     di
  103.         ret
  104. ;-------------------------------------------------------
  105. ;Write message about incorrect v_mode and write message about jmp on swith v_mode
  106. v_mode_error:
  107.         _setcursor 19,2
  108.         mov     si, fatalsel
  109.         call    printplain
  110.         _setcursor 20,2
  111.         mov     si,pres_key
  112.         call    printplain
  113.         xor     eax,eax
  114.         int     16h
  115.         jmp     cfgmanager.d
  116. ;-------------------------------------------------------
  117. ;
  118.  
  119.  
  120.  
  121. ;-------------------------------------------------------
  122. print_vesa_info:
  123.         _setcursor 5,2
  124.  
  125.         mov     [es:vi.VESASignature],'VBE2'
  126.         mov     ax,0x4F00
  127.         mov     di,vi      ;0xa000
  128.         int     0x10
  129.         or      ah,ah
  130.         jz      @f
  131.         mov     [es:vi.VESASignature],'VESA'
  132.         mov     ax,$4F00
  133.         mov     di,vi
  134.         int     0x10
  135.         or      ah,ah
  136.         jnz     .exit
  137.   @@:
  138.         cmp     [es:vi.VESASignature],'VESA'
  139.         jne     .exit
  140.         cmp     [es:vi.VESAVersion],0x0100
  141.         jb      .exit
  142.         jmp     .vesaok2
  143.  
  144.   .exit:
  145.         mov     si,novesa
  146.         call    printplain
  147.         ret
  148.  
  149.   .vesaok2:
  150.         mov     ax,[es:vi.VESAVersion]
  151.         add     ax,'00'
  152.  
  153.         mov     [s_vesa.ver], ah
  154.         mov     [s_vesa.ver+2], al
  155.         mov     si,s_vesa
  156.         call    printplain
  157.  
  158.         _setcursor 4,2
  159.         mov     si,word[es:vi.OemStringPtr]
  160.         mov     di,si
  161.  
  162.         push    ds
  163.         mov     ds,word[es:vi.OemStringPtr+2]
  164.         call    printplain
  165.         pop     ds
  166.  
  167.         ret
  168. ;-----------------------------------------------------------------------------
  169.  
  170. calc_vmodes_table:
  171.         pushad
  172.  
  173. ;        push    0
  174. ;        pop     es
  175.  
  176.         lfs     si, [es:vi.VideoModePtr]
  177.  
  178.         mov     bx,modes_table
  179. ;save no vesa mode of work 320x200, EGA/CGA 256 梥⮢ and 640x480, VGA 16 梥⮢
  180.         mov     word [es:bx],640
  181.         mov     word [es:bx+2],480
  182.         mov     word [es:bx+6],0x13
  183.        
  184.         mov     word [es:bx+10],640
  185.         mov     word [es:bx+12],480
  186.         mov     word [es:bx+16],0x12
  187.         add     bx,20
  188.   .next_mode:
  189.         mov     cx,word [fs:si] ; mode number
  190.         cmp     cx,-1
  191.         je      .modes_ok.2
  192.  
  193.         mov     ax,0x4F01
  194.         mov     di,mi
  195.         int     0x10
  196.  
  197.         or      ah,ah
  198.         jnz     .modes_ok.2;vesa_info.exit
  199.  
  200.         test    [es:mi.ModeAttributes],00000001b   ;videomode support ?
  201.         jz      @f
  202.         test    [es:mi.ModeAttributes],00010000b   ;picture ?
  203.         jz      @f
  204.         test    [es:mi.ModeAttributes],10000000b   ;LFB ?
  205.         jz      @f
  206.  
  207. ;        cmp     [es:mi.BitsPerPixel], 24
  208. ;        jb      @f
  209.  
  210.         cmp     [es:mi.BitsPerPixel],16
  211.         jne     .l0
  212.         cmp     [es:mi.GreenMaskSize],5
  213.         jne     .l0
  214.         mov     [es:mi.BitsPerPixel],15
  215.  
  216.  
  217.   .l0:
  218.         cmp     [es:mi.XRes],640
  219.         jb      @f
  220.         cmp     [es:mi.YRes],480
  221.         jb      @f
  222. ;        cmp     [es:mi.BitsPerPixel],8
  223. ;        jb      @f
  224.  
  225.         mov     ax,[es:mi.XRes]
  226.         mov     [es:bx+0],ax               ; +0[2] : resolution X
  227.         mov     ax,[es:mi.YRes]
  228.         mov     [es:bx+2],ax               ; +2[2] : resolution Y
  229.         mov     ax,[es:mi.ModeAttributes]
  230.         mov     [es:bx+4],ax               ; +4[2] : attributes
  231.  
  232.         cmp     [s_vesa.ver],'2'
  233.         jb      .lp1
  234.  
  235.         or      cx,0x4000  ; use LFB
  236.   .lp1: mov     [es:bx+6],cx               ; +6 : mode number
  237.         movzx   ax,byte [es:mi.BitsPerPixel]
  238.         mov     word [es:bx+8],ax               ; +8 : bits per pixel
  239.         add     bx,size_of_step
  240.  
  241.     @@:
  242.         add     si,2
  243.         jmp     .next_mode
  244.  
  245.   .modes_ok.2:
  246.  
  247.         mov     word[es:bx],-1  ;end video table
  248.         mov     word[end_cursor],bx     ;save end cursor position
  249. ;;;;;;;;;;;;;;;;;;
  250. ;Sort array
  251. ;        mov     si,modes_table
  252. ;.new_mode:
  253. ;        mov     ax,word [es:si]
  254. ;        cmp     ax,-1
  255. ;        je      .exxit
  256. ;        add     ax,word [es:si+2]
  257. ;        add     ax,word [es:si+8]
  258. ;        mov     bp,si
  259. ;.again:
  260. ;        add     bp,12
  261. ;        mov     bx,word [es:bp]
  262. ;        cmp     bx,-1
  263. ;        je      .exit
  264. ;        add     bx,word [es:bp+2]
  265. ;        add     bx,word [es:bp+8]
  266. ;        
  267. ;        cmp     ax,bx
  268. ;        ja      .loops
  269. ;        jmp     .again
  270. ;.loops:
  271. ;        push    dword [es:si]
  272. ;        push    dword [es:si+4]
  273. ;        push    dword [es:si+8]
  274. ;        push    dword [es:bp]
  275. ;        push    dword [es:bp+4]
  276. ;        push    dword [es:bp+8]
  277. ;
  278. ;        pop     dword [es:si+8]
  279. ;        pop     dword [es:si+4]
  280. ;        pop     dword [es:si]
  281. ;        pop     dword [es:bp+8]
  282. ;        pop     dword [es:bp+4]
  283. ;        pop     dword [es:bp]
  284. ;        jmp     .new_mode
  285. ;
  286. ;.exit:  add     si,12
  287. ;        jmp     .new_mode
  288. ;.exxit:
  289.         popad
  290.         ret
  291.  
  292. ;-----------------------------------------------------------------------------
  293.  
  294. draw_current_vmode:
  295.         push    0
  296.         pop     es
  297.  
  298.         mov     si,word [cursor_pos]
  299.  
  300.         cmp     word [es:si+6],0x12
  301.         je      .no_vesa_0x12
  302.  
  303.         cmp     word [es:si+6],0x13
  304.         je      .no_vesa_0x13
  305.  
  306.         mov     di,loader_block_error
  307.         movzx   eax,word[es:si+0]
  308.         mov     ecx,10
  309.         call    int2strnz
  310.         mov     byte[es:di],'x'
  311.         inc     di
  312.         movzx   eax,word[es:si+2]
  313.         call    int2strnz
  314.         mov     byte[es:di],'x'
  315.         inc     di
  316.         movzx   eax,word[es:si+8]
  317.         call    int2strnz
  318.         mov     dword[es:di],0x00000d0a
  319.         mov     si,loader_block_error
  320.         push    ds
  321.         push    es
  322.         pop     ds
  323.         call    printplain
  324.         pop     ds
  325.         ret
  326. .no_vesa_0x13:
  327.         mov     si,mode0
  328.         jmp     .print
  329. .no_vesa_0x12:
  330.         mov     si,mode9
  331. .print:
  332.         call    printplain
  333.         ret        
  334. ;-----------------------------------------------------------------------------
  335. check_first_parm:
  336.         mov     si,word [preboot_graph]
  337.         test    si,si
  338.         jnz      .no_zero        ;if no zero
  339. .zerro:
  340. ;        mov     ax,modes_table
  341. ;        mov     word [cursor_pos],ax
  342. ;        mov     word [home_cursor],ax
  343. ;        mov     word [preboot_graph],ax
  344. ;SET default video of mode first probe will fined a move of work 1024x768@32
  345.  
  346.         mov     ax,1024
  347.         mov     bx,768
  348.         mov     si,modes_table
  349.         call    .loops
  350.         test    ax,ax
  351.         jz     .ok_found_mode
  352.         mov     ax,800
  353.         mov     bx,600
  354.         mov     si,modes_table
  355.         call    .loops
  356.         test    ax,ax
  357.         jz     .ok_found_mode
  358.         mov     ax,640
  359.         mov     bx,480
  360.         mov     si,modes_table
  361.         call    .loops
  362.         test    ax,ax
  363.         jz     .ok_found_mode
  364.  
  365.         mov     si,modes_table
  366.         jmp     .ok_found_mode
  367.  
  368.  
  369.  
  370. .no_zero:
  371.         mov     bp,word [number_vm]
  372.         cmp     bp,word [es:si+6]
  373.         jz      .ok_found_mode
  374.         mov     ax,word [x_save]
  375.         mov     bx,word [y_save]
  376.         mov     si,modes_table
  377.         call    .loops
  378.         test    ax,ax
  379.         jz     .ok_found_mode
  380.  
  381.         mov    si,modes_table
  382. ;        cmp     ax,modes_table
  383. ;        jb      .zerro           ;check on correct if bellow
  384. ;        cmp     ax,word [end_cursor]
  385. ;        ja      .zerro           ;check on correct if anymore
  386.  
  387. .ok_found_mode:
  388.         mov     word [home_cursor],si
  389. ;        mov     word [cursor_pos],si
  390.         mov     word [preboot_graph],si
  391.         mov     ax,si
  392.  
  393.         mov     ecx,long_v_table
  394.  
  395. .loop:  add     ax,size_of_step
  396.         cmp     ax,word [end_cursor]
  397.         jae     .next_step
  398.         loop    .loop
  399. .next_step:
  400.         sub     ax,size_of_step*long_v_table
  401.         cmp     ax,modes_table
  402.         jae     @f
  403.         mov     ax,modes_table
  404. @@:
  405.  
  406.         mov     word[home_cursor],ax
  407.         push    word [preboot_graph]
  408.         pop     word [cursor_pos]
  409.         ret
  410. ;;;;;;;;;;;;;;;;;;;;;;;;;;;
  411. .loops:
  412.         cmp     ax,word [es:si]
  413.         jne     .next
  414.         cmp     bx,word [es:si+2]
  415.         jne     .next
  416.         cmp     word [es:si+8],32
  417.         je      .ok
  418.         cmp     word [es:si+8],24
  419.         je      .ok
  420. .next:  add     si,size_of_step
  421.         cmp     word [es:si],-1
  422.         je      .exit
  423.         jmp     .loops
  424. .ok:    xor     ax,ax        
  425. .exit:  ret
  426.  
  427.  
  428. ;-----------------------------------------------------------------------------
  429.  
  430. ;default_vmode:
  431.        
  432. ;-----------------------------------------------------------------------------
  433. draw_vmodes_table:
  434.         _setcursor 9, 2
  435.         mov     si,gr_mode
  436.         call    printplain
  437.  
  438.         mov     si,_st
  439.         call    printplain
  440.  
  441.         push    word [cursor_pos]
  442.         pop     ax
  443.         push    word [home_cursor]
  444.         pop     si
  445.         mov     cx,si
  446.  
  447.         cmp     ax,si
  448.         je      .ok
  449.         jb      .low
  450.  
  451.  
  452.         add     cx,size_of_step*long_v_table
  453.        
  454.         cmp     ax,cx
  455.         jb      .ok
  456.        
  457.         sub     cx,size_of_step*long_v_table
  458.         add     cx,size_of_step
  459.         cmp     cx,word[end_cursor]
  460.         jae     .ok
  461.         add     si,size_of_step
  462.         push    si
  463.         pop     word [home_cursor]
  464.         jmp     .ok
  465.  
  466.  
  467. .low:   sub     cx,size_of_step
  468.         cmp     cx,modes_table
  469.         jb      .ok
  470.         push    cx
  471.         push    cx
  472.         pop     word [home_cursor]
  473.         pop     si
  474.  
  475.  
  476. .ok:
  477.         mov     bp,long_v_table               ;show rows
  478. .@@_next_bit:
  479.         cmp     word [es:si+6],0x12
  480.         je      .show_0x12
  481.         cmp     word [es:si+6],0x13
  482.         je      .show_0x13
  483.  
  484.         movzx   eax,word[es:si]
  485.         cmp     ax,-1
  486.         je      .@@_end
  487.         mov     di,_rs+23          
  488.         mov     ecx,10
  489.         mov     bl,4
  490.         call    int2str
  491.         movzx   eax,word[es:si+2]
  492.         inc     di
  493.         mov     bl,4
  494.         call    int2str
  495.  
  496.         movzx   eax,word[es:si+8]
  497.         inc     di
  498.         mov     bl,2
  499.         call    int2str
  500. ;clear cursor
  501.         mov     word[ds:_r1+21],'  '
  502.         mov     word[ds:_r1+50],'  '
  503.  
  504.         mov     word[ds:_r2+21],'  '
  505.         mov     word[ds:_r2+45],'  '
  506.  
  507.         mov     word[ds:_rs+21],'  '
  508.         mov     word[ds:_rs+46],'  '
  509.  
  510.         cmp     si, word [cursor_pos]
  511.         jne     .next
  512. ;draw   cursor
  513.         mov     word[ds:_rs+21],'>>'
  514.         mov     word[ds:_rs+46],'<<'
  515.        
  516.  
  517.  
  518. .next:
  519.         push    si
  520.         mov     si,_rs
  521. .@@_sh:
  522.         call    printplain
  523.         pop     si
  524.         add     si,size_of_step
  525.  
  526.         dec     bp
  527.         jnz     .@@_next_bit
  528.  
  529. .@@_end:
  530.         mov     si,_bt
  531.         call    printplain
  532. ; show scroll
  533.         push    es
  534.         push    0xB800
  535.         pop     es
  536. ; arrows
  537.         mov     di, (11*80+53)*2
  538.         mov     al, 30
  539.         stosb
  540.         add     di, 80*2-1
  541.         mov     al, 32
  542.         mov     cx, scroll_area_size
  543. @@:
  544.         stosb
  545.         add     di, 80*2-1
  546.         loop    @b
  547.         mov     al, 31
  548.         stosb
  549. ; calculate scroll size
  550.         mov     ax, [end_cursor]
  551.         sub     ax, modes_table
  552.         mov     bx, size_of_step
  553.         cwd
  554.         div     bx
  555.         mov     si, ax          ; si = size of list
  556.         mov     ax, [home_cursor]
  557.         sub     ax, modes_table
  558.         cwd
  559.         div     bx
  560.         mov     di, ax
  561.         mov     ax, scroll_area_size*long_v_table
  562.         cwd
  563.         div     si
  564.         test    ax, ax
  565.         jnz     @f
  566.         inc     ax
  567. @@:
  568.         cmp     al, scroll_area_size
  569.         jb      @f
  570.         mov     al, scroll_area_size
  571. @@:
  572.         mov     cx, ax
  573. ; cx = scroll height
  574. ; calculate scroll pos
  575.         xor     bx, bx          ; initialize scroll pos
  576.         sub     al, scroll_area_size+1
  577.         neg     al
  578.         sub     si, long_v_table-1
  579.         jbe     .draw_scroll
  580.         mul     di
  581.         div     si
  582.         mov     bx, ax
  583. .draw_scroll:
  584.         mov     al, 0xDB
  585.         imul    di, bx, 80*2
  586.         add     di, (12*80+53)*2
  587. @@:
  588.         stosb
  589.         add     di, 80*2-1
  590.         loop    @b
  591.         pop     es
  592.         ret
  593. .show_0x13:
  594.         push    si
  595.  
  596.         cmp     si, word [cursor_pos]
  597.         jne     @f
  598.         mov     word[ds:_r1+21],'>>'
  599.         mov     word[ds:_r1+50],'<<'        
  600. @@:
  601.         mov     si,_r1
  602.         jmp     .@@_sh
  603. .show_0x12:
  604.         push    si
  605.         cmp     si, word [cursor_pos]
  606.         jne     @f
  607.  
  608.         mov     word[ds:_r2+21],'>>'
  609.         mov     word[ds:_r2+45],'<<'
  610. @@:
  611.         mov     si,_r2
  612.         jmp     .@@_sh
  613.  
  614. ;-----------------------------------------------------------------------------
  615. ;Clear arrea of current video page (0xb800)
  616. clear_vmodes_table:
  617.         pusha
  618.        ; draw frames
  619.         push    es
  620.         push    0xb800
  621.         pop     es
  622.         mov     di,1444
  623.         xor     ax,ax
  624.         mov     ah, 1*16+15
  625.         mov     cx,70
  626.         mov     bp,12
  627. .loop_start:
  628.         rep     stosw
  629.         mov     cx,70
  630.         add     di,20
  631.         dec     bp               ; 㬥­ìè¨âì DX,
  632.         jns        .loop_start      
  633.         pop     es
  634.         popa
  635.         ret
  636.  
  637. ;-----------------------------------------------------------------------------
  638.  
  639. set_vmode:
  640.         push    0 ;0;x1000
  641.         pop     es
  642.  
  643.         mov     si,word [preboot_graph]            ;[preboot_graph]
  644.         mov     cx,word [es:si+6]            ; number of mode
  645.        
  646.  
  647.         mov     ax,word [es:si+0]            ; resolution X
  648.         mov     bx,word [es:si+2]            ; resolution Y
  649.  
  650.  
  651.         mov     word [es:0x900A],ax              ; resolution X
  652.         mov     word [es:0x900C],bx              ; resolution Y
  653.         mov     word [es:0x9008],cx              ; number of mode
  654.  
  655.         cmp     cx,0x12
  656.         je      .mode0x12_0x13
  657.         cmp     cx,0x13
  658.         je      .mode0x12_0x13
  659.  
  660.  
  661.         cmp     byte [s_vesa.ver],'2'
  662.         jb      .vesa12
  663.  
  664. ;  VESA 2 and Vesa 3
  665.  
  666.         mov     ax,0x4f01
  667.         and     cx,0xfff
  668.         mov     di,mi;0xa000
  669.         int     0x10
  670.         ; LFB
  671.         mov     eax,[es:mi.PhysBasePtr];di+0x28]
  672.         mov     [es:0x9018],eax
  673.         ; ---- vbe voodoo
  674.         BytesPerLine equ 0x10
  675.         mov     ax, [es:di+BytesPerLine]
  676.         mov     [es:0x9001], ax
  677.         ; BPP
  678.         cmp     [es:mi.BitsPerPixel],16
  679.         jne     .l0
  680.         cmp     [es:mi.GreenMaskSize],5
  681.         jne     .l0
  682.         mov     [es:mi.BitsPerPixel],15
  683. .l0:
  684.         mov     al, byte [es:di+0x19]
  685.         mov     [es:0x9000], al
  686.         jmp     .exit
  687.  
  688. .mode0x12_0x13:
  689.         mov     byte [es:0x9000], 32
  690.         or      dword [es:0x9018], 0xFFFFFFFF; 0x800000
  691.  
  692.  
  693. ;  VESA 1.2 PM BANK SWITCH ADDRESS
  694.  
  695. .vesa12:
  696.  
  697.  
  698.         mov     ax,0x4f0A
  699.         xor     bx,bx
  700.         int     0x10
  701.         xor     eax,eax
  702.         xor     ebx,ebx
  703.         mov     ax,es
  704.         shl     eax,4
  705.         mov     bx,di
  706.         add     eax,ebx
  707.         movzx   ebx,word[es:di]
  708.         add     eax,ebx
  709.         push    0x0000
  710.         pop     es
  711.         mov     [es:0x9014],eax
  712.   .exit:
  713.         ret
  714.  
  715.  
  716. ;        mov     dword[es:0x9018],0x000A0000
  717. ;        ret
  718.  
  719. ;=============================================================================
  720. ;=============================================================================
  721. ;=============================================================================
  722.  
  723.