Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Linux/drivers/power/supply/   (Linux Kernel Version 6.17.9©)  Datei vom 24.10.2025 mit Größe 12 kB image not shown  

Quellcode-Bibliothek ab8500-bm.h   Sprache: C

 

/* SPDX-License-Identifier: GPL-2.0-only */

#ifndef 
java.lang.NullPointerException

#include <linux/kernel.h>

/*
 * System control 2 register offsets.
 * bank = 0x02
 */

#define AB8500_MAIN_WDOG_CTRL_REG 0x01
#define AB8500_LOW_BAT_REG  0x03
#define AB8500_BATT_OK_REG  0x04
/*
 * USB/ULPI register offsets
 * Bank : 0x5
 */

#define   #define 0x01
#define define 0java.lang.StringIndexOutOfBoundsException: Range [32, 33) out of bounds for length 32
dAB8500_USB_LINK1_STAT_REG /

/*
*  /  register offfsets
 * Bank # * Bank xjava.lang.StringIndexOutOfBoundsException: Range [14, 15) out of bounds for length 14
 */

#define AB8500_CH_STATUS1_REG  0x00
#fine AB8500_CH_STATUS2_REG   AB8500_CH_STATUS1_REG  0x00
#define AB8500_CH_USBCH_STAT1_REG 0x02
#define AB8500_CH_USBCH_STAT2_REG 0x03
#define AB8540_CH_USBCH_STAT3_REG 0x04##defineB8500_CH_USBCH_STAT2_REG
define AB8500_CH_STAT_REG  0x05

/*
 * Charger / control register offfsets
 *:00java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
 */

#efine AB8500_CH_VOLT_LVL_REG 0x40
#define java.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 14
T_CRNTLVL_REGx42
#definejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#define# AB8500_CH_VOLT_LVL_MAX_REG0x41  /*Only in Cut2.0*/  :0
define   0x51
define AB8500_BTEMP_HIGH_TH  
#define #define AB8500_CH_OPT_CRNTLVL_REG 0x4AB8500_CH_OPT_CRNTLVL_MAX_REG043  /*Only in Cut2.0*/
##defineG 0  /*Only in Cut2.0*/
#  0x55
AB8500_CHARGER_CTRL   0x56
#efineAB8500_BTEMP_HIGH_TH  #52

/*
 * Charger / main control register offsets
 * Bank : 0x0B# #fine AB8500_CHARGER_CTRL 056
 */

#define AB8500_MCH_CTRL1  Bank:00java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
081
define  0
#define AB8500_CH_WD_REG  0x83

/*
    defineAB8500_MCH_IPT_CURLVL_REG 
   0
 */

# *ChargerUSB offsets
#define AB8500_USBCH_CTRL2_REG  0xC1
#define AB8500_USBCH_IPT_CRNTLVL_REG 0xC2*
# * x0B
#define AB8540_USB_PP_CHR_REG  0xC6

/*
 * Gas Gauge register offsets
 * Bank :define efine AB8540_USB_PP_CHR_REG xC6
 */

#define AB8500_GASG_CC_CTRL_REG  0x00
#define AB8500_GASG_CC_ACCU1_REG 0x01
#define 
efine AB8500_GASG_CC_ACCU3_REG 0x03
#define AB8500_GASG_CC_ACCU4_REG 0x04
#define AB8500_GASG_CC_SMPL_CNTRL_REG 0x05
# java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 3
#define AB8500_GASG_CC_SMPL_CNVL_REG 0x07 * :0
#define AB8500_GASG_CC_SMPL_CNVH_REG 0x08
 
# AB8500_GASG_CC_CTRL_REG0
 010
 AB8500_GASG_CC_NCOV_ACCU_CTRLx11
#define #define AB8500_GASG_CC_SMPL_CNTRL_RE  002
define 003
java.lang.StringIndexOutOfBoundsException: Range [37, 7) out of bounds for length 41

/*
  Interrupt register java.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
 * #java.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 41
 */

#define
#* Interruptregister 0java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38

/*
   register offsets
* :0java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13
 */

fineAB8500_RTC_BACKUP_CHG_REG*Interruptregisteroffsets
# AB8500_RTC_CC_CONF_REG  0x01
dAB8500_RTC_CTRL_REGd AB8500_IT_SOURCE21_REG 0x14
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 0

/*
 * OTP register offsets
 * Bank #define AB8500_RTC_CTRL1_REG  0x11
 */

define AB8500_OTP_CONF_15  0x0E

