Universal Remote Control R7 - SPECS SHEET Manual de usuario Pagina 22

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 31
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 21
S3F80KB_AN_REV 0.00 (Preliminary Spec) IR REMOTE CONTROLLER
21
;Set FOSC/256
LD T0OvrCntH,#00H
InitFast:
AND T1CON,#11111110B ;Clear Timer1 interrupt pending bit
OR T1CON,#00001000B ;Clear Timer1 counter
LDW IPH,#T1FastInt1st ;Load address of fast ISR
LD T1FastFlag,#00H ;fast inerrupt flag
LD T0OvrCnt,#00H ;T0OVR ISR counter
LD PulseCnt,#00H ;falling edge counter
LD R0,#080H
LD R2,#08H
LDW RR14,#0000H
LD R11,#0BH ;IR_Cnt pointer
LD R1,#04H
EI
RcvLoop: ;loop until the first pulse received
TM T0OvrCntH,#04H ;check learning mode counter limit
JP NZ,LearningMode ;if T0OvrCntH > #04H,exit loop
TM R15,#01H ;pulse received
JR NZ,CheckNoise
JR RcvLoop
CheckNoise:
LD R3,P3
AND R3,#00001000B
;JP NZ,InitFast ;If P3.3 is not low, Pulse is noise
LDW RR12,RR6
;DJNZ R0,CheckNoise ;Check P3.3 for 3 times.
LD T0OvrCnt,#00H
;OR T1CON,#00001000B
;=============================================================================;
; @brief Leader signal capture ;
;=============================================================================;
LeaderHInit:
LDW RR4,SignalStart ;first signal time
Wait:
DJNZ R0,Wait
;Wait for the low signal
Vista de pagina 21
1 2 ... 17 18 19 20 21 22 23 24 25 26 27 ... 30 31

Comentarios a estos manuales

Sin comentarios