0

I'm a new android and i'm working on my project. My project, calculate heart rate from camera phone, it gets frame from camera phone, and analyze data of frames into Red, Green, and Blue plane.Then, i perform these plane and get results, then i use these results to draw real time graph on my layout. You know, frames are always arrive continuously, it means that i should have 3 threads, thread 1 is used to get frames and analyze data, thread 2 gets input from ouput of thread 1 and performs its function, thread 3 gets input from thread 2 and draws a real time graph. I really am a new android and i tried to find out about "thread android" keyword but i still don't know how to apply my knowledge i got, how can threads communicate with each other, so i still deadlock.

Please give me advices, and if have example code is great. Thanks,

user3422305
  • 43
  • 1
  • 6
  • you can use a Handler. You can use a `EventBus` which is a thread party libray – Raghunandan May 03 '14 at 04:50
  • Hi Raghunandan, thank you very much for the answer. But, in my project, i used aChartengine lib, so, i don't want to use more library, i apprehend that it'll affect to my size app. Thanks again. – user3422305 May 03 '14 at 06:09
  • Yes, i have heard about Handler, but i think it likes as a Main Thread, a server,... so, it can receive message returned from WorkerThread. I just think that, maybe i'm wrong. Like i described above, can you tell me more about Handler? And How do i apply it to my project? I really appreciate that. – user3422305 May 03 '14 at 06:28
  • google search to know more – Raghunandan May 03 '14 at 06:30

0 Answers0