asm 的hello world 2011.04.28

这几天一直在弄一个嵌入式的程序,搭环境,熟悉库函数,熟悉汇编,乱成一锅粥,到现在还是没有什么系统性的收获。

或许下周弄出来吧,(一定得弄出来,不然老大该跟我急了……)。

今天,熟悉汇编,好歹用汇编写出了hello world,算是我汇编生涯的一个起点吧,

写下来纪念一下:

例:

date segment

     a db 'hello,world!$'

date ends

code segment

     assume cs:code,ds:date

start : mov ax,date

        mov ds,ax

        mov dx,offset a

        mov ah,9

        int 21h

        mov ah,4ch

        int 21h

code ends

end start

 
 
输出:
hello,world!
 
https://blog.csdn.net/lingxiu0613/article/details/6370858
原文地址:https://www.cnblogs.com/findumars/p/8822903.html