react-native-gizwits-sdk-v5 1.5.5-thirdbluetooth → 1.5.6-thirdbluetooth

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (129) hide show
  1. package/android/libs/sdk-bluetooth-release.aar +0 -0
  2. package/ios/GizwitsiOSSDK.framework/GizwitsiOSSDK +0 -0
  3. package/ios/GizwitsiOSSDK.framework/Headers/CocoaAsyncSocket.h +18 -0
  4. package/ios/GizwitsiOSSDK.framework/Headers/DDASLLogger.h +41 -0
  5. package/ios/GizwitsiOSSDK.framework/Headers/DDAbstractDatabaseLogger.h +102 -0
  6. package/ios/GizwitsiOSSDK.framework/Headers/DDContextFilterLogFormatter.h +63 -0
  7. package/ios/GizwitsiOSSDK.framework/Headers/DDDispatchQueueLogFormatter.h +128 -0
  8. package/ios/GizwitsiOSSDK.framework/Headers/DDFileLogger.h +340 -0
  9. package/ios/GizwitsiOSSDK.framework/Headers/DDLog+LOGV.h +99 -0
  10. package/ios/GizwitsiOSSDK.framework/Headers/DDLog.h +632 -0
  11. package/ios/GizwitsiOSSDK.framework/Headers/DDMultiFormatter.h +30 -0
  12. package/ios/GizwitsiOSSDK.framework/Headers/DDTTYLogger.h +171 -0
  13. package/ios/GizwitsiOSSDK.framework/Headers/ESPAES.h +19 -0
  14. package/ios/GizwitsiOSSDK.framework/Headers/ESPDataCode.h +44 -0
  15. package/ios/GizwitsiOSSDK.framework/Headers/ESPDatumCode.h +38 -0
  16. package/ios/GizwitsiOSSDK.framework/Headers/ESPGuideCode.h +15 -0
  17. package/ios/GizwitsiOSSDK.framework/Headers/ESPTools.h +22 -0
  18. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouch.h +36 -0
  19. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouchDelegate.h +24 -0
  20. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouchGenerator.h +46 -0
  21. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouchResult.h +36 -0
  22. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouchTask.h +124 -0
  23. package/ios/GizwitsiOSSDK.framework/Headers/ESPTouchTaskParameter.h +173 -0
  24. package/ios/GizwitsiOSSDK.framework/Headers/ESPUDPSocketClient.h +50 -0
  25. package/ios/GizwitsiOSSDK.framework/Headers/ESPUDPSocketServer.h +49 -0
  26. package/ios/GizwitsiOSSDK.framework/Headers/ESP_ByteUtil.h +128 -0
  27. package/ios/GizwitsiOSSDK.framework/Headers/ESP_CRC8.h +61 -0
  28. package/ios/GizwitsiOSSDK.framework/Headers/ESP_NetUtil.h +82 -0
  29. package/ios/GizwitsiOSSDK.framework/Headers/ESP_WifiUtil.h +33 -0
  30. package/ios/GizwitsiOSSDK.framework/Headers/ForegroundReconnection.h +23 -0
  31. package/ios/GizwitsiOSSDK.framework/Headers/GCDTimer.h +19 -0
  32. package/ios/GizwitsiOSSDK.framework/Headers/GizwitsiOSSDK-Swift.h +338 -0
  33. package/ios/GizwitsiOSSDK.framework/Headers/GizwitsiOSSDK.h +24 -0
  34. package/ios/GizwitsiOSSDK.framework/Headers/MQTTClient.h +39 -0
  35. package/ios/GizwitsiOSSDK.framework/Headers/MQTTInMemoryPersistence.h +16 -0
  36. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSSLSecurityPolicyDecoder.h +19 -0
  37. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSSLSecurityPolicyEncoder.h +18 -0
  38. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSessionLegacy.h +112 -0
  39. package/ios/GizwitsiOSSDK.framework/Headers/MQTTSessionSynchron.h +194 -0
  40. package/ios/GizwitsiOSSDK.framework/Headers/MQTTStrict.h +33 -0
  41. package/ios/GizwitsiOSSDK.framework/Headers/MQTTUntil.h +14 -0
  42. package/ios/GizwitsiOSSDK.framework/Headers/ReconnectTimer.h +21 -0
  43. package/ios/GizwitsiOSSDK.framework/Headers/_GCDAsyncSocket.h +1226 -0
  44. package/ios/GizwitsiOSSDK.framework/Headers/_GCDAsyncUdpSocket.h +1036 -0
  45. package/ios/GizwitsiOSSDK.framework/Headers/_GizwitsParser.h +61 -0
  46. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketDecoder.h +39 -0
  47. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketEncoder.h +38 -0
  48. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCFSocketTransport.h +79 -0
  49. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTCoreDataPersistence.h +21 -0
  50. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTDecoder.h +66 -0
  51. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTLog.h +123 -0
  52. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTMessage.h +233 -0
  53. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTPersistence.h +124 -0
  54. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTProperties.h +76 -0
  55. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSSLSecurityPolicy.h +158 -0
  56. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSSLSecurityPolicyTransport.h +30 -0
  57. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSession.h +886 -0
  58. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTSessionManager.h +237 -0
  59. package/ios/GizwitsiOSSDK.framework/Headers/_MQTTTransport.h +114 -0
  60. package/ios/GizwitsiOSSDK.framework/Headers/_SSZipArchive.h +178 -0
  61. package/ios/GizwitsiOSSDK.framework/Headers/_SSZipCommon.h +71 -0
  62. package/ios/GizwitsiOSSDK.framework/Headers/_ZipArchive.h +26 -0
  63. package/ios/GizwitsiOSSDK.framework/Headers/a_weighting.h +88 -0
  64. package/ios/GizwitsiOSSDK.framework/Headers/aubio.h +231 -0
  65. package/ios/GizwitsiOSSDK.framework/Headers/audio_unit.h +61 -0
  66. package/ios/GizwitsiOSSDK.framework/Headers/awhitening.h +125 -0
  67. package/ios/GizwitsiOSSDK.framework/Headers/beattracking.h +121 -0
  68. package/ios/GizwitsiOSSDK.framework/Headers/biquad.h +75 -0
  69. package/ios/GizwitsiOSSDK.framework/Headers/c_weighting.h +88 -0
  70. package/ios/GizwitsiOSSDK.framework/Headers/common.h +104 -0
  71. package/ios/GizwitsiOSSDK.framework/Headers/cvec.h +247 -0
  72. package/ios/GizwitsiOSSDK.framework/Headers/dct.h +85 -0
  73. package/ios/GizwitsiOSSDK.framework/Headers/fft.h +144 -0
  74. package/ios/GizwitsiOSSDK.framework/Headers/filter.h +176 -0
  75. package/ios/GizwitsiOSSDK.framework/Headers/filterbank.h +90 -0
  76. package/ios/GizwitsiOSSDK.framework/Headers/filterbank_mel.h +72 -0
  77. package/ios/GizwitsiOSSDK.framework/Headers/fmat.h +172 -0
  78. package/ios/GizwitsiOSSDK.framework/Headers/fvec.h +178 -0
  79. package/ios/GizwitsiOSSDK.framework/Headers/hist.h +63 -0
  80. package/ios/GizwitsiOSSDK.framework/Headers/ioutils.h +60 -0
  81. package/ios/GizwitsiOSSDK.framework/Headers/log.h +99 -0
  82. package/ios/GizwitsiOSSDK.framework/Headers/lvec.h +118 -0
  83. package/ios/GizwitsiOSSDK.framework/Headers/mathutils.h +330 -0
  84. package/ios/GizwitsiOSSDK.framework/Headers/mfcc.h +79 -0
  85. package/ios/GizwitsiOSSDK.framework/Headers/musicutils.h +171 -0
  86. package/ios/GizwitsiOSSDK.framework/Headers/notes.h +113 -0
  87. package/ios/GizwitsiOSSDK.framework/Headers/onset.h +347 -0
  88. package/ios/GizwitsiOSSDK.framework/Headers/parameter.h +159 -0
  89. package/ios/GizwitsiOSSDK.framework/Headers/peakpicker.h +57 -0
  90. package/ios/GizwitsiOSSDK.framework/Headers/phasevoc.h +112 -0
  91. package/ios/GizwitsiOSSDK.framework/Headers/pitch.h +197 -0
  92. package/ios/GizwitsiOSSDK.framework/Headers/pitchfcomb.h +76 -0
  93. package/ios/GizwitsiOSSDK.framework/Headers/pitchmcomb.h +77 -0
  94. package/ios/GizwitsiOSSDK.framework/Headers/pitchschmitt.h +75 -0
  95. package/ios/GizwitsiOSSDK.framework/Headers/pitchspecacf.h +103 -0
  96. package/ios/GizwitsiOSSDK.framework/Headers/pitchyin.h +100 -0
  97. package/ios/GizwitsiOSSDK.framework/Headers/pitchyinfast.h +102 -0
  98. package/ios/GizwitsiOSSDK.framework/Headers/pitchyinfft.h +99 -0
  99. package/ios/GizwitsiOSSDK.framework/Headers/resampler.h +65 -0
  100. package/ios/GizwitsiOSSDK.framework/Headers/sampler.h +140 -0
  101. package/ios/GizwitsiOSSDK.framework/Headers/scale.h +80 -0
  102. package/ios/GizwitsiOSSDK.framework/Headers/sink.h +181 -0
  103. package/ios/GizwitsiOSSDK.framework/Headers/sink_apple_audio.h +163 -0
  104. package/ios/GizwitsiOSSDK.framework/Headers/sink_sndfile.h +162 -0
  105. package/ios/GizwitsiOSSDK.framework/Headers/sink_wavwrite.h +162 -0
  106. package/ios/GizwitsiOSSDK.framework/Headers/source.h +184 -0
  107. package/ios/GizwitsiOSSDK.framework/Headers/source_apple_audio.h +156 -0
  108. package/ios/GizwitsiOSSDK.framework/Headers/source_avcodec.h +155 -0
  109. package/ios/GizwitsiOSSDK.framework/Headers/source_sndfile.h +155 -0
  110. package/ios/GizwitsiOSSDK.framework/Headers/source_wavread.h +160 -0
  111. package/ios/GizwitsiOSSDK.framework/Headers/specdesc.h +204 -0
  112. package/ios/GizwitsiOSSDK.framework/Headers/tempo.h +255 -0
  113. package/ios/GizwitsiOSSDK.framework/Headers/tss.h +103 -0
  114. package/ios/GizwitsiOSSDK.framework/Headers/types.h +70 -0
  115. package/ios/GizwitsiOSSDK.framework/Headers/vecutils.h +116 -0
  116. package/ios/GizwitsiOSSDK.framework/Headers/wavetable.h +178 -0
  117. package/ios/GizwitsiOSSDK.framework/Info.plist +0 -0
  118. package/ios/GizwitsiOSSDK.framework/LICENSE +17 -0
  119. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/Project/arm64-apple-ios.swiftsourceinfo +0 -0
  120. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.abi.json +57489 -0
  121. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.private.swiftinterface +1752 -0
  122. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.swiftdoc +0 -0
  123. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.swiftinterface +1752 -0
  124. package/ios/GizwitsiOSSDK.framework/Modules/GizwitsiOSSDK.swiftmodule/arm64-apple-ios.swiftmodule +0 -0
  125. package/ios/GizwitsiOSSDK.framework/Modules/module.modulemap +11 -0
  126. package/ios/GizwitsiOSSDK.framework/PrivacyInfo.xcprivacy +23 -0
  127. package/ios/GizwitsiOSSDK.framework/README.md +31 -0
  128. package/package.json +1 -1
  129. package/react-native-gizwits-sdk-v5.podspec +2 -2
