altos/lpc: Stop using burst mode for LPC ADC
authorKeith Packard <keithp@keithp.com>
Fri, 23 Aug 2013 18:22:10 +0000 (11:22 -0700)
committerKeith Packard <keithp@keithp.com>
Sun, 25 Aug 2013 23:20:06 +0000 (16:20 -0700)
commit1aed2eb5c7d477a2f3d4fada22980041aba97cb8
tree11f40bede11ff372022ce427a6eadb722531128a
parent4fe47adc7aca54951a50b1c1ae95cb02e46f8d3d
altos/lpc: Stop using burst mode for LPC ADC

Burst mode doesn't stop after one round of conversions, so we end up
getting incorrect values in whatever the last conversion register is.

Just use single conversions and take an interrupt per channel.

Also, slow down the ADC so that our values are more stable -- just
need to make sure we get the whole conversion sequence done 100 times
a second.

Signed-off-by: Keith Packard <keithp@keithp.com>
src/lpc/ao_adc_lpc.c