Board logo

标题: 让你的启动盘不一样 [打印本页]

作者: sparrow1058     时间: 2006-11-29 09:20    标题: 让你的启动盘不一样

将下面代码用masm编译,生成color.exe 加入到autoexec.bat 可以让你的启动盘不一样。
;color.asm
;9 bright blue; a bright green;  b,c,d,e,f
;根据秒数初始化你的dos界面
.model  small
.data
.386
.code
start:        mov        ax,@data
        mov        ds,ax
        mov        al,00h
        out        70h,al
        nop
        in        al,71h     ;get second
        and        ax,00ffh
        cmp        ax,07h
        jb        @F
        mov        cl,07h
        div        cl
        mov        al,ah
@@:
        add        al,9
        mov        bh,al
        mov        cx,0h
        mov     dx,2479h
        mov     ax,0600h
        int     10h
        mov     bh,0
        mov     dx,0
        mov     ah,02h
        int     10h
        mov        ah,4ch
        int        21h
end        start

[ Last edited by sparrow1058 on 2006-11-29 at 09:23 AM ]
作者: electronixtar     时间: 2006-11-29 09:30
顶啊~~~
作者: manbuz     时间: 2006-12-1 05:17
呵呵,可以不用买单片机学习了。。楼主这行是高手啊