The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.
Dependents: hello SerialTestv11 SerialTestv12 Sierpinski ... more
mbed 2
This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.
TARGET_WIZwiki_W7500/TARGET_WIZNET/TARGET_W7500x/W7500x_Peripheral_Library/W7500x_adc.h@107:4f6c30876dfa, 2015-09-16 (annotated)
- Committer:
- Kojto
- Date:
- Wed Sep 16 15:32:31 2015 +0100
- Revision:
- 107:4f6c30876dfa
- Parent:
- TARGET_WIZwiki_W7500/W7500x_adc.h@101:7cff1c4259d7
Release 107 of the mbed library
Changes:
- new platforms - DISCO_F746NG, DISCO_L476VG, NUCLEO_L476RG
- KL43Z - bugfix RTC init function
- K20 - SPI mode fix
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Kojto | 101:7cff1c4259d7 | 1 | /** |
Kojto | 101:7cff1c4259d7 | 2 | ****************************************************************************** |
Kojto | 101:7cff1c4259d7 | 3 | * @file |
Kojto | 101:7cff1c4259d7 | 4 | * @author |
Kojto | 101:7cff1c4259d7 | 5 | * @version |
Kojto | 101:7cff1c4259d7 | 6 | * @date |
Kojto | 101:7cff1c4259d7 | 7 | * @brief This file contains all the functions prototypes for the ADC |
Kojto | 101:7cff1c4259d7 | 8 | * firmware library. |
Kojto | 101:7cff1c4259d7 | 9 | ****************************************************************************** |
Kojto | 101:7cff1c4259d7 | 10 | * |
Kojto | 101:7cff1c4259d7 | 11 | ****************************************************************************** |
Kojto | 101:7cff1c4259d7 | 12 | */ |
Kojto | 101:7cff1c4259d7 | 13 | |
Kojto | 101:7cff1c4259d7 | 14 | /* Define to prevent recursive inclusion -------------------------------------*/ |
Kojto | 101:7cff1c4259d7 | 15 | #ifndef __W7500X_ADC_H |
Kojto | 101:7cff1c4259d7 | 16 | #define __W7500X_ADC_H |
Kojto | 101:7cff1c4259d7 | 17 | |
Kojto | 101:7cff1c4259d7 | 18 | #ifdef __cplusplus |
Kojto | 101:7cff1c4259d7 | 19 | extern "C" { |
Kojto | 101:7cff1c4259d7 | 20 | #endif |
Kojto | 101:7cff1c4259d7 | 21 | |
Kojto | 101:7cff1c4259d7 | 22 | /* Includes ------------------------------------------------------------------*/ |
Kojto | 101:7cff1c4259d7 | 23 | #include "W7500x.h" |
Kojto | 101:7cff1c4259d7 | 24 | |
Kojto | 101:7cff1c4259d7 | 25 | typedef enum { ADC_CH0 = 0, |
Kojto | 101:7cff1c4259d7 | 26 | ADC_CH1 = 1, |
Kojto | 101:7cff1c4259d7 | 27 | ADC_CH2 = 2, |
Kojto | 101:7cff1c4259d7 | 28 | ADC_CH3 = 3, |
Kojto | 101:7cff1c4259d7 | 29 | ADC_CH4 = 4, |
Kojto | 101:7cff1c4259d7 | 30 | ADC_CH5 = 5, |
Kojto | 101:7cff1c4259d7 | 31 | ADC_CH6 = 6, |
Kojto | 101:7cff1c4259d7 | 32 | ADC_CH7 = 7, |
Kojto | 101:7cff1c4259d7 | 33 | ADC_CH15 = 15} ADC_CH; |
Kojto | 101:7cff1c4259d7 | 34 | |
Kojto | 101:7cff1c4259d7 | 35 | #define IS_ADC_CH_NUM(NUM) (((NUM) == ADC_CH0) || \ |
Kojto | 101:7cff1c4259d7 | 36 | ((NUM) == ADC_CH1) || \ |
Kojto | 101:7cff1c4259d7 | 37 | ((NUM) == ADC_CH2) || \ |
Kojto | 101:7cff1c4259d7 | 38 | ((NUM) == ADC_CH3) || \ |
Kojto | 101:7cff1c4259d7 | 39 | ((NUM) == ADC_CH4) || \ |
Kojto | 101:7cff1c4259d7 | 40 | ((NUM) == ADC_CH5) || \ |
Kojto | 101:7cff1c4259d7 | 41 | ((NUM) == ADC_CH6) || \ |
Kojto | 101:7cff1c4259d7 | 42 | ((NUM) == ADC_CH7) || \ |
Kojto | 101:7cff1c4259d7 | 43 | ((NUM) == ADC_CH15)) |
Kojto | 101:7cff1c4259d7 | 44 | |
Kojto | 101:7cff1c4259d7 | 45 | void ADC_Init(void); |
Kojto | 101:7cff1c4259d7 | 46 | void ADC_DeInit(void); |
Kojto | 101:7cff1c4259d7 | 47 | void ADC_PowerDownEnable (FunctionalState NewState); |
Kojto | 101:7cff1c4259d7 | 48 | void ADC_ChannelSelect (ADC_CH num); |
Kojto | 101:7cff1c4259d7 | 49 | void ADC_Start (void); |
Kojto | 101:7cff1c4259d7 | 50 | uint16_t ADC_ReadData (void); |
Kojto | 101:7cff1c4259d7 | 51 | void ADC_InterruptMask (FunctionalState NewState); |
Kojto | 101:7cff1c4259d7 | 52 | uint8_t ADC_IsInterrupt (void); |
Kojto | 101:7cff1c4259d7 | 53 | void ADC_InterruptClear (void); |
Kojto | 101:7cff1c4259d7 | 54 | |
Kojto | 101:7cff1c4259d7 | 55 | #ifdef __cplusplus |
Kojto | 101:7cff1c4259d7 | 56 | } |
Kojto | 101:7cff1c4259d7 | 57 | #endif |
Kojto | 101:7cff1c4259d7 | 58 | |
Kojto | 101:7cff1c4259d7 | 59 | #endif //__W7500X_ADC_H |