adds the ability to write registers