Skip to content

Conversation

@AviaAv
Copy link
Contributor

@AviaAv AviaAv commented Nov 10, 2025

Tracked on: [LRS-1349]

@AviaAv AviaAv requested review from Nir-Az and Copilot November 10, 2025 07:58
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for D555 devices to the firmware update test. The changes enable testing firmware updates for D555 devices alongside the existing D400 device support, including handling device-specific differences like the absence of an update counter in D555.

Key changes:

  • Added D555 device support with a dedicated command-line argument for custom D555 firmware
  • Refactored firmware selection logic to handle both D400 and D555 devices
  • Updated device detection to use serial numbers for tracking devices through the update process

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
unit-tests/test-fw-update.py Added D555 device support, refactored firmware path handling, improved device tracking with serial numbers, and added D555-specific logic for update counter
unit-tests/run-unit-tests.py Added command-line argument support for custom D555 firmware path

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

print( ' --no-reset Do not try to reset any devices, with or without a hub' )
print( ' --hub-reset If a hub is available, reset the hub itself' )
print( ' --custom-fw-d400 If custom fw provided flash it if its different that the current fw installed' )
print( ' --custom-fw-d555 If custom fw provided flash it if its different that the current fw installed' )
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems relevant to all D500

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@OhadMeir we cannot use it for D500 as D555 and D585 does not share the same FW image.
Need to revert back to D555 only.
When D585 be added we will add another field for it

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was under the impression that with D585 new FW update process uses a single file similar to the D555.
Can't the same procedure be used for both?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

run-unit-tests.py is called once for all cameras, same flow should work on D555 and D585, but the input file is different, so we need 2 parameters.
Does this answer?
If not lets talk :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As discussed, leave D555

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted changes


if product_line == "D400":
size = 0x2
elif "D555" in product_name:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same, check D500 product line, not D555 specific

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's OK to keep as all D500 does not have a counter

@AviaAv AviaAv requested review from Nir-Az and OhadMeir November 12, 2025 13:30
print( ' --no-reset Do not try to reset any devices, with or without a hub' )
print( ' --hub-reset If a hub is available, reset the hub itself' )
print( ' --custom-fw-d400 If custom fw provided flash it if its different that the current fw installed' )
print( ' --custom-fw-d500 If custom fw provided flash it if its different that the current fw installed' )
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

d555

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted

longopts=['help', 'verbose', 'debug', 'quiet', 'regex=', 'stdout', 'tag=', 'list-tags',
'list-tests', 'no-exceptions', 'context=', 'repeat=', 'retry=', 'config=', 'no-reset', 'hub-reset',
'rslog', 'skip-disconnected', 'live', 'not-live', 'device=', 'exclude-device=', 'test-dir=','skip-regex=','custom-fw-d400='] )
'rslog', 'skip-disconnected', 'live', 'not-live', 'device=', 'exclude-device=', 'test-dir=','skip-regex=','custom-fw-d400=','custom-fw-d500='] )
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

d555

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted

parser = argparse.ArgumentParser(description="Test firmware update")
parser.add_argument('--custom-fw-d400', type=str, help='Path to custom firmware file')
parser.add_argument('--custom-fw-d400', type=str, help='Path to custom D400 firmware file')
parser.add_argument('--custom-fw-d500', type=str, help='Path to custom D500 firmware file')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

555

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted

custom_fw_version = None
if product_line == "D400" and args.custom_fw_d400:
custom_fw_path = args.custom_fw_d400
elif product_line == "D500" and args.custom_fw_d500:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

camera_name include D555

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reverted

image_file = find_image_or_exit(product_name)
# always flash signed fw when device on recovery before flashing anything else
# on D500 we currently do not have bundled FW
image_file = find_image_or_exit(product_name) if not product_line == "D500" else custom_fw_path
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

d555 all over

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reverted

@Nir-Az
Copy link
Collaborator

Nir-Az commented Nov 13, 2025

@AviaAv please avoid doing commit --amend during a CR as now we cannot see the new changed and need to review all changes again..

@Nir-Az Nir-Az merged commit e5faf0b into realsenseai:development Nov 17, 2025
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants