code: def get_control_mode(self):
          
          mode_value = self.read_register(4101)
          
          try:
              return CONTROL_MODES[mode_value]
          except KeyError:
              raise ValueError( 'Could not parse the control mode value: {0}. Allowed values are: {1}'.format(
                  repr(mode_value), repr(list(CONTROL_MODES.keys()) ) ))
docs: Get the name of the current operation mode.
          
          Returns:
              A string decribing the controlmode.
              
          The returned string is one of the items in :data:`CONTROL_MODES`.