annotate Common/Drivers/STM32F4xx_HAL_DRIVER_v120/Inc/stm32f4xx_hal_cryp.h @ 85:923c4566a2a1 kittz

increased interCPU baudrate, cpu2: i2c in SPI1 IRQ
author Dmitry Romanov <kitt@bk.ru>
date Wed, 21 Nov 2018 12:49:54 +0300
parents 5f11787b4f42
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
38
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
1 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
2 ******************************************************************************
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
3 * @file stm32f4xx_hal_cryp.h
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
4 * @author MCD Application Team
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
5 * @version V1.2.0
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
6 * @date 26-December-2014
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
7 * @brief Header file of CRYP HAL module.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
8 ******************************************************************************
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
9 * @attention
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
10 *
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
11 * <h2><center>&copy; COPYRIGHT(c) 2014 STMicroelectronics</center></h2>
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
12 *
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
13 * Redistribution and use in source and binary forms, with or without modification,
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
14 * are permitted provided that the following conditions are met:
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
15 * 1. Redistributions of source code must retain the above copyright notice,
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
16 * this list of conditions and the following disclaimer.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
17 * 2. Redistributions in binary form must reproduce the above copyright notice,
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
18 * this list of conditions and the following disclaimer in the documentation
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
19 * and/or other materials provided with the distribution.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
21 * may be used to endorse or promote products derived from this software
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
22 * without specific prior written permission.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
23 *
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
34 *
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
35 ******************************************************************************
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
36 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
37
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
38 /* Define to prevent recursive inclusion -------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
39 #ifndef __STM32F4xx_HAL_CRYP_H
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
40 #define __STM32F4xx_HAL_CRYP_H
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
41
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
42 #ifdef __cplusplus
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
43 extern "C" {
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
44 #endif
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
45
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
46 #if defined(STM32F415xx) || defined(STM32F417xx) || defined(STM32F437xx) || defined(STM32F439xx)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
47 /* Includes ------------------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
48 #include "stm32f4xx_hal_def.h"
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
49
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
50 /** @addtogroup STM32F4xx_HAL_Driver
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
51 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
52 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
53
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
54 /** @addtogroup CRYP
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
55 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
56 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
57
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
58 /* Exported types ------------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
59
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
60 /** @defgroup CRYP_Exported_Types CRYP Exported Types
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
61 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
62 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
63
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
64 /** @defgroup CRYP_Exported_Types_Group1 CRYP Configuration Structure definition
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
65 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
66 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
67
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
68 typedef struct
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
69 {
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
70 uint32_t DataType; /*!< 32-bit data, 16-bit data, 8-bit data or 1-bit string.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
71 This parameter can be a value of @ref CRYP CRYP_Data_Type */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
72
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
73 uint32_t KeySize; /*!< Used only in AES mode only : 128, 192 or 256 bit key length.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
74 This parameter can be a value of @ref CRYP CRYP_Key_Size */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
75
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
76 uint8_t* pKey; /*!< The key used for encryption/decryption */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
77
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
78 uint8_t* pInitVect; /*!< The initialization vector used also as initialization
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
79 counter in CTR mode */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
80
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
81 uint8_t IVSize; /*!< The size of initialization vector.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
82 This parameter (called nonce size in CCM) is used only
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
83 in AES-128/192/256 encryption/decryption CCM mode */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
84
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
85 uint8_t TagSize; /*!< The size of returned authentication TAG.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
86 This parameter is used only in AES-128/192/256
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
87 encryption/decryption CCM mode */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
88
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
89 uint8_t* Header; /*!< The header used in GCM and CCM modes */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
90
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
91 uint32_t HeaderSize; /*!< The size of header buffer in bytes */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
92
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
93 uint8_t* pScratch; /*!< Scratch buffer used to append the header. It's size must be equal to header size + 21 bytes.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
94 This parameter is used only in AES-128/192/256 encryption/decryption CCM mode */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
95 }CRYP_InitTypeDef;
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
96
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
97 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
98 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
99 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
100
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
101 /** @defgroup CRYP_Exported_Types_Group2 CRYP State structures definition
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
102 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
103 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
104
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
105
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
106 typedef enum
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
107 {
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
108 HAL_CRYP_STATE_RESET = 0x00, /*!< CRYP not yet initialized or disabled */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
109 HAL_CRYP_STATE_READY = 0x01, /*!< CRYP initialized and ready for use */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
110 HAL_CRYP_STATE_BUSY = 0x02, /*!< CRYP internal processing is ongoing */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
111 HAL_CRYP_STATE_TIMEOUT = 0x03, /*!< CRYP timeout state */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
112 HAL_CRYP_STATE_ERROR = 0x04 /*!< CRYP error state */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
113 }HAL_CRYP_STATETypeDef;
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
114
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
115 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
116 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
117 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
118
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
119 /** @defgroup CRYP_Exported_Types_Group3 CRYP phase structures definition
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
120 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
121 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
122
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
123
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
124 typedef enum
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
125 {
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
126 HAL_CRYP_PHASE_READY = 0x01, /*!< CRYP peripheral is ready for initialization. */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
127 HAL_CRYP_PHASE_PROCESS = 0x02, /*!< CRYP peripheral is in processing phase */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
128 HAL_CRYP_PHASE_FINAL = 0x03 /*!< CRYP peripheral is in final phase
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
129 This is relevant only with CCM and GCM modes */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
130 }HAL_PhaseTypeDef;
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
131
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
132 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
133 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
134 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
135
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
136 /** @defgroup CRYP_Exported_Types_Group4 CRYP handle Structure definition
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
137 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
138 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
139
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
140 typedef struct
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
141 {
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
142 CRYP_InitTypeDef Init; /*!< CRYP required parameters */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
143
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
144 uint8_t *pCrypInBuffPtr; /*!< Pointer to CRYP processing (encryption, decryption,...) buffer */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
145
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
146 uint8_t *pCrypOutBuffPtr; /*!< Pointer to CRYP processing (encryption, decryption,...) buffer */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
147
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
148 __IO uint16_t CrypInCount; /*!< Counter of inputed data */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
149
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
150 __IO uint16_t CrypOutCount; /*!< Counter of outputted data */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
151
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
152 HAL_StatusTypeDef Status; /*!< CRYP peripheral status */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
153
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
154 HAL_PhaseTypeDef Phase; /*!< CRYP peripheral phase */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
155
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
156 DMA_HandleTypeDef *hdmain; /*!< CRYP In DMA handle parameters */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
157
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
158 DMA_HandleTypeDef *hdmaout; /*!< CRYP Out DMA handle parameters */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
159
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
160 HAL_LockTypeDef Lock; /*!< CRYP locking object */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
161
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
162 __IO HAL_CRYP_STATETypeDef State; /*!< CRYP peripheral state */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
163 }CRYP_HandleTypeDef;
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
164
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
165 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
166 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
167 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
168
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
169 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
170 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
171 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
172
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
173 /* Exported constants --------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
174 /** @defgroup CRYP_Exported_Constants CRYP Exported Constants
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
175 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
176 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
177
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
178 /** @defgroup CRYP_Exported_Constants_Group1 CRYP CRYP_Key_Size
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
179 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
180 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
181 #define CRYP_KEYSIZE_128B ((uint32_t)0x00000000)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
182 #define CRYP_KEYSIZE_192B CRYP_CR_KEYSIZE_0
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
183 #define CRYP_KEYSIZE_256B CRYP_CR_KEYSIZE_1
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
184 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
185 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
186 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
187
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
188 /** @defgroup CRYP_Exported_Constants_Group2 CRYP CRYP_Data_Type
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
189 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
190 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
191 #define CRYP_DATATYPE_32B ((uint32_t)0x00000000)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
192 #define CRYP_DATATYPE_16B CRYP_CR_DATATYPE_0
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
193 #define CRYP_DATATYPE_8B CRYP_CR_DATATYPE_1
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
194 #define CRYP_DATATYPE_1B CRYP_CR_DATATYPE
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
195 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
196 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
197 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
198
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
199 /** @defgroup CRYP_Exported_Constants_Group3 CRYP CRYP_AlgoModeDirection
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
200 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
201 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
202 #define CRYP_CR_ALGOMODE_DIRECTION ((uint32_t)0x0008003C)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
203 #define CRYP_CR_ALGOMODE_TDES_ECB_ENCRYPT ((uint32_t)0x00000000)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
204 #define CRYP_CR_ALGOMODE_TDES_ECB_DECRYPT ((uint32_t)0x00000004)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
205 #define CRYP_CR_ALGOMODE_TDES_CBC_ENCRYPT ((uint32_t)0x00000008)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
206 #define CRYP_CR_ALGOMODE_TDES_CBC_DECRYPT ((uint32_t)0x0000000C)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
207 #define CRYP_CR_ALGOMODE_DES_ECB_ENCRYPT ((uint32_t)0x00000010)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
208 #define CRYP_CR_ALGOMODE_DES_ECB_DECRYPT ((uint32_t)0x00000014)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
209 #define CRYP_CR_ALGOMODE_DES_CBC_ENCRYPT ((uint32_t)0x00000018)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
210 #define CRYP_CR_ALGOMODE_DES_CBC_DECRYPT ((uint32_t)0x0000001C)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
211 #define CRYP_CR_ALGOMODE_AES_ECB_ENCRYPT ((uint32_t)0x00000020)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
212 #define CRYP_CR_ALGOMODE_AES_ECB_DECRYPT ((uint32_t)0x00000024)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
213 #define CRYP_CR_ALGOMODE_AES_CBC_ENCRYPT ((uint32_t)0x00000028)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
214 #define CRYP_CR_ALGOMODE_AES_CBC_DECRYPT ((uint32_t)0x0000002C)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
215 #define CRYP_CR_ALGOMODE_AES_CTR_ENCRYPT ((uint32_t)0x00000030)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
216 #define CRYP_CR_ALGOMODE_AES_CTR_DECRYPT ((uint32_t)0x00000034)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
217 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
218 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
219 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
220
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
221 /** @defgroup CRYP_Exported_Constants_Group4 CRYP CRYP_Interrupt
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
222 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
223 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
224 #define CRYP_IT_INI ((uint32_t)CRYP_IMSCR_INIM) /*!< Input FIFO Interrupt */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
225 #define CRYP_IT_OUTI ((uint32_t)CRYP_IMSCR_OUTIM) /*!< Output FIFO Interrupt */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
226 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
227 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
228 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
229
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
230 /** @defgroup CRYP_Exported_Constants_Group5 CRYP CRYP_Flags
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
231 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
232 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
233 #define CRYP_FLAG_BUSY ((uint32_t)0x00000010) /*!< The CRYP core is currently
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
234 processing a block of data
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
235 or a key preparation (for
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
236 AES decryption). */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
237 #define CRYP_FLAG_IFEM ((uint32_t)0x00000001) /*!< Input FIFO is empty */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
238 #define CRYP_FLAG_IFNF ((uint32_t)0x00000002) /*!< Input FIFO is not Full */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
239 #define CRYP_FLAG_OFNE ((uint32_t)0x00000004) /*!< Output FIFO is not empty */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
240 #define CRYP_FLAG_OFFU ((uint32_t)0x00000008) /*!< Output FIFO is Full */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
241 #define CRYP_FLAG_OUTRIS ((uint32_t)0x01000002) /*!< Output FIFO service raw
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
242 interrupt status */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
243 #define CRYP_FLAG_INRIS ((uint32_t)0x01000001) /*!< Input FIFO service raw
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
244 interrupt status */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
245 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
246 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
247 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
248
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
249 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
250 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
251 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
252
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
253 /* Exported macro ------------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
254 /** @defgroup CRYP_Exported_Macros CRYP Exported Macros
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
255 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
256 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
257
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
258 /** @brief Reset CRYP handle state
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
259 * @param __HANDLE__: specifies the CRYP handle.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
260 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
261 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
262 #define __HAL_CRYP_RESET_HANDLE_STATE(__HANDLE__) ((__HANDLE__)->State = HAL_CRYP_STATE_RESET)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
263
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
264 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
265 * @brief Enable/Disable the CRYP peripheral.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
266 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
267 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
268 #define __HAL_CRYP_ENABLE() (CRYP->CR |= CRYP_CR_CRYPEN)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
269 #define __HAL_CRYP_DISABLE() (CRYP->CR &= ~CRYP_CR_CRYPEN)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
270
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
271 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
272 * @brief Flush the data FIFO.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
273 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
274 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
275 #define __HAL_CRYP_FIFO_FLUSH() (CRYP->CR |= CRYP_CR_FFLUSH)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
276
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
277 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
278 * @brief Set the algorithm mode: AES-ECB, AES-CBC, AES-CTR, DES-ECB, DES-CBC.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
279 * @param MODE: The algorithm mode.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
280 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
281 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
282 #define __HAL_CRYP_SET_MODE(MODE) CRYP->CR |= (uint32_t)(MODE)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
283
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
284 /** @brief Check whether the specified CRYP flag is set or not.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
285 * @param __FLAG__: specifies the flag to check.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
286 * This parameter can be one of the following values:
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
287 * @arg CRYP_FLAG_BUSY: The CRYP core is currently processing a block of data
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
288 * or a key preparation (for AES decryption).
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
289 * @arg CRYP_FLAG_IFEM: Input FIFO is empty
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
290 * @arg CRYP_FLAG_IFNF: Input FIFO is not full
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
291 * @arg CRYP_FLAG_INRIS: Input FIFO service raw interrupt is pending
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
292 * @arg CRYP_FLAG_OFNE: Output FIFO is not empty
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
293 * @arg CRYP_FLAG_OFFU: Output FIFO is full
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
294 * @arg CRYP_FLAG_OUTRIS: Input FIFO service raw interrupt is pending
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
295 * @retval The new state of __FLAG__ (TRUE or FALSE).
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
296 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
297
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
298 #define __HAL_CRYP_GET_FLAG(__FLAG__) ((((uint8_t)((__FLAG__) >> 24)) == 0x01)?(((CRYP->RISR) & ((__FLAG__) & CRYP_FLAG_MASK)) == ((__FLAG__) & CRYP_FLAG_MASK)): \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
299 (((CRYP->RISR) & ((__FLAG__) & CRYP_FLAG_MASK)) == ((__FLAG__) & CRYP_FLAG_MASK)))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
300
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
301 /** @brief Check whether the specified CRYP interrupt is set or not.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
302 * @param __INTERRUPT__: specifies the interrupt to check.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
303 * This parameter can be one of the following values:
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
304 * @arg CRYP_IT_INRIS: Input FIFO service raw interrupt is pending
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
305 * @arg CRYP_IT_OUTRIS: Output FIFO service raw interrupt is pending
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
306 * @retval The new state of __INTERRUPT__ (TRUE or FALSE).
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
307 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
308 #define __HAL_CRYP_GET_IT(__INTERRUPT__) ((CRYP->MISR & (__INTERRUPT__)) == (__INTERRUPT__))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
309
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
310 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
311 * @brief Enable the CRYP interrupt.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
312 * @param __INTERRUPT__: CRYP Interrupt.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
313 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
314 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
315 #define __HAL_CRYP_ENABLE_IT(__INTERRUPT__) ((CRYP->IMSCR) |= (__INTERRUPT__))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
316
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
317 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
318 * @brief Disable the CRYP interrupt.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
319 * @param __INTERRUPT__: CRYP interrupt.
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
320 * @retval None
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
321 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
322 #define __HAL_CRYP_DISABLE_IT(__INTERRUPT__) ((CRYP->IMSCR) &= ~(__INTERRUPT__))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
323
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
324 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
325 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
326 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
327
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
328 /* Include CRYP HAL Extension module */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
329 #include "stm32f4xx_hal_cryp_ex.h"
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
330
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
331 /* Exported functions --------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
332 /** @defgroup CRYP_Exported_Functions CRYP Exported Functions
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
333 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
334 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
335
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
336 /** @addtogroup CRYP_Exported_Functions_Group1
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
337 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
338 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
339 HAL_StatusTypeDef HAL_CRYP_Init(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
340 HAL_StatusTypeDef HAL_CRYP_DeInit(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
341 void HAL_CRYP_MspInit(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
342 void HAL_CRYP_MspDeInit(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
343 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
344 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
345 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
346
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
347 /** @addtogroup CRYP_Exported_Functions_Group2
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
348 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
349 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
350 /* AES encryption/decryption using polling ***********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
351 HAL_StatusTypeDef HAL_CRYP_AESECB_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
352 HAL_StatusTypeDef HAL_CRYP_AESECB_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
353 HAL_StatusTypeDef HAL_CRYP_AESCBC_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
354 HAL_StatusTypeDef HAL_CRYP_AESCBC_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
355 HAL_StatusTypeDef HAL_CRYP_AESCTR_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
356 HAL_StatusTypeDef HAL_CRYP_AESCTR_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
357
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
358 /* AES encryption/decryption using interrupt *********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
359 HAL_StatusTypeDef HAL_CRYP_AESECB_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
360 HAL_StatusTypeDef HAL_CRYP_AESCBC_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
361 HAL_StatusTypeDef HAL_CRYP_AESCTR_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
362 HAL_StatusTypeDef HAL_CRYP_AESECB_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
363 HAL_StatusTypeDef HAL_CRYP_AESCTR_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
364 HAL_StatusTypeDef HAL_CRYP_AESCBC_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
365
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
366 /* AES encryption/decryption using DMA ***************************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
367 HAL_StatusTypeDef HAL_CRYP_AESECB_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
368 HAL_StatusTypeDef HAL_CRYP_AESECB_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
369 HAL_StatusTypeDef HAL_CRYP_AESCBC_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
370 HAL_StatusTypeDef HAL_CRYP_AESCBC_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
371 HAL_StatusTypeDef HAL_CRYP_AESCTR_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
372 HAL_StatusTypeDef HAL_CRYP_AESCTR_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
373 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
374 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
375 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
376
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
377 /** @addtogroup CRYP_Exported_Functions_Group3
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
378 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
379 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
380 /* DES encryption/decryption using polling ***********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
381 HAL_StatusTypeDef HAL_CRYP_DESECB_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
382 HAL_StatusTypeDef HAL_CRYP_DESCBC_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
383 HAL_StatusTypeDef HAL_CRYP_DESECB_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
384 HAL_StatusTypeDef HAL_CRYP_DESCBC_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
385
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
386 /* DES encryption/decryption using interrupt *********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
387 HAL_StatusTypeDef HAL_CRYP_DESECB_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
388 HAL_StatusTypeDef HAL_CRYP_DESECB_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
389 HAL_StatusTypeDef HAL_CRYP_DESCBC_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
390 HAL_StatusTypeDef HAL_CRYP_DESCBC_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
391
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
392 /* DES encryption/decryption using DMA ***************************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
393 HAL_StatusTypeDef HAL_CRYP_DESECB_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
394 HAL_StatusTypeDef HAL_CRYP_DESECB_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
395 HAL_StatusTypeDef HAL_CRYP_DESCBC_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
396 HAL_StatusTypeDef HAL_CRYP_DESCBC_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
397 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
398 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
399 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
400
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
401 /** @addtogroup CRYP_Exported_Functions_Group4
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
402 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
403 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
404 /* TDES encryption/decryption using polling **********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
405 HAL_StatusTypeDef HAL_CRYP_TDESECB_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
406 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Encrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
407 HAL_StatusTypeDef HAL_CRYP_TDESECB_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
408 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Decrypt(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData, uint32_t Timeout);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
409
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
410 /* TDES encryption/decryption using interrupt ********************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
411 HAL_StatusTypeDef HAL_CRYP_TDESECB_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
412 HAL_StatusTypeDef HAL_CRYP_TDESECB_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
413 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Encrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
414 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Decrypt_IT(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
415
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
416 /* TDES encryption/decryption using DMA **************************************/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
417 HAL_StatusTypeDef HAL_CRYP_TDESECB_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
418 HAL_StatusTypeDef HAL_CRYP_TDESECB_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
419 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Encrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pPlainData, uint16_t Size, uint8_t *pCypherData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
420 HAL_StatusTypeDef HAL_CRYP_TDESCBC_Decrypt_DMA(CRYP_HandleTypeDef *hcryp, uint8_t *pCypherData, uint16_t Size, uint8_t *pPlainData);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
421 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
422 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
423 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
424
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
425 /** @addtogroup CRYP_Exported_Functions_Group5
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
426 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
427 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
428 void HAL_CRYP_InCpltCallback(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
429 void HAL_CRYP_OutCpltCallback(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
430 void HAL_CRYP_ErrorCallback(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
431 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
432 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
433 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
434
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
435 /** @addtogroup CRYP_Exported_Functions_Group6
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
436 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
437 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
438 void HAL_CRYP_IRQHandler(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
439 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
440 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
441 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
442
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
443 /** @addtogroup CRYP_Exported_Functions_Group7
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
444 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
445 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
446 HAL_CRYP_STATETypeDef HAL_CRYP_GetState(CRYP_HandleTypeDef *hcryp);
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
447 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
448 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
449 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
450
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
451 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
452 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
453 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
454
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
455 /* Private types -------------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
456 /** @defgroup CRYP_Private_Types CRYP Private Types
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
457 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
458 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
459
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
460 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
461 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
462 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
463
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
464 /* Private variables ---------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
465 /** @defgroup CRYP_Private_Variables CRYP Private Variables
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
466 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
467 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
468
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
469 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
470 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
471 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
472
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
473 /* Private constants ---------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
474 /** @defgroup CRYP_Private_Constants CRYP Private Constants
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
475 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
476 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
477 #define CRYP_FLAG_MASK ((uint32_t)0x0000001F)
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
478 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
479 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
480 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
481
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
482 /* Private macros ------------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
483 /** @defgroup CRYP_Private_Macros CRYP Private Macros
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
484 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
485 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
486
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
487 #define IS_CRYP_KEYSIZE(__KEYSIZE__) (((__KEYSIZE__) == CRYP_KEYSIZE_128B) || \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
488 ((__KEYSIZE__) == CRYP_KEYSIZE_192B) || \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
489 ((__KEYSIZE__) == CRYP_KEYSIZE_256B))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
490
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
491
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
492 #define IS_CRYP_DATATYPE(__DATATYPE__) (((__DATATYPE__) == CRYP_DATATYPE_32B) || \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
493 ((__DATATYPE__) == CRYP_DATATYPE_16B) || \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
494 ((__DATATYPE__) == CRYP_DATATYPE_8B) || \
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
495 ((__DATATYPE__) == CRYP_DATATYPE_1B))
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
496
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
497
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
498 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
499 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
500 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
501
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
502 /* Private functions ---------------------------------------------------------*/
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
503 /** @defgroup CRYP_Private_Functions CRYP Private Functions
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
504 * @{
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
505 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
506
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
507 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
508 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
509 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
510
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
511 #endif /* STM32F415xx || STM32F417xx || STM32F437xx || STM32F439xx */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
512
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
513 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
514 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
515 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
516
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
517 /**
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
518 * @}
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
519 */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
520
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
521 #ifdef __cplusplus
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
522 }
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
523 #endif
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
524
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
525 #endif /* __STM32F4xx_HAL_CRYP_H */
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
526
5f11787b4f42 include in ostc4 repository
heinrichsweikamp
parents:
diff changeset
527 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/