-
Notifications
You must be signed in to change notification settings - Fork 5
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
Cannot build Wrapper object using stm32l0xx_hal #1
Comments
hey thanks for opening an issue! i'm super excited to play with this on those modules. this appears to be a poor design decision on my part with the embedded-spi abstraction, that i definitely hadn't intended to propagate through to driver consumers. the quickest fix for you would probably be to wrap the different GPIO pins in a common base enum that implements the correct fix here i think is to split the type of each pin so that: this is actually something i intended to do because it means that each of the implementations (ie. the i'd be happy to accept (and coach you through if it's useful) a PR making this change, otherwise i'll put it on my list and the quick fix should work for now ^_^ |
I'll have a go at working on a PR; It'd be the best way for me to learn about the guts of this stuff anyway. I've got a decent amount of experience with embedded C so it's mostly just battling the rust approach to it, which is the whole point I'm doing this! I ran into the same underlying issue modeling my BSP by following the f3 example. The LED's on that board are all off the same port, where mine are on two. Good to see the bundling in an enum approach I ended up with for now isn't a complete hack :) |
I'm having some trouble using Wrapper::new with stm32l0xx_hal. I suspect the underlying issue is with the hal crate but I'm not sure where to start. I'm trying to follow your example in the radio-sx127x crate in Sx127x::spi method. My crate is at https://gitlab.com/berkowski/b-l072z-lrwan1, but the problem code is below.
Fails to compile with
Whatever pin I change
cs
to be I get an error thatwith_reset
expects that same pin, and this level of rust is a bit beyond mine to decipher. Not a great excuse, but I could use some help tracking down the culprit.The text was updated successfully, but these errors were encountered: