10#ifndef INFUSE_SDK_INCLUDE_INFUSE_TASK_RUNNER_TASKS_BATTERY_H_
11#define INFUSE_SDK_INCLUDE_INFUSE_TASK_RUNNER_TASKS_BATTERY_H_
13#include <zephyr/kernel.h>
54#define BATTERY_TASK(define_mem, define_config, bat_ptr) \
55 IF_ENABLED(define_config, ({.name = "bat", \
56 .task_id = TASK_ID_BATTERY, \
57 .exec_type = TASK_EXECUTOR_WORKQUEUE, \
58 .flags = TASK_FLAG_ARG_IS_DEVICE, \
59 .task_arg.dev = bat_ptr, \
60 .executor.workqueue = { \
61 .worker_fn = battery_task_fn, \
Battery measurement task.
int task_battery_manual_run(const struct device *dev, const struct task_battery_args *args, struct tdf_battery_state *tdf)
Manually run the core battery sampling logic.
void battery_task_fn(struct k_work *work)
Battery task function.
Autogenerated TDF definitions.
Task Runner task scheduling.
Battery task arguments.
Definition battery_args.h:31
General battery state.
Definition definitions.h:154