Cordio Stack and Cordio Profiles  r2p3-02rel0
plxps_main.h
Go to the documentation of this file.
1 /*************************************************************************************************/
2 /*!
3  * \file
4  *
5  * \brief Pulse Oximeter profile sensor internal interfaces.
6  *
7  * Copyright (c) 2012-2018 Arm Ltd. All Rights Reserved.
8  * Arm Ltd. confidential and proprietary.
9  *
10  * IMPORTANT. Your use of this file is governed by a Software License Agreement
11  * ("Agreement") that must be accepted in order to download or otherwise receive a
12  * copy of this file. You may not use or copy this file for any purpose other than
13  * as described in the Agreement. If you do not agree to all of the terms of the
14  * Agreement do not use this file and delete all copies in your possession or control;
15  * if you do not have a copy of the Agreement, you must contact Arm Ltd. prior
16  * to any use, copying or further distribution of this software.
17  */
18 /*************************************************************************************************/
19 #ifndef PLXPS_MAIN_H
20 #define PLXPS_MAIN_H
21 
22 #include "app_hw.h"
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
28 /*! \addtogroup PULSE_OXIMETER_PROFILE
29  * \{ */
30 
31 /**************************************************************************************************
32  Macros
33 **************************************************************************************************/
34 
35 /*! \brief Minimum RACP write length */
36 #define PLXPS_RACP_MIN_WRITE_LEN 2
37 
38 /*! \brief RACP response length */
39 #define PLXPS_RACP_RSP_LEN 4
40 
41 /*! \brief Pulse Oximeter RACP number of stored records response length */
42 #define PLXPS_RACP_NUM_REC_RSP_LEN 4
43 
44 /*! \brief RACP operand maximum length */
45 #define PLXPS_OPERAND_MAX ((CH_RACP_GLS_FILTER_TIME_LEN * 2) + 1)
46 
47 /**************************************************************************************************
48  Data Types
49 **************************************************************************************************/
50 
51 /*! \brief Pulse Oximeter measurement record */
52 typedef struct
53 {
54  plxpScm_t spotCheck; /*!< \brief Pulse Oximeter spot check measurement */
55 } plxpsRec_t;
56 
57 
58 /*************************************************************************************************/
59 /*!
60  * \brief Initialize the pulse oximeter record database.
61  *
62  * \return None.
63  */
64 /*************************************************************************************************/
65 void plxpsDbInit(void);
66 
67 /*************************************************************************************************/
68 /*!
69  * \brief Get the next record that matches the given filter parameters that follows
70  * the given current record.
71  *
72  * \param oper Operator.
73  * \param pCurrRec Pointer to current record.
74  * \param pRec Return pointer to next record, if found.
75  *
76  * \return \ref CH_RACP_RSP_SUCCESS if a record is found, otherwise an error status is returned.
77  */
78 /*************************************************************************************************/
80 
81 /*************************************************************************************************/
82 /*!
83  * \brief Delete records that match the given filter parameters.
84  *
85  * \param oper Operator.
86  *
87  * \return \ref CH_RACP_RSP_SUCCESS if records deleted, otherwise an error status is returned.
88  */
89 /*************************************************************************************************/
91 
92 /*************************************************************************************************/
93 /*!
94  * \brief Get the number of records matching the filter parameters.
95  *
96  * \param oper Operator.
97  * \param pNumRec Returns number of records which match filter parameters.
98 
99  *
100  * \return RACP status.
101  */
102 /*************************************************************************************************/
104 
105 /*************************************************************************************************/
106 /*!
107 * \brief Generate a new record.
108 *
109 * \return None.
110 */
111 /*************************************************************************************************/
112 void plxpsDbGenerateRecord(void);
113 
114 
115 /*! \} */ /* PULSE_OXIMETER_PROFILE */
116 
117 #ifdef __cplusplus
118 };
119 #endif
120 
121 #endif /* PLXPS_MAIN_H */
void plxpsDbGenerateRecord(void)
Generate a new record.
Application framework hardware interfaces.
uint8_t plxpsDbDeleteRecords(uint8_t oper)
Delete records that match the given filter parameters.
void plxpsDbInit(void)
Initialize the pulse oximeter record database.
plxpScm_t spotCheck
Pulse Oximeter spot check measurement.
Definition: plxps_main.h:54
uint8_t plxpsDbGetNextRecord(uint8_t oper, plxpsRec_t *pCurrRec, plxpsRec_t **pRec)
Get the next record that matches the given filter parameters that follows the given current record...
uint8_t plxpsDbGetNumRecords(uint8_t oper, uint8_t *pNumRec)
Get the number of records matching the filter parameters.
unsigned char uint8_t
Unsigned 8-bit value.
Definition: wsf_types.h:63
Pulse Oximeter measurement record.
Definition: plxps_main.h:52
Pulse Oximeter spot check measurement structure.
Definition: app_hw.h:100