Mistake on this page?
Report an issue in GitHub or email us
PN512Driver.h
1 /* mbed Microcontroller Library
2  * Copyright (c) 2018 ARM Limited
3  * SPDX-License-Identifier: Apache-2.0
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 
18 #ifndef MBED_PN512_DRIVER_H
19 #define MBED_PN512_DRIVER_H
20 
21 #include <stdint.h>
22 
23 #include "nfc/NFCControllerDriver.h"
24 #include "PN512TransportDriver.h"
25 
26 #include "acore/acore/ac_buffer.h"
29 #include "transceiver/pn512.h"
30 
31 namespace mbed {
32 namespace nfc {
33 
35 public:
36  PN512Driver(PN512TransportDriver *transport_driver);
37 
38  virtual nfc_transceiver_t *initialize(nfc_scheduler_timer_t *scheduler_timer);
39  virtual void get_supported_nfc_techs(nfc_tech_t *initiator, nfc_tech_t *target) const;
40 
41 private:
42  // PN512TransportDriver::Delegate implementation
43  virtual void on_hw_interrupt();
44 
45  PN512TransportDriver *_transport_driver;
46  pn512_t _pn512;
47 };
48 
49 } // namespace nfc
50 } // namespace mbed
51 
52 #endif
The abstraction for a NFC controller driver.
virtual nfc_transceiver_t * initialize(nfc_scheduler_timer_t *scheduler_timer)
Initialize the driver and retrieve the interface to the controller.
Definition: pn512.h:53
The PN512 supports multiple transport mechanisms (SPI, I2C, UART): this class provides a unified API ...
The PN512TransportDriver delegate.
virtual void get_supported_nfc_techs(nfc_tech_t *initiator, nfc_tech_t *target) const
Retrieve list of technologies supported by the controller.
Definition: ATHandler.h:46
Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.