Home
last modified time | relevance | path

Searched refs:vals (Results 1 – 5 of 5) sorted by relevance

/Zephyr-latest/tests/drivers/fuel_gauge/bq27z746/src/
Dtest_bq27z746.c44 union fuel_gauge_prop_val vals[ARRAY_SIZE(props)]; in ZTEST_USER_F() local
46 int ret = fuel_gauge_get_props(fixture->dev, props, vals, ARRAY_SIZE(props)); in ZTEST_USER_F()
122 union fuel_gauge_prop_val vals[ARRAY_SIZE(props)]; in ZTEST_USER_F() local
124 zassert_ok(fuel_gauge_get_props(fixture->dev, props, vals, ARRAY_SIZE(props))); in ZTEST_USER_F()
129 zassert_equal(vals[0].avg_current, -2000); in ZTEST_USER_F()
130 zassert_equal(vals[1].cycle_count, 100); in ZTEST_USER_F()
131 zassert_equal(vals[2].current, -2000); in ZTEST_USER_F()
132 zassert_equal(vals[3].full_charge_capacity, 1000); in ZTEST_USER_F()
133 zassert_equal(vals[4].remaining_capacity, 1000); in ZTEST_USER_F()
134 zassert_equal(vals[5].runtime_to_empty, 1); in ZTEST_USER_F()
[all …]
/Zephyr-latest/samples/fuel_gauge/max17048/src/
Dmain.c49 union fuel_gauge_prop_val vals[ARRAY_SIZE(props)]; in main() local
51 ret = fuel_gauge_get_props(dev, props, vals, ARRAY_SIZE(props)); in main()
55 printk("Time to empty %d minutes\n", vals[0].runtime_to_empty); in main()
57 printk("Time to full %d minutes\n", vals[1].runtime_to_full); in main()
59 printk("Charge %d%%\n", vals[2].relative_state_of_charge); in main()
61 printk("Voltage %d\n uV", vals[3].voltage); in main()
/Zephyr-latest/drivers/fuel_gauge/
Dfuel_gauge_syscall_handlers.c31 union fuel_gauge_prop_val *vals, size_t len) in z_vrfy_fuel_gauge_get_props() argument
38 K_OOPS(k_usermode_from_copy(k_vals, vals, len * sizeof(union fuel_gauge_prop_val))); in z_vrfy_fuel_gauge_get_props()
43 K_OOPS(k_usermode_to_copy(vals, k_vals, len * sizeof(union fuel_gauge_prop_val))); in z_vrfy_fuel_gauge_get_props()
64 const union fuel_gauge_prop_val *vals, size_t len) in z_vrfy_fuel_gauge_set_props() argument
71 K_OOPS(k_usermode_from_copy(k_vals, vals, len * sizeof(union fuel_gauge_prop_val))); in z_vrfy_fuel_gauge_set_props()
/Zephyr-latest/include/zephyr/drivers/
Dfuel_gauge.h292 union fuel_gauge_prop_val *vals, size_t len);
295 union fuel_gauge_prop_val *vals, size_t len) in z_impl_fuel_gauge_get_props() argument
300 int ret = api->get_property(dev, props[i], vals + i); in z_impl_fuel_gauge_get_props()
346 const union fuel_gauge_prop_val *vals, size_t len);
350 const union fuel_gauge_prop_val *vals, size_t len) in z_impl_fuel_gauge_set_props() argument
353 int ret = fuel_gauge_set_prop(dev, props[i], vals[i]); in z_impl_fuel_gauge_set_props()
/Zephyr-latest/tests/lib/devicetree/api/src/
Dmain.c2409 struct vnd_child_binding vals[] = { in ZTEST() local
2441 zassert_equal(ARRAY_SIZE(vals), 3, ""); in ZTEST()
2450 zassert_equal(vals[0].val, 0, ""); in ZTEST()
2451 zassert_equal(vals[1].val, 1, ""); in ZTEST()
2452 zassert_equal(vals[2].val, 2, ""); in ZTEST()
2488 struct vnd_child_binding vals[] = { in ZTEST() local
2520 zassert_equal(ARRAY_SIZE(vals), 3, ""); in ZTEST()
2529 zassert_equal(vals[0].val, 1, ""); in ZTEST()
2530 zassert_equal(vals[1].val, 2, ""); in ZTEST()
2531 zassert_equal(vals[2].val, 3, ""); in ZTEST()