rules/uv4l: Don't hard code raspicam script.
This commit is contained in:
parent
eeefa5908d
commit
db04cf06cb
@ -22,11 +22,6 @@ post_unpack()
|
|||||||
{
|
{
|
||||||
mv "../etc" "../uv4l-$version/"
|
mv "../etc" "../uv4l-$version/"
|
||||||
mv "../usr" "../uv4l-$version/"
|
mv "../usr" "../uv4l-$version/"
|
||||||
touch startStreamRaspiCam.sh
|
|
||||||
echo "#!/bin/sh" >> startStreamRaspiCam.sh
|
|
||||||
echo "killall uv4l" >> startStreamRaspiCam.sh
|
|
||||||
echo "modprobe cuse" >> startStreamRaspiCam.sh
|
|
||||||
echo "uv4l -nopreview --auto-video_nr --driver raspicam --encoding h264 --width 1080 --height 720 --framerate 12 --quality 8 --server-option '--port=9090' --server-option '--max-queued-connections=30' --server-option '--max-streams=25' --server-option '--max-threads=29'" >> startStreamRaspiCam.sh
|
|
||||||
}
|
}
|
||||||
|
|
||||||
host_install()
|
host_install()
|
||||||
@ -39,7 +34,8 @@ target_install()
|
|||||||
{
|
{
|
||||||
$cmd_cp -r "usr/lib/"* "$cfg_dir_rootfs/usr/lib/"
|
$cmd_cp -r "usr/lib/"* "$cfg_dir_rootfs/usr/lib/"
|
||||||
$cmd_cp -r "usr/bin/"* "$cfg_dir_rootfs/usr/bin/"
|
$cmd_cp -r "usr/bin/"* "$cfg_dir_rootfs/usr/bin/"
|
||||||
$cmd_cp -r "startStreamRaspiCam.sh" "$cfg_dir_rootfs/usr/bin/"
|
|
||||||
|
tar -C "$pkg_dir/fs" -c -f - . | tar -C "$cfg_dir_rootfs" -x -v -f -
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
28
rules/uv4l/fs/etc/rc.d/raspicam
Normal file
28
rules/uv4l/fs/etc/rc.d/raspicam
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
start()
|
||||||
|
{
|
||||||
|
killall uv4l
|
||||||
|
modprobe cuse &&
|
||||||
|
uv4l \
|
||||||
|
-nopreview \
|
||||||
|
--auto-video_nr \
|
||||||
|
--driver raspicam \
|
||||||
|
--encoding h264 \
|
||||||
|
--width 1080 \
|
||||||
|
--height 720 \
|
||||||
|
--framerate 20 \
|
||||||
|
--quality 10 \
|
||||||
|
--server-option \
|
||||||
|
--port=9090 \
|
||||||
|
--server-option \
|
||||||
|
--max-queued-connections=30 \
|
||||||
|
--server-option \
|
||||||
|
--max-streams=25 \
|
||||||
|
--server-option \
|
||||||
|
--max-threads=29
|
||||||
|
}
|
||||||
|
|
||||||
|
stop()
|
||||||
|
{
|
||||||
|
killall uv4l
|
||||||
|
rmmod uv4l
|
||||||
|
}
|
Reference in New Issue
Block a user