Internal system. More...
Functions | |
system_result_t | hal_system_reset (void) |
Perform system reset. | |
system_result_t | hal_system_set_power_mode (system_power_mode_t mode) |
Put device into sleep mode. | |
uint32_t | hal_system_get_ticks (void) |
Get system ticks. | |
system_result_t | hal_system_get_serial_number (void *serial_number, const size_t len) |
Get device serial number from manufacturer. | |
system_result_t | hal_system_get_temp_celsius (float *temp) |
Get device internal temperature in degrees Celsius. | |
Internal system.
enum system_power_mode_t |
#include <system/public_inc/hal_system.h>
Enumerator | |
---|---|
SYSTEM_POWER_MODE_SLEEP | |
SYSTEM_POWER_MODE_IDLE | |
SYSTEM_POWER_MODE_SHUTDOWN | |
SYSTEM_POWER_MODE_DEEP_SLEEP | |
SYSTEM_POWER_MODE_STOP | |
TOTAL_SYSTEM_POWER_MODE |
enum system_result_t |
#include <system/public_inc/hal_system.h>
Enumerator | |
---|---|
SYSTEM_RESULT_OK | No error. |
SYSTEM_RESULT_INVALID | Operation invalid. |
SYSTEM_RESULT_UNSUPPORTED | Operation not supported. |
SYSTEM_RESULT_ERR | Error occurred. |
TOTAL_SYSTEM_RESULT |
system_result_t hal_system_get_serial_number | ( | void * | serial_number, |
const size_t | len ) |
#include <system/public_inc/hal_system.h>
Get device serial number from manufacturer.
[in,out] | serial_number | Device serial number buffer |
[in] | len | Buffer size |
SYSTEM_RESULT_OK | Success get device serial number |
SYSTEM_RESULT_UNSUPPORTED | Operation not supported |
SYSTEM_RESULT_ERR | Failed to get device serial number |
system_result_t hal_system_get_temp_celsius | ( | float * | temp | ) |
#include <system/public_inc/hal_system.h>
Get device internal temperature in degrees Celsius.
[in,out] | temp | Temperature in degrees Celsius |
SYSTEM_RESULT_OK | Success get internal temperature |
SYSTEM_RESULT_UNSUPPORTED | Operation not supported |
SYSTEM_RESULT_ERR | Failed to get internal temperature |
uint32_t hal_system_get_ticks | ( | void | ) |
#include <system/public_inc/hal_system.h>
Get system ticks.
system_result_t hal_system_reset | ( | void | ) |
#include <system/public_inc/hal_system.h>
Perform system reset.
SYSTEM_RESULT_UNSUPPORTED | Operation not supported |
SYSTEM_RESULT_ERR | Failed to perform system reset |
system_result_t hal_system_set_power_mode | ( | system_power_mode_t | mode | ) |
#include <system/public_inc/hal_system.h>
Put device into sleep mode.
[in] | mode | Device power mode |
SYSTEM_RESULT_OK | Success enter sleep mode |
SYSTEM_RESULT_UNSUPPORTED | Operation not supported |
SYSTEM_RESULT_ERR | Failed to enter sleep mode |