0

I have custom hardware, with a custom Android Launcher app running. I need to read an ADC chip (ADS7871) at a set interval. Currently this is being done using a handler, but it seems the postdelayed value is not maintained if other tasks are operating in the background.

Is there a better method for performing a task at set intervals, which will take priority?

Many Thanks, Nigel

  • What sort of interval? Seconds... or milliseconds? Keep in mind that Android is not a realtime OS. – 323go Jan 21 '16 at 13:33
  • I'm looking for milliseconds, any ideas? – Nigel Evans Jan 22 '16 at 15:04
  • You'd either need to go to kernel level if you want to do it in software. I haven't quite dug that deep, so many I'm missing something. I had one time-critical data acquisition project where I simply added a micro to handle the synchronous input and then allowed android to read the buffer every second or so. – 323go Jan 22 '16 at 20:50
  • Makes sense, maybe I'll add something to the adc driver to buffer values at a timed interval and return the result. Thanks! – Nigel Evans Jan 22 '16 at 20:52

0 Answers0