mbed-os github

Dependencies:   ADS1015 Faulhaber HTU21D_mod MS5837_potless Sensor_Head_RevB_3 USBDevice_dfu Utilsdfu beep

Fork of ARNSRS_testDFU by POTLESS

Revision:
75:eec3e587c8b8
Parent:
74:f4704f312116
Child:
76:9dc83d5cf075
--- a/main.cpp	Thu Jul 19 08:13:34 2018 +0000
+++ b/main.cpp	Thu Jul 19 12:10:08 2018 +0000
@@ -8,7 +8,6 @@
 #include "beep.h"
 #include "USBSerial.h"
 
-
 //Commandes  des servos
 #define PWM_SERVO_POUMON PB_15
 #define nSleep_SERVO_POUMON PC_6
@@ -275,7 +274,10 @@
     
     wait(0.5);
     
+    HAL_GPIO_DeInit(GPIOC, GPIO_PIN_4|GPIO_PIN_5);
+    
     // mise à zero UART IHM pour éviter son redémarrage intempestif (le tx suffirait)
+    HAL_PWREx_EnablePullUpPullDownConfig();
     HAL_PWREx_EnableGPIOPullDown(PWR_GPIO_C, PWR_GPIO_BIT_4);
     HAL_PWREx_EnableGPIOPullDown(PWR_GPIO_C, PWR_GPIO_BIT_5);
     
@@ -322,7 +324,7 @@
     UTILS::Write(FLAG_ADDR, 0xBABEFACE);
 
     //Mise en veille
-    HAL_PWREx_EnablePullUpPullDownConfig() ;
+    HAL_PWREx_EnablePullUpPullDownConfig();
     HAL_PWREx_EnableGPIOPullDown(PWR_GPIO_A, PWR_GPIO_BIT_0);
     HAL_PWR_DisableWakeUpPin(PWR_WAKEUP_PIN1_LOW); // pour PA_0
     // Clear wake up Flag