Restructure of expansion board lib, moving files & folders.

Dependencies:   VL53L3_Lib

Dependents:  

Committer:
charlesmn
Date:
Fri Oct 16 15:04:28 2020 +0000
Revision:
0:293607457a02
Change typo in name

Who changed what in which revision?

UserRevisionLine numberNew contents of line
charlesmn 0:293607457a02 1 /**
charlesmn 0:293607457a02 2 ******************************************************************************
charlesmn 0:293607457a02 3 * @file Nfc.h
charlesmn 0:293607457a02 4 * @author ST Central Labs
charlesmn 0:293607457a02 5 * @version V1.0.0
charlesmn 0:293607457a02 6 * @date 13-April-2015
charlesmn 0:293607457a02 7 * @brief This file contains the abstract class describing the interface of a
charlesmn 0:293607457a02 8 * nfc component.
charlesmn 0:293607457a02 9 ******************************************************************************
charlesmn 0:293607457a02 10 * @attention
charlesmn 0:293607457a02 11 *
charlesmn 0:293607457a02 12 * <h2><center>&copy; COPYRIGHT(c) 2015 STMicroelectronics</center></h2>
charlesmn 0:293607457a02 13 *
charlesmn 0:293607457a02 14 * Redistribution and use in source and binary forms, with or without modification,
charlesmn 0:293607457a02 15 * are permitted provided that the following conditions are met:
charlesmn 0:293607457a02 16 * 1. Redistributions of source code must retain the above copyright notice,
charlesmn 0:293607457a02 17 * this list of conditions and the following disclaimer.
charlesmn 0:293607457a02 18 * 2. Redistributions in binary form must reproduce the above copyright notice,
charlesmn 0:293607457a02 19 * this list of conditions and the following disclaimer in the documentation
charlesmn 0:293607457a02 20 * and/or other materials provided with the distribution.
charlesmn 0:293607457a02 21 * 3. Neither the name of STMicroelectronics nor the names of its contributors
charlesmn 0:293607457a02 22 * may be used to endorse or promote products derived from this software
charlesmn 0:293607457a02 23 * without specific prior written permission.
charlesmn 0:293607457a02 24 *
charlesmn 0:293607457a02 25 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
charlesmn 0:293607457a02 26 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
charlesmn 0:293607457a02 27 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
charlesmn 0:293607457a02 28 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
charlesmn 0:293607457a02 29 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
charlesmn 0:293607457a02 30 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
charlesmn 0:293607457a02 31 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
charlesmn 0:293607457a02 32 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
charlesmn 0:293607457a02 33 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
charlesmn 0:293607457a02 34 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
charlesmn 0:293607457a02 35 *
charlesmn 0:293607457a02 36 ******************************************************************************
charlesmn 0:293607457a02 37 */
charlesmn 0:293607457a02 38
charlesmn 0:293607457a02 39
charlesmn 0:293607457a02 40 /* Generated with Stm32CubeTOO -----------------------------------------------*/
charlesmn 0:293607457a02 41
charlesmn 0:293607457a02 42 /* Define to prevent from recursive inclusion --------------------------------*/
charlesmn 0:293607457a02 43
charlesmn 0:293607457a02 44 #ifndef __NFC_CLASS_H
charlesmn 0:293607457a02 45 #define __NFC_CLASS_H
charlesmn 0:293607457a02 46
charlesmn 0:293607457a02 47
charlesmn 0:293607457a02 48 /* Includes ------------------------------------------------------------------*/
charlesmn 0:293607457a02 49
charlesmn 0:293607457a02 50 #include <Component.h>
charlesmn 0:293607457a02 51
charlesmn 0:293607457a02 52 typedef enum {
charlesmn 0:293607457a02 53 NFC_SUCCESS = 0,
charlesmn 0:293607457a02 54 } NFC_t;
charlesmn 0:293607457a02 55 /* Error codes are in component driver */
charlesmn 0:293607457a02 56
charlesmn 0:293607457a02 57
charlesmn 0:293607457a02 58 /* Classes ------------------------------------------------------------------*/
charlesmn 0:293607457a02 59
charlesmn 0:293607457a02 60 /**
charlesmn 0:293607457a02 61 * An abstract class for Nfc components.
charlesmn 0:293607457a02 62 */
charlesmn 0:293607457a02 63 class Nfc : public Component {
charlesmn 0:293607457a02 64 public:
charlesmn 0:293607457a02 65
charlesmn 0:293607457a02 66 /**
charlesmn 0:293607457a02 67 * Read data from the tag.
charlesmn 0:293607457a02 68 * @param offset Read offset.
charlesmn 0:293607457a02 69 * @param nb_bytes_to_read Number of bytes to read.
charlesmn 0:293607457a02 70 * @param[out] p_buffer_read Buffer to store the read data into.
charlesmn 0:293607457a02 71 * @return NFC_SUCCESS if no errors
charlesmn 0:293607457a02 72 */
charlesmn 0:293607457a02 73 virtual int read_binary(uint16_t offset, uint8_t nb_bytes_to_read, uint8_t *p_buffer_read) = 0;
charlesmn 0:293607457a02 74
charlesmn 0:293607457a02 75 /**
charlesmn 0:293607457a02 76 * Write data to the tag.
charlesmn 0:293607457a02 77 * @param offset Write offset.
charlesmn 0:293607457a02 78 * @param nb_bytes_to_write Number of bytes to write.
charlesmn 0:293607457a02 79 * @param p_buffer_write Buffer to write.
charlesmn 0:293607457a02 80 * @return NFC_SUCCESS if no errors
charlesmn 0:293607457a02 81 */
charlesmn 0:293607457a02 82 virtual int update_binary(uint16_t offset, uint8_t nb_bytes_to_write, uint8_t *p_buffer_write) = 0;
charlesmn 0:293607457a02 83
charlesmn 0:293607457a02 84 /**
charlesmn 0:293607457a02 85 * @brief Destructor.
charlesmn 0:293607457a02 86 */
charlesmn 0:293607457a02 87 virtual ~Nfc() {};
charlesmn 0:293607457a02 88 };
charlesmn 0:293607457a02 89
charlesmn 0:293607457a02 90 #endif /* __NFC_CLASS_H */
charlesmn 0:293607457a02 91
charlesmn 0:293607457a02 92 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/