mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 14:25:20 +03:00
Adding RP2350 SDK and target framework (#13988)
* Adding RP2350 SDK and target framework * Spacing * Removing board definitions
This commit is contained in:
parent
462cb05930
commit
2dd6f95aad
576 changed files with 435012 additions and 0 deletions
15
lib/main/pico-sdk/rp2_common/hardware_sha256/sha256.c
Normal file
15
lib/main/pico-sdk/rp2_common/hardware_sha256/sha256.c
Normal file
|
@ -0,0 +1,15 @@
|
|||
/**
|
||||
* Copyright (c) 2024 Raspberry Pi (Trading) Ltd.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
||||
#include "hardware/sha256.h"
|
||||
|
||||
void sha256_get_result(sha256_result_t *out, enum sha256_endianness endianness) {
|
||||
for (uint i = 0; i < count_of(out->words); i++) {
|
||||
uint32_t data = sha256_hw->sum[i];
|
||||
if (endianness == SHA256_BIG_ENDIAN) data = __builtin_bswap32(data);
|
||||
out->words[i] = data;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue