Demo to control 4 LEDs
Dependencies: BSP_DISCO_F469NI mbed
Diff: ADC_F469/ADC.cpp
- Revision:
- 1:a6d179a9ffbb
diff -r e06404fdff2f -r a6d179a9ffbb ADC_F469/ADC.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/ADC_F469/ADC.cpp Tue Oct 31 14:39:54 2017 +0000 @@ -0,0 +1,36 @@ +/* + * ADC.cpp + * + * Copyright 2017 Faberge@TsarTeam + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + */ + +#include "ADC.h" + +uint16_t analogRead(const uint16_t channel) +{ + /* If function is called for the first time, + * configure ADC and low level pin settings + */ + + uint16_t result; + + switch(channel) + { + case(A0): break; + case(A1): break; + case(A2): break; + } + + return result; +} \ No newline at end of file