Added conversion to/from binary and hex, with tests