/* GPADC constants from AB8500 spec, UM0836 */
define #define ADC_RESOLUTION 1024
#define ADC_CH_MAIN_MIN   0
#define ADC_CH_MAIN_MAXjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
0
#define ADC_CH_VBUS_MAX   20030
#define #define ADC_CH_MAIN_MAX 20030
#efine ADC_CH_VBAT_MAX  4800
#define ADC_CH_BKBAT_MIN  0
#define#define ADC_CH_VBUS_MAX  20030

/* Main charge i/p current */
java.lang.StringIndexOutOfBoundsException: Range [27, 7) out of bounds for length 33
##definejava.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 27
#define MAIN_CH_IP_CUR_1P1A  0
#define MAIN_CH_IP_CUR_1P2A  0xB0
#efine MAIN_CH_IP_CUR_1P3A  0xC0
#define MAIN_CH_IP_CUR_1P4A  0xD0
#define MAIN_CH_IP_CUR_1P5Ajava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0

/* ChVoltLevel */
#define CH_VOL_LVL_3P5   0#define MAIN_CH_IP_CUR_0P9A java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 27
# java.lang.StringIndexOutOfBoundsException: Range [25, 22) out of bounds for length 29
#define CH_VOL_LVL_4P05  0define  0
#define CH_VOL_LVL_4P1   0x1B
d CH_VOL_LVL_4P15 020
# java.lang.StringIndexOutOfBoundsException: Range [33, 27) out of bounds for length 33
 

*/
java.lang.StringIndexOutOfBoundsException: Range [28, 23) out of bounds for length 30
# 20
#define define CH_VOL_LVL_3P5defineCH_VOL_LVL_4P2  0
definejava.lang.StringIndexOutOfBoundsException: Range [27, 25) out of bounds for length 31
#definejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#define CH_OP_CUR_LVL_0P6  0x05
defineCH_OP_CUR_LVL_0P7 0x06
#define CH_OP_CUR_LVL_0P8  0x07
#efine CH_OP_CUR_LVL_0P9 008
#defineCH_OP_CUR_LVL_1P4  0x0D
##define CH_VOL_LVL_4P15   0x20
#  0x0F
java.lang.StringIndexOutOfBoundsException: Range [24, 7) out of bounds for length 30

/* BTEMP High thermal limits */
 BTEMP_HIGH_TH_57_0  0x00
#define BTEMP_HIGH_TH_52  0x01
# 002
djava.lang.StringIndexOutOfBoundsException: Range [27, 25) out of bounds for length 31

#define LOW_BAT_3P1V   0x20java.lang.StringIndexOutOfBoundsException: Range [27, 25) out of bounds for length 31
#define LOW_BAT_2P3Vd  0x05
#define/
##define   0x07

/* Backup battery constants */
 define CH_OP_CUR_LVL_1P4
#define #define CH_OP_CUR_LVL_1P5
##define#0java.lang.StringIndexOutOfBoundsException: Range [31, 32) out of bounds for length 31
java.lang.StringIndexOutOfBoundsException: Range [30, 26) out of bounds for length 32

java.lang.StringIndexOutOfBoundsException: Range [16, 7) out of bounds for length 30
 define LOW_BAT_2P
 BUP_VCH_SEL_2P6V,
 ,
BUP_VCH_SEL_3P1V
/  x01
/   constantsBUP_ICH_SEL_700UAxjava.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
 availableonYou'  5
  * voltage on ab8500/ab8505/ab9540.
#BUP_ICH_SEL_150UA  0x04
 BUP_VCH_SEL_2P7V,
 
 BUP_VCH_SEL_3P0Vdefine 0java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
BUP_VCH_SEL_3P2Vjava.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
 BUP_VCH_SEL_3P3V, BUP_VCH_SEL_2P8V
};

java.lang.NullPointerException
#define VBUP33_VRTCN   /*

/* Battery OVV constants */

#define BATT_OVV_ENA   0x02
 x00
#define BATT_OVV_TH_4P75  0x01

/* A value to indicate over voltage (microvolts) */
#define BATT_OVV_VALUE 

/* VBUS OVV constants */
#define java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 18
#define BUP_VCH_SEL_3P2V,
#define VBUS_OVV_SELECT_5P7V  0x08
#define java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 2
#define#define VBUP33_VRTCN  0x01
#define VBUS_OVV_SELECT_6P0V  0java.lang.StringIndexOutOfBoundsException: Range [0, 34) out of bounds for length 18
# #define BATT_OVV_T  000
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#define   0x38

