Hi, I started again to dig into embedded rust and continue with my lcd driver.
I think I misunderstood how I can use a pin as input and output.
 
I use the embassy_stm32::gpio and have a few pins defined as eg:
OutputOpenDrain::new(p.A6, Level::Low, Speed::VeryHigh, Pull::None)
 
In the driver I use a trait that requires the pins to implement ehal::digital::{InputPin, OutputPin}.
 
That works fine in a sense that cargo is not complaining and when I use them as outputs it seems to work. I change output with set_high etc.
 
But when I want to read them I think I miss something. I just use the method .is_high(). The results I get are strange though.
 
There is quite a chance that I have a bug elsewhere or misunderstood the specs of the lcd driver. But maybe I am just reading the values of the pins that I have set when used as output.
 
Can you tell me if I have to do something before using the pins as input?