Files
MuditaOS/module-bsp/board/linux/trng/trng.cpp
Lefucjusz 773f2c7eb1 [BH-2069] Update license URL in headers
Update outdated license file URL in
license headers across all project.
2024-09-18 11:53:01 +02:00

16 lines
424 B
C++

// Copyright (c) 2017-2024, Mudita Sp. z.o.o. All rights reserved.
// For licensing, see https://github.com/mudita/MuditaOS/blob/master/LICENSE.md
#include "bsp/trng/trng.hpp"
#include <random>
#include <memory>
namespace bsp::trng
{
std::uint32_t getRandomValue()
{
const auto trueRandomSource = std::make_unique<std::random_device>();
return (*trueRandomSource)();
}
} // namespace bsp::trng