荆棘 发表于 2012-11-14 18:53:52

这个是哪里错了的?

assume cs:codesg,ds:datasg
datasgsegment
      db 'welcome to masm!'
                db '................'
    datasg ends

codesg segment         

start:mov ax,datasg
      mov ds,ax
          mov bl,0h
          mov cx,16
          
        s:mov ,
          inc bl
          loop s
          
          mov ah,4ch
          int 21h
codesg ends
    end start
       


s0512 发表于 2012-11-14 18:53:53

assume cs:codesg,ds:datasg
datasgsegment
      db 'welcome to masm!'
                db '................'
    datasg ends

codesg segment         

start:mov ax,datasg
      mov ds,ax
          mov bx,0h
          mov cx,16
         
       ; s:mov ,;MOV不能同时为内存地址
s:      mov al,
          mov ,al      
          inc bx
          loop s
         
          mov ah,4ch
          int 21h
codesg ends
    end start
小修改了上,楼主过目{:5_110:}

荆棘 发表于 2012-11-14 18:54:41

求帮助!求帮助!求帮助!

zzwwjj000 发表于 2012-11-14 19:23:22

bl好像不是默认的偏移地址寄存器,,好像不能放在一起用

荆棘 发表于 2012-11-14 21:32:37

zzwwjj000 发表于 2012-11-14 19:23 static/image/common/back.gif
bl好像不是默认的偏移地址寄存器,,好像不能放在一起用

不是的 代表的是 DS: 中存放的数据   用代表的是 bx的第八位寄存器 这样子不行吗?我看不出这个有什么问题的 可是编译出错

荆棘 发表于 2012-11-14 21:37:37

zzwwjj000 发表于 2012-11-14 19:23 static/image/common/back.gif
bl好像不是默认的偏移地址寄存器,,好像不能放在一起用

低八位   

博丽灵梦 发表于 2012-11-15 15:40:02


就是这里的问题哦

s0512 发表于 2012-11-15 18:34:09

打了错别字,晕倒。。。
修改了下下

荆棘 发表于 2012-11-15 23:32:16

s0512 发表于 2012-11-15 18:33 static/image/common/back.gif
assume cs:codesg,ds:datasg
datasgsegment
      db 'welcome to masm!'


谢了呀!这个是我错了!不过这题我主要是想弄明白为什么 偏移地址为什么不能是8位的 都已经解决了
页: [1]
查看完整版本: 这个是哪里错了的?