Home | History | Annotate | Download | only in health

Lines Matching refs:props

53 static void manta_bat_check_temp(struct BatteryProperties *props)
55 if (props->chargerAcOnline == false &&
56 props->chargerUsbOnline == false)
59 if (props->batteryTemperature >= TEMP_HIGH_THRESHOLD) {
64 props->batteryTemperature);
67 } else if (props->batteryTemperature <= TEMP_HIGH_RECOVERY &&
68 props->batteryTemperature >= TEMP_LOW_RECOVERY) {
73 props->batteryTemperature);
76 } else if (props->batteryTemperature <= TEMP_LOW_THRESHOLD) {
81 props->batteryTemperature);
140 static void manta_bat_charging_timer(struct BatteryProperties *props)
154 if (props->batteryVoltage > RECHARGING_VOLTAGE &&
155 props->batteryLevel == 100) {
166 struct BatteryProperties *props)
168 if (props->chargerUsbOnline || props->chargerAcOnline) {
204 static void manta_bat_monitor(struct BatteryProperties *props)
209 manta_bat_check_temp(props);
211 props->batteryTemperature = 42; /* 4.2C */
212 props->batteryVoltage = 4242; /* 4242mV */
213 props->batteryLevel = 42; /* 42% */
214 props->batteryCurrentNow = 42000;/* 42mA */
217 if (props->batteryStatus == BATTERY_STATUS_FULL &&
223 manta_bat_check_charge_source_changed(props);
227 if (props->batteryVoltage < RECHARGING_VOLTAGE &&
230 props->batteryVoltage);
258 if (props->chargerUsbOnline || props->chargerAcOnline) {
271 manta_bat_charging_timer(props);
274 props->batteryHealth = manta_bat_health;
275 props->batteryStatus = manta_bat_charging_status;
276 props->batteryTechnology = "Li-ion";
277 props->batteryPresent = manta_bat_batterypresent;
280 int healthd_board_battery_update(struct BatteryProperties *props)
282 manta_bat_monitor(props);