📄 hello.asm
字号:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;
;; Project : FDOS 0.0.8
;; Author : Ottonello, Santiago
;; Webpage : http://www.visual-opal.de
;; Date : 8.8.2003
;; Caption : Echo command
;; Function : Echoes given parameter to Standard Output
;; Filename : hello.asm
;; Compile Syntax : nasm hello.asm -f bin -I FDOS.INC -o hello.bin
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
%include "FDOS.INC"
;-------------------------------------------------------------------------------
; Main Program Begins Here
;-------------------------------------------------------------------------------
BEGPGM ;Load segment register
PRTSTR Welcome ;Print Buffer
GETPRM Buffer ;Get Command Line and Store in Buf
MOV byte [Buffer+255], 00h ;Zero Terminate Buffer,secures Fnc 1
PRTSTR Buffer ;Print Buffer
PRTSTR Prompt ;Print Prompt
GETSTR Name ;Read Name
PRTSTR Greet ;Print Prompt
PRTSTR Name ;Print Name
ENDPGM ;Bye Bye
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Data
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Buffer times 255 db 0
Name times 255 db 0
Welcome db "Hello I'm the hello world program", 13, 10, \
"You have passed the following parameters ...",13,10,0
Prompt db 13,10,"Please enter your name ...",0
Greet db 13,10,"Hello ",0
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -