; TASM [this-source]
; TASM [showbyte]
; TLINK [this-source] [showbyte] , [name-of-exe]
; this program prints var1 and var2 using Showbyte.
; if this program displays number correctly, then you have mastered a new skill:
; you can make and link external modules.
.model small
.stack 100h
.data
var1 db 86h                 ;replace with whatever value you wish
var2 db 0E5h                 ;replace with whatever value you wish
crlf db 0Dh,0Ah,'$'
.code
extrn showbyte:proc
main proc
mov ax, @data
mov ds, ax
mov dl, var1
call showbyte
mov ah, 2
xchg dh, dl
int 21h
xchg dh, dl
int 21h
                ;CRLF, get cursor to next line
mov ah, 9
mov dx, offset crlf
int 21h
mov dl, var2
call showbyte
mov ah, 2
xchg dh, dl
int 21h
xchg dh, dl
int 21h
mov ax, 4C00h
int 21h
main endp
end main