Hi , I'm running livekit agent on Ubuntu OS on Ras...
# sdk-web
b
Hi , I'm running livekit agent on Ubuntu OS on Rasberrypi5 , the problem is ECHO cancellation . I am using the respeaker lite usb microphone with the raspi . The TTS output is again falling back into STT node and causing an echo . I am not able to know how to use python sdk media devices with agent for echo cancellation and right now starting the agent in console mode .
p
This is happening because the TTS playback from the agent is being captured again by the ReSpeaker mic, so it loops back into the STT pipeline. On Raspberry Pi with LiveKit agents, echo cancellation is usually not handled directly inside the Python SDK media devices, so running in console mode makes it worse since there’s no control over the audio routing. The practical fix is to either enable OS-level AEC (PulseAudio/PipeWire with WebRTC echo cancellation) or implement a simple half-duplex flow in the agent where STT is paused or frames are ignored while TTS is speaking. I’ve solved this setup on Linux voice agents before and can help you wire proper device routing plus AEC or STT gating so the TTS audio no longer feeds back into the recognizer. @bored-dinner-9401
b
I definitely appreciate your help
p
So should we talk in the inbox @bored-dinner-9401
b
sure