Photon Vision Stability and Multiple Cameras

Hello,
I have a Raspberry Pi 3B+ that I threw Photon Vision v2022.1.1 on. The mjpeg camera streams don’t seem to be very reliable. Sometimes they come up fine and other times they don’t load at all. I read that some browsers might have issues with mjpeg steams, but I tried both Chrome and Edge and got similar results. When the stream doesn’t show up in the browser, it is also gone on shuffle board. As soon as I try to run two cameras, both steams consistently won’t load. My question is whether or not others have been having similar issues with this particular release of Photon Vision or am I doing something wrong?

There are later releases you could try - while I don’t recall any specific change to address an issue like that, it’s worthwhile to see if the behavior is different on latest.

Could you download the .zip from the Settings page “export” button? This will contain log files that could help diagnose the issue.

I’ll have to wait until tomorrow evening to get the log files.

I went to Github and downloaded the what looked to be the latest release. This time it was showing v2021.1.11 as the latest release. I’m not sure anymore how I got the other version. I this the correct image?

Nevermind.
I found a different Github page with latest releases.

I will go ahead and try the new images tomorrow and see if that fixes it.

You got it, Installing PhotonVision - PhotonVision Docs has the latest install instructions.

I did just try running two cameras, four streams, on Chrome on my Matebook Pro, with photonvision v2022.1.3

Looks to be functional? Not saying for certain it will work on your side, but I believe what you’re describing is at least by design possible and functional.

Make sure you disable all your adblockers. If u remember, that might have been an issue with some users in the past.

I uploaded v2022.1.3 tonight and have not seen a change in the issues.

Sometimes when I made changes on the webpage and then rebooted the pi the changes do not stick.

I also checked and did not have any ad blockers running and also took down some browser shields.

Here is my most recent logs.

I removed a big section in the middle of the log that was just camera exposure settings changing.
Otherwise ChiefDelphi wouldn’t let me post it:

