⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 irremote.h

📁 IT projecotr reference design.
💻 H
字号:
/****************************************************************************/
/*             TEXAS INSTRUMENTS PROPRIETARY INFORMATION                    */
/*                                                                          */
/*  (c) Copyright, Texas Instruments Incorporated, 2006.                    */
/*      All Rights Reserved.                                                */
/*                                                                          */
/*  Property of Texas Instruments Incorporated. Restricted Rights -         */
/*  Use, duplication, or disclosure is subject to restrictions set          */
/*  forth in TI's program license agreement and associated documentation.   */
/****************************************************************************/

/****************************************************************************/
/* irRemote.h                                                               */
/*                                                                          */
/* Application interface to IR remote control.                              */
/****************************************************************************/


#ifndef __IRREMOTE_H
#define __IRREMOTE_H

#include "common.h"
#include "sysmon.h"
#include "keycode.h"


/****************************************************************************/
/* Manifest constants and declarations.                                     */
/****************************************************************************/

                        /****************************************************/
                        /* Timing constants.                                */
                        /*                                                  */
                        /* Use care in defining frequencies so that arith-  */
                        /* metic truncation does not cause excessive error  */
                        /* in calculated values.                            */
                        /****************************************************/

#define GIR_CLOCK_FREQ   16666666                                     /* Hz */
#define IR_SAMPLING_FREQ   166666                                     /* Hz */

#define IRSAMPLEPERIOD   ( 1000000 / IR_SAMPLING_FREQ )
#define IR_DIVIDER       ((uint16)(( GIR_CLOCK_FREQ / IR_SAMPLING_FREQ ) - 1 ))

#define FRT_TICKS_PER_MILLISECOND   16667                          /* ticks */

#define IRMSGSYNC   0x4656                           /* IR-message sync tag */

#define IR_EOFRAME  10000               /* end-of-frame delay, microseconds */

                        /****************************************************/
                        /* IR protocol interface structure.                 */
                        /*                                                  */
                        /* One of these structures is defined by each IR    */
                        /* protocol decoder to make its entry points known  */
                        /* to the main IR handler.                          */
                        /*                                                  */
                        /* startFunc: Called by the IR handler to start the */
                        /*      protocol decoder at initialization time.    */
                        /* eventFunc: Called by the IR handler for each IR  */
                        /* waveform edge seen by the IR receiver.           */
                        /****************************************************/

typedef struct IRProtocolInterfaceStruct
{
    void (*startFunc)( uint08 port );
    BOOL (*eventFunc)( UIREP *report, uint08 port, uint16 event );
}
    IR_PROTOIF_STRUCT;


                        /****************************************************/
                        /* Public functions.                                */
                        /****************************************************/

void irRemote_info( TASKINFO_STRUCT *info );
EXEC_CC_ENUM irfunc_init( void );

uint32 irfunc_MsecTime( void );                        /* millisecond timer */

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -