api12参考如下方法:let data1 = new Int8Array([99, 1, 1, 1, 12, -52, -52, -52, -52, -52, -52, -32, 1, 0, 0, 0, 39, 123, 34, 117, 115, 101, 73, 100, 34, 58, 34, 57, 56, 55, 54, 53, 52, 51, 50, 49, 34, 44, 34, 118, 105, 110, 34, 58, 34, 49, 50, 51, 52, 53, 54, 55, 56, 57, 34, 125, 0, 0, 0, 0]) let checksum = zlib.createChecksumSync() checksum.crc32(0, data1.buffer).then((data) => { console.info('crc32 success', data); }).catch((errData: base.BusinessError) => { console.error(`errData is errCode:${errData.code} message:${errData.message}`); })参考文档:https://developer.huawei.com/consumer/cn/doc/harmonyos-references-V5/js-apis-zlib-V5\#crc3212
api12参考如下方法:
参考文档:https://developer.huawei.com/consumer/cn/doc/harmonyos-references-V5/js-apis-zlib-V5\#crc3212