l***@126.com
l***@126.com
  • 发布:2024-07-01 08:09
  • 更新:2024-07-01 08:47
  • 阅读:398

蓝牙写入数值 value 传递ArrayBuffer 提示参数 是any[]不匹配

分类:uni-app

08:05:26.028 TS2769:No overload matches this call.
08:05:26.035 Overload 1 of 2, '(options: WriteBLECharacteristicValueOptions): Promise<StopBluetoothDevicesDiscoverySuccess>', gave the following error.
08:05:26.042 Type 'ArrayBuffer' is missing the following properties from type 'any[]': length, pop, push, concat, and 30 more.
08:05:26.045 Overload 2 of 2, '(options: WriteBLECharacteristicValueOptions): void', gave the following error.
08:05:26.051 Type 'ArrayBuffer' is not assignable to type 'any[]'.
08:05:26.074 ERROR Build failed with errors.

2024-07-01 08:09 负责人:无 分享
已邀请:
l***@126.com

l***@126.com (作者)

如果将ArrayBuffer转为any[] 数组微信小程序报错 writeBLECharacteristicValue error: {"errno":1001,"errMsg":"writeBLECharacteristicValue:fail parameter error: parameter.value should be ArrayBuffer instead of Array;"}

要回复问题请先登录注册