Поможем написать учебную работу
Если у вас возникли сложности с курсовой, контрольной, дипломной, рефератом, отчетом по практике, научно-исследовательской и любой другой работой - мы готовы помочь.
Если у вас возникли сложности с курсовой, контрольной, дипломной, рефератом, отчетом по практике, научно-исследовательской и любой другой работой - мы готовы помочь.
1-билет
include <p16F788.inc>
A EQU h'21'
K_SOT EQU h'22'
K_DES EQU h'23'
K_ED EQU h'24'
Rab_reg EQU h'25'
VYCH EQU h'26'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
MOVF A, W
MOVWF Rab_reg
MOVLW D'100'
MOVWF VYCH
M_SOT
INCF K_SOT, F
SUBWF Rab_reg, F
BTFSC STATUS,C
GOTO M_SOT
ADDWF Rab_reg, F
DECF K_SOT, F
MOVLW D'10'
MOVWF VYCH
M_DES
INCF K_DES, F
SUBWF Rab_reg, F
BTFSC STATUS,C
GOTO M_DES
ADDWF Rab_reg, F
DECF K_DES, F
MOVF Rab_Reg, W
MOVWF K_ED
GOTO $
END
2-билет
include<p16F788.inc>
R1 EQU h'3A'
R2 EQU h'22'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
BSF STATUS,PR0
CLRF TRISC
BCF STATUS,PR0
MOVLW h'EA'
MOVWF R2
MOVF R1,W
XORWF R2,W
BTFSS STATUS,Z
GOTO M
SWAPF R2,W
MOVWF PORTC
GOTO$
M CLRF R2
GOTO $
END
3-билет
include<p16F788.inc>
R1 EQU h'21'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
BSF STATUS,PR0
CLRF TRISC
BCF STATUS,PR0
MOVLW h'25'
MOVWF R1
MOVLW B'10010111'
ANDWF h'2F',W
XORWF R1,W
BTFSS STATUS,Z
GOTO M
CLRF h'2F'
GOTO $
M
MOVWF PORTC
GOTO $
END
25,23,24,15-билет
include <p16F788.inc>
A EQU h'21'
B EQU h'22'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
CLRF PORTD
BSF STATUS,PR0
CLRF TRISC
CLRF TRISD
BCF STATUS,PR0
MOVF A, W
SUBWF B,W
BTFSS STATUS, C
GOTO M
NOP
XORWF B, W
BTFSS STATUS, Z
GOTO $
MOVLW B'11111111'
MOVWF PORTD
GOTO $
M
MOVLW B'11111111'
MOVWF PORTC
GOTO $
END
22-билет
include <p16F788.inc>
SAN EQU h'21'
K_DES EQU h'23'
K_ED EQU h'24'
Rab_reg EQU h'25'
VYCH EQU h'26'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTD
BSF STATUS,PR0
BCF TRISD,6
BCF STATUS,PR0
BSF PORTD,6
M BTFSS PORTD,3
GOTO M
INCF 2AH, W
MOVWF SAN
MOVWF Rab_reg
MOVLW D'10'
MOVWF VYCH
M_DES
INCF K_DES, F
SUBWF Rab_reg, F
BTFSC STATUS,C
GOTO M_DES
ADDWF Rab_reg, F
DECF K_DES, F
MOVF Rab_Reg, W
MOVWF K_ED
GOTO $
END
19-билет
include <p16F788.inc>
R1 EQU h'21'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
BSF STATUS,PR0
CLRF TRISC
BCF STATUS,PR0
MOVLW H'54'
MOVWF R1
XORWF 40H, W
BTFSS STATUS, Z
GOTO M
MOVLW B'01010101'
MOVWF PORTC
GOTO $
M
MOVLW B'10101010'
MOVWF PORTC
GOTO $
END
20-билет
include <p16F788.inc>
A EQU h'21'
B EQU h'22'
C EQU h'23'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
CLRF PORTD
BSF STATUS,PR0
CLRF TRISC
BCF TRISD,7
BCF STATUS,PR0
BSF PORTD,7
M BTFSS PORTD,2
GOTO M
MOVF B, W
SUBWF A, W
BTFSS STATUS, C
GOTO M1
MOVF B, W
MOVWF C
GOTO K
M1 MOVF A, W
MOVWF C
K MOVF C, W
MOVWF PORTC
GOTO $
END
21-билет
include <p16F788.inc>
ADR EQU h'21'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
CLRF PORTD
BSF STATUS,PR0
CLRF TRISC
BCF TRISD,7
BCF STATUS,PR0
BSF PORTD,7
M BTFSS PORTD,2
GOTO M
MOVLW 26H
MOVWF FSR
NEXT
MOVWF INDF
RLF INDF,0
MOVWF ADR
INCF FSR, F
MOVLW 41H
XORWF FSR,0
BTFSS STATUS,Z
GOTO NEXT
MOVLW B'10000000'
MOVWF PORTD
GOTO $
END
16-билет
include<p16F788.inc>
R1 EQU h'21''
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTD
BSF STATUS,PR0
CLRF TRISD
BCF STATUS,PR0
MOVF 2FH, W
ANDWF 2BH, W
MOVWF R1
MOVLW B'00000000'
XORWF R1, W
BTFSS STATUS, Z
GOTO M
MOVWF 2CH
GOTO $
M
MOVLW B'11111111'
MOVWF PORTD
GOTO $
END
17-билет
include<p16F788.inc>
R1 EQU h'21'
R2 EQU h'22'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTD
BSF STATUS,PR0
CLRF TRISD
BCF STATUS,PR0
MOVF 2AH, W
IORWF 2CH, W
MOVWF R1
MOVLW 5AH
MOVWF R2
MOVF R1, W
XORWF R2, W
BTFSS STATUS, Z
GOTO M
GOTO $
M
MOVLW B'11111111'
MOVWF PORTD
GOTO $
END
18-билет
include <p16F788.inc>
ADR EQU h'21'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
CLRF PORTC
BSF STATUS,PR0
CLRF TRISC
BCF STATUS,PR0
MOVLW 26H
MOVWF FSR
NEXT
MOVWF INDF
MOVLW B'10001000'
IORWF INDF,W
MOVWF ADR
INCF FSR, F
MOVLW 41H
XORWF FSR,0
BTFSS STATUS,Z
GOTO NEXT
M BSF PORTS,7
NOP
NOP
NOP
GOTO M
GOTO $
END
13-билет
include <p16F788.inc>
A EQU h'21'
B EQU h'22'
C EQU h'23'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
MOVF A, W
SUBWF B, W
BTFSS STATUS, C
GOTO M
MOVF A, W
MOVWF C
GOTO K
M
MOVF B, W
MOVWF C
K
MOVLW 31H
MOVWF FSR
NEXT
MOVF C, W
MOVWF INDF
INCF FSR, F
MOVLW 40H
XORWF FSR,0
BTFSS STATUS,Z
GOTO NEXT
GOTO $
END
14-билет
include <p16F788.inc>
A EQU h'21'
B EQU h'22'
C EQU h'23'
ORG h'00'
NOP
NOP
NOP
ORG h'05'
START
CLRF STATUS
MOVF A, W
SUBWF B, W
BTFSS STATUS, C
GOTO M
MOVF B, W
MOVWF C
GOTO K
M
MOVF A, W
MOVWF C
K
MOVLW 71H
MOVWF FSR
NEXT
MOVF C, W
MOVWF INDF
INCF FSR, F
BSF STATUS, PR0
MOVLW 80H
XORWF FSR,0
BTFSS STATUS,Z
GOTO NEXT
GOTO $
END