@onekeyfe/hd-core 1.2.0-alpha.0 → 1.2.0-alpha.10
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.
- package/__tests__/connectSettings.test.ts +19 -0
- package/__tests__/device-wallet-session-store.test.ts +131 -0
- package/__tests__/preInitialize.test.ts +33 -0
- package/__tests__/protocol-v2-firmware-targets.test.ts +19 -0
- package/__tests__/protocol-v2.test.ts +1930 -765
- package/dist/api/ClearSessionCache.d.ts +9 -0
- package/dist/api/ClearSessionCache.d.ts.map +1 -0
- package/dist/api/FileRead.d.ts.map +1 -1
- package/dist/api/FileWrite.d.ts.map +1 -1
- package/dist/api/FirmwareUpdateV2.d.ts.map +1 -1
- package/dist/api/FirmwareUpdateV3.d.ts.map +1 -1
- package/dist/api/FirmwareUpdateV4.d.ts +26 -5
- package/dist/api/FirmwareUpdateV4.d.ts.map +1 -1
- package/dist/api/GetDeviceInfo.d.ts.map +1 -1
- package/dist/api/GetFeatures.d.ts +1 -1
- package/dist/api/GetOnekeyFeatures.d.ts.map +1 -1
- package/dist/api/GetPassphraseState.d.ts +4 -4
- package/dist/api/GetPassphraseState.d.ts.map +1 -1
- package/dist/api/device/DeviceUnlock.d.ts +1 -1
- package/dist/api/firmware/FirmwareUpdateBaseMethod.d.ts +1 -0
- package/dist/api/firmware/FirmwareUpdateBaseMethod.d.ts.map +1 -1
- package/dist/api/firmware/bootloaderHelper.d.ts.map +1 -1
- package/dist/api/firmware/getBinary.d.ts +4 -0
- package/dist/api/firmware/getBinary.d.ts.map +1 -1
- package/dist/api/firmware/progressThrottle.d.ts +3 -0
- package/dist/api/firmware/progressThrottle.d.ts.map +1 -0
- package/dist/api/firmware/uploadFirmware.d.ts.map +1 -1
- package/dist/api/index.d.ts +8 -10
- package/dist/api/index.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceFactoryInfoGet.d.ts +6 -0
- package/dist/api/protocol-v2/DeviceFactoryInfoGet.d.ts.map +1 -0
- package/dist/api/protocol-v2/DeviceFactoryInfoSet.d.ts +7 -0
- package/dist/api/protocol-v2/DeviceFactoryInfoSet.d.ts.map +1 -0
- package/dist/api/protocol-v2/DeviceFirmwareUpdate.d.ts +1 -1
- package/dist/api/protocol-v2/DeviceFirmwareUpdate.d.ts.map +1 -1
- package/dist/api/protocol-v2/DeviceGetFirmwareUpdateStatus.d.ts +3 -2
- package/dist/api/protocol-v2/DeviceGetFirmwareUpdateStatus.d.ts.map +1 -1
- package/dist/api/protocol-v2/{DeviceGetDeviceInfo.d.ts → DeviceInfoGet.d.ts} +10 -10
- package/dist/api/protocol-v2/DeviceInfoGet.d.ts.map +1 -0
- package/dist/api/protocol-v2/DeviceSessionGet.d.ts +9 -0
- package/dist/api/protocol-v2/DeviceSessionGet.d.ts.map +1 -0
- package/dist/api/protocol-v2/DeviceStatusGet.d.ts +6 -0
- package/dist/api/protocol-v2/DeviceStatusGet.d.ts.map +1 -0
- package/dist/api/protocol-v2/FilesystemFormat.d.ts.map +1 -1
- package/dist/api/protocol-v2/{FilesystemFixPermission.d.ts → FilesystemPermissionFix.d.ts} +2 -2
- package/dist/api/protocol-v2/FilesystemPermissionFix.d.ts.map +1 -0
- package/dist/api/protocol-v2/ProtocolInfoRequest.d.ts +6 -0
- package/dist/api/protocol-v2/ProtocolInfoRequest.d.ts.map +1 -0
- package/dist/api/protocol-v2/helpers.d.ts +27 -19
- package/dist/api/protocol-v2/helpers.d.ts.map +1 -1
- package/dist/api/ton/TonSignData.d.ts +1 -5
- package/dist/api/ton/TonSignData.d.ts.map +1 -1
- package/dist/api/tron/TronSignMessage.d.ts +0 -1
- package/dist/api/tron/TronSignMessage.d.ts.map +1 -1
- package/dist/api/tron/TronSignTransaction.d.ts +0 -1
- package/dist/api/tron/TronSignTransaction.d.ts.map +1 -1
- package/dist/constants/index.d.ts +2 -1
- package/dist/constants/index.d.ts.map +1 -1
- package/dist/core/index.d.ts.map +1 -1
- package/dist/data-manager/DataManager.d.ts +1 -1
- package/dist/data-manager/DataManager.d.ts.map +1 -1
- package/dist/data-manager/connectSettings.d.ts.map +1 -1
- package/dist/device/Device.d.ts +17 -18
- package/dist/device/Device.d.ts.map +1 -1
- package/dist/device/DeviceWalletSessionStore.d.ts +15 -0
- package/dist/device/DeviceWalletSessionStore.d.ts.map +1 -0
- package/dist/deviceProfile/buildDeviceFeatures.d.ts +6 -0
- package/dist/deviceProfile/buildDeviceFeatures.d.ts.map +1 -0
- package/dist/deviceProfile/buildDeviceProfile.d.ts +3 -4
- package/dist/deviceProfile/buildDeviceProfile.d.ts.map +1 -1
- package/dist/deviceProfile/index.d.ts +1 -1
- package/dist/deviceProfile/index.d.ts.map +1 -1
- package/dist/index.d.ts +657 -539
- package/dist/index.js +2579 -2161
- package/dist/inject.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/features.d.ts +12 -14
- package/dist/protocols/protocol-v2/features.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/firmware.d.ts +11 -9
- package/dist/protocols/protocol-v2/firmware.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/index.d.ts +1 -0
- package/dist/protocols/protocol-v2/index.d.ts.map +1 -1
- package/dist/protocols/protocol-v2/walletSession.d.ts +13 -0
- package/dist/protocols/protocol-v2/walletSession.d.ts.map +1 -0
- package/dist/types/api/firmwareUpdate.d.ts +4 -6
- package/dist/types/api/firmwareUpdate.d.ts.map +1 -1
- package/dist/types/api/getDeviceInfo.d.ts +4 -2
- package/dist/types/api/getDeviceInfo.d.ts.map +1 -1
- package/dist/types/api/getPassphraseState.d.ts +4 -4
- package/dist/types/api/getPassphraseState.d.ts.map +1 -1
- package/dist/types/api/index.d.ts +11 -11
- package/dist/types/api/index.d.ts.map +1 -1
- package/dist/types/api/protocolV2.d.ts +16 -17
- package/dist/types/api/protocolV2.d.ts.map +1 -1
- package/dist/types/api/sessionCache.d.ts +10 -0
- package/dist/types/api/sessionCache.d.ts.map +1 -0
- package/dist/types/device.d.ts +88 -8
- package/dist/types/device.d.ts.map +1 -1
- package/dist/types/params.d.ts +1 -0
- package/dist/types/params.d.ts.map +1 -1
- package/dist/types/settings.d.ts +21 -1
- package/dist/types/settings.d.ts.map +1 -1
- package/dist/utils/capabilitieUtils.d.ts.map +1 -1
- package/dist/utils/deviceFeaturesUtils.d.ts +2 -0
- package/dist/utils/deviceFeaturesUtils.d.ts.map +1 -1
- package/dist/utils/deviceInfoUtils.d.ts.map +1 -1
- package/dist/utils/deviceVersionUtils.d.ts.map +1 -1
- package/dist/utils/findDefectiveBatchDevice.d.ts +1 -1
- package/dist/utils/patch.d.ts +1 -1
- package/dist/utils/patch.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/api/ClearSessionCache.ts +28 -0
- package/src/api/FileRead.ts +16 -3
- package/src/api/FileWrite.ts +14 -1
- package/src/api/FirmwareUpdateV2.ts +9 -2
- package/src/api/FirmwareUpdateV3.ts +2 -1
- package/src/api/FirmwareUpdateV4.ts +1089 -285
- package/src/api/GetDeviceInfo.ts +6 -13
- package/src/api/GetOnekeyFeatures.ts +3 -14
- package/src/api/GetPassphraseState.ts +7 -4
- package/src/api/device/DeviceRebootToBoardloader.ts +4 -4
- package/src/api/device/DeviceRebootToBootloader.ts +4 -4
- package/src/api/firmware/FirmwareUpdateBaseMethod.ts +18 -4
- package/src/api/firmware/bootloaderHelper.ts +3 -2
- package/src/api/firmware/getBinary.ts +1 -1
- package/src/api/firmware/progressThrottle.ts +44 -0
- package/src/api/firmware/releaseHelper.ts +3 -3
- package/src/api/firmware/uploadFirmware.ts +5 -2
- package/src/api/index.ts +8 -10
- package/src/api/protocol-v2/{FactoryGetDeviceInfo.ts → DeviceFactoryInfoGet.ts} +3 -3
- package/src/api/protocol-v2/DeviceFactoryInfoSet.ts +32 -0
- package/src/api/protocol-v2/DeviceFirmwareUpdate.ts +3 -5
- package/src/api/protocol-v2/DeviceGetFirmwareUpdateStatus.ts +39 -5
- package/src/api/protocol-v2/{DeviceGetDeviceInfo.ts → DeviceInfoGet.ts} +52 -22
- package/src/api/protocol-v2/DeviceReboot.ts +2 -2
- package/src/api/protocol-v2/DeviceSessionGet.ts +26 -0
- package/src/api/protocol-v2/DeviceStatusGet.ts +14 -0
- package/src/api/protocol-v2/FilesystemFormat.ts +4 -1
- package/src/api/protocol-v2/{FilesystemFixPermission.ts → FilesystemPermissionFix.ts} +2 -2
- package/src/api/protocol-v2/{GetProtoVersion.ts → ProtocolInfoRequest.ts} +2 -2
- package/src/api/protocol-v2/helpers.ts +58 -59
- package/src/api/ton/TonSignData.ts +1 -5
- package/src/api/tron/TronSignMessage.ts +0 -1
- package/src/api/tron/TronSignTransaction.ts +0 -1
- package/src/constants/index.ts +10 -1
- package/src/core/index.ts +22 -10
- package/src/data/messages/messages-protocol-v2.json +992 -1420
- package/src/data/messages/messages.json +8 -0
- package/src/data-manager/DataManager.ts +11 -4
- package/src/data-manager/connectSettings.ts +4 -0
- package/src/device/Device.ts +158 -294
- package/src/device/DevicePool.ts +9 -9
- package/src/device/DeviceWalletSessionStore.ts +78 -0
- package/src/deviceProfile/buildDeviceFeatures.ts +365 -0
- package/src/deviceProfile/buildDeviceProfile.ts +165 -200
- package/src/deviceProfile/index.ts +4 -1
- package/src/inject.ts +13 -16
- package/src/protocols/protocol-v2/features.ts +28 -67
- package/src/protocols/protocol-v2/firmware.ts +12 -36
- package/src/protocols/protocol-v2/index.ts +1 -0
- package/src/protocols/protocol-v2/walletSession.ts +83 -0
- package/src/types/api/firmwareUpdate.ts +16 -20
- package/src/types/api/getDeviceInfo.ts +4 -2
- package/src/types/api/getPassphraseState.ts +4 -4
- package/src/types/api/index.ts +17 -20
- package/src/types/api/protocolV2.ts +35 -40
- package/src/types/api/sessionCache.ts +14 -0
- package/src/types/device.ts +98 -34
- package/src/types/params.ts +4 -0
- package/src/types/settings.ts +42 -30
- package/src/utils/capabilitieUtils.ts +1 -2
- package/src/utils/deviceFeaturesUtils.ts +54 -29
- package/src/utils/deviceInfoUtils.ts +11 -29
- package/src/utils/deviceVersionUtils.ts +7 -25
- package/src/utils/findDefectiveBatchDevice.ts +6 -6
- package/dist/api/protocol-v2/DevReboot.d.ts +0 -7
- package/dist/api/protocol-v2/DevReboot.d.ts.map +0 -1
- package/dist/api/protocol-v2/DeviceGetDeviceInfo.d.ts.map +0 -1
- package/dist/api/protocol-v2/DeviceGetOnboardingStatus.d.ts +0 -6
- package/dist/api/protocol-v2/DeviceGetOnboardingStatus.d.ts.map +0 -1
- package/dist/api/protocol-v2/FactoryDeviceInfoSettings.d.ts +0 -7
- package/dist/api/protocol-v2/FactoryDeviceInfoSettings.d.ts.map +0 -1
- package/dist/api/protocol-v2/FactoryGetDeviceInfo.d.ts +0 -6
- package/dist/api/protocol-v2/FactoryGetDeviceInfo.d.ts.map +0 -1
- package/dist/api/protocol-v2/FilesystemFixPermission.d.ts.map +0 -1
- package/dist/api/protocol-v2/GetProtoVersion.d.ts +0 -6
- package/dist/api/protocol-v2/GetProtoVersion.d.ts.map +0 -1
- package/dist/deviceProfile/legacyFeaturesView.d.ts +0 -5
- package/dist/deviceProfile/legacyFeaturesView.d.ts.map +0 -1
- package/src/api/protocol-v2/DevReboot.ts +0 -24
- package/src/api/protocol-v2/DeviceGetOnboardingStatus.ts +0 -16
- package/src/api/protocol-v2/FactoryDeviceInfoSettings.ts +0 -29
- package/src/deviceProfile/legacyFeaturesView.ts +0 -123
package/src/types/device.ts
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { EDeviceType } from '@onekeyfe/hd-shared';
|
|
1
|
+
import { EDeviceType, type EFirmwareType } from '@onekeyfe/hd-shared';
|
|
2
2
|
|
|
3
3
|
import type { IVersionArray } from './settings';
|
|
4
4
|
import type { PROTO } from '../constants';
|
|
5
|
-
import type { OneKeyDeviceCommType } from '@onekeyfe/hd-transport';
|
|
6
|
-
import type { DeviceProfile } from './api/getDeviceInfo';
|
|
5
|
+
import type { OneKeyDeviceCommType, ProtocolV2DeviceInfo } from '@onekeyfe/hd-transport';
|
|
7
6
|
|
|
8
7
|
export type DeviceStatus = 'available' | 'occupied' | 'used';
|
|
9
8
|
|
|
@@ -34,8 +33,7 @@ export type KnownDevice = {
|
|
|
34
33
|
name: string;
|
|
35
34
|
error?: typeof undefined;
|
|
36
35
|
mode: EOneKeyDeviceMode;
|
|
37
|
-
|
|
38
|
-
features?: PROTO.Features;
|
|
36
|
+
features?: Features;
|
|
39
37
|
sessionId?: string | null;
|
|
40
38
|
unavailableCapabilities: UnavailableCapabilities;
|
|
41
39
|
bleFirmwareVersion: IVersionArray | null;
|
|
@@ -88,35 +86,101 @@ export type SearchDevice = {
|
|
|
88
86
|
|
|
89
87
|
export type Device = KnownDevice;
|
|
90
88
|
|
|
91
|
-
type
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
89
|
+
export type DeviceFeaturesProtocol = 'V1' | 'V2' | 'unknown';
|
|
90
|
+
|
|
91
|
+
export type DeviceFeaturesMode =
|
|
92
|
+
| 'normal'
|
|
93
|
+
| 'bootloader'
|
|
94
|
+
| 'notInitialized'
|
|
95
|
+
| 'backupMode'
|
|
96
|
+
| 'unknown';
|
|
97
|
+
|
|
98
|
+
export type DeviceFeaturesVerify = {
|
|
99
|
+
firmwareBuildId?: string;
|
|
100
|
+
firmwareHash?: string;
|
|
101
|
+
bootloaderBuildId?: string;
|
|
102
|
+
bootloaderHash?: string;
|
|
103
|
+
boardBuildId?: string;
|
|
104
|
+
boardHash?: string;
|
|
105
|
+
bleBuildId?: string;
|
|
106
|
+
bleHash?: string;
|
|
107
|
+
se01BuildId?: string;
|
|
108
|
+
se01Hash?: string;
|
|
109
|
+
se02BuildId?: string;
|
|
110
|
+
se02Hash?: string;
|
|
111
|
+
se03BuildId?: string;
|
|
112
|
+
se03Hash?: string;
|
|
113
|
+
se04BuildId?: string;
|
|
114
|
+
se04Hash?: string;
|
|
115
|
+
se01BootBuildId?: string;
|
|
116
|
+
se01BootHash?: string;
|
|
117
|
+
se02BootBuildId?: string;
|
|
118
|
+
se02BootHash?: string;
|
|
119
|
+
se03BootBuildId?: string;
|
|
120
|
+
se03BootHash?: string;
|
|
121
|
+
se04BootBuildId?: string;
|
|
122
|
+
se04BootHash?: string;
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
export type DeviceFeaturesRaw = {
|
|
126
|
+
protocolV1Features?: PROTO.Features;
|
|
127
|
+
protocolV1OneKeyFeatures?: OnekeyFeatures;
|
|
128
|
+
protocolV2DeviceInfo?: ProtocolV2DeviceInfo;
|
|
129
|
+
};
|
|
130
|
+
|
|
131
|
+
export type Features = {
|
|
132
|
+
protocol: DeviceFeaturesProtocol;
|
|
133
|
+
protocolVersion?: number | null;
|
|
134
|
+
deviceType: IDeviceType;
|
|
135
|
+
firmwareType: EFirmwareType;
|
|
136
|
+
model: string | null;
|
|
137
|
+
vendor: string | null;
|
|
138
|
+
deviceId: string | null;
|
|
139
|
+
serialNo: string;
|
|
140
|
+
label: string | null;
|
|
141
|
+
bleName: string | null;
|
|
142
|
+
capabilities: Array<number | string>;
|
|
143
|
+
mode: DeviceFeaturesMode;
|
|
144
|
+
initialized: boolean | null;
|
|
145
|
+
bootloaderMode: boolean | null;
|
|
146
|
+
unlocked: boolean | null;
|
|
147
|
+
firmwarePresent: boolean | null;
|
|
148
|
+
passphraseProtection: boolean | null;
|
|
149
|
+
pinProtection: boolean | null;
|
|
150
|
+
backupRequired: boolean | null;
|
|
151
|
+
noBackup: boolean | null;
|
|
152
|
+
unfinishedBackup: boolean | null;
|
|
153
|
+
recoveryMode: boolean | null;
|
|
154
|
+
language: string | null;
|
|
155
|
+
bleEnabled: boolean | null;
|
|
156
|
+
sdCardPresent: boolean | null;
|
|
157
|
+
sdProtection: boolean | null;
|
|
158
|
+
wipeCodeProtection: boolean | null;
|
|
159
|
+
passphraseAlwaysOnDevice: boolean | null;
|
|
160
|
+
attachToPinEnabled?: boolean | null;
|
|
161
|
+
safetyChecks: string | null;
|
|
162
|
+
autoLockDelayMs: number | null;
|
|
163
|
+
displayRotation: number | null;
|
|
164
|
+
experimentalFeatures: boolean | null;
|
|
165
|
+
firmwareVersion: string | null;
|
|
166
|
+
bootloaderVersion: string | null;
|
|
167
|
+
boardVersion: string | null;
|
|
168
|
+
bleVersion: string | null;
|
|
169
|
+
se01Version?: string | null;
|
|
170
|
+
se02Version?: string | null;
|
|
171
|
+
se03Version?: string | null;
|
|
172
|
+
se04Version?: string | null;
|
|
173
|
+
se01BootVersion?: string | null;
|
|
174
|
+
se02BootVersion?: string | null;
|
|
175
|
+
se03BootVersion?: string | null;
|
|
176
|
+
se04BootVersion?: string | null;
|
|
177
|
+
seVersion?: string | null;
|
|
178
|
+
verify?: DeviceFeaturesVerify;
|
|
179
|
+
sessionId: string | null;
|
|
180
|
+
passphraseState?: string;
|
|
181
|
+
unlockedAttachPin?: boolean;
|
|
182
|
+
raw?: DeviceFeaturesRaw;
|
|
183
|
+
};
|
|
120
184
|
|
|
121
185
|
export type OnekeyFeatures = PROTO.OnekeyFeatures;
|
|
122
186
|
|
package/src/types/params.ts
CHANGED
package/src/types/settings.ts
CHANGED
|
@@ -40,6 +40,40 @@ export type IVersionArray = [number, number, number];
|
|
|
40
40
|
|
|
41
41
|
export type ILocale = 'zh-CN' | 'en-US';
|
|
42
42
|
|
|
43
|
+
export type IProtocolV2FirmwareComponentTarget =
|
|
44
|
+
| 'ROMLOADER'
|
|
45
|
+
| 'BOOTLOADER'
|
|
46
|
+
| 'APPLICATION_P1'
|
|
47
|
+
| 'APPLICATION_P2'
|
|
48
|
+
| 'COPROCESSOR'
|
|
49
|
+
| 'SE01'
|
|
50
|
+
| 'SE02'
|
|
51
|
+
| 'SE03'
|
|
52
|
+
| 'SE04';
|
|
53
|
+
|
|
54
|
+
export type IProtocolV2FirmwareComponent = {
|
|
55
|
+
target: IProtocolV2FirmwareComponentTarget;
|
|
56
|
+
url: string;
|
|
57
|
+
fingerprint?: string;
|
|
58
|
+
version?: IVersionArray;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/** Pro2 RESC bundle okpkg 描述,用于 FileWrite 直写方式增量同步资源 */
|
|
62
|
+
export type IProtocolV2ResourceBundle = {
|
|
63
|
+
/** bundle 名称,如 images / animation / translations / fonts_roobert */
|
|
64
|
+
name: string;
|
|
65
|
+
/** 下载 URL */
|
|
66
|
+
url: string;
|
|
67
|
+
/** 设备上的目标路径,如 vol0:/bundles/images/images.okpkg */
|
|
68
|
+
devicePath: string;
|
|
69
|
+
/** okpkg container 的 payload_version(用于 FileRead 比对跳过) */
|
|
70
|
+
version?: IVersionArray;
|
|
71
|
+
/** okpkg container 的 payload_hash(SHA3-512,用于 FileRead 比对) */
|
|
72
|
+
payloadHash?: string;
|
|
73
|
+
/** okpkg container 的 header_hash(SHA3-512,用于 FileRead 比对) */
|
|
74
|
+
headerHash?: string;
|
|
75
|
+
};
|
|
76
|
+
|
|
43
77
|
/** STM32 firmware config */
|
|
44
78
|
export type IFirmwareReleaseInfo = {
|
|
45
79
|
required: boolean;
|
|
@@ -58,6 +92,11 @@ export type IFirmwareReleaseInfo = {
|
|
|
58
92
|
bootloaderVersion?: IVersionArray;
|
|
59
93
|
displayBootloaderVersion?: IVersionArray;
|
|
60
94
|
bootloaderRelatedFirmwareVersion?: IVersionArray;
|
|
95
|
+
upgradeType?: 'payload-package-set' | string;
|
|
96
|
+
components?: Record<string, IProtocolV2FirmwareComponent>;
|
|
97
|
+
installOrder?: string[];
|
|
98
|
+
/** Pro2 RESC bundle 列表(FileWrite 直写增量同步模式) */
|
|
99
|
+
resourceBundles?: IProtocolV2ResourceBundle[];
|
|
61
100
|
bootloaderChangelog?: {
|
|
62
101
|
[k in ILocale]: string;
|
|
63
102
|
};
|
|
@@ -83,43 +122,16 @@ export type IBLEFirmwareReleaseInfo = {
|
|
|
83
122
|
};
|
|
84
123
|
};
|
|
85
124
|
|
|
86
|
-
type IKnownDevice = Exclude<IDeviceType, 'unknown'
|
|
125
|
+
type IKnownDevice = Exclude<IDeviceType, 'unknown'>;
|
|
87
126
|
|
|
88
|
-
/**
|
|
89
|
-
* Device firmware configuration map
|
|
90
|
-
*
|
|
91
|
-
* IMPORTANT: This type is used for firmware update logic.
|
|
92
|
-
* - DO NOT remove existing firmware fields
|
|
93
|
-
* - Only ADD new optional firmware fields for new versions
|
|
94
|
-
* - 'firmware' field is required for backward compatibility
|
|
95
|
-
* - 'ble' field is required for BLE firmware updates
|
|
96
|
-
*
|
|
97
|
-
* @example
|
|
98
|
-
* // When adding firmware-v8:
|
|
99
|
-
* // {
|
|
100
|
-
* // firmware: IFirmwareReleaseInfo[];
|
|
101
|
-
* // 'firmware-v2'?: IFirmwareReleaseInfo[];
|
|
102
|
-
* // 'firmware-v8'?: IFirmwareReleaseInfo[];
|
|
103
|
-
* // 'firmware-v8'?: IFirmwareReleaseInfo[]; // New
|
|
104
|
-
* // 'firmware-btc-v8'?: IFirmwareReleaseInfo[];
|
|
105
|
-
* // 'firmware-btc-v8'?: IFirmwareReleaseInfo[]; // New
|
|
106
|
-
* // ble: IBLEFirmwareReleaseInfo[];
|
|
107
|
-
* // }
|
|
108
|
-
*/
|
|
109
127
|
export type DeviceTypeMap = {
|
|
110
128
|
[k in IKnownDevice]: {
|
|
111
|
-
/** Base firmware field (required for backward compatibility) */
|
|
112
129
|
firmware: IFirmwareReleaseInfo[];
|
|
113
|
-
/**
|
|
130
|
+
/** Pro2 Protocol V2 payload package set */
|
|
131
|
+
'firmware-v1'?: IFirmwareReleaseInfo[];
|
|
114
132
|
'firmware-v2'?: IFirmwareReleaseInfo[];
|
|
115
|
-
/** Universal firmware v7 */
|
|
116
133
|
'firmware-v8'?: IFirmwareReleaseInfo[];
|
|
117
|
-
/** Bitcoin-only firmware v7 */
|
|
118
134
|
'firmware-btc-v8'?: IFirmwareReleaseInfo[];
|
|
119
|
-
// Future firmware versions should be added here as optional fields:
|
|
120
|
-
// 'firmware-v8'?: IFirmwareReleaseInfo[];
|
|
121
|
-
// 'firmware-btc-v8'?: IFirmwareReleaseInfo[];
|
|
122
|
-
/** BLE firmware (required) */
|
|
123
135
|
ble: IBLEFirmwareReleaseInfo[];
|
|
124
136
|
};
|
|
125
137
|
};
|
|
@@ -2,8 +2,7 @@ import type { Enum_Capability } from '@onekeyfe/hd-transport';
|
|
|
2
2
|
import type { Features } from '../types/device';
|
|
3
3
|
|
|
4
4
|
export const existCapability = (features?: Features, capability?: Enum_Capability) =>
|
|
5
|
-
|
|
6
|
-
features?.capabilities?.includes(capability);
|
|
5
|
+
capability !== undefined && features?.capabilities?.includes(capability);
|
|
7
6
|
|
|
8
7
|
export const requireCapability = (features: Features, capability: Enum_Capability) => {
|
|
9
8
|
if (!existCapability(features, capability)) {
|
|
@@ -13,14 +13,11 @@ import { PROTOBUF_MESSAGE_CONFIG } from '../data-manager/MessagesConfig';
|
|
|
13
13
|
import { getDeviceType } from './deviceInfoUtils';
|
|
14
14
|
import { getDeviceFirmwareVersion } from './deviceVersionUtils';
|
|
15
15
|
import { existCapability } from './capabilitieUtils';
|
|
16
|
+
import { getProtocolV2WalletSession } from '../protocols/protocol-v2/walletSession';
|
|
16
17
|
|
|
17
18
|
import type { Device } from '../device/Device';
|
|
18
19
|
import type { Features, IDeviceType, SupportFeatureType } from '../types';
|
|
19
20
|
|
|
20
|
-
// 生成的 GetPassphraseState 已包含 _only_main_pin / allow_create_attach_pin,
|
|
21
|
-
// 不再需要手动扩展字段。
|
|
22
|
-
type GetPassphraseStateMessage = GetPassphraseState;
|
|
23
|
-
|
|
24
21
|
export const getSupportProtocolV1MessageSchema = (
|
|
25
22
|
features: Features | undefined
|
|
26
23
|
): { messages: JSON; protocolV1MessageSchema: ProtocolV1MessageSchema } => {
|
|
@@ -93,12 +90,32 @@ export const getPassphraseStateWithRefreshDeviceInfo = async (
|
|
|
93
90
|
expectPassphraseState?: string;
|
|
94
91
|
onlyMainPin?: boolean;
|
|
95
92
|
allowCreateAttachPin?: boolean;
|
|
93
|
+
initSession?: boolean;
|
|
96
94
|
}
|
|
97
95
|
) => {
|
|
96
|
+
if (device.isProtocolV2()) {
|
|
97
|
+
if (!device.features) {
|
|
98
|
+
return {
|
|
99
|
+
passphraseState: undefined,
|
|
100
|
+
newSession: undefined,
|
|
101
|
+
unlockedAttachPin: undefined,
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
return getProtocolV2WalletSession(device, {
|
|
106
|
+
initSession: options?.initSession,
|
|
107
|
+
expectedPassphraseState: options?.expectPassphraseState,
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
|
|
98
111
|
const { features } = device;
|
|
99
112
|
const locked = features?.unlocked === false;
|
|
100
113
|
const deviceType = device.getCurrentDeviceType();
|
|
101
114
|
|
|
115
|
+
if (options?.initSession) {
|
|
116
|
+
device.clearInternalState();
|
|
117
|
+
}
|
|
118
|
+
|
|
102
119
|
const { passphraseState, newSession, unlockedAttachPin } = await getPassphraseState(device, {
|
|
103
120
|
...options,
|
|
104
121
|
});
|
|
@@ -123,21 +140,22 @@ export const getPassphraseStateWithRefreshDeviceInfo = async (
|
|
|
123
140
|
|
|
124
141
|
// Attach to pin try to fix internal state
|
|
125
142
|
const deviceId = device.getCurrentDeviceId();
|
|
126
|
-
|
|
127
|
-
device.
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
);
|
|
134
|
-
}
|
|
143
|
+
device.updateInternalState(
|
|
144
|
+
device.getCurrentPassphraseProtection() ?? false,
|
|
145
|
+
passphraseState,
|
|
146
|
+
deviceId,
|
|
147
|
+
newSession,
|
|
148
|
+
options?.initSession ? null : device.features?.sessionId
|
|
149
|
+
);
|
|
135
150
|
|
|
136
|
-
return {
|
|
151
|
+
return {
|
|
152
|
+
passphraseState,
|
|
153
|
+
newSession,
|
|
154
|
+
unlockedAttachPin: unlockedAttachPin ?? device.features?.unlockedAttachPin,
|
|
155
|
+
};
|
|
137
156
|
};
|
|
138
157
|
|
|
139
158
|
// 仅适用于 Protocol V1 的 Pro:Pro2 走独立版本线,不能套用 4.15.0 门槛
|
|
140
|
-
// (Pro2 在 getPassphraseState 中通过 isProtocolV2 直接判定支持)。
|
|
141
159
|
const supportProSeriesAttachPinPassphrase = (deviceType: IDeviceType, firmwareVersion: string) =>
|
|
142
160
|
deviceType === EDeviceType.Pro && semver.gte(firmwareVersion, '4.15.0');
|
|
143
161
|
|
|
@@ -147,6 +165,7 @@ export const getPassphraseState = async (
|
|
|
147
165
|
expectPassphraseState?: string;
|
|
148
166
|
onlyMainPin?: boolean;
|
|
149
167
|
allowCreateAttachPin?: boolean;
|
|
168
|
+
initSession?: boolean;
|
|
150
169
|
}
|
|
151
170
|
): Promise<{
|
|
152
171
|
passphraseState: string | undefined;
|
|
@@ -155,26 +174,29 @@ export const getPassphraseState = async (
|
|
|
155
174
|
}> => {
|
|
156
175
|
const { features, commands } = device;
|
|
157
176
|
|
|
158
|
-
//
|
|
159
|
-
if (!features
|
|
177
|
+
// 设备尚未建立任何状态时无法判定,保持旧的空返回语义
|
|
178
|
+
if (!features)
|
|
160
179
|
return { passphraseState: undefined, newSession: undefined, unlockedAttachPin: undefined };
|
|
161
180
|
|
|
162
181
|
const firmwareVersion = device.getCurrentFirmwareVersionString() ?? '0.0.0';
|
|
163
182
|
const deviceType = device.getCurrentDeviceType();
|
|
164
183
|
|
|
184
|
+
if (device.isProtocolV2()) {
|
|
185
|
+
return getProtocolV2WalletSession(device, {
|
|
186
|
+
initSession: options?.initSession,
|
|
187
|
+
expectedPassphraseState: options?.expectPassphraseState,
|
|
188
|
+
});
|
|
189
|
+
}
|
|
190
|
+
|
|
165
191
|
const supportAttachPinCapability = existCapability(
|
|
166
192
|
features,
|
|
167
193
|
Enum_Capability.Capability_AttachToPin
|
|
168
194
|
);
|
|
169
|
-
// Pro2 (Protocol V2) 协议自带 GetPassphraseState(10028),固件从首个版本即支持,
|
|
170
|
-
// 不依赖 Pro 系列的 4.15.0 版本线;V2 也没有 GetAddress Testnet 探测这条 legacy 回退路径。
|
|
171
195
|
const supportGetPassphraseState =
|
|
172
|
-
|
|
173
|
-
supportAttachPinCapability ||
|
|
174
|
-
supportProSeriesAttachPinPassphrase(deviceType, firmwareVersion);
|
|
196
|
+
supportAttachPinCapability || supportProSeriesAttachPinPassphrase(deviceType, firmwareVersion);
|
|
175
197
|
|
|
176
198
|
if (supportGetPassphraseState) {
|
|
177
|
-
const payload:
|
|
199
|
+
const payload: GetPassphraseState = options?.onlyMainPin
|
|
178
200
|
? { _only_main_pin: true }
|
|
179
201
|
: { passphrase_state: options?.expectPassphraseState };
|
|
180
202
|
if (options?.allowCreateAttachPin) {
|
|
@@ -278,6 +300,9 @@ export const getFirmwareUpdateField = ({
|
|
|
278
300
|
if (deviceType === EDeviceType.Pro) {
|
|
279
301
|
return latestFirmwareField;
|
|
280
302
|
}
|
|
303
|
+
if (deviceType === EDeviceType.Pro2) {
|
|
304
|
+
return 'firmware-v1';
|
|
305
|
+
}
|
|
281
306
|
return 'firmware';
|
|
282
307
|
};
|
|
283
308
|
/**
|
|
@@ -321,6 +346,10 @@ export const getFirmwareUpdateFieldArray = (
|
|
|
321
346
|
return ['firmware-v8'];
|
|
322
347
|
}
|
|
323
348
|
|
|
349
|
+
if (deviceType === 'pro2') {
|
|
350
|
+
return ['firmware-v1'];
|
|
351
|
+
}
|
|
352
|
+
|
|
324
353
|
return ['firmware'];
|
|
325
354
|
};
|
|
326
355
|
|
|
@@ -340,12 +369,8 @@ export const fixFeaturesFirmwareVersion = (features: Features): Features => {
|
|
|
340
369
|
// fix Touch、Pro device when bootloader version is lower than 2.5.2, the features returned do not have firmware_version error
|
|
341
370
|
const tempFeatures = { ...features };
|
|
342
371
|
|
|
343
|
-
if (tempFeatures.
|
|
344
|
-
tempFeatures.
|
|
345
|
-
}
|
|
346
|
-
|
|
347
|
-
if (tempFeatures.onekey_version && !semver.valid(tempFeatures.onekey_version)) {
|
|
348
|
-
tempFeatures.onekey_version = fixVersion(tempFeatures.onekey_version);
|
|
372
|
+
if (tempFeatures.firmwareVersion && !semver.valid(tempFeatures.firmwareVersion)) {
|
|
373
|
+
tempFeatures.firmwareVersion = fixVersion(tempFeatures.firmwareVersion);
|
|
349
374
|
}
|
|
350
375
|
|
|
351
376
|
return tempFeatures;
|
|
@@ -14,30 +14,12 @@ export const getDeviceType = (features?: Features): IDeviceType => {
|
|
|
14
14
|
if (!features || typeof features !== 'object') {
|
|
15
15
|
return EDeviceType.Unknown;
|
|
16
16
|
}
|
|
17
|
+
if (features.deviceType) {
|
|
18
|
+
return features.deviceType;
|
|
19
|
+
}
|
|
17
20
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
case 'CLASSIC':
|
|
21
|
-
return EDeviceType.Classic;
|
|
22
|
-
case 'CLASSIC1S':
|
|
23
|
-
return EDeviceType.Classic1s;
|
|
24
|
-
case 'MINI':
|
|
25
|
-
return EDeviceType.Mini;
|
|
26
|
-
case 'TOUCH':
|
|
27
|
-
return EDeviceType.Touch;
|
|
28
|
-
case 'PRO':
|
|
29
|
-
return EDeviceType.Pro;
|
|
30
|
-
case 'PRO2':
|
|
31
|
-
case 'pro2':
|
|
32
|
-
return EDeviceType.Pro2;
|
|
33
|
-
case 'PURE':
|
|
34
|
-
return EDeviceType.ClassicPure;
|
|
35
|
-
default:
|
|
36
|
-
// future And old device onekey_device_type is empty
|
|
37
|
-
if (!isEmpty(features.onekey_serial_no)) {
|
|
38
|
-
return EDeviceType.Unknown;
|
|
39
|
-
}
|
|
40
|
-
// old device type
|
|
21
|
+
if (features.model === EDeviceType.Pro2 || features.model === 'pro2') {
|
|
22
|
+
return EDeviceType.Pro2;
|
|
41
23
|
}
|
|
42
24
|
|
|
43
25
|
// low version hardware
|
|
@@ -45,7 +27,7 @@ export const getDeviceType = (features?: Features): IDeviceType => {
|
|
|
45
27
|
const serialNo = getDeviceUUID(features);
|
|
46
28
|
|
|
47
29
|
// not exist serialNo, bootloader mode, model 1 is classic
|
|
48
|
-
if (isEmpty(serialNo) && features.
|
|
30
|
+
if (isEmpty(serialNo) && features.bootloaderMode === true && features.model === '1') {
|
|
49
31
|
return EDeviceType.Classic;
|
|
50
32
|
}
|
|
51
33
|
|
|
@@ -59,6 +41,7 @@ export const getDeviceType = (features?: Features): IDeviceType => {
|
|
|
59
41
|
if (miniFlag.toLowerCase() === 'mi') return EDeviceType.Mini;
|
|
60
42
|
if (miniFlag.toLowerCase() === 'tc') return EDeviceType.Touch;
|
|
61
43
|
if (miniFlag.toLowerCase() === 'pr') return EDeviceType.Pro;
|
|
44
|
+
if (miniFlag.toLowerCase() === 'p2') return EDeviceType.Pro2;
|
|
62
45
|
|
|
63
46
|
// unknown device
|
|
64
47
|
return EDeviceType.Unknown;
|
|
@@ -89,15 +72,14 @@ export const getDeviceTypeByBleName = (name?: string): IDeviceType => {
|
|
|
89
72
|
*/
|
|
90
73
|
export const getDeviceBleName = (features?: Features): string | null => {
|
|
91
74
|
if (features == null) return null;
|
|
92
|
-
return features.
|
|
75
|
+
return features.bleName || null;
|
|
93
76
|
};
|
|
94
77
|
|
|
95
78
|
/**
|
|
96
79
|
* Get Connected Device UUID by features
|
|
97
80
|
*/
|
|
98
81
|
export const getDeviceUUID = (features: Features) => {
|
|
99
|
-
|
|
100
|
-
return serialNo ?? '';
|
|
82
|
+
return features.serialNo ?? '';
|
|
101
83
|
};
|
|
102
84
|
|
|
103
85
|
/**
|
|
@@ -163,8 +145,8 @@ export const getFirmwareType = (features: Features | undefined) => {
|
|
|
163
145
|
if (!features) {
|
|
164
146
|
return EFirmwareType.Universal;
|
|
165
147
|
}
|
|
166
|
-
if (features.
|
|
167
|
-
return
|
|
148
|
+
if (features.firmwareType) {
|
|
149
|
+
return features.firmwareType;
|
|
168
150
|
}
|
|
169
151
|
// old firmware
|
|
170
152
|
return features?.capabilities?.length > 0 &&
|
|
@@ -8,12 +8,8 @@ import type { Features, IVersionArray } from '../types';
|
|
|
8
8
|
export const getDeviceFirmwareVersion = (features: Features | undefined): IVersionArray => {
|
|
9
9
|
if (!features) return [0, 0, 0];
|
|
10
10
|
|
|
11
|
-
if (semver.valid(features.
|
|
12
|
-
return features.
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
if (semver.valid(features.onekey_version)) {
|
|
16
|
-
return features.onekey_version?.split('.') as unknown as IVersionArray;
|
|
11
|
+
if (features.firmwareVersion && semver.valid(features.firmwareVersion)) {
|
|
12
|
+
return features.firmwareVersion.split('.').map(Number) as IVersionArray;
|
|
17
13
|
}
|
|
18
14
|
|
|
19
15
|
return [0, 0, 0];
|
|
@@ -23,7 +19,7 @@ export const getDeviceFirmwareVersion = (features: Features | undefined): IVersi
|
|
|
23
19
|
* Get Connected Device bluetooth firmware version by features
|
|
24
20
|
*/
|
|
25
21
|
export const getDeviceBLEFirmwareVersion = (features: Features): IVersionArray => {
|
|
26
|
-
const bleVer = features?.
|
|
22
|
+
const bleVer = features?.bleVersion;
|
|
27
23
|
|
|
28
24
|
if (!bleVer) {
|
|
29
25
|
return [0, 0, 0];
|
|
@@ -46,24 +42,10 @@ export const getDeviceBootloaderVersion = (features: Features | undefined): IVer
|
|
|
46
42
|
if (!features) return [0, 0, 0];
|
|
47
43
|
|
|
48
44
|
// classic1s 3.5.0 pro 4.6.0
|
|
49
|
-
if (semver.valid(features.
|
|
50
|
-
return features.
|
|
45
|
+
if (features.bootloaderVersion && semver.valid(features.bootloaderVersion)) {
|
|
46
|
+
return features.bootloaderVersion.split('.').map(Number) as IVersionArray;
|
|
51
47
|
}
|
|
52
48
|
|
|
53
|
-
// low version hardware
|
|
54
|
-
if (!features.bootloader_version) {
|
|
55
|
-
if (features.bootloader_mode) {
|
|
56
|
-
return [
|
|
57
|
-
features?.major_version ?? 0,
|
|
58
|
-
features?.minor_version ?? 0,
|
|
59
|
-
features?.patch_version ?? 0,
|
|
60
|
-
];
|
|
61
|
-
}
|
|
62
|
-
return [0, 0, 0];
|
|
63
|
-
}
|
|
64
|
-
if (semver.valid(features.bootloader_version)) {
|
|
65
|
-
return features.bootloader_version?.split('.') as unknown as IVersionArray;
|
|
66
|
-
}
|
|
67
49
|
return [0, 0, 0];
|
|
68
50
|
};
|
|
69
51
|
|
|
@@ -71,8 +53,8 @@ export const getDeviceBootloaderVersion = (features: Features | undefined): IVer
|
|
|
71
53
|
* Get Connected Device boardloader version by features
|
|
72
54
|
*/
|
|
73
55
|
export const getDeviceBoardloaderVersion = (features: Features): IVersionArray => {
|
|
74
|
-
if (semver.valid(features
|
|
75
|
-
return features
|
|
56
|
+
if (features?.boardVersion && semver.valid(features.boardVersion)) {
|
|
57
|
+
return features.boardVersion.split('.').map(Number) as IVersionArray;
|
|
76
58
|
}
|
|
77
59
|
|
|
78
60
|
return [0, 0, 0];
|
|
@@ -5,7 +5,7 @@ import type { Features } from '../types';
|
|
|
5
5
|
/**
|
|
6
6
|
* 检测故障固件设备
|
|
7
7
|
* 检测规则:
|
|
8
|
-
* - 序列号范围:21032200001 到 21032201500
|
|
8
|
+
* - 序列号范围:21032200001 到 21032201500
|
|
9
9
|
* - SE版本为 1.1.0.2
|
|
10
10
|
*
|
|
11
11
|
* 对齐之前版本的检测逻辑
|
|
@@ -13,13 +13,13 @@ import type { Features } from '../types';
|
|
|
13
13
|
export const findDefectiveBatchDevice = (features: Features) => {
|
|
14
14
|
if (!features) return;
|
|
15
15
|
|
|
16
|
-
const {
|
|
17
|
-
if (!
|
|
16
|
+
const { serialNo, seVersion } = features;
|
|
17
|
+
if (!serialNo) return;
|
|
18
18
|
|
|
19
|
-
const versionNum = +
|
|
19
|
+
const versionNum = +serialNo.slice(5);
|
|
20
20
|
if (Number.isNaN(versionNum)) return;
|
|
21
21
|
|
|
22
|
-
return versionNum >= 21032200001 && versionNum <= 21032201500 &&
|
|
22
|
+
return versionNum >= 21032200001 && versionNum <= 21032201500 && seVersion === '1.1.0.2';
|
|
23
23
|
};
|
|
24
24
|
|
|
25
25
|
/**
|
|
@@ -29,7 +29,7 @@ export const getDefectiveDeviceInfo = (features: Features) => {
|
|
|
29
29
|
if (!findDefectiveBatchDevice(features)) return null;
|
|
30
30
|
const serialNo = getDeviceUUID(features);
|
|
31
31
|
const deviceType = getDeviceType(features);
|
|
32
|
-
const seVersion = features
|
|
32
|
+
const { seVersion } = features;
|
|
33
33
|
|
|
34
34
|
return {
|
|
35
35
|
serialNo,
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { BaseMethod } from '../BaseMethod';
|
|
2
|
-
import type { DeviceRebootParams } from './helpers';
|
|
3
|
-
export default class DevReboot extends BaseMethod<DeviceRebootParams> {
|
|
4
|
-
init(): void;
|
|
5
|
-
run(): Promise<import("packages/hd-transport/dist").Success>;
|
|
6
|
-
}
|
|
7
|
-
//# sourceMappingURL=DevReboot.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DevReboot.d.ts","sourceRoot":"","sources":["../../../src/api/protocol-v2/DevReboot.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAG3C,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAEpD,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,UAAU,CAAC,kBAAkB,CAAC;IACnE,IAAI;IAWE,GAAG;CAMV"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DeviceGetDeviceInfo.d.ts","sourceRoot":"","sources":["../../../src/api/protocol-v2/DeviceGetDeviceInfo.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,MAAM,0BAA0B,GAAG;IACvC,EAAE,CAAC,EAAE,OAAO,CAAC;IACb,EAAE,CAAC,EAAE,OAAO,CAAC;IACb,EAAE,CAAC,EAAE,OAAO,CAAC;IACb,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,MAAM,MAAM,wBAAwB,GAAG;IACrC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,MAAM,MAAM,yBAAyB,GAAG;IACtC,OAAO,CAAC,EAAE,0BAA0B,CAAC;IACrC,KAAK,CAAC,EAAE,wBAAwB,CAAC;CAClC,CAAC;AAmDF,MAAM,CAAC,OAAO,OAAO,mBAAoB,SAAQ,UAAU,CAAC;IAC1D,OAAO,EAAE,0BAA0B,CAAC;IACpC,KAAK,EAAE,wBAAwB,CAAC;CACjC,CAAC;IACA,IAAI;IAmBE,GAAG;CAgBV"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"DeviceGetOnboardingStatus.d.ts","sourceRoot":"","sources":["../../../src/api/protocol-v2/DeviceGetOnboardingStatus.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,CAAC,OAAO,OAAO,yBAA0B,SAAQ,UAAU;IAC/D,IAAI;IAQE,GAAG;CAIV"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { BaseMethod } from '../BaseMethod';
|
|
2
|
-
import type { FactoryDeviceInfoSettingsParams } from './helpers';
|
|
3
|
-
export default class FactoryDeviceInfoSettings extends BaseMethod<FactoryDeviceInfoSettingsParams> {
|
|
4
|
-
init(): void;
|
|
5
|
-
run(): Promise<import("packages/hd-transport/dist").Success>;
|
|
6
|
-
}
|
|
7
|
-
//# sourceMappingURL=FactoryDeviceInfoSettings.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FactoryDeviceInfoSettings.d.ts","sourceRoot":"","sources":["../../../src/api/protocol-v2/FactoryDeviceInfoSettings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,OAAO,KAAK,EAAE,+BAA+B,EAAE,MAAM,WAAW,CAAC;AAEjE,MAAM,CAAC,OAAO,OAAO,yBAA0B,SAAQ,UAAU,CAAC,+BAA+B,CAAC;IAChG,IAAI;IAeE,GAAG;CAQV"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FactoryGetDeviceInfo.d.ts","sourceRoot":"","sources":["../../../src/api/protocol-v2/FactoryGetDeviceInfo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,MAAM,CAAC,OAAO,OAAO,oBAAqB,SAAQ,UAAU;IAC1D,IAAI;IAQE,GAAG;CAQV"}
|