Lines Matching full:target
30 int (*set_channel)(const struct emul *target, struct sensor_chan_spec ch,
33 int (*get_sample_range)(const struct emul *target, struct sensor_chan_spec ch, q31_t *lower,
36 int (*set_attribute)(const struct emul *target, struct sensor_chan_spec ch,
39 int (*get_attribute_metadata)(const struct emul *target, struct sensor_chan_spec ch,
50 * @param target Pointer to emulator instance to query
52 * @return True if supported, false if unsupported or if \p target is NULL.
54 static inline bool emul_sensor_backend_is_supported(const struct emul *target) in emul_sensor_backend_is_supported() argument
56 return target && target->backend_api; in emul_sensor_backend_is_supported()
62 * @param target Pointer to emulator instance to operate on
71 static inline int emul_sensor_backend_set_channel(const struct emul *target, in emul_sensor_backend_set_channel() argument
75 if (!target || !target->backend_api) { in emul_sensor_backend_set_channel()
79 struct emul_sensor_driver_api *api = (struct emul_sensor_driver_api *)target->backend_api; in emul_sensor_backend_set_channel()
82 return api->set_channel(target, ch, value, shift); in emul_sensor_backend_set_channel()
90 * @param target Pointer to emulator instance to operate on
104 static inline int emul_sensor_backend_get_sample_range(const struct emul *target, in emul_sensor_backend_get_sample_range() argument
108 if (!target || !target->backend_api) { in emul_sensor_backend_get_sample_range()
112 struct emul_sensor_driver_api *api = (struct emul_sensor_driver_api *)target->backend_api; in emul_sensor_backend_get_sample_range()
115 return api->get_sample_range(target, ch, lower, upper, epsilon, shift); in emul_sensor_backend_get_sample_range()
123 * @param[in] target Pointer to emulator instance to operate on
130 static inline int emul_sensor_backend_set_attribute(const struct emul *target, in emul_sensor_backend_set_attribute() argument
135 if (!target || !target->backend_api) { in emul_sensor_backend_set_attribute()
139 struct emul_sensor_driver_api *api = (struct emul_sensor_driver_api *)target->backend_api; in emul_sensor_backend_set_attribute()
144 return api->set_attribute(target, ch, attribute, value); in emul_sensor_backend_set_attribute()
153 * @param[in] target Pointer to emulator instance to operate on
164 static inline int emul_sensor_backend_get_attribute_metadata(const struct emul *target, in emul_sensor_backend_get_attribute_metadata() argument
170 if (!target || !target->backend_api) { in emul_sensor_backend_get_attribute_metadata()
174 struct emul_sensor_driver_api *api = (struct emul_sensor_driver_api *)target->backend_api; in emul_sensor_backend_get_attribute_metadata()
179 return api->get_attribute_metadata(target, ch, attribute, min, max, increment, shift); in emul_sensor_backend_get_attribute_metadata()