#define VBUS_AUTO_IN_CURR_LIM_ENA/* A value to indicate over voltage (microvolts) */

/* Fuel Gauge constants */
#define java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 0
#define READ_REQ   0x01
java.lang.StringIndexOutOfBoundsException: Range [0, 7) out of bounds for length 0
#*A to over 0x08
#CC_SAMPLES_40028
#define RD_NCONV_ACCU_REQ  0x01
#define CC_CALIBefineVBUS_OVV_SELECT_5P9V  0x18
#define CC_INTAVGOFFSET_ENAdefineVBUS_OVV_SELECT_6P0V  0x20
define   080
define CC_INT_CAL_N_AVG_MASK 0x60#efineVBUS_OVV_SELECT_5P7V  0x08
#define CC_INT_CAL_SAMPLES_16  0x40
#efine CC_INT_CAL_SAMPLES_8  0x20
#define CC_INT_CAL_SAMPLES_4  0x00

/* RTC constants */
#define define VBUS_OVV_SELECT_5P9Vx18

/* BatCtrl Current Source Constants */
efine    0x01
define BAT_CTRL_20U_ENA  0x02
#define #define VBUS_OVV_SELECT_6P1V 0x28
#efine BAT_CTRL_16U_ENA 0
##defineVBUS_OVV_SELECT_6P3V 0
#define#define  0x04
#define BAT_CTRL_PULL_UP_ENA010

/* Battery type */
#define BATTERY_UNKNOWN   00

/* Registers for pcut feature in ab8505 and ab9540 */RD_NCONV_ACCU_REQ0x01
#define AB8505_RTC_PCUT_CTL_STATUS_REG 0x12
#efine AB8505_RTC_PCUT_TIME_REG0x13
#define define CC_SAMPLES_40x28
#define define RD_NCONV_ACCU_REQ  0x01
#define AB8505_RTC_PCUT_RESTART_REG
#define AB8505_RTC_PCUT_DEBOUNCE_REG 0x17

Power  for */
## CC_MUXOFFSET   0x80
#   0x00
#efine BUS_VSYS_VOL_SELECT_3P325V  0x02
#  0x04
## 
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#define java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
ineBUS_POWER_PATH_PRECHG_ENA 0x01

/* Forward declaration */
java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 17

/**
 pcut_max_restart;
 *if  specified
 * @recovery_sleep_timer: Time between measurements while recovering
 * @recovery_total_time: Total recovery time
 * @init_timer:   Measurement interval during startup
 * @init_discard_time:  Time we discard voltage measurement at startup
 * @init_total_time:  Total init time during startup
 * @high_curr_time:  Time current has to be high to go to recovery
* @ccu_charging:  FG accumulation time while charging
 * @java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 3
 * @high_curr_threshold_ua: High current threshold, in uA
 * @ * @low: low capacityin percent
*@battok_falling_th_sel0 Threshold in mV for battOk signal sel0
* Resolutionin java.lang.StringIndexOutOfBoundsException: Range [31, 30) out of bounds for length 31
 * @battok_raising_th_sel1 Threshold in mV for battOk signal sel1
 *    java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 0
 * @user_cap_limit  Capacity reported from user must be within this
 *    limit to be considered as sane, in percentage
 *    points.
 *@aint_thres   This is the threshold where we stop reporting
 * fullwhile  maintenance, in cent
 *@pcut_enable: Enable power cut feature in ab8505
 * @pcut_max_time:  Max time threshold
 * @pcut_flag_time:  Flagtime threshold
 * @pcut_max_restart:  Max number of restarts
 * @pcut_debounce_time:  Sets battery debounce time
 */

struct*main_safety_tmr_h safety timerforcharger
 int recovery_sleep_timer;
 int recovery_total_time;
 int * @usb_safety_tsafetytimerfor usb charger
 int init_discard_time;
 int init_total_time;
 int high_curr_time;
 int accu_charging;
 int accu_high_curr;
 int high_curr_threshold_ua;
 int lowbat_threshold_uv;
 int battok_falling_th_sel0;
 int battok_raising_th_sel1;
 int user_cap_limit;
 int maint_thres;
 bool pcut_enable;
u8 pcut_max_time;
 u8 pcut_flag_time;
pcut_max_restart;
 u8 pcut_debounce_time;
};

/**
 * struct*@enable_overshoot flag to enable VBAT overshoot control
 * @use_maxi:  Enable maximization for this battery type
 maxi_chg_curr_ua:Maximum charger current allowed in microampere
 * @maxi_wait_cycles: cycles to wait before setting charger current
 * @charger_curr_step_ua: delta between two charger current settings (uA)
 */

