ANSIX936KDFXX.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2023, Texas Instruments Incorporated
3  * All rights reserved.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions
7  * are met:
8  *
9  * * Redistributions of source code must retain the above copyright
10  * notice, this list of conditions and the following disclaimer.
11  *
12  * * Redistributions in binary form must reproduce the above copyright
13  * notice, this list of conditions and the following disclaimer in the
14  * documentation and/or other materials provided with the distribution.
15  *
16  * * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
21  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
22  * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
23  * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
24  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
25  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27  * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29  * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
30  * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
52 #ifndef ti_drivers_ansix936kdf_ANSIX936KDFXX__include
53 #define ti_drivers_ansix936kdf_ANSIX936KDFXX__include
54 
55 #include <stdbool.h>
56 
57 #include <ti/drivers/SHA2.h>
58 
59 #include <ti/devices/DeviceFamily.h>
60 
61 #if (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X1_CC26X1)
62  #include <ti/drivers/sha2/SHA2CC26X1.h>
63 #elif ((DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X2_CC26X2) || \
64  (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X4_CC26X3_CC26X4))
65  #include <ti/drivers/sha2/SHA2CC26X2.h>
66 #elif (DeviceFamily_PARENT == DeviceFamily_PARENT_CC23X0)
68 #else
69  #error "ANSIX936KDFXX device family not supported"
70 #endif
71 
72 #ifdef __cplusplus
73 extern "C" {
74 #endif
75 
82 typedef struct
83 {
84 #if (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X1_CC26X1)
85  SHA2CC26X1_HWAttrs sha2HWAttrs;
86 #elif ((DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X2_CC26X2) || \
87  (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X4_CC26X3_CC26X4))
88  SHA2CC26X2_HWAttrs sha2HWAttrs;
89 #elif (DeviceFamily_PARENT == DeviceFamily_PARENT_CC23X0)
90  SHA2LPF3SW_HWAttrs sha2HWAttrs;
91 #endif
93 
99 typedef struct
100 {
103 #if (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X1_CC26X1)
104  SHA2CC26X1_Object sha2Object;
105 #elif ((DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X2_CC26X2) || \
106  (DeviceFamily_PARENT == DeviceFamily_PARENT_CC13X4_CC26X3_CC26X4))
107  SHA2CC26X2_Object sha2Object;
108 #elif (DeviceFamily_PARENT == DeviceFamily_PARENT_CC23X0)
109  SHA2LPF3SW_Object sha2Object;
110 #endif
111  bool isOpen;
113 
114 #ifdef __cplusplus
115 }
116 #endif
117 
118 #endif /* ti_drivers_ansix936kdf_ANSIX936KDFXX__include */
SHA2_Config sha2Config
Definition: ANSIX936KDFXX.h:101
SHA2CC26X1_HWAttrs sha2HWAttrs
Definition: ANSIX936KDFXX.h:85
SHA2 Global configuration.
Definition: SHA2.h:544
bool isOpen
Definition: ANSIX936KDFXX.h:111
Hardware-specific configuration attributes.
Definition: SHA2LPF3SW.h:95
SHA2 driver header.
ANSIX936KDFXX Object.
Definition: ANSIX936KDFXX.h:99
SHA2 software driver implementation for the Low Power F3 family.
SHA2_Handle sha2Handle
Definition: ANSIX936KDFXX.h:102
SHA2CC26X1_Object sha2Object
Definition: ANSIX936KDFXX.h:104
Hardware-specific configuration attributes.
Definition: ANSIX936KDFXX.h:82
© Copyright 1995-2024, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale