<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 async def send_command(self, command, args, validator, timeout=10.0):
 """Send a command and synchronously wait for a single response. Args: command (string):
 The command name args (dict):
 Optional arguments. validator (Verifier):
 A SchemaVerifier to verify the response payload. timeout (float):
 The maximum time to wait for a response. Defaults to 10 seconds. Returns: dict: The response payload Raises: ExternalError: If the server is not connected or the command fails. asyncio.TimeoutError: If the command times out. ValidationError: If the response payload does not match the given validator. """


        if self._con is None:
            raise ExternalError("No websock connection established")

        cmd_uuid = str(uuid.uuid4())
        msg = dict(type='command', operation=command, uuid=cmd_uuid,
                   payload=args)

        packed = pack(msg)

        # Note: register future before sending to avoid race conditions
        response_future = self._manager.wait_for(type="response", uuid=cmd_uuid,
                                                 timeout=timeout)

        await self._con.send(packed)

        response = await response_future

        if response.get('success') is False:
            self._raise_error(command, response)

        if validator is None:
            return response.get('payload')

        return validator.verify(response.get('payload'))