Commit 4d3e65a 1 parent 1fbeddd commit 4d3e65a Copy full SHA for 4d3e65a
File tree 2 files changed +5
-3
lines changed
2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ detect_libcamera() {
65
65
[[ -x " $( command -v libcamera-hello) " ]]; then
66
66
avail=" $( libcamera-hello --list-cameras | sed ' /^\[.*\].*/d' | awk ' NR==1 {print $1}' ) "
67
67
if [[ " ${avail} " = " Available" ]]; then
68
- echo " 1 "
68
+ get_libcamera_path | wc -l
69
69
else
70
70
echo " 0"
71
71
fi
Original file line number Diff line number Diff line change @@ -88,7 +88,7 @@ function print_cfg {
88
88
}
89
89
90
90
function print_cams {
91
- local total v4l
91
+ local device total v4l
92
92
v4l=" $( find /dev/v4l/by-id/ -iname " *index0" 2> /dev/null | wc -l) "
93
93
libcamera=" $( detect_libcamera) "
94
94
legacy=" $( detect_legacy) "
@@ -100,7 +100,9 @@ function print_cams {
100
100
log_msg " INFO: Found ${total} total available Device(s)"
101
101
fi
102
102
if [[ " ${libcamera} " -ne 0 ]]; then
103
- log_msg " Detected 'libcamera' device -> $( get_libcamera_path) "
103
+ for device in $( get_libcamera_path) ; do
104
+ log_msg " Detected 'libcamera' device -> ${device} "
105
+ done
104
106
fi
105
107
if [[ " ${legacy} " -ne 0 ]]; then
106
108
raspicam=" $( v4l2-ctl --list-devices | grep -A1 -e ' mmal' | \
You can’t perform that action at this time.
0 commit comments