Searched +full:battery +full:- +full:cutoff +full:- +full:payload (Results 1 – 7 of 7) sorted by relevance
/Zephyr-latest/dts/bindings/fuel-gauge/ |
D | battery-cutoff.yaml | 4 # SPDX-License-Identifier: Apache-2.0 9 Properties for fuel-gauges that may control battery cutoff, this is common in SBS-compliant or 10 similarly smart battery fuel gauges. 13 their associated battery from the system. See the default fuel gauge SBS Gauge compatible as an 17 battery-cutoff-support: 19 Helper prop that indicates whether this device can cutoff the battery; this is also often 22 battery-cutoff-reg-addr: 24 Address of register to receive cutoff payload for battery cutoff. 26 battery-cutoff-payload: 28 Payload to write to cutoff battery register. This must be array of maximum 2 integers.
|
D | sbs,default-sbs-gauge.yaml | 4 # SPDX-License-Identifier: Apache-2.0 7 compatible: "sbs,default-sbs-gauge" 9 include: ["sbs,sbs-gauge-new-api.yaml", "battery-cutoff.yaml"] 12 Default generic smart battery fuel gauge driver. Includes support for battery cutoff if enabled. 18 battery-cutoff-reg-addr: 21 battery-cutoff-payload:
|
/Zephyr-latest/doc/hardware/peripherals/ |
D | fuel_gauge.rst | 6 The fuel gauge subsystem exposes an API to uniformly access battery fuel gauge devices. Currently, 20 Fuel gauges typically support multiple properties, such as temperature readings of the battery-pack 21 or present-time current/voltage. 29 Battery Cutoff 32 Many fuel gauges embedded within battery packs expose a register address that when written to with a 33 specific payload will do a battery cutoff. This battery cutoff is often referred to as ship, shelf, 34 or sleep mode due to its utility in reducing battery drain while devices are stored or shipped. 36 The fuel gauge API exposes battery cutoff with the :c:func:`fuel_gauge_battery_cutoff` function.
|
/Zephyr-latest/tests/drivers/fuel_gauge/sbs_gauge/boards/ |
D | emulated_board_cutoff.overlay | 4 * SPDX-License-Identifier: Apache-2.0 7 #include <zephyr/dt-bindings/i2c/i2c.h> 12 compatible = "zephyr,i2c-emul-controller"; 13 clock-frequency = <I2C_BITRATE_STANDARD>; 14 #address-cells = <1>; 15 #size-cells = <0>; 21 clock-frequency = <I2C_BITRATE_STANDARD>; 22 compatible = "zephyr,i2c-emul-controller"; 24 compatible = "sbs,default-sbs-gauge","sbs,sbs-gauge-new-api"; 27 battery-cutoff-support; [all …]
|
/Zephyr-latest/drivers/fuel_gauge/sbs_gauge/ |
D | sbs_gauge.h | 4 * SPDX-License-Identifier: Apache-2.0 51 * Nearly all cutoff payloads are actually a singular value that must be written twice to the fuel 55 * Why not devicetree: Finding the maximum length of all the battery cutoff payloads in a devicetree 56 * at compile-time would require labyrinthine amount of macro-batics. 59 * is rare, and most will have a payload size of 2. 66 /* Size of the payload array */ 68 /* Array SMBus word values to write to cut off the battery */ 69 uint32_t payload[SBS_GAUGE_CUTOFF_PAYLOAD_MAX_SIZE]; member 70 /* Register to write cutoff payload */
|
D | emul_sbs_gauge.c | 5 * SPDX-License-Identifier: Apache-2.0 7 * Emulator for SBS 1.1 compliant smart battery fuel gauge. 33 /** Run-time data used by the emulator */ 40 /* Whether the battery cutoff or not */ 43 * Counts the number of times the cutoff payload has been sent to the designated 48 /* Non-register values associated with the state of the battery */ 49 /* Battery terminal voltage */ 51 /* Battery terminal current - Pos is charging, Neg is discharging */ 67 struct sbs_gauge_emul_data *data = target->data; in emul_sbs_gauge_maybe_do_battery_cutoff() 68 const struct sbs_gauge_emul_cfg *cfg = target->cfg; in emul_sbs_gauge_maybe_do_battery_cutoff() [all …]
|
D | sbs_gauge.c | 7 * SPDX-License-Identifier: Apache-2.0 31 cfg = dev->config; in sbs_cmd_reg_read() 32 status = i2c_burst_read_dt(&cfg->i2c, reg_addr, i2c_data, ARRAY_SIZE(i2c_data)); in sbs_cmd_reg_read() 45 const struct sbs_gauge_config *config = dev->config; in sbs_cmd_reg_write() 50 return i2c_burst_write_dt(&config->i2c, reg_addr, buf, sizeof(buf)); in sbs_cmd_reg_write() 59 cfg = dev->config; in sbs_cmd_buffer_read() 60 status = i2c_burst_read_dt(&cfg->i2c, reg_addr, buffer, buffer_size); in sbs_cmd_buffer_read() 78 val->avg_current = tmp_val * 1000; in sbs_gauge_get_prop() 82 val->cycle_count = tmp_val; in sbs_gauge_get_prop() 86 val->current = (int16_t)tmp_val * 1000; in sbs_gauge_get_prop() [all …]
|