Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: telemetry_demo_FRDM-TFC
Fork of FRDM-TFC by
Revision 11:787a9a24dbfb, committed 2016-02-22
- Comitter:
- Overdrivr
- Date:
- Mon Feb 22 13:40:03 2016 +0000
- Parent:
- 10:86c5fc9a53d9
- Commit message:
- Bugfix - library fully functionnal, Hbridges current sense can be read correctly
Changed in this revision
| TFC.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/TFC.cpp Wed Feb 17 20:42:32 2016 +0000
+++ b/TFC.cpp Mon Feb 22 13:40:03 2016 +0000
@@ -218,14 +218,6 @@
#define PGAG_32 0x05
#define PGAG_64 0x06
-
-#define ADC_STATE_INIT 0
-#define ADC_STATE_CAPTURE_POT_0 1
-#define ADC_STATE_CAPTURE_POT_1 2
-#define ADC_STATE_CAPTURE_BATTERY_LEVEL 3
-#define ADC_STATE_CAPTURE_LINE_SCAN 4
-
-
/////////// The above values fit into the structure below to select ADC/PGA
/////////// configuration desired:
@@ -796,8 +788,8 @@
PotADC_Value[1] = ADC0->R[0];
CurrentADC_State = ADC_STATE_CAPTURE_I_HBRIDGE_A;
+ ADC0->CFG2 &= ~ADC_CFG2_MUXSEL_MASK; //Select the A side of the mux
ADC0->SC1[0] = TFC_I_HBRIDGE_0_SENSE_ADC_CHANNEL | ADC_SC1_AIEN_MASK; // HBRIDGE channel
- ADC0->CFG2 &= ~ADC_CFG2_MUXSEL_MASK; //Select the A side of the mux
break;
