<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def do_setmode(self, arg):
        ''' shift from ASM to DISASM '''
        op_modes = config.get_op_modes()
        if arg in op_modes:
            op_mode = op_modes[arg]
            op_mode.cmdloop()
        else:
            print("Error: unknown operational mode, please use 'help setmode'.")