RosettaCodeData/Task/Hello-world-Newbie/8080-Assembly/hello-world-newbie.8080
2023-07-01 13:44:08 -04:00

13 lines
620 B
Text

; Hello World!
; Prints Hello, World! to stdout
BDOS equ 5 ; BDOS call entry
PRINT equ 9 ; BDOS string stdout subroutine
org 100h ; (mostly) All CP/M programs start at 100h
start lxi d,message ; load message pointer to DE register pair
mvi c,PRINT ; set up BDOS call to do string print
call BDOS ; call BDOS routine
ret ; pop back out into CP/M
message db 'Hello, World!','$' ; message string, all CP/M strings have an EOL of '$'