diff options
author | inmarket <andrewh@inmarket.com.au> | 2014-03-24 10:08:15 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2014-03-24 10:08:15 +1000 |
commit | c354639f7b8ab1c33866b3d57a243de95a75decc (patch) | |
tree | 74db3a736e6839de1ef49b1df719c5d92e0189b7 /demos/modules | |
parent | c7566aa5531b35a84f06940966f31acadfc85ade (diff) | |
download | uGFX-c354639f7b8ab1c33866b3d57a243de95a75decc.tar.gz uGFX-c354639f7b8ab1c33866b3d57a243de95a75decc.tar.bz2 uGFX-c354639f7b8ab1c33866b3d57a243de95a75decc.zip |
Update GADC
Diffstat (limited to 'demos/modules')
-rw-r--r-- | demos/modules/gadc/main.c | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/demos/modules/gadc/main.c b/demos/modules/gadc/main.c index 8e5ecaa4..67eed456 100644 --- a/demos/modules/gadc/main.c +++ b/demos/modules/gadc/main.c @@ -167,10 +167,19 @@ int main(void) { gtimerStart(&lsTimer, LowSpeedTimer, ghText, TRUE, MY_LS_DELAY); #endif - // Allocate buffers for the high speed GADC device - 4 x 128 byte buffers. - // You may need to increase this for slower cpu's. - // You may be able to decrease this for low latency operating systems. - gfxBufferAlloc(4, 128); + /** + * Allocate buffers for the high speed GADC device - eg. 4 x 128 byte buffers. + * You may need to increase this for slower cpu's. + * You may be able to decrease this for low latency operating systems. + * 10 x 128 seems to work on the really slow Olimex SAM7EX256 board (display speed limitation) + * If your oscilloscope display stops but the low speed reading keep going then it is likely that + * your high speed timer has stalled due to running out of free buffers. Increase the number + * of buffers.. + * If you make the buffers too large with a slow sample rate you may not allow enough time for all + * the low speed items to occur in which case your memory will fill up with low speed requests until + * you run out of memory. + */ + gfxBufferAlloc(10, 128); /* Set up the scope window in the top right on the screen */ { |