Fixed a bug with the D command. Now 0Da sends the last a measurments. Improved the structure of memory for cleaner code.