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

AP_Generator: FuelCell: increase max data rate #29414

Merged
merged 1 commit into from
Mar 4, 2025

Conversation

IamPete1
Copy link
Member

@IamPete1 IamPete1 commented Mar 2, 2025

At some point between when the comment was added on the function and now the generator scheduler rate was dropped to 10Hz. 30 bytes read per call at 10Hz means a max of 300 bytes per second rather than the 600 bytes per second it would have been originally.

This bumps it up to 255 bytes for a max of 2550 bytes per second. These typically ruin on a serial port at 9600 baud so a max of 960 bytes per second. We could go lower, 50 or 100 bytes per call would be fine for the existing units, but this was a PITA to debug so some headroom is nice.

@IamPete1
Copy link
Member Author

IamPete1 commented Mar 3, 2025

Without, we log exactly the 300 bytes/second limit and the generator is unhealthy:
image

With this fix we get the true data rate of about 350 bytes per second.
image

Copy link
Contributor

@CraigElder CraigElder left a comment

Choose a reason for hiding this comment

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

I found this issue and have tested this fix on real hardware.

@peterbarker peterbarker merged commit d4f0d40 into ArduPilot:master Mar 4, 2025
102 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Pending
Development

Successfully merging this pull request may close these issues.

3 participants