[2021-01-11 01:53:20] [General - Main] [INFO] Logging initialized in debug mode.
[2021-01-11 01:53:20] [General - ShellExec] [DEBUG] Executing "id -u"
[2021-01-11 01:53:20] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:20] [General - ShellExec] [DEBUG] Executing "cat /proc/device-tree/model"
[2021-01-11 01:53:20] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:21] [General - Main] [INFO] Starting PhotonVision version v2022.1.3 on Linux Raspbian (Pi PI_3)
[2021-01-11 01:53:22] [Camera - PicamJNI] [INFO] Successfully loaded libpicam shared object
[2021-01-11 01:53:22] [General - Main] [INFO] Native libraries loaded.
[2021-01-11 01:53:22] [General - ConfigManager] [INFO] Loading settings...
[2021-01-11 01:53:22] [General - ConfigManager] [INFO] Hardware config does not exist! Loading defaults
[2021-01-11 01:53:22] [General - ConfigManager] [INFO] Hardware settings does not exist! Loading defaults
[2021-01-11 01:53:22] [General - ConfigManager] [INFO] Network config file does not exist! Loading defaults
[2021-01-11 01:53:22] [General - ConfigManager] [DEBUG] Cameras config folder did not exist. Created!
[2021-01-11 01:53:23] [General - NetworkManager] [INFO] Setting DHCP with team team 0
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "cat /etc/hostname | tr -d " \t\n\r""
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "echo photonvision > /etc/hostname"
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "hostnamectl set-hostname photonvision"
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "sed -i "s/127.0.1.1.*photonvision/127.0.1.1\tphotonvision/g" /etc/hosts"
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "sudo service avahi-daemon restart"
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - NetworkManager] [INFO] Set hostname to photonvision
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Executing "dhclient eth0"
[2021-01-11 01:53:23] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:53:23] [General - NetworkTablesManager] [INFO] Starting NT Client
[2021-01-11 01:53:23] [General - NetworkTablesManager] [ERROR] [NetworkTablesManager] Could not connect to the robot! Will retry in the background...
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [DEBUG] Matching 1 new cameras!
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [INFO] Adding local video device - "Microsoft® LifeCam HD-3000" at "/dev/video0"
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [DEBUG] After matching loaded configs 1 cameras were unmatched.
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [INFO] Creating a new camera config for camera Microsoft_LifeCam_HD-3000
[2021-01-11 01:53:24] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:53:24] [Camera - CameraConfiguration] [DEBUG] Creating USB camera configuration for UsbCameraMicrosoft LifeCam HD-3000 (AKA Microsoft_LifeCam_HD-3000) at /dev/video0
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [DEBUG] Matched or created 1 camera configs!
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [DEBUG] Matched config for camera "USBFrameProvider - opencv_Microsoft_LifeCam_HD-3000" and loaded 0 pipelines
[2021-01-11 01:53:24] [Camera - VisionSourceManager] [INFO] Adding 1 configs to VMM.
[2021-01-11 01:53:24] [WebServer - DataChangeService] [DEBUG] Added subscriber - Sources: DCS_WEBSOCKET, DCS_HTTP, DCS_NETWORKTABLES, DCS_VISIONMODULE, DCS_OTHER, Destinations: DCD_ACTIVEMODULE, DCD_ACTIVEPIPELINESETTINGS, DCD_GENSETTINGS, DCD_UI, DCD_OTHER
[2021-01-11 01:53:25] [VisionModule - VisionModule - Microsoft_LifeCam_HD-3000] [INFO] Setting pipeline to 0
[2021-01-11 01:53:25] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:53:25] [WebServer - DataChangeService] [DEBUG] Added subscriber - Sources: DCS_WEBSOCKET, DCS_HTTP, DCS_NETWORKTABLES, DCS_VISIONMODULE, DCS_OTHER, Destinations: DCD_UI
[2021-01-11 01:53:25] [WebServer - DataChangeService] [DEBUG] Added subscriber - Sources: DCS_WEBSOCKET, Destinations: DCD_GENSETTINGS
[2021-01-11 01:53:26] [General - NetworkTablesManager] [ERROR] NT Connection has failed! Will retry in background.
[2021-01-11 01:53:26] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:53:26] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:53:26] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:53:27] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.local
[2021-01-11 01:53:32] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.lan
[2021-01-11 01:53:32] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.frc-field.local
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 44.209637ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 157.84166ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 18.905989ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 40.42427ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 79.64011ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 105.50234ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 141.16333ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 174.60855ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 255.67099ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 30.91922ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 43.755993ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 131.52234ms
[2021-01-11 01:56:51] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 370.30807ms
[2021-01-11 01:56:52] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 374.20688ms
[2021-01-11 01:56:52] [WebServer - SocketHandler] [INFO] New websocket connection from /10.31.60.66:57700
[2021-01-11 01:56:52] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 13.312708ms
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:56:53] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.local
[2021-01-11 01:56:58] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.lan
[2021-01-11 01:56:58] [General - NetworkTablesManager] [INFO] Looking up roboRIO-0-FRC.frc-field.local
[2021-01-11 01:57:35] [General - NetworkManager] [INFO] Setting DHCP with team team 3160
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "cat /etc/hostname | tr -d " \t\n\r""
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "echo FROGvision > /etc/hostname"
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "hostnamectl set-hostname FROGvision"
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "sed -i "s/127.0.1.1.*photonvision/127.0.1.1\tFROGvision/g" /etc/hosts"
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "sudo service avahi-daemon restart"
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - NetworkManager] [INFO] Set hostname to FROGvision
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Executing "dhclient eth0"
[2021-01-11 01:57:35] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:35] [General - NetworkTablesManager] [INFO] Starting NT Client
[2021-01-11 01:57:36] [General - NetworkTablesManager] [ERROR] [NetworkTablesManager] Could not connect to the robot! Will retry in the background...
[2021-01-11 01:57:36] [WebServer - Server] [DEBUG] Handled HTTP POST request from 10.31.60.66 in 1251.3804ms
[2021-01-11 01:57:36] [General - NetworkTablesManager] [INFO] NT Connected!
[2021-01-11 01:57:36] [General - ScriptManager] [INFO] Queued event: kNTConnected
[2021-01-11 01:57:37] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:57:37] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:57:37] [General - NetworkTablesManager] [ERROR] NT Connection has failed! Will retry in background.
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.local
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Pinging roboRIO-3160-FRC.local
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Was able to connect to roboRIO-3160-FRC.local
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.lan
[2021-01-11 01:57:37] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.frc-field.local
[2021-01-11 01:57:37] [WebServer - Server] [DEBUG] Handled HTTP GET request from 10.31.60.66 in 8.875469ms
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.local
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Pinging roboRIO-3160-FRC.local
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Was able to connect to roboRIO-3160-FRC.local
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.lan
[2021-01-11 01:57:38] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.frc-field.local
[2021-01-11 01:57:47] [VisionModule - VisionModule - Microsoft_LifeCam_HD-3000] [INFO] Setting pipeline to -1
[2021-01-11 01:57:47] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:57:49] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:57:49] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:57:50] [General - MetricsPublisher] [DEBUG] Publishing Metrics...
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "sed 's/.\{3\}$/.&/' <<< cat /sys/class/thermal/thermal_zone0/temp"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | awk '{print 100 - $1}'"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "vcgencmd get_mem arm | grep -Eo '[0-9]+'"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "vcgencmd get_mem gpu | grep -Eo '[0-9]+'"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "free --mega | awk -v i=2 -v j=3 'FNR == i {print $j}'"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "vcgencmd get_mem malloc | grep -Eo '[0-9]+'"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Executing "df ./ --output=pcent | tail -n +2"
[2021-01-11 01:57:50] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:57:50] [WebServer - Server] [DEBUG] Handled HTTP POST request from 10.31.60.66 in 372.8405ms
[2021-01-11 01:58:18] [VisionModule - VisionModuleChangeSubscriber - Microsoft_LifeCam_HD-3000] [DEBUG] Skipping pipeline change, index -1 already active
[2021-01-11 01:58:27] [VisionModule - VisionModuleChangeSubscriber - Microsoft_LifeCam_HD-3000] [DEBUG] Skipping pipeline change, index -1 already active
[2021-01-11 01:58:30] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:58:30] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 51
[2021-01-11 01:58:30] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 51
[2021-01-11 01:58:39] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 51
[2021-01-11 01:58:41] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:58:41] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:58:43] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 49
[2021-01-11 01:58:44] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:58:45] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:58:47] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:58:47] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:59:06] [WebServer - Server] [DEBUG] Handled HTTP POST request from 10.31.60.66 in 28.843489ms
[2021-01-11 01:59:06] [General - NetworkTablesManager] [INFO] NT Connected!
[2021-01-11 01:59:06] [General - ScriptManager] [INFO] Queued event: kNTConnected
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.local
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Pinging roboRIO-3160-FRC.local
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Was able to connect to roboRIO-3160-FRC.local
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.lan
[2021-01-11 01:59:07] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.frc-field.local
[2021-01-11 01:59:08] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:59:08] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [DEBUG] Matching 1 new cameras!
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [INFO] Adding local video device - "Microsoft® LifeCam HD-3000" at "/dev/video2"
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [DEBUG] After matching loaded configs 1 cameras were unmatched.
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [INFO] Creating a new camera config for camera Microsoft_LifeCam_HD-3000
[2021-01-11 01:59:20] [Camera - CameraConfiguration] [DEBUG] Creating USB camera configuration for UsbCameraMicrosoft LifeCam HD-3000 (AKA Microsoft_LifeCam_HD-3000) at /dev/video2
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [DEBUG] Matched or created 1 camera configs!
[2021-01-11 01:59:20] [General - NetworkTablesManager] [INFO] NT Connected!
[2021-01-11 01:59:20] [General - ScriptManager] [INFO] Queued event: kNTConnected
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [DEBUG] Matched config for camera "USBFrameProvider - opencv_Microsoft_LifeCam_HD-3000" and loaded 0 pipelines
[2021-01-11 01:59:20] [Camera - VisionSourceManager] [INFO] Adding 1 configs to VMM.
[2021-01-11 01:59:20] [WebServer - DataChangeService] [DEBUG] Added subscriber - Sources: DCS_WEBSOCKET, DCS_HTTP, DCS_NETWORKTABLES, DCS_VISIONMODULE, DCS_OTHER, Destinations: DCD_ACTIVEMODULE, DCD_ACTIVEPIPELINESETTINGS, DCD_GENSETTINGS, DCD_UI, DCD_OTHER
[2021-01-11 01:59:20] [VisionModule - VisionModule - Microsoft_LifeCam_HD-3000] [INFO] Setting pipeline to 0
[2021-01-11 01:59:21] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Searching for rios
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Trying 127.0.0.1
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Didn't match RIO IP
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Trying 10.31.60.57
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Maybe found 10.31.60.57
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Looking up 10.31.60.2
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Pinging 10.31.60.2
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Was able to connect to 10.31.60.2
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.local
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Pinging roboRIO-3160-FRC.local
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Was able to connect to roboRIO-3160-FRC.local
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.lan
[2021-01-11 01:59:21] [General - NetworkTablesManager] [INFO] Looking up roboRIO-3160-FRC.frc-field.local
[2021-01-11 01:59:22] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:59:22] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:59:36] [VisionModule - VisionModuleChangeSubscriber - Microsoft_LifeCam_HD-3000] [DEBUG] Skipping pipeline change, index -1 already active
[2021-01-11 01:59:36] [VisionModule - VisionModule - Microsoft_LifeCam_HD-3000] [INFO] Setting pipeline to -1
[2021-01-11 01:59:36] [Camera - USBCameraSource - Microsoft_LifeCam_HD-3000] [DEBUG] Setting camera exposure to 50
[2021-01-11 01:59:38] [General - ConfigManager] [DEBUG] Saving to disk...
[2021-01-11 01:59:38] [General - ConfigManager] [INFO] Settings saved!
[2021-01-11 01:59:44] [General - MetricsPublisher] [DEBUG] Publishing Metrics...
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Executing "sed 's/.\{3\}$/.&/' <<< cat /sys/class/thermal/thermal_zone0/temp"
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Executing "top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | awk '{print 100 - $1}'"
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Executing "free --mega | awk -v i=2 -v j=3 'FNR == i {print $j}'"
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Executing "vcgencmd get_mem malloc | grep -Eo '[0-9]+'"
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Executing "df ./ --output=pcent | tail -n +2"
[2021-01-11 01:59:44] [General - ShellExec] [DEBUG] Got exit code 0
[2021-01-11 01:59:44] [WebServer - Server] [DEBUG] Handled HTTP POST request from 10.31.60.66 in 308.4312ms
[2021-01-11 01:59:45] [WebServer - Server] [DEBUG] Handled HTTP POST request from 10.31.60.66 in 6.242552ms
[2021-01-11 01:59:45] [General - ShellExec] [DEBUG] Executing "systemctl restart photonvision.service"
[2021-01-11 01:59:45] [General - ShellExec] [DEBUG] Got exit code 143
[2021-01-11 01:59:45] [General - HardwareManager] [INFO] Shutting down LEDs...

