Machine State and rework

Isolated machine data into Separate Class, other improvements related to
timer handling and commented most of the code (intensive use of StyleCop
will be performed soon)