2017-01-09 20:23:01 +08:00
|
|
|
/**************************************************************************************
|
|
|
|
|
Filename: ir_defs.h
|
2016-11-03 23:04:54 +08:00
|
|
|
Revised: Date: 2016-10-26
|
2016-11-02 22:29:13 +08:00
|
|
|
Revision: Revision: 1.0
|
|
|
|
|
|
2016-11-03 22:53:45 +08:00
|
|
|
Description: This file provides algorithms for IR decode
|
|
|
|
|
|
2016-11-02 22:29:13 +08:00
|
|
|
Revision log:
|
2016-11-03 23:04:54 +08:00
|
|
|
* 2016-10-01: created by strawmanbobi
|
2017-01-09 20:23:01 +08:00
|
|
|
**************************************************************************************/
|
2016-11-02 22:29:13 +08:00
|
|
|
|
2020-03-08 19:41:00 +08:00
|
|
|
#ifndef _IR_DEFS_H
|
|
|
|
|
#define _IR_DEFS_H
|
|
|
|
|
|
2026-01-06 12:24:48 +08:00
|
|
|
#define IR_DECODE_LIB_VER "1.5.2"
|
2025-09-22 09:17:01 +08:00
|
|
|
|
2020-07-26 20:49:42 +08:00
|
|
|
#if defined (BOARD_PC)
|
2020-03-08 19:41:00 +08:00
|
|
|
#pragma ide diagnostic ignored "OCUnusedGlobalDeclarationInspection"
|
|
|
|
|
#pragma ide diagnostic ignored "OCUnusedMacroInspection"
|
2020-07-26 20:49:42 +08:00
|
|
|
#endif
|
2016-12-14 21:37:56 +08:00
|
|
|
|
2016-11-02 22:29:13 +08:00
|
|
|
#ifdef __cplusplus
|
|
|
|
|
extern "C"
|
|
|
|
|
{
|
|
|
|
|
#endif
|
|
|
|
|
|
2016-12-14 21:37:56 +08:00
|
|
|
#if defined BOARD_ANDROID
|
|
|
|
|
#include <android/log.h>
|
2017-01-21 20:28:52 +08:00
|
|
|
#define LOG_TAG "ir_decode"
|
2016-12-14 21:37:56 +08:00
|
|
|
#endif
|
|
|
|
|
|
2016-11-02 22:29:13 +08:00
|
|
|
#define TRUE 1
|
|
|
|
|
#define FALSE 0
|
|
|
|
|
|
2018-01-19 19:21:28 +08:00
|
|
|
#define FORMAT_HEX 16
|
|
|
|
|
#define FORMAT_DECIMAL 10
|
|
|
|
|
|
2019-03-04 23:40:49 +08:00
|
|
|
// #define USE_DYNAMIC_TAG 1
|
|
|
|
|
|
|
|
|
|
#if defined USE_DYNAMIC_TAG
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
#endif
|
2018-01-19 19:21:28 +08:00
|
|
|
|
2016-11-02 22:29:13 +08:00
|
|
|
typedef unsigned char UINT8;
|
|
|
|
|
typedef signed char INT8;
|
|
|
|
|
typedef unsigned short UINT16;
|
|
|
|
|
typedef signed short INT16;
|
2017-01-02 18:38:22 +08:00
|
|
|
typedef signed int INT;
|
|
|
|
|
typedef unsigned int UINT;
|
2016-12-14 21:37:56 +08:00
|
|
|
typedef int BOOL;
|
2016-11-02 22:29:13 +08:00
|
|
|
|
2017-05-31 20:36:08 +08:00
|
|
|
void noprint(const char *fmt, ...);
|
|
|
|
|
|
2018-01-19 19:21:28 +08:00
|
|
|
#define ir_malloc(A) malloc(A)
|
|
|
|
|
#define ir_free(A) free(A)
|
2017-03-16 21:42:32 +08:00
|
|
|
|
2017-01-21 20:28:52 +08:00
|
|
|
#define ir_memcpy(A, B, C) memcpy(A, B, C)
|
|
|
|
|
#define ir_memset(A, B, C) memset(A, B, C)
|
|
|
|
|
#define ir_strlen(A) strlen(A)
|
2019-03-03 21:23:50 +08:00
|
|
|
#if ((defined BOARD_PC) || (defined BOARD_PC_JNI)) && (defined DEBUG)
|
2025-10-04 10:18:17 +08:00
|
|
|
#define ir_printf(...) do { printf(__VA_ARGS__); fflush(stdout); } while(0)
|
2017-05-31 20:36:08 +08:00
|
|
|
#else
|
|
|
|
|
#define ir_printf noprint
|
|
|
|
|
#endif
|
2017-03-06 21:07:52 +08:00
|
|
|
#define USER_DATA_SIZE 1636
|
2019-03-04 23:40:49 +08:00
|
|
|
// #define USER_DATA_SIZE 4096
|
2016-11-02 22:29:13 +08:00
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
|
}
|
|
|
|
|
#endif
|
2020-03-08 19:41:00 +08:00
|
|
|
#endif //_IR_DEFS_H
|