Tonight I did some trouble shooting.
Let me know if you see any holes in my thoughts.

I loaded fresh installs of the latest raspi img on multiple raspberry pi(s). No change.
Thus I would conclude that it is not a raspberry pi hardware issue.

Software wise, other people seem to be using the same pi img okay, so I don’t think that’s the issue.

I tried multiple laptops with different browsers. No change
Must not be on the receiving end.

I’ve also noticed that I can’t connect to wifi on the pi. After looking into it, there isn’t any wpa_supplicant config file. Was this a feature that was specifically removed for Photon Vision?
Because of this I’ve just had the pi plugged in to a spare robot radio and connected to it that way.
I tried disabling the bandwidth limit on the radio. No change.

We did start play with using a picam and usb cam at the same time. I was able to get those two cameras running at the same time. However, I’m running into the same issue with the picam as posted in this thread.

Also noticed that I’m still getting target coordinates on both cameras even when I can’t see the streams.

At this point I am just wanting to compare my setup with others to see if I can find the point where they differ.

So far it would seem to not be the hardware or software. I’m going to start looking into the networking side of things and see if I can find anything there.

This one I can answer solidly - yes, to be field legal, wifi has to be disabled. The change you observe is intentional - communication should be done over ethernet.

The screenshots I’d posted above were with the browser as specified, v1.3 picam and a microsoft lifecam.

