{"id":1270,"date":"2018-10-23T21:34:30","date_gmt":"2018-10-23T13:34:30","guid":{"rendered":"http:\/\/www.yusian.com\/blog\/?p=1270"},"modified":"2018-10-24T21:10:58","modified_gmt":"2018-10-24T13:10:58","slug":"%e7%ac%ac%e4%b8%80%e4%b8%aa%e6%b1%87%e7%bc%96%e7%a8%8b%e5%ba%8fhello-world%ef%bc%88hello-assembler%ef%bc%89","status":"publish","type":"post","link":"https:\/\/www.yusian.com\/blog\/assembler\/2018\/10\/23\/2134301270.html","title":{"rendered":"\u7b2c\u4e00\u4e2a\u6c47\u7f16\u7a0b\u5e8fHello World!\uff08Hello Assembler!\uff09"},"content":{"rendered":"<p>1\u3001\u770b\u56fe\u8bf4\u8bdd<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1-300x183.png\" alt=\"\" width=\"600\" height=\"366\" class=\"alignnone size-medium wp-image-1271\" srcset=\"https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1-300x183.png 300w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1-768x468.png 768w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1-1024x624.png 1024w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1-624x380.png 624w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_1.png 1804w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2-300x196.png\" alt=\"\" width=\"600\" height=\"392\" class=\"alignnone size-medium wp-image-1272\" srcset=\"https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2-300x196.png 300w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2-768x502.png 768w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2-1024x670.png 1024w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2-624x408.png 624w, https:\/\/www.yusian.com\/blog\/wp-content\/uploads\/2018\/10\/emu8086_2.png 1804w\" sizes=\"auto, (max-width: 600px) 100vw, 600px\" \/><\/p>\n<p>2\u3001\u4ee3\u7801<\/p>\n<pre lang=\"asm\" line=\"1\">assume cs:code ,ds:data\r\n;\u6570\u636e\u6bb5\r\ndata segment\r\n    db 'Hello Assembler!$'    \r\ndata ends\r\n;\u4ee3\u7801\u6bb5\r\ncode segment\r\nstart:\r\n    ;\u52a0\u8f7d\u6570\u636e\u5230ds\u6570\u636e\u6bb5\u5bc4\u5b58\u5668\r\n    mov ax, data\r\n    mov ds, ax\r\n    ;\u4f7f\u7528int 21hr\u6307\u4ee4\u4ece\u7ec8\u7aef\u8f93\u51fa\u5b57\u7b26(ah\u4e3a09h)\r\n    ;DS:DX=\u4e32\u5730\u5740,dx\u5373\u4e3a\u504f\u79fb\u5730\u5740\r\n    mov dx, 00h\r\n    mov ah, 09h\r\n    int 21h\r\n    ;\u7a0b\u5e8f\u9000\u51fa\r\n    mov ax, 4c00h\r\n    int 21h    \r\ncode ends\r\nend start<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>1\u3001\u770b\u56fe\u8bf4\u8bdd 2\u3001\u4ee3\u7801 assume cs:code ,ds:data ;\u6570\u636e\u6bb5 data segment db &#8216;Hello Assembler!$&#8217; data ends ;\u4ee3\u7801\u6bb5 code segment start: ;\u52a0\u8f7d\u6570\u636e\u5230ds\u6570\u636e\u6bb5\u5bc4\u5b58\u5668 mov ax, data mov ds, ax ;\u4f7f\u7528int 21hr\u6307\u4ee4\u4ece\u7ec8\u7aef\u8f93\u51fa\u5b57\u7b26(ah\u4e3a09h) ;DS:DX=\u4e32\u5730\u5740,dx\u5373\u4e3a\u504f\u79fb\u5730\u5740 mov dx, 00h mov ah, 09h int 21h ;\u7a0b\u5e8f\u9000\u51fa mov ax, 4c00h int 21h code ends end start<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[124],"tags":[122,121,123],"class_list":["post-1270","post","type-post","status-publish","format-standard","hentry","category-assembler","tag-helloworld","tag-121","tag-123"],"_links":{"self":[{"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/posts\/1270","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/comments?post=1270"}],"version-history":[{"count":0,"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/posts\/1270\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/media?parent=1270"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/categories?post=1270"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.yusian.com\/blog\/wp-json\/wp\/v2\/tags?post=1270"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}