mirror of
https://gitlab.os-k.eu/os-k-team/kvisc.git
synced 2023-08-25 14:05:46 +02:00
70 lines
933 B
Plaintext
70 lines
933 B
Plaintext
; The OS/K Team licenses this file to you under the MIT license.
|
|
; See the LICENSE file in the project root for more information.
|
|
|
|
;
|
|
; SHUTDOWN syscall
|
|
;
|
|
; End virtual machine
|
|
;
|
|
Sys.Shutdown := 0x00
|
|
|
|
;
|
|
; EXIT syscall
|
|
;
|
|
; Return to COMMAND.COM
|
|
;
|
|
Sys.Exit := 0x01
|
|
|
|
; FIND syscalls
|
|
;
|
|
; Find file on disk
|
|
;
|
|
; IN
|
|
; ax0 = address of name buffer
|
|
; ax1 = size of name buffer
|
|
;
|
|
; OUT
|
|
; rax = # of bytes written in name buffer
|
|
; rdx = size of file
|
|
;
|
|
;
|
|
Sys.FindFirst := 0x20
|
|
Sys.FindNext := 0x21
|
|
|
|
;
|
|
; OPEN/CREATE syscalls
|
|
;
|
|
; IN
|
|
; ax0 = name string
|
|
;
|
|
; OUT
|
|
; rax = handle of file, or <0 if couldn't open
|
|
;
|
|
Sys.OpenFile := 0x30
|
|
Sys.CreateFile := 0x31
|
|
|
|
;
|
|
; CLOSE syscall
|
|
;
|
|
; IN
|
|
; ax0 = file handle
|
|
;
|
|
Sys.CloseFile := 0x35
|
|
|
|
;
|
|
; READ syscall
|
|
;
|
|
; IN
|
|
; ax0 = file handle
|
|
; ax1 = buffer address
|
|
; ax2 = buffer size
|
|
;
|
|
; OUT
|
|
; rax = number of bytes read, <0 on error
|
|
;
|
|
Sys.ReadFile := 0x38
|
|
|
|
; Halt mode
|
|
Sys.EnterHaltMode := 0x999
|
|
|