NFC: Fix IAR compilation issues

pull/7822/head
Donatien Garnier 2018-08-23 16:00:22 +01:00
parent 5c24c4dd82
commit 9cf8eedb63
6 changed files with 5 additions and 15 deletions

View File

@ -36,7 +36,6 @@ extern "C" {
#endif
//Generic interface for NDEF messages
typedef struct __ndef_msg ndef_msg_t;
/** Function called to generate the tag's content on read (target mode)
@ -51,12 +50,12 @@ typedef nfc_err_t (*ndef_encode_fn_t)(ndef_msg_t *pTag, ac_buffer_builder_t *pBu
*/
typedef nfc_err_t (*ndef_decode_fn_t)(ndef_msg_t *pTag, ac_buffer_t *pBuffer, void *pUserData);
typedef struct __ndef_msg {
struct __ndef_msg {
ndef_encode_fn_t encode;
ndef_decode_fn_t decode;
ac_buffer_builder_t bufferBldr;
void *pUserData;
} ndef_msg_t;
};
void ndef_msg_init(ndef_msg_t *pNdef, ndef_encode_fn_t encode, ndef_decode_fn_t decode, uint8_t *data, size_t size, void *pUserData);

View File

@ -27,6 +27,7 @@
#include "stddef.h"
#include "stdint.h"
#include "string.h"
#include "stdbool.h"
#include "nfc_errors.h"

View File

@ -31,8 +31,6 @@ extern "C" {
struct nfc_tech_iso7816;
struct nfc_tech_iso7816_app;
typedef struct nfc_tech_iso7816 nfc_tech_iso7816_t;
typedef struct nfc_tech_iso7816_app nfc_tech_iso7816_app_t;
typedef void (*nfc_tech_iso7816_app_cb)(nfc_tech_iso7816_app_t *pIso7816App, void *pUserData);

View File

@ -36,11 +36,6 @@ typedef struct nfc_tech_isodep nfc_tech_isodep_t;
typedef void (*nfc_tech_isodep_cb_t)(nfc_tech_isodep_t *pIsodep, nfc_err_t ret, void *pUserData);
typedef void (*nfc_tech_isodep_disconnected_cb)(nfc_tech_isodep_t *pIsodep, bool deselected, void *pUserData);
struct nfc_tech_isodep {
};
#ifdef __cplusplus
}
#endif

View File

@ -32,11 +32,8 @@ extern "C" {
#endif
struct nfc_tech_isodep_target;
typedef struct nfc_tech_isodep_target nfc_tech_isodep_target_t;
typedef struct nfc_tech_isodep_target nfc_tech_isodep_target_t;
struct nfc_tech_isodep_target {
nfc_tech_isodep_t isodep;
nfc_transceiver_t *pTransceiver;
struct {

View File

@ -53,7 +53,7 @@ enum __nfc_framing {
};
typedef enum __nfc_framing nfc_framing_t;
typedef struct __nfc_tech {
struct __nfc_tech {
unsigned int nfc_type1 : 1;
unsigned int nfc_type2 : 1;
unsigned int nfc_type3 : 1;
@ -62,7 +62,7 @@ typedef struct __nfc_tech {
unsigned int nfc_nfc_dep_a : 1;
unsigned int nfc_nfc_dep_f_212 : 1;
unsigned int nfc_nfc_dep_f_424 : 1;
} nfc_tech_t;
};
typedef struct __polling_options polling_options_t;
struct __polling_options {