<!--
{
  "availability" : [
    "DriverKit: 19.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SerialDriverKit",
  "identifier" : "/documentation/SerialDriverKit/IOUserSerial/HwProgramBaudRate",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "SerialDriverKit"
    ],
    "preciseIdentifier" : "c:@S@IOUserSerial@F@HwProgramBaudRate#i#"
  },
  "title" : "HwProgramBaudRate"
}
-->

# HwProgramBaudRate

Sets the communication baud rate to the specified value.

```
virtual kern_return_t HwProgramBaudRate(uint32_t baudRate);
```

## Parameters

`baudRate`

The baud rate, in bits per second, to use when communicating with the system.

## Return Value

<doc://com.apple.documentation/documentation/DriverKit/kIOReturnSuccess> on success, or another value if an error occurs. See <doc://com.apple.documentation/documentation/DriverKit/error-codes>.

## Discussion

Override this method and use it to configure the baud rate for your device.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)