随笔分类 -  汇编语言

摘要:assume cs:code,ss:stack stack segment db 16 dup(0) stack ends code segment s: mov al,5 mov bl,3 ret;return to block clode behind the call start: mov a 阅读全文
posted @ 2022-11-27 13:18 Z_Chan 编辑
摘要:上代码 assume cs:code,ss:stack stack segment db 16 dup(0) stack ends code segment s: mov bx,16 ret;return to block clode behind the call start: mov ax,st 阅读全文
posted @ 2022-11-27 12:42 Z_Chan 编辑
摘要:;ret and call assume cs:code stack segment db 8 dup(0) stack ends code segment mov ax,4c00h int 21h start: mov ax,stack mov ss,ax mov sp,8;stack top p 阅读全文
posted @ 2022-11-26 17:29 Z_Chan 编辑
摘要:assume cs:code,ss:stack stack segment db 4 dup(11h);create 4 byte's memory and inject 11*4 stack ends code segment start: mov ax,stack mov ss,ax mov a 阅读全文
posted @ 2022-11-26 17:07 Z_Chan 编辑
摘要:offset就是把偏移地址取出来 ;offset can get ip address in front of the : assume cs:code code segment start: mov ax,offset start s:mov ax,offset s code ends end s 阅读全文
posted @ 2022-11-24 13:57 Z_Chan 编辑
摘要:我们用dx,实现cx数据的临时存储 ;dx be used for double loops, it can save the value of cx ;double loop assume cs:code code segment mov cx,2h mov ax,0h s: mov dx,cx 阅读全文
posted @ 2022-11-23 13:33 Z_Chan 编辑
摘要:效果图,在地址76c:0这里本来是abc的,上代码 assume ds:data,cs:code data segment db 'abc' data ends;data block but the data will be saved in memory block 76c:0 code segm 阅读全文
posted @ 2022-11-23 09:15 Z_Chan 编辑
摘要:版权声明:本文为CSDN博主「JackieZhengChina」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。 原文链接:https://blog.csdn.net/admans/article/details/106942355 阅读全文
posted @ 2022-11-22 11:27 Z_Chan 编辑
摘要:assume cs:code code segment ; db 1h,2h,3h,4h; arr[] in cs ip=[0,1,2,3] dw 1200h,1300h; arr[] in cs ip=[0,2,4] 读出来是反的1200变0012,很烦这个我一般都是试一下就知道了不记 ;会读成代 阅读全文
posted @ 2022-11-21 12:18 Z_Chan 编辑
摘要:assume cs:code code segment mov cx,0ffh ;循环ff次,到00就停止loop mov bx,0 ;初始化bx,这个是偏移地址 s: mov ax,0h mov ds,ax ;确定ds段地址为0 mov al,ds:[bx] ;两位两位读数据 add bx,200 阅读全文
posted @ 2022-11-21 12:07 Z_Chan 编辑
摘要:assume cs:codesg codesg segment mov ax,1000h mov ds,ax mov ax,[5];this [5] can not symbol [5] in debug ;or mov ax,ds:[5] ; mov bx,5 ; mov ax,[bx] ; mo 阅读全文
posted @ 2022-11-21 11:27 Z_Chan 编辑
摘要:assume cs:codesg codesg segment mov ax,12h mov ax,4c00h int 21h ;return to cmd -p codesg ends end assume cs:codesg //确定cs段地址,就是代码段地址,取个别名叫codesg codes 阅读全文
posted @ 2022-11-21 11:20 Z_Chan 编辑
摘要:效果图 手机安装gcc .data msg: .asciz "hello, gnu asm\n" len = .- msg .text .global main main: push {r0,r1,r2,lr} ldr r1,=msg mov r0, #1 ldr r2, =len mov %r7, 阅读全文
posted @ 2022-11-14 14:09 Z_Chan 编辑
摘要:debug -a mov ax,11 mov bx,12 add ax,bx mov ax,00 -t ;一条一条执行即可 ax bx cx dx都是寄存器 mov ax,11 ;ax=11H add ax,E ;ax=ax+EH debug默认16进制,因为四位二进制对应一位16进制,好用 阅读全文
posted @ 2022-11-13 11:51 Z_Chan 编辑

点击右上角即可分享
微信分享提示