2 ; KolibriOS system functions:
\r
3 SF_TERMINATE_PROCESS=-1
\r
4 SF_CREATE_WINDOW=0 ; define and draw the window
\r
5 SF_PUT_PIXEL=1 ; draw pixel to the window
\r
6 SF_GET_KEY=2 ; get code of the pressed key
\r
9 SF_SLEEP=5 ; pause process
\r
10 SF_PUT_IMAGE=7 ; draw image to the window
\r
11 SF_DEFINE_BUTTON=8 ; define/delete the button
\r
12 SF_THREAD_INFO=9 ; information on execution thread
\r
13 SF_WAIT_EVENT=10 ; wait for event
\r
14 SF_CHECK_EVENT=11 ; check for event and return
\r
18 SF_DRAW_RECT=13 ; draw rectangle to the window
\r
19 SF_GET_SCREEN_SIZE=14 ; get screen resolution
\r
20 SF_BACKGROUND_SET=15 ; work with desktop background graphics
\r
21 SSF_SIZE_BG=1 ; set a size of the background image
\r
22 SSF_PIXEL_BG=2 ; put pixel on the background image
\r
23 SSF_REDRAW_BG=3 ; redraw background
\r
24 SSF_MODE_BG=4 ; set drawing mode for the background
\r
25 SSF_IMAGE_BG=5 ; put block of pixels on the background image
\r
26 SSF_MAP_BG=6 ; map background image to the address space of the process
\r
27 SSF_UNMAP_BG=7 ; close mapped background data
\r
28 SSF_LAST_DRAW=8 ; get coordinates of the last draw to the background
\r
29 SSF_REDRAW_RECT=9 ; redraws a rectangular part of the background
\r
30 SF_RD_TO_FLOPPY=16 ; save ramdisk on the floppy
\r
31 SF_GET_BUTTON=17 ; get ID of the pressed button
\r
33 SSF_UNFOCUS_WINDOW=1 ; take focus from the window of the given thread
\r
34 SSF_TERMINATE_THREAD=2 ; terminate process/thread by the slot number
\r
35 SSF_FOCUS_WINDOW=3 ; give focus to the window of the given thread
\r
36 SSF_GET_IDLE_COUNT=4 ; get counter of idle cycles per second
\r
37 SSF_GET_CPU_FREQUENCY=5 ; get CPU clock rate
\r
38 SSF_RD_TO_HDD=6 ; save ramdisk to the file on hard disk
\r
39 SSF_GET_ACTIVE_WINDOW=7 ; get slot number of the active window
\r
43 SSF_SHUTDOWN=9 ; system shutdown/reboot
\r
44 SSF_MINIMIZE_WINDOW=10 ; minimize active window
\r
45 SSF_INFO_DISC_SYS=11 ; get disk subsystem information
\r
46 SSF_KERNEL_VERSION=13 ; get kernel version
\r
47 SSF_WAIT_RETRACE=14 ; wait for screen retrace
\r
48 SSF_CURSOR_CENTER=15 ; center mouse cursor on the screen
\r
49 SSF_GET_FREE_RAM=16 ; get size of free RAM
\r
50 SSF_GET_TOTAL_RAM=17 ; get total amount of RAM
\r
51 SSF_TERMINATE_THREAD_ID=18 ; Terminate process/thread by the ID
\r
52 SSF_MOUSE_SETTINGS=19
\r
56 SSSF_SET_SPEEDUP=3 ; set mouse acceleration
\r
57 SSSF_SET_POS=4 ; set mouse pointer position
\r
58 SSSF_SET_BUTTON=5 ; simulate state of mouse buttons
\r
59 SSSF_GET_DOUBLE_CLICK_DELAY=6
\r
60 SSSF_SET_DOUBLE_CLICK_DELAY=7
\r
61 SSF_GET_RAM_INFO=20 ; get information on RAM
\r
62 SSF_GET_THREAD_SLOT=21 ; get slot number of process/thread by the ID
\r
63 SSF_FOREIGN_WINDOW=22 ; operations with window of another thread by slot/ID
\r
69 SSF_SET_SCREEN_LIMITS=24
\r
70 SSF_WINDOW_BEHAVIOR=25 ; window focus relation with other windows
\r
78 SSF_KEYBOARD_LAYOUT=2
\r
80 SSF_ACCESS_HD_LBA=11 ; setting of low-level access to HD
\r
81 SSF_ACCESS_PCI=12 ; setting of low-level access to PCI
\r
83 SF_WAIT_EVENT_TIMEOUT=23; wait for event with timeout
\r
87 SF_SCREEN_PUT_IMAGE=25 ; put image on the background layer
\r
89 ; Same as SF_SYSTEM_SET, plus:
\r
91 SSF_TIME_COUNT_PRO=10 ; get value of the high precision time counter
\r
93 SF_CURRENT_FOLDER=30
\r
94 SSF_SET_CF=1 ; set current folder for the thread
\r
96 SSF_ADD_SYS_FOLDER=3 ; install the add.system directory for the kernel
\r
97 SF_GET_PIXEL_OWNER=34 ; get slot number of the screen pixel owner
\r
98 SF_GET_PIXEL=35 ; read the screen pixel color
\r
99 SF_GET_IMAGE=36 ; read the screen area
\r
101 SSF_SCREEN_POSITION=0
\r
102 SSF_WINDOW_POSITION=1
\r
103 SSF_BUTTON=2 ; states of the mouse buttons
\r
104 SSF_BUTTON_EXT=3 ; states and events of the mouse buttons
\r
110 SF_BACKGROUND_GET=39
\r
114 SF_SET_EVENTS_MASK=40 ; turn on/off desired events
\r
115 SF_PORT_IN_OUT=43 ; input/output to a port
\r
116 SF_SET_PORTS=46 ; reserve/free a group of input/output ports
\r
117 SF_DRAW_NUMBER=47 ; draw number to the window
\r
118 SF_STYLE_SETTINGS=48
\r
119 SSF_APPLY=0 ; apply screen settings
\r
120 SSF_SET_BUTTON_STYLE=1
\r
122 SSF_GET_COLORS=3 ; get standard window colors
\r
123 SSF_GET_SKIN_HEIGHT=4
\r
124 SSF_GET_SCREEN_AREA=5 ; get screen working area
\r
125 SSF_SET_SCREEN_AREA=6
\r
126 SSF_GET_SKIN_MARGINS=7
\r
128 SSF_GET_FONT_SMOOTH=9
\r
129 SSF_SET_FONT_SMOOTH=10
\r
130 SSF_GET_FONT_SIZE=11
\r
131 SSF_SET_FONT_SIZE=12
\r
133 SF_SET_WINDOW_SHAPE=50
\r
134 SF_CREATE_THREAD=51
\r
136 SSF_GET_SLOT_COUNT=0 ; get the number of slots in the clipboard
\r
139 SSF_DEL_SLOT=3 ; delete the last slot in the clipboard
\r
140 SSF_UNLOCK_BUFFER=4 ; emergency buffer unlock
\r
143 SF_IPC=60 ; Inter Process Communication
\r
144 SSF_SET_AREA=1 ; set area for IPC receiving
\r
146 SF_GET_GRAPHICAL_PARAMS=61
\r
148 SSF_BITS_PER_PIXEL=2
\r
149 SSF_BYTES_PER_LINE=3
\r
151 SSF_GET_VERSION=0 ; get version of PCI-interface
\r
152 SSF_GET_LAST_BUS=1 ; get number of the last PCI-bus
\r
153 SSF_GET_ADRR_MODE=2 ; get addressing mode of the PCI configuration space
\r
163 SF_MEMORY_RESIZE=64 ; resize total application memory
\r
164 SF_PUT_IMAGE_EXT=65 ; draw image with palette to the window
\r
166 SSF_SET_INPUT_MODE=1
\r
167 SSF_GET_INPUT_MODE=2
\r
168 SSF_GET_CONTROL_KEYS=3; get status of control keys
\r
169 SSF_SET_SYS_HOTKEY=4
\r
170 SSF_DEL_SYS_HOTKEY=5
\r
171 SSF_LOCK_INPUT=6 ; block normal input
\r
172 SSF_UNLOCK_INPUT=7 ; restore normal input
\r
173 SF_CHANGE_WINDOW=67 ; change position/sizes of the window
\r
175 SSF_GET_TASK_SWITCH_COUNT=0
\r
179 SSSF_CACHE_STATUS=1
\r
187 SSF_WAIT_SIGNAL=14 ; wait for signal from another program/driver
\r
189 SSF_CONTROL_DRIVER=17
\r
192 SSF_LOAD_DRIVER_PE=21
\r
193 SSF_MEM_OPEN=22 ; open named memory area
\r
195 SSF_SET_EXCEPTION_HANDLER=24
\r
196 SSF_SET_EXCEPTION_STATE=25
\r
197 SSF_MEM_FREE_EXT=26
\r
200 SSF_SET_MESSAGE_AREA=0
\r
201 SSF_GET_REGISTERS=1
\r
202 SSF_SET_REGISTERS=2
\r
209 SSF_DEFINE_BREAKPOINT=9
\r
220 SSF_CREATE_FOLDER=9
\r
224 SF_NETWORK_DEVICE=74
\r
225 SSF_DEVICE_COUNT=255 ; get number of active network devices
\r
230 SSF_DEVICE_POINTER=4
\r
231 SSF_TX_PACKET_COUNT=6
\r
232 SSF_RX_PACKET_COUNT=7
\r
233 SSF_TX_BYTE_COUNT=8
\r
234 SSF_RX_BYTE_COUNT=9
\r
236 SSF_TX_PACKET_ERROR_COUNT=11
\r
237 SSF_TX_PACKET_DROP_COUNT=12
\r
238 SSF_TX_PACKET_MISS_COUNT=13
\r
239 SSF_RX_PACKET_ERROR_COUNT=14
\r
240 SSF_RX_PACKET_DROP_COUNT=15
\r
241 SSF_RX_PACKET_MISS_COUNT=16
\r
242 SF_NETWORK_SOCKET=75
\r
254 SF_NETWORK_PROTOCOL=76
\r
255 SSF_ETHERNET_READ_MAC=0
\r
256 SSF_IP4_PACKETS_SENT=10000h
\r
257 SSF_IP4_PACKETS_RECEIVED=10001h
\r
258 SSF_IP4_READ_IP=10002h
\r
259 SSF_IP4_WRITE_IP=10003h
\r
260 SSF_IP4_READ_DNS=10004h
\r
261 SSF_IP4_WRITE_DNS=10005h
\r
262 SSF_IP4_READ_SUBNET=10006h
\r
263 SSF_IP4_WRITE_SUBNET=10007h
\r
264 SSF_IP4_READ_GATEWAY=10008h
\r
265 SSF_IP4_WRITE_GATEWAY=10009h
\r
266 SSF_ICMP_PACKETS_SENT=20000h
\r
267 SSF_ICMP_PACKETS_RECEIVED=20001h
\r
268 SSF_ICMP_ECHO_REPLY=20003h
\r
269 SSF_UDP_PACKETS_SENT=30000h
\r
270 SSF_UDP_PACKETS_RECEIVED=30001h
\r
271 SSF_TCP_PACKETS_SENT=40000h
\r
272 SSF_TCP_PACKETS_RECEIVED=40001h
\r
273 SSF_ARP_PACKETS_SENT=50000h
\r
274 SSF_ARP_PACKETS_RECEIVED=50001h
\r
275 SSF_ARP_GET_ENTRY_COUNT=50002h
\r
276 SSF_ARP_READ_ENTRY=50003h
\r
277 SSF_ARP_ADD_STATIC_ENTRY=50004h
\r
278 SSF_ARP_DEL_ENTRY=50005h
\r
279 SSF_ARP_SEND_ANNOUNCE=50006h
\r
280 SSF_ARP_CONFLICTS_COUNT=50007h
\r
287 ; File system errors:
\r
289 FSERR_UNSUPPORTED=2
\r
291 FSERR_FILE_NOT_FOUND=5
\r
292 FSERR_END_OF_FILE=6
\r
293 FSERR_INVALID_BUFFER=7
\r
296 FSERR_ACCESS_DENIED=10
\r
297 FSERR_DEVICE_FAIL=11
\r
298 FSERR_OUT_OF_MEMORY=12
\r