From 95b9bd97c26278ac3c941a1b685e84f1571c19e4 Mon Sep 17 00:00:00 2001 From: James Snyder Date: Mon, 16 Feb 2009 23:06:07 +0000 Subject: [PATCH] Minor consistency change for ADC on LM3S. --- src/platform/lm3s/platform.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/platform/lm3s/platform.c b/src/platform/lm3s/platform.c index f6e1ead6..bdb4b2da 100644 --- a/src/platform/lm3s/platform.c +++ b/src/platform/lm3s/platform.c @@ -606,10 +606,11 @@ int platform_adc_sample( unsigned id ) // If switching from burst, resize & flush buffer if ( s->burst == 1 ) { - buf_flush( BUF_ID_ADC, id ); res = buf_set( BUF_ID_ADC, id, ADC_BUF_SIZE , BUF_DSIZE_U16 ); if ( res != PLATFORM_OK ) return res; + // Need more general buf resizing... for now flush each time + buf_flush( BUF_ID_ADC, id ); s->burst = 0; s->reqsamples = 0; }