-
Notifications
You must be signed in to change notification settings - Fork 137
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
DShot timing improvements #149
base: main
Are you sure you want to change the base?
Conversation
thanks! I will test |
LL_RCC_MSI_SetRange(LL_RCC_MSIRANGE_6); | ||
LL_RCC_MSI_SetCalibTrimming(0); | ||
LL_RCC_PLL_ConfigDomain_SYS(LL_RCC_PLLSOURCE_MSI, LL_RCC_PLLM_DIV_1, 40, LL_RCC_PLLR_DIV_2); | ||
LL_RCC_HSI_SetCalibTrimming(16); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why 16 for the trimming? maybe this is specific to your board?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I remember correctly that value comes from ST's data sheet and is mentioned there as default value. I did not do any trimming specific to my hardware.
Mcu/l431/Src/peripherals.c
Outdated
@@ -71,17 +71,15 @@ void SystemClock_Config(void) | |||
#endif | |||
|
|||
#else | |||
LL_RCC_MSI_Enable(); | |||
LL_RCC_HSI_Enable(); | |||
|
|||
/* Wait till MSI is ready */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment needs to be updated
/* Wait till MSI is ready */ | |
/* Wait till HSI is ready */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!
Do you mind merge multi commits into one? |
|
@NightHawk32 right |
198351d
to
c86212d
Compare
@Huibean done! |
I observed that the DShot telemetry responses of L431 are sometimes not picked up correctly by betaflight due to 2 reasons:
That's the MSI drifting when heated up witrh a heatgun:
https://github.com/user-attachments/assets/b4a752c0-762f-486b-9145-2abaf7c73def
This is wich HSI:
https://github.com/user-attachments/assets/8c232ff9-8f6b-4ace-a406-ba07d1ed5a5e
This also aligns well with this PR in the bootloader: am32-firmware/AM32-bootloader#35