Nanobeacon driver.
More...
#include <stdbool.h>
#include <stdint.h>
#include "errorcode.h"
#include "kernel/err.h"
#include "lm32soc/dev_soc.h"
Go to the source code of this file.
Nanobeacon driver.
Definition in file nano.h.
Enumeration for nanobeacon enable states.
Enumerator |
---|
nanoEnableNone |
nanoEnableNone
|
nanoEnableCore |
nanoEnableCore
|
nanoEnableStepUp |
nanoEnableStepUp
|
nanoEnableCoreAndStepUp |
nanoEnableCoreAndStepUp
|
Definition at line 35 of file nano.h.
bool nanoConfig |
( |
uint32_t |
delay, |
|
|
uint32_t |
period, |
|
|
uint32_t |
width, |
|
|
uint32_t |
noOfPulses |
|
) |
| |
Configures the nano-beacon.
- Parameters
-
delay | The delay from the start of the second in 16ns ticks. |
period | The period of the nano-beacon in 16ns ticks |
width | The width of the nano-beacon pulse in 16ns ticks |
noOfPulses | The number of pulses per PPS. |
- Return values
-
true | Configuration succesful |
false | Configuration failed, check error module. |
Definition at line 22 of file nano.c.
Enable or disable the nano-beacon.
- Parameters
-
enable | true - Enable, false - disable. |
Definition at line 69 of file nano.h.
void nanoSetPulseDoneTask |
( |
int |
taskId | ) |
|
Configures the task to run if a pulse is done.
- Parameters
-
taskId | The taskID, or -1 to disable. |
Definition at line 34 of file nano.c.