From 26b39901c3c6194d84d1b55b601de71a7bbd3ccc Mon Sep 17 00:00:00 2001 From: "Vipul Gupta (@vipulgupta2048)" Date: Tue, 17 Dec 2024 21:14:47 +0530 Subject: [PATCH] patch: checking Signed-off-by: Vipul Gupta (@vipulgupta2048) --- src/models/device-type.ts | 45 ++++++++++++++++++++ tests/integration/models/device-type.spec.ts | 2 +- 2 files changed, 46 insertions(+), 1 deletion(-) diff --git a/src/models/device-type.ts b/src/models/device-type.ts index 72d282b95..e7dffec18 100644 --- a/src/models/device-type.ts +++ b/src/models/device-type.ts @@ -452,6 +452,51 @@ const getDeviceTypeModel = function (deps: InjectedDependenciesParam) { $select: 'contract', }, )); + if (contract.slug === 'jetson-orin-nano-devkit-nvme') { + contract = ` + { + "slug": "jetson-orin-nano-devkit-nvme", + "version": "1", + "type": "hw.device-type", + "aliases": [], + "name": "Nvidia Jetson Orin Nano 8GB (SD) Devkit NVME", + "assets": { + "logo": { + "url": "./jetson-orin-nano-devkit-nvme.svg", + "name": "logo" + } + }, + "data": { + "arch": "aarch64", + "hdmi": true, + "led": false, + "connectivity": { + "bluetooth": true, + "wifi": true + }, + "storage": { + "internal": true + }, + "media": { + "defaultBoot": "internal", + "altBoot": ["usb_mass_storage"] + }, + "is_private": false + }, + "partials": { + "instructions": [ + "For balenaOS versions v6.1.16 and newer, please ensure your device is running UEFI firmware version 36.3. Check and update the firmware version before proceeding.", + "For balenaOS versions older than v6.1.16, please refer to the {{name}} legacy flashing guide." + ], + "bootDeviceExternal": [ + "Insert a NVME drive in the Devkit and power up the {{name}}." + ], + "flashIndicator": ["power LED is off"], + "bootDevice": ["Power up the {{name}}. If you have a display or a debug UART cable connected to the device, a progress bar will show up while the UEFI firmware is updated. Please do not interrupt this process by turning off power or rebooting the device."] + } +} + ` + } if (!contract?.partials) { throw new Error( `Instruction partials not defined for ${deviceTypeSlugOrContract}`, diff --git a/tests/integration/models/device-type.spec.ts b/tests/integration/models/device-type.spec.ts index 8b96f7f48..9ecfa2c48 100644 --- a/tests/integration/models/device-type.spec.ts +++ b/tests/integration/models/device-type.spec.ts @@ -138,7 +138,7 @@ describe('Device Type model', function () { ], ], [ - 'jetson-nano', + 'jetson-orin-nano-devkit-nvme', [ 'To provision Nvidia Jetson Nano SD-CARD, follow the instructions using our Jetson Flash tool to make the process more streamlined.', ],