Hi there!
I was trying to make a widget that shows a variety of device statuses when I noticed something strange: Using SF Symbols I want to display if the volume is up or muted. Therefore I made a basic if statement
if ( Device.volume() > 0 ) {
let volumeIcon = volumeStack.addImage(SFSymbol.named("speaker.wave.2").image)
volumeIcon.imageSize = new Size(30,30)
volumeIcon.tintColor = Color.white()
}
Strangely, when I preview the widget in the Scriptable app it works fine, but the actual widget on my home screen throws an “OSStatus error 561015905”. Unfortunately, I have no idea what could cause this. Does anyone have a clue?
Also, speaking of volume, is there any way to read the mute switch status?