Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct BATTERY_CAPACITY configuration #11

Open
Kabron287 opened this issue Mar 23, 2021 · 1 comment
Open

Correct BATTERY_CAPACITY configuration #11

Kabron287 opened this issue Mar 23, 2021 · 1 comment

Comments

@Kabron287
Copy link

In the BQ27441_Extended_Configuration example lipo.setCapacity(BATTERY_CAPACITY) command executed
AFTER entering config mode(lipo.enterConfig()),
while in the BQ27441_Basic example it executed WITHOUT entering config mode.
Is it correct?

@wystewart
Copy link

both are correct. setCapacity will call enterConfig as long as enterConfig has not been previously called (without parameters or with true as parameter). However if you call enterConfig with no parameters, then call exitConfig, then at somepoint call setCapacity or other config functions without calling enterConfig first they will fail. Alternately call enterConfig(false), exitConfig then you can call setCapacity without calling enterConfig.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants