v2.0.0
Data Structures | Macros | Enumerations | Functions
sha256.h File Reference
`#include "pico.h"`
`#include "hardware/structs/sha256.h"`
Include dependency graph for sha256.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

## Data Structures
union | sha256_result_t
| SHA-256 result generated by the API. More...

## Macros
#define | PARAM_ASSERTIONS_ENABLED_HARDWARE_SHA256 0
#define | SHA256_RESULT_BYTES 32
| Size of a sha256 result in bytes.

## Enumerations
enum | sha256_endianness { SHA256_LITTLE_ENDIAN , SHA256_BIG_ENDIAN }
| SHA-256 endianness definition used in the API. More...

## Functions
static void | sha256_set_dma_size (uint size_in_bytes)
| Configure the correct DMA data size. More...
static void | sha256_set_bswap (bool swap)
| Enable or disable byte swapping of 32-bit values. More...
static void | sha256_start (void)
| Prepare the hardware for a new checksum. More...
static bool | sha256_is_sum_valid (void)
| Check if a valid checksum has been calculated. More...
static bool | sha256_is_ready (void)
| Check if a the hardware is ready to accept more data. More...
static void | sha256_wait_valid_blocking (void)
| Wait until the checksum is valid. More...
static void | sha256_wait_ready_blocking (void)
| Wait until the hardware is ready to accept more data. More...
void | sha256_get_result (sha256_result_t *out, enum sha256_endianness endianness)
| Get the checksum result. More...
static bool | sha256_err_not_ready (void)
| Check if data was written before the hardware was ready. More...
static void | sha256_err_not_ready_clear (void)
| Clear the "not ready" error condition. More...
static volatile void * | sha256_get_write_addr (void)
| Address to write the data to be hashed. More...
static void | sha256_put_word (uint32_t word)
| Write one 32bit word of data to the SHA-256 hardware. More...
static void | sha256_put_byte (uint8_t b)
| Write one byte of data to the SHA-256 hardware. More...