Sony IR Remote


Results 1 to 40 of 41

Thread: Sony IR Remote

Threaded View

  1. #29
    Join Date
    Dec 2008
    Location
    Ploiesti, ROMANIA
    Posts
    582


    Did you find this post helpful? Yes | No

    Default

    Using PIC 16F628A I build this remote-by-wire for my Blaupunkt Radio-SD Card. Work verry fine... even it's simple and can be improved.
    Code:
    ;
    ; Simple Remote-by-wire for Blaupunkt ; use RC10 protocol
    ;
    @ DEVICE pic16F628A, XT_OSC, WDT_OFF, PWRT_OFF, BOD_OFF, MCLR_ON, LVP_OFF, CPD_OFF, PROTECT_OFF     
    
    DEFINE  OSC 4      ; USE 4 MHz crystal                       
    
    TRISA= %00000000                   
    TRISB= %00011111 			
    CMCON=7                                
    
    TO_BLAU VAR PORTA.0
    TO_BLAU = 1 
    
    PULSA	VAR WORD
    PULSB	VAR WORD
    I	VAR BYTE
    
    DELAYS  CON 660
    
    
    MAIN :
    PAUSE 500
        	IF PORTB.0 = 0 THEN        'volume +
        	PULSA=2650
        	PULSB=2580
        	GOSUB PULSE
        	ENDIF 
    
    
    	IF PORTB.1 = 0 THEN        'volume -
    	PULSA = 3250
    	PULSB = 3200
    	GOSUB PULSE
    	ENDIF
    
    	IF PORTB.2 = 0 THEN        'mute
        	PULSA = 5050
        	PULSB = 5000
    	GOSUB PULSE
    	ENDIF
    
        	IF PORTB.3 = 0 THEN        'SRC aka Source
    	PULSA = 6875     
    	PULSB = 6850     
        	GOSUB PULSE
    	ENDIF
    
        	IF PORTB.4 = 0 THEN        'Next aka Right
    	PULSA = 5660    
    	PULSB = 5630     
        	GOSUB PULSE
    	ENDIF
    	
    GOTO MAIN
    
    ;SUBROUTINE
    
    PULSE:
    	FOR I = 1 TO 10
    		LOW TO_BLAU
    		PAUSEUS PULSA
    		HIGH TO_BLAU
    		PAUSEUS PULSB
    		LOW TO_BLAU
    		PAUSEUS DELAYS
    		HIGH TO_BLAU
    		PAUSEUS 50000
    		PAUSEUS 50000
    	NEXT I	
    RETURN
    
    END
    Attached Images Attached Images  

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts