Add random number initialization to MyHw layer

This commit is contained in:
Marcelo Aquino
2016-08-21 23:42:44 -03:00
parent 9304cebddf
commit 48e90983ac
4 changed files with 5 additions and 2 deletions
+1 -1
View File
@@ -92,7 +92,7 @@ static void DEBUG_SIGNING_PRINTBUF(const __FlashStringHelper* str, uint8_t* buf,
void signerAtsha204SoftInit(void) {
// initialize pseudo-RNG
randomSeed(analogRead(MY_SIGNING_SOFT_RANDOMSEED_PIN));
hwRandomNumberInit();
// Set secrets
hwReadConfigBlock((void*)_signing_hmac_key, (void*)EEPROM_SIGNING_SOFT_HMAC_KEY_ADDRESS, 32);
hwReadConfigBlock((void*)_signing_node_serial_info, (void*)EEPROM_SIGNING_SOFT_SERIAL_ADDRESS, 9);