   } else {
                        const audioData = event.data; // ArrayBuffer
                        player.playAudio(audioData);
                    }
                };

                websocket.onerror = (error) => {
                    addLog(`WebSocket错误: ${error}`);
                    updateStatus("连接错误", "disconnected");
                };

                websocket.onclose = () => {
                    addLog("连接已关闭");
                    updateStatus("连接已关闭", "