You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ma...@apache.org on 2016/10/18 20:16:19 UTC
[4/5] incubator-mynewt-core git commit: stm32f4 gpio;
when enabling GPIO output, start driving it with the desired initial
state.
stm32f4 gpio; when enabling GPIO output, start driving it with
the desired initial state.
Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/d3ed09cd
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/d3ed09cd
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/d3ed09cd
Branch: refs/heads/develop
Commit: d3ed09cd9b1836c67465a0ffa4e6bc63b7cc25ac
Parents: 8ef2522
Author: Marko Kiiskila <ma...@runtime.io>
Authored: Tue Oct 18 12:51:56 2016 -0700
Committer: Marko Kiiskila <ma...@runtime.io>
Committed: Tue Oct 18 13:15:41 2016 -0700
----------------------------------------------------------------------
hw/mcu/stm/stm32f4xx/src/hal_gpio.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/d3ed09cd/hw/mcu/stm/stm32f4xx/src/hal_gpio.c
----------------------------------------------------------------------
diff --git a/hw/mcu/stm/stm32f4xx/src/hal_gpio.c b/hw/mcu/stm/stm32f4xx/src/hal_gpio.c
index 9b19040..1db025e 100644
--- a/hw/mcu/stm/stm32f4xx/src/hal_gpio.c
+++ b/hw/mcu/stm/stm32f4xx/src/hal_gpio.c
@@ -469,11 +469,11 @@ int hal_gpio_init_out(int pin, int val)
init_cfg.Speed = GPIO_SPEED_HIGH;
init_cfg.Alternate = 0;
+ hal_gpio_write(pin, val);
rc = hal_gpio_init_stm(pin, &init_cfg);
if (rc) {
return rc;
}
- hal_gpio_write(pin, val);
return 0;
}