Cascoda SDK
Cascoda SDK for building software to run with CA-821x transceivers
cascoda_rand.c File Reference
#include <assert.h>
#include <stddef.h>
#include <stdint.h>
#include <string.h>
#include "mbedtls/ctr_drbg.h"
#include "mbedtls/entropy.h"
#include "mbedtls/entropy_poll.h"
#include "cascoda-util/cascoda_rand.h"
#include "ca821x_api.h"
#include "ca821x_toolchain.h"
#include "cascoda_bm_internal.h"
Include dependency graph for cascoda_rand.c:

Macros

#define MIN(a, b)   (((a) < (b)) ? (a) : (b))
 

Functions

CA_TOOL_WEAK mbedtls_ctr_drbg_context * otRandomCryptoMbedTlsContextGet (void)
 
void RAND_SetCryptoEntropyDev (struct ca821x_dev *pDeviceRef)
 Set the device for seeding the CPRNG. More...
 
ca_error RAND_GetCryptoBytes (uint16_t aNumBytes, void *aBytesOut)
 Get random data for cryptographic purposes. More...
 
void RAND_AddRadioEntropySource (void)
 Add the radio-based RNG as an entropy source used by mbedTLS. More...
 

Macro Definition Documentation

◆ MIN

#define MIN (   a,
 
)    (((a) < (b)) ? (a) : (b))

Function Documentation

◆ otRandomCryptoMbedTlsContextGet()

CA_TOOL_WEAK mbedtls_ctr_drbg_context* otRandomCryptoMbedTlsContextGet ( void  )

◆ RAND_SetCryptoEntropyDev()

void RAND_SetCryptoEntropyDev ( struct ca821x_dev pDeviceRef)

Set the device for seeding the CPRNG.

Parameters
pDeviceRefca821x device to use for entropy sourcing