mirror of
https://github.com/polhenarejos/pico-keys-sdk
synced 2026-05-11 01:38:26 +02:00
Adding functions for calling random in core0.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -176,6 +176,17 @@ void neug_wait_full(void) { //should be called only on core1
|
||||
}
|
||||
}
|
||||
|
||||
void neug_wait_full_ext(bool blocking) {
|
||||
struct rng_rb *rb = &the_ring_buffer;
|
||||
|
||||
while (!rb->full) {
|
||||
if (blocking == true)
|
||||
sleep_ms(1);
|
||||
else
|
||||
neug_task();
|
||||
}
|
||||
}
|
||||
|
||||
void neug_fini(void) {
|
||||
neug_get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user