Added (untested) multithreaded telemetry data management 
Cleaned most existing code (removing magic numbers, etc.)