code: async def set_led_mode(self, led_id, mode, timeout=OTGW_DEFAULT_TIMEOUT):
          
          if led_id in "ABCDEF" and mode in "RXTBOFHWCEMP":
              cmd = globals().get("OTGW_CMD_LED_{}".format(led_id))
              status = {}
              ret = await self._wait_for_cmd(cmd, mode, timeout)
              if ret is None:
                  return
              var = globals().get("OTGW_LED_{}".format(led_id))
              status[var] = ret
              self._update_status(status)
              return ret
docs: Configure the functions of the six LEDs (A-F) that can
          optionally be connected to pins RB3/RB4/RB6/RB7 and the GPIO
          pins of the PIC. The following functions are currently
          available:
  
          R Receiving an Opentherm message from the thermostat or boiler
          X Transmitting an Opentherm message to the thermostat or boiler
          T Transmitting or receiving a message on the master interface
          B Transmitting or receiving a message on the slave interface
          O Remote setpoint override is active
          F Flame is on
          H Central heating is on
          W Hot water is on
          C Comfort mode (Domestic Hot Water Enable) is on
          E Transmission error has been detected
          M Boiler requires maintenance
          P Raised power mode active on thermostat interface.
  
          Return the new mode for the specified led, or None on failure.
  
          This method is a coroutine