mbed library sources. With a patch for the can_api

Fork of mbed-dev by mbed official

Files at this revision

API Documentation at this revision

Comitter:
mbed_official
Date:
Fri May 13 09:15:11 2016 +0100
Parent:
126:4d7eabe73831
Child:
128:c31e94a47539
Commit message:
Synchronized with git revision 6483faedd2d82f36a7b5e03540fc62721c1fef38

Full URL: https://github.com/mbedmicro/mbed/commit/6483faedd2d82f36a7b5e03540fc62721c1fef38/

[STM32F7] Fix end of conversion

Changed in this revision

targets/hal/TARGET_STM/TARGET_STM32F7/analogin_api.c Show annotated file Show diff for this revision Revisions of this file
--- a/targets/hal/TARGET_STM/TARGET_STM32F7/analogin_api.c	Wed May 11 17:15:11 2016 +0100
+++ b/targets/hal/TARGET_STM/TARGET_STM32F7/analogin_api.c	Fri May 13 09:15:11 2016 +0100
@@ -190,7 +190,7 @@
 
     // Wait end of conversion and get value
     HAL_ADC_PollForConversion(&AdcHandle, 10);
-    if (HAL_ADC_GetState(&AdcHandle) == HAL_ADC_STATE_EOC_REG) {
+    if (HAL_ADC_GetState(&AdcHandle) & HAL_ADC_STATE_EOC_REG) {
         return (HAL_ADC_GetValue(&AdcHandle));
     } else {
         return 0;