Skip to content

For ESP32  #13

Open
Open
@DavidCarl

Description

Hello

I am looking to implement this library for a project I am doing with a ESP32.

The issue is the following when I try to instantiate this library in the SPI pin from the ESP32.

    let spi = peripherals.spi2;

    let mut lora = sx127x_lora::LoRa::new(spi, sc, rst, FREQUENCY, delay);

It simply gives me this error:

let spi: SPI2
Go to SPI2

the trait bound `esp_idf_hal::gpio::Gpio14<esp_idf_hal::gpio::Unknown>: embedded_hal::digital::v1::OutputPin` is not satisfied
required because of the requirements on the impl of `embedded_hal::digital::v2::OutputPin` for `esp_idf_hal::gpio::Gpio14<esp_idf_hal::gpio::Unknown>`rustcE0277
the trait bound `esp_idf_hal::spi::SPI2: embedded_hal::blocking::spi::transfer::Default<u8>` is not satisfied
required because of the requirements on the impl of `embedded_hal::blocking::spi::Transfer<u8>` for `esp_idf_hal::spi::SPI2`rustcE0277
main.rs(43, 20): required by a bound introduced by this call
lib.rs(190, 29): required by a bound in `sx127x_lora::LoRa::<SPI, CS, RESET, DELAY>::new`
the trait bound `esp_idf_hal::spi::SPI2: embedded_hal::blocking::spi::write::Default<u8>` is not satisfied
required because of the requirements on the impl of `embedded_hal::blocking::spi::Write<u8>` for `esp_idf_hal::spi::SPI2`rustcE0277
main.rs(43, 20): required by a bound introduced by this call
lib.rs(190, 52): required by a bound in `sx127x_lora::LoRa::<SPI, CS, RESET, DELAY>::new`

Is this anything you have experience with by any chance?

Sincerely

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions