From d3d9c0c553e96693c5a44aa9365a01adbe3d7e88 Mon Sep 17 00:00:00 2001 From: ayer1 Date: Tue, 16 Mar 2010 19:29:02 +0000 Subject: [PATCH] all misc. whitespace EXCEPT: shimmerAnalogSetupP was missing the appropriate pin setups for the msp430: set input and modfunc. should be fixed now. --- tos/platforms/shimmer/shimmerAnalogSetupC.nc | 1 - tos/platforms/shimmer/shimmerAnalogSetupP.nc | 42 ++++++++++++++++++++ 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a/tos/platforms/shimmer/shimmerAnalogSetupC.nc b/tos/platforms/shimmer/shimmerAnalogSetupC.nc index 05659639..d2194e14 100644 --- a/tos/platforms/shimmer/shimmerAnalogSetupC.nc +++ b/tos/platforms/shimmer/shimmerAnalogSetupC.nc @@ -53,7 +53,6 @@ implementation { components LedsC; shimmerAnalogSetupP.Leds -> LedsC; - } diff --git a/tos/platforms/shimmer/shimmerAnalogSetupP.nc b/tos/platforms/shimmer/shimmerAnalogSetupP.nc index a4d926b7..34cedf68 100644 --- a/tos/platforms/shimmer/shimmerAnalogSetupP.nc +++ b/tos/platforms/shimmer/shimmerAnalogSetupP.nc @@ -64,6 +64,15 @@ implementation { addNewChannels(new_chans, 3); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_5_INPUT(); + TOSH_SEL_ADC_5_MODFUNC(); + + TOSH_MAKE_ADC_4_INPUT(); + TOSH_SEL_ADC_4_MODFUNC(); + + TOSH_MAKE_ADC_3_INPUT(); + TOSH_SEL_ADC_3_MODFUNC(); } command void shimmerAnalogSetup.addGyroInputs() { @@ -71,6 +80,15 @@ implementation { addNewChannels(new_chans, 3); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_1_INPUT(); + TOSH_SEL_ADC_1_MODFUNC(); + + TOSH_MAKE_ADC_6_INPUT(); + TOSH_SEL_ADC_6_MODFUNC(); + + TOSH_MAKE_ADC_2_INPUT(); + TOSH_SEL_ADC_2_MODFUNC(); } command void shimmerAnalogSetup.addECGInputs() { @@ -78,6 +96,12 @@ implementation { addNewChannels(new_chans, 2); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_1_INPUT(); + TOSH_SEL_ADC_1_MODFUNC(); + + TOSH_MAKE_ADC_2_INPUT(); + TOSH_SEL_ADC_2_MODFUNC(); } command void shimmerAnalogSetup.addUVInputs() { @@ -85,6 +109,15 @@ implementation { addNewChannels(new_chans, 3); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_1_INPUT(); + TOSH_SEL_ADC_1_MODFUNC(); + + TOSH_MAKE_ADC_2_INPUT(); + TOSH_SEL_ADC_2_MODFUNC(); + + TOSH_MAKE_ADC_6_INPUT(); + TOSH_SEL_ADC_6_MODFUNC(); } command void shimmerAnalogSetup.addGSRInput() { @@ -92,6 +125,9 @@ implementation { addNewChannels(new_chans, 1); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_1_INPUT(); + TOSH_SEL_ADC_1_MODFUNC(); } command void shimmerAnalogSetup.addAnExInput() { @@ -99,6 +135,12 @@ implementation { addNewChannels(new_chans, 2); initADC12MEMCTLx(); + + TOSH_MAKE_ADC_0_INPUT(); + TOSH_SEL_ADC_0_MODFUNC(); + + TOSH_MAKE_ADC_7_INPUT(); + TOSH_SEL_ADC_7_MODFUNC(); } command void shimmerAnalogSetup.finishADCSetup(uint16_t * buffer){ -- 2.39.2