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

Add support for STM32F42x/STM32F43x rev. 5/B #15407

Merged
merged 2 commits into from
Jan 31, 2021

Conversation

sfalexrog
Copy link
Contributor

This P/R adds REV_IDs for STM32F427 rev. 5 and B.

Note that, accoding to https://www.st.com/resource/en/errata_sheet/dm00068628-stm32f427437-and-stm32f429439-line-limitations-stmicroelectronics.pdf, both 5 and B share the same REV_ID. This patch reports both as rev. 5.

Fixes #15406

According to ST, both 5 and B share the same REV_ID.

Signed-off-by: Alexey Rogachevskiy <sfalexrog@gmail.com>
@@ -151,8 +153,10 @@ int board_mcu_version(char *rev, const char **revstr, const char **errata)
chip_errata = NULL;
break;

case MCU_REV_STM32F7_REV_V:
*rev = 'V';
case MCU_REV_STM32F4_REV_5:
Copy link
Member

Choose a reason for hiding this comment

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

Are these gaps we could be preemptively filling in before someone hits them?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm sorry, I could not quite understand what you've meant there. Could you elaborate?

Copy link
Member

Choose a reason for hiding this comment

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

@dagar I believe it is a sparse array.

This is the latese published in R18 of https://www.st.com/resource/en/reference_manual/dm00031020-stm32f405-415-stm32f407-417-stm32f427-437-and-stm32f429-439-advanced-arm-based-32-bit-mcus-stmicroelectronics.pdf

0x1000 = Revision A
0x1003 = Revision Y
0x1007 = Revision 1
0x2001= Revision 3
0x2003= Revision 5 and B

case MCU_REV_STM32F4_REV_5:
// MCU_REV_STM32F4_REV_B shares the same REV_ID
// MCU_REV_STM32F7_REV_V shares the same REV_ID
*rev = chip_version == STM32H74xx_75xx ? 'V' : '5';
Copy link
Member

Choose a reason for hiding this comment

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

The comment does not match the code
STM32H74xx_75xx

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, sorry, I got confused by surrounding code.

Judging by the ST errata sheets, there's no V or X revisions for STM32F7 series, only STM32H7. I've changed the enum names to reflect that.

Copy link
Member

Choose a reason for hiding this comment

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

comment says MCU_REV_STM32F7_REV_V shares the same REV_ID code has STM32H74xx_75xx

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, I've changed the comment to say H7.

The comment was about the enum name of MCU_REV_STM32F7_REV_V, which is itself somewhat confusing, since no F7 to date seems to have a REV_ID of 0x2003.

@stale
Copy link

stale bot commented Dec 25, 2020

This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions.

@stale stale bot added the stale label Dec 25, 2020
@LorenzMeier LorenzMeier merged commit c01d459 into PX4:master Jan 31, 2021
@LorenzMeier
Copy link
Member

Thanks!

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

Successfully merging this pull request may close these issues.

STM32F427 rev.5 reported incorrectly
4 participants