GUI final version, the code is a mess but I plan to use Qt for the final
GUI, this is only a prototype.