---
title: "setClock(_:)"
framework: Core Audio
role: symbol
role_heading: Instance Method
platforms: [macOS 15.0+]
path: "coreaudio/audiohardwaredevice/setclock(_:)"
---

# setClock(_:)

Set the clock property.

## Declaration

```swift
func setClock(_ clock: AudioHardwareClock) throws
```

## Parameters

- `clock`: The AudioHardwareClock to use as the main time base of the device.
