How can GPIO be set to output

I would like to use a couple of GPIO pins as output instead of inputs. These would be digital signals.

I see references to setting GPIO_MODE_INPUT and GPIO_ReadPin, but no similar instances for writing or output setting.

Is this feature not available? If so, are there any workarounds?

Anil Sawe

I am wondering that myself currently. I wanna use two GPIOs as digital outputs. Have you figured it out?

Likewise, same question here. Any luck?

OK did it. Just fired up ST32CubeMX, changed GPIO_6 to Output, generated the code, diffed against master and applied resulting patch, then added a few functions to expose to odrivetool. The whole experience to quickly expose functionality to the host was pretty slick.