Presentation is loading. Please wait.

Presentation is loading. Please wait.

Microprocessor Lab CSL1543 0:0:2

Similar presentations


Presentation on theme: "Microprocessor Lab CSL1543 0:0:2"— Presentation transcript:

1 Microprocessor Lab CSL1543 0:0:2
Week 10 : DAC Interfacing

2 1. WRITE AND EXECUTE AN ASSEMBLY LANGUAGE PROGRAM TO GENERATE THE SQUARE WAVEFORM USING A DAC INTERFACE. Department of CSE, MSRIT

3 SQUARE WAVE .MODEL SMALL .STACK 100 .DATA .CODE DELAY PROC NEAR
MOV BX, 0FFFH L1: MOV SI, 02FFFH L2: DEC SI JNZ L2 DEC DX JNZ L1 RET DELAY ENDP Department of CSE, MSRIT

4 .MODEL SMALL .STACK 100 .DATA .CODE DELAY PROC NEAR DELAY ENDP
START: MOV MOV DS, AX MOV AL, 80H MOV DX, 24A3H OUT DX, AL SQUARE: MOV AL, 00H MOV DX, 24A0H CALL DELAY MOV AL, 0FFH MOV AH, 06h MOV DL, 0FFh INT 21h JNZ LAST JMP SQUARE ;INT 03H LAST: MOV AH,04Ch END START .MODEL SMALL .STACK 100 .DATA .CODE DELAY PROC NEAR MOV BX, 0FFFH L1: MOV SI, 02FFFH L2: DEC SI JNZ L2 DEC DX JNZ L1 RET DELAY ENDP Department of CSE, MSRIT

5 2. WRITE AND EXECUTE AN ASSEMBLY LANGUAGE PROGRAM TO GENERATE THE TRIANGULAR WAVEFORM USING A DAC INTERFACE. Department of CSE, MSRIT

6 MOV AH, 06h MOV DL, 0FFh INT 21h JNZ LAST JMP L1 INT 03H
.MODEL SMALL .STACK 100 .DATA .CODE START: MOV MOV DS, AX MOV AL, 80H MOV DX, 24A3H OUT DX, AL L1: MOV AL, 00H UP: MOV DX, 24A0H INC AL CMP AL, 0FFH JNE UP MOV AL, 0FFH DOWN: MOV DX, 24A0H DEC AL CMP AL, 00H JNE DOWN MOV AH, 06h MOV DL, 0FFh INT 21h JNZ LAST JMP L1 INT 03H LAST: MOV AH,04Ch END START Department of CSE, MSRIT

7 3. WRITE AND EXECUTE AN ASSEMBLY LANGUAGE PROGRAM TO GENERATE THE RAMP WAVE (UP) USING THE DAC INTERFACE. Department of CSE, MSRIT

8 MODEL SMALL .STACK 20 .DATA .CODE START: MOV MOV DS, AX MOV AL, 80H MOV DX, 24A3H OUT DX, AL L1: MOV AL, 00H UP: MOV DX, 24A0H INC AL CMP AL, 0FFH JNE UP MOV AH, 06h MOV DL, 0FFh INT 21h JNZ LAST JMP L1 LAST: MOV AH, 04ch ; INT 03H END START Department of CSE, MSRIT

9 4. WRITE A PROGRAM TO INTERFACE A DAC TO GENERATE A RAMP WAVE FORM (DOWN).
Department of CSE, MSRIT

10 .MODEL SMALL .STACK 100 .DATA .CODE START: MOV MOV DS, AX MOV AL, 80H MOV DX, 24A3H OUT DX, AL L1: MOV AL, 0FFH UP: MOV DX, 24A0H DEC AL CMP AL, 00H JNE UP MOV AH, 06h MOV DL, 0FFh INT 21h JNZ LAST JMP L1 INT 03H LAST: MOV AH, 04ch END START Department of CSE, MSRIT


Download ppt "Microprocessor Lab CSL1543 0:0:2"

Similar presentations


Ads by Google