Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

[ASM]Write String only using BIOS (See related posts)

First, set starting address of text into DS:SI registers. Procedure writes text until null-character is met.
;-----------------------------------------------------------------------------;
;		WRITE_STRING(DS:SI Text)                                      ;
;-----------------------------------------------------------------------------;
;	Writes string from DS:SI until character #0 is met		      ;
Write_String:		
	mov ah, 0xE	
	xor bh, bh	
	mov bl, 0x7
.nextchar	
	lodsb		
	or al,al
	jz .return
	int 10h	
	jmp .nextchar
.return		
	ret	


You need to create an account or log in to post comments to this site.


Click here to browse all 4858 code snippets

Related Posts