Fixed writing to memory, we were wrongly using Big Endian instead of Little Endian when writing values to memory.

Fixed a crash when closing the GUI, and make the instructions execute faster (50ms delay) when running the CPU from the GUI.