added set_registers to methods