I have spent hours trying to work out how to get webcam running on Octoprint. I have worked out that you need to build and install mjpg-streamer from git and I have got this going (just) but I cannot work out how to start automatically and included in Octoprint.
Maybe adding a separate mjpg-streamer software install would be a good alternatively. Unfortunately this is beyond my skill level. The following is what I have managed so far from https://github.com/jacksonliam/mjpg-streamer.
Login as dietpi user on fresh install of DietPi with Octoprint and FFMpeg (under Software Additional):
Code: Select all
sudo apt-get install cmake
git clone https://github.com/jacksonliam/mjpg-streamer.git
cd mjpg-streamer/mjpg-streamer-experimental
make
sudo make install
Code: Select all
./mjpg_streamer -i "input_uvc.so" -o "output_http.so -p 5001"
http://dietpi:5001/?action=stream_0
http://dietpi:5001/?action=snapshot
I then go through the configuration steps for Octopi
http://dietpi:5000/
Under "Webcam & Timelapse Recordings":
- * Stream URL: http://dietpi:5001/?action=stream_0
* Snapshot URL: http://dietpi:5001/?action=snapshot
* Path to FFmpeg: /usr/bin/ffmpeg