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

Use BATTERY_STATE for cellCount #3964

Merged
merged 3 commits into from
May 20, 2024
Merged

Conversation

haslinghuis
Copy link
Member

@haslinghuis haslinghuis added this to the 11.0 milestone May 15, 2024
@haslinghuis haslinghuis self-assigned this May 15, 2024
Copy link

netlify bot commented May 15, 2024

Deploy Preview for origin-betaflight-app ready!

Name Link
🔨 Latest commit 4176efb
🔍 Latest deploy log https://app.netlify.com/sites/origin-betaflight-app/deploys/664517430aac470008f55369
😎 Deploy Preview https://deploy-preview-3964.dev.app.betaflight.com
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@haslinghuis haslinghuis requested a review from a team May 15, 2024 17:26
@McGiverGim
Copy link
Member

Maybe then we can remove this?

const NO_BATTERY_VOLTAGE_MAXIMUM = 1.8; // Maybe is better to add a call to MSP_BATTERY_STATE but is not available for all versions

I think we don't support old versions anymore, so better to clean all this.

@McGiverGim
Copy link
Member

The idea was to remove the constant completely. The MSP message contains one variable that directly indicates if there is battery or not.

Copy link

sonarcloud bot commented May 15, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
22.2% Duplication on New Code

See analysis details on SonarCloud

Copy link
Member

@McGiverGim McGiverGim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Not tested but looks good to me.

@nerdCopter
Copy link
Member

no idea when i'll get to test with battery, request other testers.

@haslinghuis
Copy link
Member Author

Instead of calculating cell count we use cell count from firmware like used in pid profile cell count switching.

@nerdCopter
Copy link
Member

tested 2:
image
image

@haslinghuis haslinghuis merged commit c3cb9ce into betaflight:master May 20, 2024
7 checks passed
@haslinghuis haslinghuis deleted the fix-battery branch May 20, 2024 12:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

configurator battery gauge does not follow force_battery_cell_count
3 participants