As the title says... Chat on...

User avatar
By TerryE
#43048 up and down are edge triggers -- that is a transition from low to high or v.v. high and low are level triggers.
User avatar
By goliatone
#43230 So, if we are using the gpio.trig which takes a callback function that takes one argument, level, then what should be the value of level based on the type? I'm guessing high would be 1 and low be 0. What about up/down? What would be the value of level?

Thank you TerryE for the reply.
User avatar
By TerryE
#44285 Up and down are edge triggers. So on up you have a low to high transition and if read as high by the interrupt routine.