Skip to content

Commit 1e7e1db

Browse files
wkhadgarcfriedt
authored andcommitted
drivers: gpio_gecko: update driver to use signal-only output.
Enable the pin configuration as single-ended pull-up output, allowing for a currentless, signal-only output. Signed-off-by: Paulo Santos <[email protected]>
1 parent f2dcb6c commit 1e7e1db

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

drivers/gpio/gpio_gecko.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,9 @@ static int gpio_gecko_configure(const struct device *dev,
107107
if (flags & GPIO_OUTPUT) {
108108
/* Following modes enable both output and input */
109109
if (flags & GPIO_SINGLE_ENDED) {
110-
if (flags & GPIO_LINE_OPEN_DRAIN) {
110+
if ((flags & GPIO_LINE_OPEN_DRAIN) && (flags & GPIO_PULL_UP)) {
111+
mode = gpioModeWiredAndPullUp;
112+
} else if (flags & GPIO_LINE_OPEN_DRAIN) {
111113
mode = gpioModeWiredAnd;
112114
} else {
113115
mode = gpioModeWiredOr;

0 commit comments

Comments
 (0)