@@ -0,0 +1,88 @@
1
+ /*
2
+ Copyright (C) 2003-2015 Paul Brossier <piem@aubio.org>
3
+
4
+ This file is part of aubio.
5
+
6
+ aubio is free software: you can redistribute it and/or modify
7
+ it under the terms of the GNU General Public License as published by
8
+ the Free Software Foundation, either version 3 of the License, or
9
+ (at your option) any later version.
10
+
11
+ aubio is distributed in the hope that it will be useful,
12
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ GNU General Public License for more details.
15
+
16
+ You should have received a copy of the GNU General Public License
17
+ along with aubio. If not, see <http://www.gnu.org/licenses/>.
18
+
19
+ */
20
+
21
+ #ifndef AUBIO_FILTER_C_DESIGN_H
22
+ #define AUBIO_FILTER_C_DESIGN_H
23
+
24
+ /** \file
25
+
26
+ C-weighting filter coefficients
27
+
28
+ This file creates a C-weighting digital filter, which reduces low and high
29
+ frequencies and enhance the middle ones to reflect the ability of the human
30
+ hearing.
31
+
32
+ The implementation is based on the following standard:
33
+
34
+ - IEC/CD 1672: Electroacoustics-Sound Level Meters, IEC, Geneva, Nov. 1996,
35
+ for A- and C-weighting filters.
36
+
37
+ See also:
38
+
39
+ - <a href="http://en.wikipedia.org/wiki/A-weighting">A-Weighting on
40
+ Wikipedia</a>
41
+ - <a href="http://en.wikipedia.org/wiki/Weighting_filter">Weighting filter on
42
+ Wikipedia</a>
43
+ - <a href="http://www.mathworks.com/matlabcentral/fileexchange/69">Christophe
44
+ Couvreur's 'octave' toolbox</a>
45
+
46
+ The coefficients in this file have been computed using Christophe Couvreur's
47
+ scripts in octave 3.0 (debian package 1:3.0.5-6+b2 with octave-signal
48
+ 1.0.9-1+b1 on i386), with <pre> [b, a] = cdsign(1/Fs) </pre> for various
49
+ sampling frequencies (8000, 11025, 16000, 22050, 24000, 32000, 44100, 48000,
50
+ 88200, 96000, and 192000 Hz).
51
+
52
+ The sampling frequency should normally be higher than 20kHz, but most common
53
+ file sampling rates have been included for completeness.
54
+
55
+ \example temporal/test-c_weighting.c
56
+
57
+ */
58
+
59
+ #ifdef __cplusplus
60
+ extern "C" {
61
+ #endif
62
+
63
+ /** create new C-design filter
64
+
65
+ \param samplerate sampling frequency of the signal to filter. Should be one of
66
+ 8000, 11025, 16000, 22050, 24000, 32000, 44100, 48000, 88200, 96000, and
67
+ 192000 Hz
68
+
69
+ \return a new filter object
70
+
71
+ */
72
+ aubio_filter_t *new_aubio_filter_c_weighting (uint_t samplerate);
73
+
74
+ /** set feedback and feedforward coefficients of a C-weighting filter
75
+
76
+ \param f filter object to get coefficients from
77
+ \param samplerate sampling frequency of the signal to filter. Should be one of
78
+ 8000, 11025, 16000, 22050, 24000, 32000, 44100, 48000, 88200, 96000, and
79
+ 192000 Hz
80
+
81
+ */
82
+ uint_t aubio_filter_set_c_weighting (aubio_filter_t * f, uint_t samplerate);
83
+
84
+ #ifdef __cplusplus
85
+ }
86
+ #endif
87
+
88
+ #endif /* AUBIO_FILTER_C_DESIGN_H */
@@ -0,0 +1,104 @@
1
+ //
2
+ // const.h
3
+ // Protocol
4
+ //
5
+ // Created by danlypro on 2022/4/19.
6
+ //
7
+
8
+ #ifndef common_h
9
+ #define common_h
10
+
11
+ //************************命令字************************
12
+ #define _GizWifiSDKCMD_SOFTAP_CONFIG_REQ (0x0001)
13
+ #define _GizWifiSDKCMD_SOFTAP_CONFIG_RESP (0x0002)
14
+ #define _GizWifiSDKCMD_DISCOVER_DEVICE_REQ (0x0003)
15
+ #define _GizWifiSDKCMD_DISCOVER_DEVICE_RESP (0x0004)
16
+ #define _GizWifiSDKCMD_ONLINE_NOTIFY (0x0005)
17
+ #define _GizWifiSDKCMD_BIND_DEVICE_REQ (0x0006)
18
+ #define _GizWifiSDKCMD_BIND_DEVICE_RESP (0x0007)
19
+ #define _GizWifiSDKCMD_LOGIN_DEVICE_REQ (0x0008)
20
+ #define _GizWifiSDKCMD_LOGIN_DEVICE_RESP (0x0009)
21
+ #define _GizWifiSDKCMD_READ_DEVICE_INFO_REQ (0x0013)
22
+ #define _GizWifiSDKCMD_READ_DEVICE_INFO_RESP (0x0014)
23
+ #define _GizWifiSDKCMD_DEVICE_KEEPALIVE_REQ (0x0015)
24
+ #define _GizWifiSDKCMD_DEVICE_KEEPALIVE_RESP (0x0016)
25
+ #define _GizWifiSDKCMD_EXIT_PRODUCT_TEST_MODE_REQ (0x0017)
26
+ #define _GizWifiSDKCMD_EXIT_PRODUCT_TEST_MODE_RESP (0x0018)
27
+ #define _GizWifiSDKCMD_CONFIG_NOTIFY (0x0019)
28
+ #define _GizWifiSDKCMD_GET_DEVICE_UPDATE_STATUS_REQ (0x001E)
29
+ #define _GizWifiSDKCMD_GET_DEVICE_UPDATE_STATUS_RESP (0x001F)
30
+ #define _GizWifiSDKCMD_UPDATE_DEVICE_REQ (0x0020)
31
+ #define _GizWifiSDKCMD_UPDATE_DEVICE_RESP (0x0021)
32
+
33
+ #define _GizWifiSDKCMD_TRANS_DEVICE_LOG (0x0012)
34
+ #define _GizWifiSDKCMD_TRANS_BUSINESS (0x0090)
35
+ #define _GizWifiSDKCMD_RECV_BUSINESS (0x0091)
36
+ #define _GizWifiSDKCMD_ONLINE_STATUS_CHANGED (0x0092)
37
+ #define _GizWifiSDKCMD_TRANS_BUSINESS_REQ (0x0093)
38
+ #define _GizWifiSDKCMD_TRANS_BUSINESS_RESP (0x0094)
39
+ #define _GizWifiSDKCMD_BIND_STATUS_CHANGED (0x010D)
40
+ #define _GizWifiSDKCMD_LOG_ENABLED_STATUS_CHANGED (0x0111)
41
+
42
+ #define _GizWifi_PROTOCOL_VERSION (0x00000003)
43
+ #define _GizWifi_ENCRYPT_PROTOCOL_VERSION (0x00000004)
44
+
45
+ //************************常用宏************************
46
+ #define _SSID_BUF_LENGHT (32)
47
+ #define _MD5_BUF_LENGTH (32)
48
+ #define _MAC_BUF_LENGTH (32)
49
+ #define _DID_BUF_LENGTH (22)
50
+ #define _PASSCODE_BUF_LENGTH (32)
51
+ #define _PRODUCTKEY_BUF_LENGTH (32)
52
+ #define _BT_MESHID_BUF_LENGTH (256)
53
+ #define _DOMAIN_BUF_LENGTH (128)
54
+ #define _HARDWARE_VERSION_LENGTH (8)
55
+ #define _SOFTWARE_VERSION_LENGTH (8)
56
+ #define _MCU_HARDWARE_VERSION_LENGTH (8)
57
+ #define _MCU_SOFTWARE_VERSION_LENGTH (8)
58
+ #define _WIFI_FIRMWARE_VERSION_LENGTH (36)
59
+ #define _WIFI_FIRMWARE_ID_LENGTH (8)
60
+ #define _PROTOCOL_VERSION_LENGTH (16)
61
+ #define _BUSINESS_PROTOCOL_VERSION_LENGTH (8)
62
+
63
+ #define _DEVICE_SUPPORT_OTA_PROTOCOL_MIN_VERSION "4.1.2"
64
+
65
+ #define _DATAPOINT_TYPE_WRITABLE "status_writable" //可读写
66
+ #define _DATAPOINT_TYPE_READONLY "status_readonly" //只读
67
+ #define _DATAPOINT_TYPE_ALERT "alert" //报警
68
+ #define _DATAPOINT_TYPE_FAULT "fault" //故障
69
+
70
+ #define _DATAPOINT_DATATYPE_BOOL "bool" //布尔型
71
+ #define _DATAPOINT_DATATYPE_ENUM "enum" //枚举型
72
+ #define _DATAPOINT_DATATYPE_UINT8 "uint8" //8 bits 整型
73
+ #define _DATAPOINT_DATATYPE_UINT16 "uint16" //16 bits 整型
74
+ #define _DATAPOINT_DATATYPE_UINT32 "uint32" //32 bits 整型
75
+ #define _DATAPOINT_DATATYPE_BINARY "binary" //二进制数据
76
+
77
+
78
+ //************************错误码************************
79
+ #define _GIZ_SDK_SUCCESS (0) //操作成功
80
+ #define _GIZ_SDK_PARAM_INVALID (5001) //参数错误
81
+ #define _GIZ_SDK_PARAM_FORM_INVALID (5002) //json格式错误
82
+ #define _GIZ_SDK_MEMORY_MALLOC_FAILED (5003) //内存分配失败
83
+ #define _GIZ_SDK_BASE64_ENCODE_FAILED (5004) //base64编码错误
84
+ #define _GIZ_SDK_DATA_PARSE_FAILED (5005) //数据包解析失败
85
+ #define _GIZ_SDK_CMD_NOT_EXIST (5006) //命令字不存在
86
+ #define _GIZ_SDK_JSON_OBJECT_CREATE_FAILED (5007) //Json对象创建失败
87
+ #define _GIZ_SDK_DEVICE_PASSCODE_INVALID (5008) //设备PASSCODE无效
88
+ #define _GIZ_SDK_JSON_PARSE_FAILED (5009) //Json解析失败
89
+ #define _GIZ_SDK_OPEN_PRODUCT_FILE_FAILED (5010) //打开产品配置文件失败
90
+ #define _GIZ_SDK_READ_PRODUCT_FILE_FAILED (5011) //读产品配置文件失败
91
+ #define _GIZ_SITE_DATAPOINTS_NOT_DEFINED (5012) //数据点未定义
92
+ #define _GIZ_SITE_DATAPOINTS_NOT_MALFORME (5013) //数据点异常
93
+ #define _GIZ_SDK_DEVICE_CONTROL_WITH_INVALID_COMMAND (5014) //设备控制指令中包含无效指令
94
+ #define _GIZ_SDK_DEVICE_CONTROL_NOT_WRITABLE_COMMAND (5015) //设备控制指令中包含不可写指令
95
+ #define _GIZ_SDK_DEVICE_CONTROL_VALUE_OUT_OF_RANGE (5016) //设备控制指令参数值不在有效范围内
96
+ #define _GIZ_SDK_DEVICE_CONTROL_VALUE_TYPE_ERROR (5017) //设备控制指令参数类型错误
97
+ #define _GIZ_SDK__DATAPOINT_PARSE_FAILED (5018) //配置文件解析失败
98
+ #define _GIZ_SDK__DATAPOINT_FILE_IS_EMPTY (5019) //配置文件为空
99
+ #define _GIZ_SDK_BASE64_DECODE_FAILED (5020) //base64解码错误
100
+
101
+
102
+
103
+
104
+ #endif /* common_h */
@@ -0,0 +1,247 @@
1
+ /*
2
+ Copyright (C) 2003-2015 Paul Brossier <piem@aubio.org>
3
+
4
+ This file is part of aubio.
5
+
6
+ aubio is free software: you can redistribute it and/or modify
7
+ it under the terms of the GNU General Public License as published by
8
+ the Free Software Foundation, either version 3 of the License, or
9
+ (at your option) any later version.
10
+
11
+ aubio is distributed in the hope that it will be useful,
12
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ GNU General Public License for more details.
15
+
16
+ You should have received a copy of the GNU General Public License
17
+ along with aubio. If not, see <http://www.gnu.org/licenses/>.
18
+
19
+ */
20
+
21
+ #ifndef AUBIO_CVEC_H
22
+ #define AUBIO_CVEC_H
23
+
24
+ #ifdef __cplusplus
25
+ extern "C" {
26
+ #endif
27
+
28
+ /** \file
29
+
30
+ Vector of complex-valued data, stored in polar coordinates
31
+
32
+ This file specifies the ::cvec_t buffer type, which is used throughout aubio
33
+ to store complex data. Complex values are stored in terms of ::cvec_t.phas
34
+ and norm, within 2 vectors of ::smpl_t of size (size/2+1) each.
35
+
36
+ \example test-cvec.c
37
+
38
+ */
39
+
40
+ /** Vector of real-valued phase and spectrum data
41
+
42
+ \code
43
+
44
+ uint_t buffer_size = 1024;
45
+
46
+ // create a complex vector of 512 values
47
+ cvec_t * input = new_cvec (buffer_size);
48
+
49
+ // set some values of the vector
50
+ input->norm[23] = 2.;
51
+ input->phas[23] = M_PI;
52
+ // ..
53
+
54
+ // compute the mean of the vector
55
+ mean = cvec_mean(input);
56
+
57
+ // destroy the vector
58
+ del_cvec (input);
59
+
60
+ \endcode
61
+
62
+ */
63
+ typedef struct {
64
+ uint_t length; /**< length of buffer = (requested length)/2 + 1 */
65
+ smpl_t *norm; /**< norm array of size ::cvec_t.length */
66
+ smpl_t *phas; /**< phase array of size ::cvec_t.length */
67
+ } cvec_t;
68
+
69
+ /** cvec_t buffer creation function
70
+
71
+ This function creates a cvec_t structure holding two arrays of size
72
+ [length/2+1], corresponding to the norm and phase values of the
73
+ spectral frame. The length stored in the structure is the actual size of both
74
+ arrays, not the length of the complex and symmetrical vector, specified as
75
+ creation argument.
76
+
77
+ \param length the length of the buffer to create
78
+
79
+ */
80
+ cvec_t * new_cvec(uint_t length);
81
+
82
+ /** cvec_t buffer deletion function
83
+
84
+ \param s buffer to delete as returned by new_cvec()
85
+
86
+ */
87
+ void del_cvec(cvec_t *s);
88
+
89
+ /** write norm value in a complex buffer
90
+
91
+ This is equivalent to:
92
+ \code
93
+ s->norm[position] = val;
94
+ \endcode
95
+
96
+ \param s vector to write to
97
+ \param val norm value to write in s->norm[position]
98
+ \param position sample position to write to
99
+
100
+ */
101
+ void cvec_norm_set_sample (cvec_t *s, smpl_t val, uint_t position);
102
+
103
+ /** write phase value in a complex buffer
104
+
105
+ This is equivalent to:
106
+ \code
107
+ s->phas[position] = val;
108
+ \endcode
109
+
110
+ \param s vector to write to
111
+ \param val phase value to write in s->phas[position]
112
+ \param position sample position to write to
113
+
114
+ */
115
+ void cvec_phas_set_sample (cvec_t *s, smpl_t val, uint_t position);
116
+
117
+ /** read norm value from a complex buffer
118
+
119
+ This is equivalent to:
120
+ \code
121
+ smpl_t foo = s->norm[position];
122
+ \endcode
123
+
124
+ \param s vector to read from
125
+ \param position sample position to read from
126
+
127
+ */
128
+ smpl_t cvec_norm_get_sample (cvec_t *s, uint_t position);
129
+
130
+ /** read phase value from a complex buffer
131
+
132
+ This is equivalent to:
133
+ \code
134
+ smpl_t foo = s->phas[position];
135
+ \endcode
136
+
137
+ \param s vector to read from
138
+ \param position sample position to read from
139
+ \returns the value of the sample at position
140
+
141
+ */
142
+ smpl_t cvec_phas_get_sample (cvec_t *s, uint_t position);
143
+
144
+ /** read norm data from a complex buffer
145
+
146
+ \code
147
+ smpl_t *data = s->norm;
148
+ \endcode
149
+
150
+ \param s vector to read from
151
+
152
+ */
153
+ smpl_t * cvec_norm_get_data (const cvec_t *s);
154
+
155
+ /** read phase data from a complex buffer
156
+
157
+ This is equivalent to:
158
+ \code
159
+ smpl_t *data = s->phas;
160
+ \endcode
161
+
162
+ \param s vector to read from
163
+
164
+ */
165
+ smpl_t * cvec_phas_get_data (const cvec_t *s);
166
+
167
+ /** print out cvec data
168
+
169
+ \param s vector to print out
170
+
171
+ */
172
+ void cvec_print(const cvec_t *s);
173
+
174
+ /** make a copy of a vector
175
+
176
+ \param s source vector
177
+ \param t vector to copy to
178
+
179
+ */
180
+ void cvec_copy(const cvec_t *s, cvec_t *t);
181
+
182
+ /** set all norm elements to a given value
183
+
184
+ \param s vector to modify
185
+ \param val value to set elements to
186
+
187
+ */
188
+ void cvec_norm_set_all (cvec_t *s, smpl_t val);
189
+
190
+ /** set all norm elements to zero
191
+
192
+ \param s vector to modify
193
+
194
+ */
195
+ void cvec_norm_zeros(cvec_t *s);
196
+
197
+ /** set all norm elements to one
198
+
199
+ \param s vector to modify
200
+
201
+ */
202
+ void cvec_norm_ones(cvec_t *s);
203
+
204
+ /** set all phase elements to a given value
205
+
206
+ \param s vector to modify
207
+ \param val value to set elements to
208
+
209
+ */
210
+ void cvec_phas_set_all (cvec_t *s, smpl_t val);
211
+
212
+ /** set all phase elements to zero
213
+
214
+ \param s vector to modify
215
+
216
+ */
217
+ void cvec_phas_zeros(cvec_t *s);
218
+
219
+ /** set all phase elements to one
220
+
221
+ \param s vector to modify
222
+
223
+ */
224
+ void cvec_phas_ones(cvec_t *s);
225
+
226
+ /** set all norm and phas elements to zero
227
+
228
+ \param s vector to modify
229
+
230
+ */
231
+ void cvec_zeros(cvec_t *s);
232
+
233
+ /** take logarithmic magnitude
234
+
235
+ \param s input cvec to compress
236
+ \param lambda value to use for normalisation
237
+
238
+ \f$ S_k = log( \lambda * S_k + 1 ) \f$
239
+
240
+ */
241
+ void cvec_logmag(cvec_t *s, smpl_t lambda);
242
+
243
+ #ifdef __cplusplus
244
+ }
245
+ #endif
246
+
247
+ #endif /* AUBIO_CVEC_H */
@@ -0,0 +1,85 @@
1
+ /*
2
+ Copyright (C) 2017 Paul Brossier <piem@aubio.org>
3
+
4
+ This file is part of aubio.
5
+
6
+ aubio is free software: you can redistribute it and/or modify
7
+ it under the terms of the GNU General Public License as published by
8
+ the Free Software Foundation, either version 3 of the License, or
9
+ (at your option) any later version.
10
+
11
+ aubio is distributed in the hope that it will be useful,
12
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ GNU General Public License for more details.
15
+
16
+ You should have received a copy of the GNU General Public License
17
+ along with aubio. If not, see <http://www.gnu.org/licenses/>.
18
+
19
+ */
20
+
21
+ /** \file
22
+
23
+ Discrete Cosine Transform
24
+
25
+ Functions aubio_dct_do() and aubio_dct_rdo() are equivalent to MATLAB/Octave
26
+ dct() and idct() functions, as well as scipy.fftpack.dct(x, norm='ortho') and
27
+ scipy.fftpack.idct(x, norm='ortho')
28
+
29
+ \example spectral/test-dct.c
30
+
31
+ */
32
+
33
+ #ifndef AUBIO_DCT_H
34
+ #define AUBIO_DCT_H
35
+
36
+ #ifdef __cplusplus
37
+ extern "C" {
38
+ #endif
39
+
40
+ /** DCT object
41
+
42
+ This object computes forward and backward DCT type 2 with orthonormal
43
+ scaling.
44
+
45
+ */
46
+ typedef struct _aubio_dct_t aubio_dct_t;
47
+
48
+ /** create new DCT computation object
49
+
50
+ \param size length of the DCT
51
+
52
+ */
53
+ aubio_dct_t * new_aubio_dct(uint_t size);
54
+
55
+ /** compute forward DCT
56
+
57
+ \param s dct object as returned by new_aubio_dct
58
+ \param input input signal
59
+ \param dct_output transformed input array
60
+
61
+ */
62
+ void aubio_dct_do (aubio_dct_t *s, const fvec_t * input, fvec_t * dct_output);
63
+
64
+ /** compute backward DCT
65
+
66
+ \param s dct object as returned by new_aubio_dct
67
+ \param input input signal
68
+ \param idct_output transformed input array
69
+
70
+ */
71
+ void aubio_dct_rdo (aubio_dct_t *s, const fvec_t * input, fvec_t * idct_output);
72
+
73
+
74
+ /** delete DCT object
75
+
76
+ \param s dct object as returned by new_aubio_dct
77
+
78
+ */
79
+ void del_aubio_dct (aubio_dct_t *s);
80
+
81
+ #ifdef __cplusplus
82
+ }
83
+ #endif
84
+
85
+ #endif /* AUBIO_DCT_H */
@@ -0,0 +1,144 @@
1
+ /*
2
+ Copyright (C) 2003-2013 Paul Brossier <piem@aubio.org>
3
+
4
+ This file is part of aubio.
5
+
6
+ aubio is free software: you can redistribute it and/or modify
7
+ it under the terms of the GNU General Public License as published by
8
+ the Free Software Foundation, either version 3 of the License, or
9
+ (at your option) any later version.
10
+
11
+ aubio is distributed in the hope that it will be useful,
12
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
+ GNU General Public License for more details.
15
+
16
+ You should have received a copy of the GNU General Public License
17
+ along with aubio. If not, see <http://www.gnu.org/licenses/>.
18
+
19
+ */
20
+
21
+ /** \file
22
+
23
+ Fast Fourier Transform
24
+
25
+ Depending on how aubio was compiled, FFT are computed using one of:
26
+ - [Ooura](http://www.kurims.kyoto-u.ac.jp/~ooura/fft.html)
27
+ - [FFTW3](http://www.fftw.org)
28
+ - [vDSP](https://developer.apple.com/library/mac/#documentation/Accelerate/Reference/vDSPRef/Reference/reference.html)
29
+
30
+ \example spectral/test-fft.c
31
+
32
+ */
33
+
34
+ #ifndef AUBIO_FFT_H
35
+ #define AUBIO_FFT_H
36
+
37
+ #ifdef __cplusplus
38
+ extern "C" {
39
+ #endif
40
+
41
+ /** FFT object
42
+
43
+ This object computes forward and backward FFTs.
44
+
45
+ */
46
+ typedef struct _aubio_fft_t aubio_fft_t;
47
+
48
+ /** create new FFT computation object
49
+
50
+ \param size length of the FFT
51
+
52
+ */
53
+ aubio_fft_t * new_aubio_fft (uint_t size);
54
+ /** delete FFT object
55
+
56
+ \param s fft object as returned by new_aubio_fft
57
+
58
+ */
59
+ void del_aubio_fft(aubio_fft_t * s);
60
+
61
+ /** compute forward FFT
62
+
63
+ \param s fft object as returned by new_aubio_fft
64
+ \param input input signal
65
+ \param spectrum output spectrum
66
+
67
+ */
68
+ void aubio_fft_do (aubio_fft_t *s, const fvec_t * input, cvec_t * spectrum);
69
+ /** compute backward (inverse) FFT
70
+
71
+ \param s fft object as returned by new_aubio_fft
72
+ \param spectrum input spectrum
73
+ \param output output signal
74
+
75
+ */
76
+ void aubio_fft_rdo (aubio_fft_t *s, const cvec_t * spectrum, fvec_t * output);
77
+
78
+ /** compute forward FFT
79
+
80
+ \param s fft object as returned by new_aubio_fft
81
+ \param input real input signal
82
+ \param compspec complex output fft real/imag
83
+
84
+ */
85
+ void aubio_fft_do_complex (aubio_fft_t *s, const fvec_t * input, fvec_t * compspec);
86
+ /** compute backward (inverse) FFT from real/imag
87
+
88
+ \param s fft object as returned by new_aubio_fft
89
+ \param compspec real/imag input fft array
90
+ \param output real output array
91
+
92
+ */
93
+ void aubio_fft_rdo_complex (aubio_fft_t *s, const fvec_t * compspec, fvec_t * output);
94
+
95
+ /** convert real/imag spectrum to norm/phas spectrum
96
+
97
+ \param compspec real/imag input fft array
98
+ \param spectrum cvec norm/phas output array
99
+
100
+ */
101
+ void aubio_fft_get_spectrum(const fvec_t * compspec, cvec_t * spectrum);
102
+ /** convert real/imag spectrum to norm/phas spectrum
103
+
104
+ \param compspec real/imag input fft array
105
+ \param spectrum cvec norm/phas output array
106
+
107
+ */
108
+ void aubio_fft_get_realimag(const cvec_t * spectrum, fvec_t * compspec);
109
+
110
+ /** compute phas spectrum from real/imag parts
111
+
112
+ \param compspec real/imag input fft array
113
+ \param spectrum cvec norm/phas output array
114
+
115
+ */
116
+ void aubio_fft_get_phas(const fvec_t * compspec, cvec_t * spectrum);
117
+ /** compute imaginary part from the norm/phas cvec
118
+
119
+ \param spectrum norm/phas input array
120
+ \param compspec real/imag output fft array
121
+
122
+ */
123
+ void aubio_fft_get_imag(const cvec_t * spectrum, fvec_t * compspec);
124
+
125
+ /** compute norm component from real/imag parts
126
+
127
+ \param compspec real/imag input fft array
128
+ \param spectrum cvec norm/phas output array
129
+
130
+ */
131
+ void aubio_fft_get_norm(const fvec_t * compspec, cvec_t * spectrum);
132
+ /** compute real part from norm/phas components
133
+
134
+ \param spectrum norm/phas input array
135
+ \param compspec real/imag output fft array
136
+
137
+ */
138
+ void aubio_fft_get_real(const cvec_t * spectrum, fvec_t * compspec);
139
+
140
+ #ifdef __cplusplus
141
+ }
142
+ #endif
143
+
144
+ #endif /* AUBIO_FFT_H */