-
Notifications
You must be signed in to change notification settings - Fork 60
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
Make flash and ram size depend on the mcu feature #173
Conversation
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.
Looks good to me, although I didn't test or check against data sheets. I'd like to hear @dbrgn's opinion, as he's the resident CubeMX expert.
No problem, it's better to take the time to review and test this 🙂 I just realized I didn't remove the memory_l0x*.x files, so I'll do that before it gets merged. On an unrelated note, I was wondering what config you guys where using for rust-analyzer? I've added the following {
"rust-analyzer.cargo.features": ["mcu-STM32L071K8Ux"],
} |
🙂 I'll take a look as soon as I can. |
It's actually been a while since I actively worked on this repository, and I don't have an active checkout. I do have |
I think so, yes! I updated the list with the old version of cube-parse in #178. Can you rebase against the current In case you're unsure how to do this with git, don't hesitate to ask, I'm happy to help! |
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.
Two small suggestions for the README, otherwise this looks good to me! Thanks for implementing this change, I think it will be very useful to get started quickly.
This fixes stm32-rs#170 by adding features for flash and RAM sizes and adding enabling the appropriate one for each mcu feature.
Sorry for the noise, I think I forgot to add a file when rebasing. It should be good now. |
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.
Thanks! An intermediate commit adds git conflict markers (which are then removed again in the next commit), but we can solve that quite easily by squashing 🙂
This fixes stm32-rs#170 by adding features for flash and RAM sizes and enabling the appropriate one for each MCU feature. The memory.x files are removed because they're now generated from the build.rs. This commit also includes a clippy fix.
This fixes #170 by adding features for flash and RAM sizes and enabling the appropriate one for each mcu feature. It uses the new output from dbrgn/cube-parse#5
I'm not sure why I have more MCUs in the list, maybe a more recent version of CubeMX?
I tested it out locally, it seems to work.
Also I think this is a breaking change. Because it might break code that does not select a
mcu-*
feature but selects the other features manually. In that case no memory.x file will be loaded and the build will fail.