TMPM4G9  V1.0.0.0
remote.h
Go to the documentation of this file.
1 
13 /*------------------------------------------------------------------------------*/
14 /* Define to prevent recursive inclusion */
15 /*------------------------------------------------------------------------------*/
16 #ifndef __REMOTE_H
17 #define __REMOTE_H
18 
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22 
23 /*------------------------------------------------------------------------------*/
24 /* Includes */
25 /*------------------------------------------------------------------------------*/
26 #include "txz_sample_def.h"
27 #include "rmc.h"
28 
38 /*------------------------------------------------------------------------------*/
39 /* Macro Function */
40 /*------------------------------------------------------------------------------*/
46 /* no define */
47  /* End of group RMC_UART_Exported_macro */
51 
52 
53 /*------------------------------------------------------------------------------*/
54 /* Configuration */
55 /*------------------------------------------------------------------------------*/
61 /* no define */
62  /* End of group RMC_UART_Exported_define */
66 
67 
68 /*------------------------------------------------------------------------------*/
69 /* Macro Definition */
70 /*------------------------------------------------------------------------------*/
75 #define REMOTE_RX_LIST_NUM_MAX (8UL) /* End of group RMC_UART_Private_define */
79 
80 
81 /*------------------------------------------------------------------------------*/
82 /* Enumerated Type Definition */
83 /*------------------------------------------------------------------------------*/
89 /*----------------------------------*/
93 /*----------------------------------*/
94 typedef enum {
99  /* End of group RMC_UART_Exported_define */
103 
104 
105 /*------------------------------------------------------------------------------*/
106 /* Structure Definition */
107 /*------------------------------------------------------------------------------*/
112 /*----------------------------------*/
116 /*----------------------------------*/
117 typedef struct
118 {
119  uint32_t data[RMC_DATA_BUFF_NUM];
120  uint8_t bits;
122 
123 /*----------------------------------*/
127 /*----------------------------------*/
128 typedef struct
129 {
130  uint32_t num;
131  uint32_t wp;
132  uint32_t rp;
135 
136 /*----------------------------------*/
140 /*----------------------------------*/
141 typedef struct
142 {
146  /* End of group RMC_UART_Private_typedef */
150 
151 
157 /*----------------------------------*/
162 /*----------------------------------*/
163 typedef struct
164 {
165  uint32_t customer;
166  uint8_t data;
167  uint8_t rdata;
169 
170 /*----------------------------------*/
175 /*----------------------------------*/
176 typedef struct
177 {
178  uint8_t bit;
179  uint8_t customer[2];
180  uint8_t data[10];
182 
183 /*----------------------------------*/
187 /*----------------------------------*/
188 typedef union
189 {
192 } remote_data_t;
193 
194 /*----------------------------------*/
199 /*----------------------------------*/
200 typedef struct
201 {
202  uint32_t id;
203  RemoteFormatType format;
204  void (*receive_data)(uint32_t id);
206 
207 /*----------------------------------*/
211 /*----------------------------------*/
212 typedef struct
213 {
216 } remote_t;
217  /* End of group RMC_UART_Exported_typedef */
221 
222 
223 /*------------------------------------------------------------------------------*/
224 /* Functions */
225 /*------------------------------------------------------------------------------*/
231 void remote_finalize(remote_t *p_instance);
232 void remote_start(remote_t *p_instance);
233 void remote_stop(remote_t *p_instance);
235 void remote_irq_handler(remote_t *p_instance, uint32_t status); /* End of group RMC_UART_Exported_functions */
239  /* End of group RMC_UART */
243  /* End of group Example */
247 
248 #ifdef __cplusplus
249 }
250 #endif /* __cplusplus */
251 #endif /* __REMOTE_H */
252 
253 
uint32_t num
Definition: remote.h:130
Definition: remote.h:96
remote_private_rx_list_t list
Definition: remote.h:144
Initial setting. User must be set.
Definition: remote.h:200
remote_initial_setting_t init
Definition: remote.h:214
Receive Data Information.
Definition: remote.h:117
uint32_t wp
Definition: remote.h:131
Remote Control Class.
Definition: remote.h:212
remote_data_fmt_sample_t sample
Definition: remote.h:190
void remote_finalize(remote_t *p_instance)
Finalize.
Definition: remote.c:369
uint8_t data
Definition: remote.h:166
TXZ_Result
Definition: txz_driver_def.h:43
remote_data_fmt_aeha_t aeha
Definition: remote.h:191
RTC handle structure definenition.
Definition: bsp_rtc.h:309
Private Information.
Definition: remote.h:141
Remote data. for Format Type = Smaple.
Definition: remote.h:163
RemoteFormatType format
Definition: remote.h:203
uint8_t bit
Definition: remote.h:178
void remote_irq_handler(remote_t *p_instance, uint32_t status)
IRQ Handler.
Definition: remote.c:594
#define RMC_DATA_BUFF_NUM
Definition: rmc.h:357
uint8_t bits
Definition: remote.h:120
rmc_t rmc
Definition: remote.h:143
Definition: remote.h:95
Definition: remote.h:97
remote_private_info_t info
Definition: remote.h:215
uint32_t id
Definition: remote.h:202
uint32_t rp
Definition: remote.h:132
Remote data.
Definition: remote.h:188
Remote data. for Format Type = Smaple.
Definition: remote.h:176
uint32_t customer
Definition: remote.h:165
BSPExInt status
Definition: main.c:140
uint8_t rdata
Definition: remote.h:167
remote_t * remote_initialize(remote_initial_setting_t *p_param)
Initialize.
Definition: remote.c:220
Receive Data List.
Definition: remote.h:128
void remote_stop(remote_t *p_instance)
Stop to receive.
Definition: remote.c:424
#define REMOTE_RX_LIST_NUM_MAX
Definition: remote.h:75
void remote_start(remote_t *p_instance)
Start to receive.
Definition: remote.c:400
TXZ_Result remote_get_list_data(remote_t *p_instance, remote_data_t *p_data)
Get Receive Data.
Definition: remote.c:453
This file provides all the functions prototypes for RMC Class.
RemoteFormatType
Format Type.
Definition: remote.h:94