Elisa3
|
00001 /******************************************************************************** 00002 00003 control IR receiver module 00004 september 2005 : first version 00005 Valentin Longchamp 00006 00007 00008 This file is part of the e-puck library license. 00009 See http://www.e-puck.org/index.php?option=com_content&task=view&id=18&Itemid=45 00010 00011 (c) 2004-2007 Valentin Longchamp 00012 00013 Robotics system laboratory http://lsro.epfl.ch 00014 Laboratory of intelligent systems http://lis.epfl.ch 00015 Swarm intelligent systems group http://swis.epfl.ch 00016 EPFL Ecole polytechnique federale de Lausanne http://www.epfl.ch 00017 00018 **********************************************************************************/ 00019 00046 /******************************************************************** 00047 * control IR receiver module * 00048 * september 2005 : first version * 00049 * Valentin Longchamp * 00050 * * 00051 ********************************************************************/ 00052 00088 #include <avr\io.h> 00089 #include <avr\interrupt.h> 00090 #include "variables.h" 00091 00092 00093 #ifndef _IR_REMOTE_CONTROLE 00094 #define _IR_REMOTE_CONTROLE 00095 00096 #define REMOTE (PINJ & _BV(PJ6))>>6 //_RB7 //_LATB7 00097 //#define REMOTE_DIR _TRISB7 00098 00099 /* defines for the keys on the remote controler 00100 * the numbers 0 to 9 are not defined since they are the same */ 00101 #define BOTTOMR 10 // -/-- key 00102 #define BOTTOMl 11 // p<p key 00103 #define STANDBY 12 00104 #define MUTE 13 00105 #define VOL_UP 16 00106 #define VOL_DOWN 17 00107 #define CHAN_UP 32 00108 #define CHAN_DOWN 33 00109 #define I_II 35 00110 #define OUT_AUX_1 56 00111 00112 00113 00114 /* functions */ 00115 void e_init_remote_control(void); 00116 void e_read_remote_control(void); 00117 00118 unsigned char e_get_check(void); 00119 unsigned char e_get_address(void); 00120 unsigned char e_get_data(void); 00121 00122 #endif