Coder Social home page Coder Social logo

stm32wb-hal's Introduction

stm32wb-hal

HAL for the STM32WB55 family of microcontrollers

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

stm32wb-hal's People

Contributors

eupn avatar rubdos avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

stm32wb-hal's Issues

help? "right" way to work on this locally?

Not really a great issue, but haven't found a better place to ask, and you probably had to to it yourself.

What's the "right" way of working on this project locally? I have a downstream "app" that uses stm32wb55, so I've added to it's Cargo.toml

# No releases of this yet.
stm32wb55 = { git = "https://github.com/eupn/stm32wb55", rev="fc16aeb208785" }
stm32wb-hal = { version = "0.1.14", features = ["xG-package"], path = "../rust-eupn-stm32wb-hal"}

The path on the -hal project is meant to pull from my local clone, but it doesn't pass the features along, so "cargo update; cargo build" in my own app just gives me:

karlp@strem:~/src/red-heart (rtic-style *)$ cargo update
    Updating git repository `https://github.com/danielgallagher0/bluetooth-hci`
    Updating crates.io index
    Updating git repository `https://github.com/eupn/stm32wb55`
karlp@strem:~/src/red-heart (rtic-style *)$ cargo run
   Compiling stm32wb-hal v0.1.14
   Compiling indexmap v1.7.0
   Compiling cortex-m-rtic v0.5.8
   Compiling generic-array v0.13.3
   Compiling generic-array v0.12.4
   Compiling heapless v0.7.5
   Compiling generic-array v0.14.4
error: failed to run custom build command for `stm32wb-hal v0.1.14`

Caused by:
  process didn't exit successfully: `/home/karlp/src/red-heart/target/debug/build/stm32wb-hal-af817ad112180049/build-script-build` (exit status: 101)
  --- stderr
  thread 'main' panicked at '

  Must select exactly one package for linker script generation!
  Choices: 'xC-package', 'xE-package' or 'xG-package'

  ', /home/karlp/.cargo/registry/src/github.com-1ecc6299db9ec823/stm32wb-hal-0.1.14/build.rs:19:13
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...
error: build failed
karlp@strem:~/src/red-heart (rtic-style *)$

If I enter my own clone directory, I can manually patch the feature in, so that cargo build in that directory works, but, that doesn't seem to get propagated anywhere... (and it doesn't seem like a very nice way of doing things anyway)

karlp@strem:~/src/rust-eupn-stm32wb-hal (more-power *)$ git diff
diff --git a/Cargo.toml b/Cargo.toml
index 4d72e96..111d4c9 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -63,7 +63,7 @@ xG-package = []
 
 rt = ["stm32wb-pac/rt"]
 
-default = [ "rt" ]
+default = [ "rt", "xG-package" ]
 
 [dev-dependencies]
 cortex-m-rtfm = "0.5"

cargo install Seemed like it might be correct, but that's only for binaries, not libraries, it says.

FlashExt not exported in prelude

It looks like FlashExt wasn't added (uncommented) to the prelude when the Flash impl was added, so your examples had to manually import FlashExt

docs.rs build fails due to required size feature

Hi,

The docs.rs builds are failing, because you must select a package size via feature.

Perhaps one option would be adding the following to Cargo.toml?

[package.metadata.docs.rs]
features = ["xG-package", "stm32-usbd"]

That should get full docs built?

bogus axp173 dependency?

This is listed as a dependency on crates.io and gets pulled in, but I can't see where it comes from? Does this need to be republished?

Cannot compile without `rt` feature

stm32wb-hal = { version = "0.1.2", default-features = false, features = ["xG-package", "rt"]}

compiles, but

stm32wb-hal = { version = "0.1.2", default-features = false, features = ["xG-package"]}

does not:

error[E0433]: failed to resolve: could not find `interrupt` in `stm32wb_pac`
  --> /home/rsmet/.cargo/registry/src/github.com-1ecc6299db9ec823/stm32wb-hal-0.1.2/src/ipcc.rs:60:61
   |
60 |             cortex_m::peripheral::NVIC::unmask(stm32wb_pac::interrupt::IPCC_C1_RX_IT);
   |                                                             ^^^^^^^^^ could not find `interrupt` in `stm32wb_pac`

error[E0433]: failed to resolve: could not find `interrupt` in `stm32wb_pac`
  --> /home/rsmet/.cargo/registry/src/github.com-1ecc6299db9ec823/stm32wb-hal-0.1.2/src/ipcc.rs:61:61
   |
61 |             cortex_m::peripheral::NVIC::unmask(stm32wb_pac::interrupt::IPCC_C1_TX_IT);
   |                                                             ^^^^^^^^^ could not find `interrupt` in `stm32wb_pac`

I'm not too acquainted yet with embedded systems, but it would be nice to get a warning what went wrong, especially because I just wanted to select the specific chip.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.