mbed-os5 only for TYBLE16
Dependents: TYBLE16_simple_data_logger TYBLE16_MP3_Air
features/nfc/source/controllers/PN512TransportDriver.cpp@0:5b88d5760320, 2019-12-17 (annotated)
- Committer:
- kenjiArai
- Date:
- Tue Dec 17 23:23:45 2019 +0000
- Revision:
- 0:5b88d5760320
mbed-os5 only for TYBLE16
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
kenjiArai | 0:5b88d5760320 | 1 | /* mbed Microcontroller Library |
kenjiArai | 0:5b88d5760320 | 2 | * Copyright (c) 2018 ARM Limited |
kenjiArai | 0:5b88d5760320 | 3 | * |
kenjiArai | 0:5b88d5760320 | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
kenjiArai | 0:5b88d5760320 | 5 | * you may not use this file except in compliance with the License. |
kenjiArai | 0:5b88d5760320 | 6 | * You may obtain a copy of the License at |
kenjiArai | 0:5b88d5760320 | 7 | * |
kenjiArai | 0:5b88d5760320 | 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
kenjiArai | 0:5b88d5760320 | 9 | * |
kenjiArai | 0:5b88d5760320 | 10 | * Unless required by applicable law or agreed to in writing, software |
kenjiArai | 0:5b88d5760320 | 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
kenjiArai | 0:5b88d5760320 | 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
kenjiArai | 0:5b88d5760320 | 13 | * See the License for the specific language governing permissions and |
kenjiArai | 0:5b88d5760320 | 14 | * limitations under the License. |
kenjiArai | 0:5b88d5760320 | 15 | */ |
kenjiArai | 0:5b88d5760320 | 16 | |
kenjiArai | 0:5b88d5760320 | 17 | #include "PN512TransportDriver.h" |
kenjiArai | 0:5b88d5760320 | 18 | |
kenjiArai | 0:5b88d5760320 | 19 | using namespace mbed; |
kenjiArai | 0:5b88d5760320 | 20 | using namespace mbed::nfc; |
kenjiArai | 0:5b88d5760320 | 21 | |
kenjiArai | 0:5b88d5760320 | 22 | PN512TransportDriver::PN512TransportDriver() : _delegate(NULL) |
kenjiArai | 0:5b88d5760320 | 23 | { |
kenjiArai | 0:5b88d5760320 | 24 | |
kenjiArai | 0:5b88d5760320 | 25 | } |
kenjiArai | 0:5b88d5760320 | 26 | |
kenjiArai | 0:5b88d5760320 | 27 | PN512TransportDriver::~PN512TransportDriver() |
kenjiArai | 0:5b88d5760320 | 28 | { |
kenjiArai | 0:5b88d5760320 | 29 | |
kenjiArai | 0:5b88d5760320 | 30 | } |
kenjiArai | 0:5b88d5760320 | 31 | |
kenjiArai | 0:5b88d5760320 | 32 | void PN512TransportDriver::set_delegate(Delegate *delegate) |
kenjiArai | 0:5b88d5760320 | 33 | { |
kenjiArai | 0:5b88d5760320 | 34 | _delegate = delegate; |
kenjiArai | 0:5b88d5760320 | 35 | } |
kenjiArai | 0:5b88d5760320 | 36 | |
kenjiArai | 0:5b88d5760320 | 37 | void PN512TransportDriver::hw_interrupt() |
kenjiArai | 0:5b88d5760320 | 38 | { |
kenjiArai | 0:5b88d5760320 | 39 | if (_delegate != NULL) { |
kenjiArai | 0:5b88d5760320 | 40 | _delegate->on_hw_interrupt(); |
kenjiArai | 0:5b88d5760320 | 41 | } |
kenjiArai | 0:5b88d5760320 | 42 | } |