First commit. Most is done, but needs rework and packing