Can you try using two Microsoft lifecams with your setup?

I’d appreciate it.

Unfortunately I only have access to one at the moment…

No worries. Thanks for the info.

I also struggle on getting stable streams. with just the pi cam it was sporadic, but when I added a USB cam as well, it idetifies it but does not display the stream at all. Going straight to the :1182/stream.mjpg returns nothing either. The pi stream is now very hit or miss.

Since I have been running the latest release, I haven’t had too many issues with the streams. Currently, I am using a picam and a usb lifecam. Occasionally I loose the stream if the pi is running a pipeline that uses a lot of resources, in which case a refresh of the browser tab brings it back. I’ve also noticed that if you’re viewing the 118X/stream.mjpg in a separate tab it sometimes freezes if that is not the stream you are viewing in the web interface.

Are you using the latest release of photon vision?

I know that sometimes the color stream will be disabled without the web interface open – is that at all related to what’s going on here?
https://github.com/PhotonVision/photonvision/blob/master/photon-server/src/main/java/org/photonvision/server/SocketHandler.java#L89

Sorry for the really low quality GIF, full resolution at https://cdn.discordapp.com/attachments/725846784131203222/934575876736188466/2022-01-22_17-27-23.mp4

Is this what you are seeing?

To expand on what Matt said:

If you’re not in driver mode then the color stream will be disabled a little while after you close the UI to improve performance.

This is because the GPU-accelerated Pi camera driver has to do extra work to copy the color data off of the GPU—the GPU processes the data and the result is put into a 32-bit per pixel RGBA buffer that lives onto the GPU and is mapped into CPU (userland-accessible) virtual memory. In this buffer the alpha channel is the thresholded result and the RGB channels are the color input stream. It is faster to just copy the alpha channel than it is to copy the RGB channel to a 24-bit per pixel RGB buffer and the alpha channel to a 8-bit per pixel thresholded buffer. To stop users from taking a performance hit we thought it would be best to automatically disable the color copying and color stream after the UI closes. The assumption was that users would typically have a dedicated “driver mode” camera.