-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
INFRA - Use Rust procedural macros to reduce code duplication in boar…
…d crates (#52)
- Loading branch information
1 parent
9481fb1
commit 1fbfb77
Showing
46 changed files
with
638 additions
and
243 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,5 @@ | ||
[default.extend-words] | ||
mosquitto = "mosquitto" | ||
mosquitto = "mosquitto" | ||
|
||
[files] | ||
extend-exclude = ["telemetry/pnpm-lock.yaml"] |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,26 @@ | ||
pub mod adc; | ||
pub mod gpio; | ||
pub mod i2c; | ||
use embassy_stm32::adc::{Adc, AnyAdcChannel, Instance}; | ||
use embassy_stm32::gpio::Input; | ||
use embassy_stm32::{i2c::I2c, mode::Blocking}; | ||
|
||
use hyped_adc::HypedAdc; | ||
use hyped_adc_derive::HypedAdc; | ||
use hyped_gpio_input::HypedGpioInput; | ||
use hyped_gpio_input_derive::HypedGpioInput; | ||
use hyped_i2c::{HypedI2c, I2cError}; | ||
use hyped_i2c_derive::HypedI2c; | ||
|
||
#[derive(HypedAdc)] | ||
pub struct Stm32f767ziAdc<'d, T: Instance> { | ||
adc: Adc<'d, T>, | ||
channel: AnyAdcChannel<T>, | ||
} | ||
|
||
#[derive(HypedGpioInput)] | ||
pub struct Stm32f767ziGpioInput { | ||
pin: Input<'static>, | ||
} | ||
|
||
#[derive(HypedI2c)] | ||
pub struct Stm32f767ziI2c<'d> { | ||
i2c: I2c<'d, Blocking>, | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.