Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
7707 Alex2003 1
2
xmlns:o="urn:schemas-microsoft-com:office:office"
3
xmlns:w="urn:schemas-microsoft-com:office:word"
4
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml"
5
xmlns="http://www.w3.org/TR/REC-html40">
6
 
7
8
9
10
11
12
13
31
32
33
332
418
448
449
 
450
451
 
452
453
 
454

Back

457
style='mso-ansi-language:RU'> to main
458
style='mso-bidi-font-weight:normal'>

459
 
460

 

463
 
464

Function 26

467
and its subfunctions (1, 2, 5, 9-12)

468
 
469

 

472
 
473

475
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
476
EN-US'>Subfunction
477
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
478
EN-US'> 1 - get the base port MPU MIDI

479
 
480

Options:

483
 
484

  * eax =

487
26 - function number

488
 
489

  * ebx = 1

492
- number of subfunction

493
 
494

Return value:

497
 
498

  * eax =

501
port number

502
 
503

 

506
 
507

Remarks:

510
 
511

  You can set the base

514
port by calling subfunction 1 of function 21.

515
 
516

 

519
 
520

Constants for registers:

523
 
524

  eax -

527
SF_SYSTEM_GET (26)

528
 
529

  ebx -

532
SSF_MPU_MIDI_BASE (1)

533
 
534

 

537
 
538

540
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
541
EN-US'>Subfunction
542
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
543
EN-US'> 2 - get keyboard layout

544
 
545

The keyboard layout is used to convert scancodes

548
coming from the keyboard into ASCII codes readable by function 2.

549
 
550

Options:

553
 
554

  * eax =

557
26 - function number

558
 
559

  * ebx = 2

562
- subfunction number

563
 
564

  * ecx =

567
which layout to get:

568
 
569

    * 1 = normal

572
 
573

    * 2 = layout when Shift is pressed

576
 
577

    * 3 = Layout while pressing Alt

580
 
581

  * edx =

584
pointer to the 128-byte buffer where the layout will be copied

585
 
586

Return value:

589
 
590

  * function does not return value

593
 
594

Or:

597
 
598

  * eax =

601
26 - function number

602
 
603

  * ebx = 2

606
- subfunction number

607
 
608

  * ecx = 9

611
 
612

Return value:

615
 
616

  * eax =

619
country identifier (1 = eng, 2 = fi, 3 = 
620
class=SpellE>ger, 4 = rus)

621
 
622

 

625
 
626

Remarks:

629
 
630

  If Alt is pressed,

633
the layout with Alt is used;

634
 
635

  if

638
Alt is not pressed, but Shift is pressed, then the layout with Shift is used;

639
 
640

  if

643
Alt and Shift are not pressed, but Ctrl is pressed, then the normal layout is
644
used, after which 0x60 is subtracted from the code;

645
 
646

  if

649
none of the control keys are pressed, then the normal layout is used.

650
 
651

  You can set the

654
layouts and country ID using sub-function 2 of function 21.

655
 
656

  The country

659
identifier is a global system variable that is not used by the kernel itself;
660
however, the @taskbar application displays an icon corresponding to the current
661
country (using the described function).

662
 
663

  The @taskbar

666
application switches layouts on user request.

667
 
668

 

671
 
672

Constants for registers:

675
 
676

  eax -

679
SF_SYSTEM_GET (26)

680
 
681

  ebx -

684
SSF_KEYBOARD_LAYOUT (2)

685
 
686

 

689
 
690

692
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
693
EN-US'>Subfunction
694
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
695
EN-US'> 5 - get system language

696
 
697

Options:

700
 
701

  * eax =

704
26 - function number

705
 
706

  * ebx = 5

709
- subfunction number

710
 
711

Return value:

714
 
715

  * eax =

718
system language (1 = eng, 2 = fi, 3 = 
719
class=SpellE>ger, 4 = rus)

720
 
721

 

724
 
725

Remarks:

728
 
729

  The system language is

732
a global system variable not used by the kernel itself, however, the @taskbar
733
application draws the corresponding icon (using the described function).

734
 
735

  You can set the

