28 lines
261 B
C++
28 lines
261 B
C++
//
|
|
// Created by erki on 29.04.21.
|
|
//
|
|
|
|
#include "utility_rand.hpp"
|
|
|
|
namespace
|
|
{
|
|
|
|
std::uint32_t rand_state = 0;
|
|
|
|
}
|
|
|
|
namespace Peripherals
|
|
{
|
|
|
|
void srand(const std::uint32_t& seed)
|
|
{
|
|
rand_state = seed;
|
|
}
|
|
|
|
std::uint32_t rand()
|
|
{
|
|
return rand32(rand_state);
|
|
}
|
|
|
|
}
|