1. Change thread principle from Thread::wait() to FSM and its evaluation in given times and signals to particular threads.
2. Distance measurement: signal + mail, add timeout
