This preview shows pages 1–2. Sign up to view the full content.
This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: dispchar al, m2 endm dispchar macro arg, 11 mov dl, arg cmp dl, 09H jle l1 add dl, 07H l1: add dl, 30h mov ah, 02H int 21h endm .data a db "00001010B" res db ? ans db ? cnt db ? Flowchart 56 .code Microprocessors & Applications (UPTU) Appendix B mov ax, @data ; Initialize data section mov ds, ax mov al, a ; Load number1 in al mov cl, 07H lea si, a up : mov cnt, cl call power mov bl, res mov al, [si] sub al, 30H mul bl add ans, al inc si dec cl jnz up disp ans mov ah, 4Ch int 21h power proc near mov ch, cnt mov bl, 01 up1: mov al, 02h mul bl mov bl, al dec ch cmp ch, 00 jnz up1 mov res, bl ret power endp end Result : 0A...
View Full Document
This note was uploaded on 08/04/2011 for the course ECON 101 taught by Professor Lucky during the Spring '11 term at Silver Lake.
- Spring '11