Post

Replies

Boosts

Views

Activity

Reply to How to Take Screenshot by devicectl
It seems devicectl doesn't support taking screenshots at this moment, unless it's a hidden command. Closest you can get: xcrun devicectl device info details --device XXX -j ~/Downloads/details.json Contains: "screenViewingURL" : "devices://device/open?id=XXX" and { "featureIdentifier" : "com.apple.coredevice.feature.viewdevicescreen", "name" : "View Device Screen" }, is granted. Not sure how to use that URL though... And xcrun devicectl device info displays --device XXX -j ~/Downloads/displays.json Contains: "result" : { "backlightState" : "off", "current" : true, "displays" : [ { "bounds" : [ [ 0, 0 ], [ 1179, 2556 ] ], "currentOrientation" : "rot0", "displayId" : 1, "name" : "LCD", "nativeOrientation" : "rot0", "nativeSize" : [ 1179, 2556 ], "pointScale" : 3, "primary" : true } ] But not a way to grab a screenshot from that display. simctl on the other hand has simctl io booted screenshot Maybe the copy command in combination with process launch can be used to launch a process that takes a screenshot and writes it to a path, then copy that file from the device. But would be very helpful if Apple would add a screenshot argument to devicectl.
Dec ’24
Reply to devicectl appIcon command not working
Unfortunately, it seems that the appIcon command has broken again. macOS Sequoia 15.0 Xcode 16.0 (16A242d) iOS 17.6.1 Any kind of combination of arguments results in: "ERROR: CGImage was nil when attempting to write to a destination. (com.apple.dt.CoreDeviceError error 6007 (0x1777))" This is the same error code and description as my original post. Edit: I've filed bug report FB15372764 for both issues. Edit II: Just updated to iOS 18.0 and the appIcon works again. It still has the pixel offset :-( except for 1024x1024 size.
Oct ’24
Reply to Using devicectl to observe Darwin Notifications
Hi Quinn, I see that I never replied to your message. The goal of listening to Darwin notifications is to communicate between an iOS test suite and macOS host. The macOS host controls the test suite, e.g. when a button is pressed the test suite performs a certain test. I wanted to use notifications to indicate that a test has been completed. By now, I have found some workarounds, but I can still see the value in being able to successfully observe iOS notifications from macOS.
Oct ’24