Skip to content

Commit

Permalink
Update functions.sh: fix check for RPi cameras
Browse files Browse the repository at this point in the history
The camera number is the first character on the line.
  • Loading branch information
EricClaeys authored Jul 11, 2024
1 parent 9968f27 commit e1e4518
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions scripts/functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -277,9 +277,10 @@ function get_connected_cameras_info()
echo -e "RPi\t0\timx477\t[4056x3040]"

else
# Input: camera_number : sensor [other stuff]
# Input:
# camera_number : sensor [other stuff]
LIBCAMERA_LOG_LEVELS=FATAL "${CMD_TO_USE_}" --list-cameras 2>&1 |
gawk '{ if ($1 ~ /[0-9]/) print $3; }'
gawk '{ if ($1 ~ /^[0-9]/) print $3; }'
fi
fi

Expand Down

0 comments on commit e1e4518

Please sign in to comment.