Skip to main content

Cyberwave is in Private Beta.

Request early access to get access to the Cyberwave dashboard.

Stream live media to and from digital twins over WebRTC. Standard USB/webcams (via OpenCV), RealSense depth cameras, host microphones, and host speakers are all supported.
Install the matching extras: pip install cyberwave[camera], pip install cyberwave[microphone], or pip install cyberwave[speaker]. Video also requires FFMPEG — see Overview & Installation. For one-off still images instead of a stream, use Frames & Cameras.

Video streaming (WebRTC)

Streaming is initiated directly from the twin object. Switching from a standard camera to a depth camera that also streams a point cloud is just a different twin name — the SDK handles the rest.
import asyncio
from cyberwave import Cyberwave

cw = Cyberwave()
camera = cw.twin("cyberwave/standard-cam")

async def main():
    try:
        print(f"Streaming to twin {camera.uuid}... (Ctrl+C to stop)")
        await camera.stream_video_background()
        while True:
            await asyncio.sleep(1)
    except (KeyboardInterrupt, asyncio.CancelledError):
        pass
    finally:
        await camera.stop_streaming()
        cw.disconnect()

asyncio.run(main())

Audio streaming (microphone)

Stream microphone audio to a digital twin over WebRTC (Opus, 48 kHz mono). Use a get_audio() callback that returns 20 ms of s16 mono audio (1920 bytes) or None for silence.
pip install cyberwave[microphone]
import asyncio
from cyberwave import Cyberwave
from cyberwave.sensor.microphone import HostMicrophoneCapture, MicrophoneAudioStreamer

capture = HostMicrophoneCapture()
capture.start()

cw = Cyberwave()
streamer = MicrophoneAudioStreamer(
    cw.mqtt,
    capture.get_audio,
    twin_uuid="your-twin-uuid",
    mic_name="mic",
)
await streamer.start()
# ... run until done ...
await streamer.stop()
capture.stop()
cw.disconnect()
For custom or robot-provided sources, pass your own get_audio() callback.

Audio playback (speaker)

The speaker counterpart consumes a WebRTC downstream leg from the media-service (or any user-supplied source) and plays it through a host sounddevice.OutputStream. SpeakerAudioStreamer subclasses the shared BaseAudioStreamer, and HostSpeakerCapture wraps the device with idempotent start() / stop().
pip install cyberwave[speaker]
Play a local file through the default output device:
from cyberwave.sensor.speaker import play_file

play_file("hello.mp3")  # supports mp3, wav, flac, ogg, ...
Subscribe a speaker twin to a peer microphone twin (Zenoh or WebRTC):
import asyncio
from cyberwave import Cyberwave
from cyberwave.sensor.speaker import associate_speaker_to_microphone

cw = Cyberwave()
session = await associate_speaker_to_microphone(
    cw,
    speaker_twin_uuid="speaker-twin-uuid",
    microphone_twin_uuid="mic-twin-uuid",
    transport="webrtc",  # or "zenoh"
)
# ... run until done ...
await session.stop()
The lower-level building blocks (SpeakerAudioStreamer, SpeakerAudioTrack, HostSpeakerCapture, list_host_sound_devices, plus volume/gain/routing helpers) are available directly from cyberwave.sensor.speaker for custom integrations.

Native Speaker / Microphone Driver

Containerised edge build for native audio drivers.