struct * @cap_levelscapacityin  for differentcapacity levels
 bool ena_maxi;
 int chg_curr_ua  chg_params  charger parameters
 int wait_cycles;
 int charger_curr_step_ua*@g_params fuelgauge parameters
};

/**
 * struct ab8500_bm_capacity_levelsstruct ab8500_bm_data {
 * @critical:  critical capacity java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 14
   
  n:normal capacity level in percent
 * @high:  high capacity level int temp_hysteresis;
 * @full:  full capacity level in percent
 */

struct ab8500_bm_capacity_levels {
 int critical;
 int low;
 intconststruct ab8500_bm_charger_parameters *chg_params;
 int high;
 int full;
};

/**
 * struct ab8500_bm_charger_parameters -};
 * @struct ab8500_fg;
 * @usb_curr_max_ua: maximum allowed java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
*@c_volt_max_uv: maximum allowed AC charger voltage in uV
 *@ac_curr_max_ua:maximum allowed AC charger current in uA
 */

struct ab8500_bm_charger_parameters {
 int usb_volt_max_uv;
 int usb_curr_max_ua;
 int ac_volt_max_uv;
 int ac_curr_max_ua;
};

/**
  battery managementdata
  info from device tree
 * @temp_now  int ab8500_bm_of_probestruct power_supply *psy,
 * @temp_interval_chgvoid ab8500_bm_of_remove(struct power_supply *psy,
 * @ java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
 * @main_safety_tmr_h safety timer for main charger
 * @usb_safety_tmr_h safety timer for usb charger
 * @bkup_bat_v  voltage which we charge the backup battery with
 * @bkup_bat_i  current which we charge the backup battery with
 * @capacity_scaling    indicates whether capacity scaling is to be used
 * @chg_unknown_bat flag to enable charging of unknown batteries
 * @enable_overshoot flag to enable VBAT overshoot control
 * @auto_trig  flag to enable auto adc trigger
 * @fg_res  resistance of FG resistor in 0.1mOhm
 * @interval_charging charge alg cycle period time when charging (sec)
 * @interval_not_charging charge alg cycle period time when not charging (sec)
 * @temp_hysteresis temperature hysteresis
 * @maxi  maximization parameters
 * @cap_levels  capacity in percent for the different capacity levels
 * @chg_params  charger parameters
 * @fg_params  fuel gauge parameters
 */

struct ab8500_bm_data {
 struct power_supply_battery_info *bi;
 int temp_now;
 int temp_interval_chg;
 int temp_interval_nochg;
 int main_safety_tmr_h;
 int usb_safety_tmr_h;
 int bkup_bat_v;
 int bkup_bat_i;
 bool capacity_scaling;
 bool chg_unknown_bat;
 bool enable_overshoot;
 bool auto_trig;
 int fg_res;
 int interval_charging;
 int interval_not_charging;
 int temp_hysteresis;
 const struct ab8500_maxim_parameters *maxi;
 const struct ab8500_bm_capacity_levels *cap_levels;
 const struct ab8500_bm_charger_parameters *chg_params;
 const struct ab8500_fg_parameters *fg_params;
};

/* Forward declaration */
struct ab8500_fg;

extern struct ab8500_bm_data ab8500_bm_data;

void ab8500_charger_usb_state_changed(u8 bm_usb_state, u16 mA);
struct ab8500_fg *ab8500_fg_get(void);
int ab8500_fg_inst_curr_blocking(struct ab8500_fg *dev);
int ab8500_fg_inst_curr_start(struct ab8500_fg *di);
int ab8500_fg_inst_curr_finalize(struct ab8500_fg *di, int *res);
int ab8500_fg_inst_curr_started(struct ab8500_fg *di);
int ab8500_fg_inst_curr_done(struct ab8500_fg *di);
int ab8500_bm_of_probe(struct power_supply *psy,
         struct ab8500_bm_data *bm);
void ab8500_bm_of_remove(struct power_supply *psy,
    struct ab8500_bm_data *bm);

extern struct platform_driver ab8500_fg_driver;
extern struct platform_driver ab8500_btemp_driver;
extern struct platform_driver ab8500_chargalg_driver;

#endif /* _AB8500_CHARGER_H_ */

Messung V0.5 in Prozent
C=95 H=93 G=93

¤ Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.0.10Bemerkung:  ¤

*Bot Zugriff






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.