code: async def disconnect(self, conn_id):
          
  
          self._ensure_connection(conn_id, True)
  
          msg = dict(connection_string=self._get_property(conn_id, "connection_string"))
  
          try:
              await self._send_command(OPERATIONS.DISCONNECT, msg, COMMANDS.DisconnectResponse)
          finally:
              self._teardown_connection(conn_id)
docs: Disconnect from a connected device.
  
          See :meth:`AbstractDeviceAdapter.disconnect`.