CoreDevice
Screen Capture
Capture screenshots through CoreDevice Screen Capture Service.
Screen Capture is a CoreDevice service reached through RSD and RemoteXPC. The client connects to com.apple.coredevice.screencaptureservice.
Use It For
- Connect through the iOS 17+ CoreDevice tunnel.
- Call the typed CoreDevice client methods.
- Use the matching tool command when one is registered.
Feature Flag
[dependencies]
idevice = { version = "0.1.64", features = ["usbmuxd", "rsd", "core_device"] }Service Names
| Path | Value |
|---|---|
| RSD | com.apple.coredevice.screencaptureservice |
Rust Example
use idevice::{
RsdService,
core_device::{ImageFormat, ScreenCaptureServiceClient},
};
let mut client: ScreenCaptureServiceClient<_> = rsd_handshake
.connect(&mut rsd_provider)
.await?;
let image = client.take_screenshot(None, ImageFormat::Png).await?;
tokio::fs::write("screenshot.png", image).await?;CLI Equivalent
idevice-tools screencaptureservice screenshot.pngCommon Errors
| Error | What to check |
|---|---|
| RSD service not found | The connected device did not advertise the CoreDevice service name. |
| RemoteXPC error | Check the CoreDevice action and payload shape used by the client. |
| Tunnel unavailable | Create the iOS 17+ tunnel before connecting to CoreDevice services over USB. |