mirror of
https://github.com/apache/nuttx.git
synced 2026-05-26 10:46:28 +08:00
battery:add goldfish battery driver
support the goldfish emulator battery driver Signed-off-by: dulibo1 <dulibo1@xiaomi.com>
This commit is contained in:
@@ -251,6 +251,25 @@ FAR struct battery_gauge_dev_s *max1704x_initialize(
|
||||
uint32_t frequency);
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_GOLDFISH_BATTERY)
|
||||
/****************************************************************************
|
||||
* Name: goldfish_battery_register
|
||||
*
|
||||
* Description:
|
||||
* Register a emulate battery to tyhe upper-half battery driver.
|
||||
*
|
||||
* Input Parameters:
|
||||
* regs - the base address for the goldfish battery.
|
||||
* irq - An irq num for the goldfish battery.
|
||||
*
|
||||
* Returned Value:
|
||||
* Zero on success or a negated errno value on failure.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int goldfish_battery_register(FAR void *regs, int irq);
|
||||
#endif
|
||||
|
||||
#undef EXTERN
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user