Closed pdgilbert closed 3 years ago
Thanks so much for the PR and all the examples, @pdgilbert! I love having them but I don't think they and the linker scripts and dependencies fit in this repo, which I'd like to keep as lean as possible. In fact, I think the current .cargo/config
, memory.x
, nucleo.cfg
and openocd.gdb
can probably be removed too.
However, if you want to maintain the examples in another repo (I think separate source files per mcu is more readable), we can put a link from README.md
to it/the examples, what do you think?
Ok, I understand wanting it mean and lean. One advantage of examples is that they also provide an integration test, but there is overhead. I'll just leave it in my fork and you could point to it there if you like. I will also run it with examples at https://pdgilbert.github.io/eg_stm_hal/, put the hope there is to have stable crates to check recent hal changes. Most users would probably prefer the examples that run with released hals.
More immediately, I cannot figure out how to cancel the pull request, and so you are unnecessarily running all my attempts to learn workflows.
I think I see how to cancel the pull request.
No worries, Github covers running the workflows 😃 thanks again for the PR!
This example (
examples/dht-multi-hals.rs
) hassetup()
functions so it can run with different HALs and MCUs. Building and running is explained in comments in the file. The changes toCargo.toml
,.cargo/config
, and the addition of directorymemoryMaps
and filebuild.rs
are all to support running with different MCUs.The root file
memory.x
is moved to directorymemoryMaps/STM32F042/
. This makes it necessary to specify a feature to find amemory.x
file. For exampleThat was not needed when
memory.x
was in the root.