blob: 616b15f37ee73be878f4031de5cbc3b18e9d5ae3 [file] [log] [blame]
version 1.0;
package android.hardware.nfc;
interface INfcClientCallback {
struct nfc_data_t {
vec<uint8_t> data;
};
enum nfc_event_t : uint32_t {
HAL_NFC_OPEN_CPLT_EVT = 0,
HAL_NFC_CLOSE_CPLT_EVT = 1,
HAL_NFC_POST_INIT_CPLT_EVT = 2,
HAL_NFC_PRE_DISCOVER_CPLT_EVT = 3,
HAL_NFC_REQUEST_CONTROL_EVT = 4,
HAL_NFC_RELEASE_CONTROL_EVT = 5,
HAL_NFC_ERROR_EVT = 6
};
enum nfc_status_t : uint32_t {
HAL_NFC_STATUS_OK = 0,
HAL_NFC_STATUS_FAILED = 1,
HAL_NFC_STATUS_ERR_TRANSPORT = 2,
HAL_NFC_STATUS_ERR_CMD_TIMEOUT = 3,
HAL_NFC_STATUS_REFUSED = 4
};
/*
* The callback passed in from the NFC stack that the HAL
* can use to pass events back to the stack.
*/
sendEvent(nfc_event_t event, nfc_status_t event_status);
/*
* The callback passed in from the NFC stack that the HAL
* can use to pass incomming data to the stack.
*/
sendData(nfc_data_t data);
};