This topic describes only module-specific error codes. For details about universal error codes, see Universal Error Codes.
Error Message
BR is disabled.
Description
This error code is reported if Bluetooth is disabled on the local device.
Possible Causes
Bluetooth is disabled on the local device.
Solution
Enable Bluetooth on the local device and try again.
Error Message
Device not paired.
Description
This error code is reported if the local device has not established a Bluetooth pairing.
Possible Causes
The local device has not established a Bluetooth pairing with the target device.
The target device has not started service listening.
An invalid MAC or UUID is used.
Solution
Use the Sports Health app to add and pair the device.
Check whether the Bluetooth service on the peer device has enabled listening for pairing requests.
Check the validity of the entered MAC and UUID. The MAC should be a Bluetooth MAC address string in the XX:XX:XX:XX:XX:XX format, and the UUID should be a standard UUID format string, such as xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
Error Message
Parameter error.
Description
The parameters passed when calling the proxy channel API do not meet the requirements, such as an abnormal MAC or UUID format or an incorrect input parameter type, causing the API call to fail.
Possible Causes
The input MAC or UUID is in an invalid format. The MAC should be a Bluetooth MAC address string in the XX:XX:XX:XX:XX:XX format, and the UUID should be a standard UUID string, for example, xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
The type of the input parameters is incorrect.
Solution
Check the code logic to ensure that the MAC is a Bluetooth MAC address string in the XX:XX:XX:XX:XX:XX format and the UUID is a standard UUID string, for example, xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
Check the code logic to ensure that the input parameter types are consistent with the API definition.
Error Message
Internal error.
Description
An internal system exception occurs, which may cause the current operation to fail or the service to become unavailable.
Possible Causes
System errors, such as null pointer, insufficient memory, unexpected distributed service restart, IPC exception, and JS engine exception.
Solution
Retry the operation.
If the problem persists, restart the application.
If restarting does not work, upgrade the application or the device version.
Error Message
Call is restricted.
Description
The call is unauthorized and restricted.
Possible Causes
The caller is not authorized to perform the operation.
Solution
Apply for the permission required for proxy channel management (confirm the specific permission name from the proxy channel management API reference), declare the corresponding permission in the application configuration, and try again.
Error Message
Operation failed or Connection timed out.
Description
A Bluetooth underlying fault causes the proxy channel operation to fail, or the connection times out because it is not established within the specified time.
Possible Causes
The underlying Bluetooth is faulty, leading to a connection failure or timeout.
Solution
Turn off and then turn on Bluetooth on the local device and the target device.
Restart the local device and the target device, and then enable Bluetooth on the devices.
Error Message
Data too long.
Description
The length of the data sent through the proxy channel exceeds the maximum limit (4096 bytes), causing the sending to fail.
Possible Causes
The length of the data to be sent exceeds 4096 bytes.
Solution
Ensure that the length of the data to be sent does not exceed 4096 bytes. If the data is too long, send it in segments.
Error Message
Send failed.
Description
When data is sent through the proxy channel, a Bluetooth fault prevents the data from being successfully delivered to the target device.
Possible Causes
The underlying Bluetooth connection is faulty or the protocol is abnormal.
Solution
Restart Bluetooth on the local device and the target device.
Restart the local device and the target device.