- PC - Programmering - Assembler - MASM - Directives
| .CODE | .DATA
| .MODEL | .STACK
|
| ASSUME | DB | DOSSEG | END | ENDS | EQU | ORG | SEGMENT | TITLE |
.MODEL SMALL |
.STACK 100h ;256 bytes |
ASSUME CS:code, DS:code, ES:code, SS:code code SEGMENT |
msg DB "Message$"
DB "Hello World",13,10
DB 'Hello World',0Dh,0Ah
DB ;uninitialized byte
mov dx,offset msg
|
start: ;code starts here
;...
END start
|
msg db "Hello",13,10
len EQU $ - msg ;len = location - OFFSET msg = 7
mov dx,OFFSET msg
mov cx,len ;mov cx,7
|
code SEGMENT
ORG 100h
start: ;code at 100h
|
code SEGMENT
;code here
code ENDS
|
| TITLE hello |