Complete re-write -> now the code is manageable
Added HxCLAP