useProtocolRun(props: Props, deps?: any)
Requires:
@ray-js/panel-sdk≥1.8.0
Description
Execute the corresponding callback based on the device communication protocol type
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| Yes | A configuration object containing devId and callbacks for each protocol type | ||
deps | any | No | Optional dependencies; changes will regenerate the executor function |
Return Value
Type: any
An executor function that triggers the corresponding callback based on the device's protocol type when called