汇编网首页登录博客注册
tenyears的学习博客
博客首页博客互动【做检测题】论坛求助

我的博客

个人首页 |  我的文章 |  我的相册 |  我的好友 |  最新访客 |  文章收藏 |  论坛提问 |  友情链接 |  给我留言  
图片载入中
学习动态
最新留言
好友圈
文章收藏
友情链接

[2010-05-16 14:08] 实验17  编写包含多个功能子程序的中断例程

点击查看原图
实验测试结果:debug跟踪调试,返回参数错误代码AH=80 

中断安装程序:t170.exe
assume cs:code

code segment

int7ch:        jmp short set
table1        dw  subr,subw
table2        db  3 dup(0)
set:        push bx
        cmp ah,1
        ja sret
        mov bl,ah
        mov bh,0
        add bx,bx
        call word ptr table1[bx]

sret:        pop bx
        iret

subr:        push cx
        push dx
        ...
阅读全文 | 评论次数(0) | 浏览次数(530) | 所属类型(汇编作业)

[2010-05-15 22:08] 实验16 效果图4

点击查看原图
清屏...
阅读全文 | 评论次数(0) | 浏览次数(572) | 所属类型(汇编作业)

[2010-05-15 22:08] 实验16 效果图3

点击查看原图
设置前景色...
阅读全文 | 评论次数(0) | 浏览次数(564) | 所属类型(汇编作业)

[2010-05-15 22:07] 实验16 效果图2

点击查看原图
设置背景色...
阅读全文 | 评论次数(0) | 浏览次数(478) | 所属类型(汇编作业)

[2010-05-15 22:06] 实验16 编写包含多个功能子程序的中断例程

点击查看原图
通过做这个实验,犯了大家都放的错误,没有真正理解程序入口地址的直接定址表的真正含义,table的偏移设置,cs、ip的设置

安装一个新的int7ch中断例程,为显示输出提供如下功能子程序。
1、清屏    
2、设置前景色  
3、设置背景色
4、向上滚动一行
入口参数:ah传递功能号,al传递颜色值

安装程序:t161.exe

assume cs:code  

code segment
int7c:        jmp short set
table        dw  sub1,sub2,sub3,sub4

set:        push bx
        cmp ah,3
        ja sr...
阅读全文 | 评论次数(0) | 浏览次数(617) | 所属类型(汇编作业)

[2010-05-15 21:56] 实验15 安装新的int 9 中断例程

点击查看原图
在DOS下,按下“A”后,除非不再松开,如果松开,就显示满屏“A”
assume cs:code

stack segment
  db 128 dup(0)
stack ends

code segment
start:        mov ax,stack
        mov ss,ax
        mov sp,128

        push cs
        pop ds

        mov ax,0
        mov es,ax

        mov si,offset int9
        mov di,204h
        mov cx,offset int9end-offset int9
        cld
        rep movsb

        p...
阅读全文 | 评论次数(0) | 浏览次数(573) | 所属类型(汇编作业)

[2010-05-15 21:33] 实验14 访问CMOS RAM

点击查看原图
assume cs:code

data segment
db 9,'/',8,'/',7,' ',4,':',2,':',0
data ends

code segment
start:        mov ax,data
        mov ds,ax
        mov ax,0b800h
        mov es,ax
        mov si,0
        mov di,0
        mov cx,11
s0:        push cx
        mov al,[si]
        cmp al,9
        ja s1
        out 70h,al
        in al,71h
        mov ah,al
        mov cl,4
        shr ah,cl
        and ...
阅读全文 | 评论次数(0) | 浏览次数(520) | 所属类型(汇编作业)

[2010-05-15 21:30] 实验13  编写、应用中断例程3

点击查看原图
分别在屏幕的第2,4,6,8行显示4句英文诗
assume cs:code 
code segment 
s1: db 'Good,better,best,','$' 
s2: db 'Never let it rest,','$' 
s3: db 'Till good is better,','$' 
s4: db 'And better,best.','$' 
s:  dw offset s1,offset s2,offset s3,offset s4 
row:db 4,6,8,10 

start:  mov ax,cs 
        mov ds,ax 
...
阅读全文 | 评论次数(0) | 浏览次数(565) | 所属类型(汇编作业)

[2010-05-15 21:27] 实验13  编写、应用中断例程2

点击查看原图
应用2:完成loop指令的功能
中断安装程序:t41.exe
assume cs:code
code segment
start:        mov ax,cs
        mov ds,ax
        mov si,offset do0
        mov ax,0
        mov es,ax
        mov di,200h
        mov cx,offset do0end-offset do0
        cld
        rep movsb

        mov ax,0
        mov es,ax
        mov word ptr es:[7ch*4],200h
        mov word ptr es:[7ch*4+2],0

        mov ax,4c...
阅读全文 | 评论次数(0) | 浏览次数(558) | 所属类型(汇编作业)

[2010-05-15 21:24] 实验13  编写、应用中断例程

点击查看原图
应用1:显示一个用0结束的字符串
中断安装程序:t39.exe
assume cs:code
code segment
start:        mov ax,cs
        mov ds,ax
        mov si,offset do0
        mov ax,0
        mov es,ax
        mov di,200h
        mov cx,offset do0end-offset do0
        cld
        rep movsb

        mov ax,0
        mov es,ax
        mov word ptr es:[7ch*4],200h
        mov word ptr es:[7ch*4+2],0

        mov ax,4...
阅读全文 | 评论次数(0) | 浏览次数(493) | 所属类型(汇编作业)
『 查看更多文章 』