; V22.0201.002, machine org I; fall 97; yap.
title asc_box1.asm
comment#
	A variation of asc_box.asm.
	Illustrating use of extended ascii character
	sets to draw simple graphics (in this case,
	a box with single lines).
end comment#
.model small
.stack 100h
.data
; the following suffices to draw a box
SPC	equ 20h
CR	equ 0dh
LF	equ 0ah
corner_nw equ 0dah
corner_ne equ 0bfh
corner_sw equ 0c0h
corner_se equ 0d9h
vertical  equ 0b3h
horizontal equ 0c4h
;
box	db 10 dup (SPC), corner_nw, 25 dup (horizontal), corner_ne, CR, LF
   	db 10 dup (SPC), vertical,  25 dup (SPC), vertical, CR, LF
   	db 10 dup (SPC), vertical,  25 dup (SPC), vertical, CR, LF
   	db 10 dup (SPC), vertical,  25 dup (SPC), vertical, CR, LF
	db 10 dup (SPC), corner_sw, 25 dup (horizontal), corner_se, CR, LF
	db '$'
.code
start:
mov ax,@data
mov ds,ax
;
; In this simple example, I just draw the nw corner 25 times
;	you can easily extend this into drawing a box...
mov ah,9
lea dx, box
int 21h
;
mov ax,4c00h
int 21h
end start

