I've been using Octolapse with a raspi cam 2.1 connected to my pi zero via the ribbon cable. The plugin is working fine, taking the snapshots and composing them into a smooth timelapse. The only thing is the resolution is only coming through at 640x480. My camera is capable of taking snapshots as a resolution of 3280x2464 (8mp). Does anyone know where I change the captured resolution? I figured it would be in the Camera section of the Octolapse settings, but don't see anything obvious there. Unless it's in the snapshot address template: {camera_address}?action=snapshot
Nothing stands out in the Camera Settings Request Templates section under Advanced Camera Options either.
I am new to OctoPrint and OctoPi but have some decent understanding of Linux and Raspberry Pi. I am using a RPi 3 B+ with the PiCamera V1.2 and no matter what I change in the config file I see no difference. I have rebooted and tried again and again. I see no difference in the resolution. I am viewing the camera feed via web browser and in Cura. Neither appear any different after each reboot. What am I doing wrong? Is there something that I need to change elsewhere?
I am changing the config file here using "sudo nano /boot/octopi.txt" and saving per the instructions in the file "/root/bin/webcamd" which I also tried there. Nothing changes the resolution.
What resolution do you get now and what resolution do you want to get?
Ewald, I ran the command fbset -s
and got this output:
mode "656x416"
geometry 656 416 656 416 32
timings 0 0 0 0 0 0 0
rgba 8/16,8/8,8/0,8/24
endmode
But in the config file /boot/octopi.txt
I maxed it out to see what would happen:
camera_raspi_options="-x 2592 -y 1944 -fps 10 -quality 100"
As you can see I even tried to up the jpeg quality but that did nothing to change the appearance of the camera output.
Jay,
Just to be sure here, but you're rebooting the raspberry pi, and not just restarting octoprint, correct? The camera settings only get loaded when the pi boots.
Oh. I believe you can only go as high as 1080p resolution, even though the camera can take higher res stills. try a setting of:
camera_raspi_options="-x 1920 -y 1080 -fps 10"
Yes, I use the reboot
command from the terminal on my MacBook via ssh. It is always good to double check with my process.
I have tried multiple resolutions at random and nothing has changed the actual appearance of it on my monitor. The only thing that changes is the output of the fbset -s
command when I use raspi-config
which I immediately reboot and check the output and appearance.
My /boot/octopi.txt
on my RaspberryPi looks like this:
### Windows users: To edit this file use Notepad++, VSCode, Atom or SublimeText.
### Do not use Notepad or WordPad.
### MacOSX users: If you use Textedit to edit this file make sure to use
### "plain text format" and "disable smart quotes" in "Textedit > Preferences"
### Configure which camera to use
#
# Available options are:
# - auto: tries first usb webcam, if that's not available tries raspi cam
# - usb: only tries usb webcam
# - raspi: only tries raspi cam
#
# Defaults to auto
#
#camera="auto"
### Additional options to supply to MJPG Streamer for the USB camera
#
# See https://github.com/foosel/OctoPrint/wiki/MJPG-Streamer-configuration
# for available options
#
# Defaults to a resolution of 640x480 px and a framerate of 10 fps
#
#camera_usb_options="-r 640x480 -f 10"
### Additional webcam devices known to cause problems with -f
#
# Apparently there a some devices out there that with the current
# mjpg_streamer release do not support the -f parameter (for specifying
# the capturing framerate) and will just refuse to output an image if it
# is supplied.
#
# The webcam daemon will detect those devices by their USB Vendor and Product
# ID and remove the -f parameter from the options provided to mjpg_streamer.
#
# By default, this is done for the following devices:
# Logitech C170 (046d:082b)
# GEMBIRD (1908:2310)
# Genius F100 (0458:708c)
# Cubeternet GL-UPC822 UVC WebCam (1e4e:0102)
#
# Using the following option it is possible to add additional devices. If
# your webcam happens to show above symptoms, try determining your cam's
# vendor and product id via lsusb, activating the line below by removing # and
# adding it, e.g. for two broken cameras "aabb:ccdd" and "aabb:eeff"
#
# additional_brokenfps_usb_devices=("aabb:ccdd" "aabb:eeff")
#
# If this fixes your problem, please report it back so we can include the device
# out of the box: https://github.com/guysoft/OctoPi/issues
#
#additional_brokenfps_usb_devices=()
### Additional options to supply to MJPG Streamer for the RasPi Cam
#
# See https://github.com/foosel/OctoPrint/wiki/MJPG-Streamer-configuration
# for available options
#
# Defaults to 10fps
#
# Jason: Resolution is NOT changing
camera_raspi_options="-x 1920 -y 1080 -fps 10"
### Configuration of camera HTTP output
#
# Usually you should NOT need to change this at all! Only touch if you
# know what you are doing and what the parameters mean.
#
# Below settings are used in the mjpg-streamer call like this:
#
# -o "output_http.so -w $camera_http_webroot $camera_http_options"
#
# Current working directory is the mjpg-streamer base directory.
#
#camera_http_webroot="./www-octopi"
#camera_http_options="-n"
It just seems to default to a blurry feed no matter where I view it - no matter what settings I change it too whether it change it in the config file or in raspi-config
I have tried to view it in my web browser on my MacBook and iPad. I have tried to view it in Cura on my MacBook. I have tried to view it on the OctoPod iOS app on my iPad. All look the same.
Not sure that it is strictly necessary as I think it is the default, but I would un-comment the line
#camera="auto"
That's the only difference I see between your file and mine, and mine works as expected.
I did try that at one point. I am actually considering whether or not there is something wrong with the lens. I saw this post and started wondering if it is my lens. So I found this on Thingiverse and decided to print it and try to adjust the lens. I will get back with you and post my results. Who knows maybe it is just blurry? It is possible.
Solved. I was the lens on the PiCamera. I used the tool to adjust it and it worked. It was a little tedious to turn in back and forth and thee tool was difficult to fit on it but it worked. And I trusted the plastic rather than pliers because I did not want to break the PiCamera. Here are the results so far:
Thanks for all of the help. I am glad to tell you that it was not an OctoPi problem. It was an official PiCamera v2.1 problem. It still needs more focusing but I am happy for now
try kill mjpg-streamer (kill -9 pid)
then cd ~/mjpg-stream/mjpg_streamer -i "./input_uvc.so -r HD -f 15" -o "./output_http.so -w ./www"
maybe work
but i don't find the self-starting commond fo mjpg-streamer
If there's only one running, then sudo pkill mjpg-streamer
works well without the PID lookup step.