Page 1 of 1

Accessing gpio 25-39 (as input) from wake stub

Posted: Mon Mar 12, 2018 2:11 pm
by loboris
In one of my projects I'm using wake stub to check the state of some pins and take some action.

Everythig works fine (as expected) for all the gpios up to 25.
Checking the gpios 25-39 with GPIO_INPUT_GET(gpio) always returns 0.
This is acctualy expected, as those gpios have input disabled after reset.

My question is: how I can enable the input on gpio 25-39 from wake stub ? There is no function in rom for that (or I can't find one).
Setting the gpio direction and enabling as input only from the main application does not help.

Re: Accessing gpio 25-39 (as input) from wake stub

Posted: Mon Mar 12, 2018 7:51 pm
by WiFive
PIN_INPUT_ENABLE?

Re: Accessing gpio 25-39 (as input) from wake stub

Posted: Tue Mar 13, 2018 10:33 am
by loboris
WiFive wrote:PIN_INPUT_ENABLE?
Thank you, I've somehow overlooked it.
It works.