Skip to content

Commit

Permalink
feat(llm) [DSDK-308]: nanox ble update
Browse files Browse the repository at this point in the history
  • Loading branch information
valpinkman committed Jun 4, 2024
1 parent 5b31bcb commit ab16901
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 7 deletions.
5 changes: 5 additions & 0 deletions .changeset/brave-dolphins-admire.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"live-mobile": minor
---

Enable Nano X BLE Fw update on LLM
3 changes: 2 additions & 1 deletion apps/ledger-live-mobile/src/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -4329,7 +4329,8 @@
"installUpdate": {
"titleInactive": "Install update",
"titleActive": "Installing update",
"description": "{{deviceName}} will restart multiple times.\n\nTo complete the update, unlock {{deviceName}} with your PIN after installation has finished."
"description": "{{deviceName}} will restart multiple times.\n\nTo complete the update, unlock {{deviceName}} with your PIN after installation has finished.",
"descriptionNanoXBle": "{{deviceName}} will restart multiple times.\n\nIt might be necessary to turn it back on manually.\n\nTo complete the update, unlock {{deviceName}} with your PIN after installation has finished."
},
"restoreSettings": {
"earlySecurityCheck": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { DeviceModelId } from "@ledgerhq/devices";
import isFirmwareUpdateVersionSupported from "@ledgerhq/live-common/hw/isFirmwareUpdateVersionSupported";
import { Device } from "@ledgerhq/live-common/hw/actions/types";

const NEW_UX_SUPPORTED_DEVICES = [DeviceModelId.stax, DeviceModelId.europa];
const NEW_UX_SUPPORTED_DEVICES = [DeviceModelId.stax, DeviceModelId.europa, DeviceModelId.nanoX];

export function isNewFirmwareUpdateUxSupported(deviceModelId?: DeviceModelId) {
return deviceModelId ? NEW_UX_SUPPORTED_DEVICES.includes(deviceModelId) : false;
Expand Down
14 changes: 9 additions & 5 deletions apps/ledger-live-mobile/src/screens/FirmwareUpdate/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Image } from "react-native";
import { getDeviceModel } from "@ledgerhq/devices";
import { DeviceModelId, getDeviceModel } from "@ledgerhq/devices";
import { isEqual } from "lodash/fp";
import {
updateFirmwareActionArgs,
Expand Down Expand Up @@ -365,9 +365,13 @@ export const FirmwareUpdate = ({
<>
<TrackScreen category={"Update device - Step 2: installing updates"} avoidDuplicates />
<Text variant="bodyLineHeight" color="neutral.c80">
{t("FirmwareUpdate.steps.installUpdate.description", {
deviceName: productName,
})}
{!device.wired && device.modelId === DeviceModelId.nanoX
? t("FirmwareUpdate.steps.installUpdate.descriptionNanoXBle", {
deviceName: productName,
})
: t("FirmwareUpdate.steps.installUpdate.description", {
deviceName: productName,
})}
</Text>
</>
),
Expand All @@ -390,7 +394,7 @@ export const FirmwareUpdate = ({
),
},
}),
[isBeforeOnboarding, t, productName, restoreSteps],
[isBeforeOnboarding, t, productName, restoreSteps, device.wired, device.modelId],
);

useEffect(() => {
Expand Down

0 comments on commit ab16901

Please sign in to comment.