738
system language by calling subfunction 5 of function
739
21.

740
 
741

 

744
 
745

Constants for registers:

748
 
749

  eax -

752
SF_SYSTEM_GET (26)

753
 
754

  ebx -

757
SSF_SYS_LANG (5)

758
 
759

 

762
 
763

765
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
766
EN-US'>Subfunction
767
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
768
EN-US'> 9 - get the value of the time counter

769
 
770

Options:

773
 
774

  * eax =

777
26 - function number

778
 
779

  * ebx = 9

782
- subfunction number

783
 
784

Return value:

787
 
788

  * eax =

791
number of hundredths of a second since

792
 
793

    system startup

796
 
797

 

800
 
801

Remarks:

804
 
805

  The counter is taken

808
modulo 2 ^ 32, which corresponds to a little more than 497 days.

809
 
810

  System time can be

813
obtained by function 3.

814
 
815

 

818
 
819

Constants for registers:

822
 
823

  eax -

826
SF_SYSTEM_GET (26)

827
 
828

  ebx -

831
SSF_TIME_COUNT (9)

832
 
833

 

836
 
837

839
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
840
EN-US'>Subfunction
841
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
842
EN-US'> 10 - Get the value of a high-precision time
843
style='mso-bidi-font-weight:normal'> counter

845
 
846

 

849
lang=EN-US style='font-family:"Arial","sans-serif";mso-ansi-language:EN-US'>Options:

850
 
851

  * eax =

854
26 - function number

855
 
856

  * ebx =

859
10 - subfunction number

860
 
861

Returned value:

864
 
865

  * edx:

868
class=SpellE>eax = number of nanoseconds since the kernel was loaded

869
 
870

  * eax =

873
low double word

874
 
875

  * edx =

878
senior double word

879
 
880

 

883
 
884

Remarks:

887
 
888

  The function uses an

891
HPET counter, if HPET is not available, a PIT counter is used. In this case,
892
the accuracy will be reduced to 10,000,000 nanoseconds.

893
 
894

                               

897
 
898

Constants for registers:

901
 
902

  eax -

905
SF_SYSTEM_GET (26)

906
 
907

  ebx -

910
SSF_TIME_COUNT_PRO (10)

911
 
912

 

915
 
916

918
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
919
EN-US'>Subfunction
920
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
921
EN-US'> 11 - Find out if low-level access to HD is allowed

922
 
923

Options:

926
 
927

  * eax =

930
26 - function number

931
 
932

  * ebx =

935
11 - number of subfunction

936
 
937

Return value:

940
 
941

  * eax =

944
0/1 - disabled / enabled

945
 
946

 

949
 
950

Remarks:

953
 
954

  Used

957
in LBA reading (subfunction 8 of function 58).
958
You can set the current state by calling subfunction
959
11 of function 21.

960
 
961

 

964
 
965

Constants for registers:

968
 
969

  eax -

972
SF_SYSTEM_GET (26)

973
 
974

  ebx -

977
SSF_ACCESS_HD_LBA (11)

978
 
979

 

982
 
983

985
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
986
EN-US'>Subfunction
987
lang=EN-US style='font-size:14.0pt;font-family:"Arial","sans-serif";mso-ansi-language:
988
EN-US'> 12 - Check if low-level access to PCI is allowed

989
 
990

Options:

993
 
994

  * eax =

997
26 - function number

998
 
999

  * ebx =

1002
12 - subfunction number

1003
 
1004

Return value:

1007
 
1008

  * eax =

1011
0/1 - disabled / enabled

1012
 
1013

 

1016
 
1017

Remarks:

1020
 
1021

  Used when working

1024
with the PCI bus (function 62).

1025
 
1026

  The current

1029
implementation uses only the low bit ecx.

1030
 
1031

  You can set the

1034
current state by calling subfunction 12 of function 21.

1035
 
1036

 

1039
 
1040

Constants for registers:

1043
 
1044

  eax -

1047
SF_SYSTEM_GET (26)

1048
 
1049

  ebx -

1052
SSF_ACCESS_PCI (12)

1053
 
1054
1055
 
1056
1057
 
1058