Dear TI,
We would like to go configure a GPIO pin from its initial input state to an output driving high, unfortunately, it always seems to initially drive low.
We are using a TM4C1290N. A snipped of our code is below with our instrumentation (debug pin toggles for the oscilloscope) removed for clarity:
// the initial write to the data register seems to have no effect. We are trying to set it high so when we make it an output it won't glitch low
GPIOPinWrite(GPIO_PORTM_BASE, GPIO_PIN_3, GPIO_PIN_3) ;
// We program the pin to be an output, but it will initially drive the pin low not high like we want
GPIOPinTypeGPIOOutput(GPIO_PORTM_BASE, GPIO_PIN_3);
// The next line will bring the pin high, but the glitch is not good for our application
GPIOPinWrite(GPIO_PORTM_BASE, GPIO_PIN_3, GPIO_PIN_3) ;
What is the proper way to change an input to an output driving high without a low glitch? I noticed one other similar post 6 years ago on an older part where the order of the PadSelect and the DirModeSelect were reversed and that fixed the problem. For us, it seemed that those calls were already done in the correct order. We tried changing the order and it made no difference. It looks like our library source file was created in 2014.
Thank you for your help.
Brett