Skip to content

Commit

Permalink
Clarify camera type response
Browse files Browse the repository at this point in the history
  • Loading branch information
brickbots committed Jan 21, 2025
1 parent 018b2f2 commit 47d9eba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions python/PiFinder/ui/callbacks.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ def switch_cam_imx462(ui_module: UIModule) -> None:


def get_camera_type(ui_module: UIModule) -> list:
print("Looking for cammmm")
cam_id = "000"

# read config.txt into a list
Expand All @@ -121,7 +120,9 @@ def get_camera_type(ui_module: UIModule) -> list:
for line in boot_lines:
if line.startswith("dtoverlay=imx"):
cam_id = line[10:16]
print("found cam " + cam_id)
# imx462 uses imx290 driver
if cam_id == "imx290":
cam_id = "imx462"

return [cam_id]

Expand Down
2 changes: 1 addition & 1 deletion python/PiFinder/ui/menu_structure.py
Original file line number Diff line number Diff line change
Expand Up @@ -861,7 +861,7 @@
{
"name": "v3 - imx462",
"callback": callbacks.switch_cam_imx462,
"value": "imx290",
"value": "imx462",
},
],
},
Expand Down

0 comments on commit 47d9eba

Please sign in to comment.