rc.droidcam.new 300 B

1234567891011121314151617181920212223242526272829303132333435
  1. #!/usr/bin/env bash
  2. case $1 in
  3. start)
  4. modprobe snd-aloop && modprobe v4l2loopback_dc
  5. ;;
  6. stop)
  7. rmmod -f snd-aloop && rmmod -f v4l2loopback_dc
  8. ;;
  9. restart)
  10. $0 stop
  11. $0 start
  12. ;;
  13. *)
  14. echo 'Run only "/etc/rc.d/rc.droidcam start | stop| restart"'
  15. ;;
  16. esac