User Tools

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
wiki:seekthermal [2025/02/23 17:28] birdywiki:seekthermal [2025/02/23 19:35] (current) birdy
Line 1: Line 1:
 ===== Notes on using the Seek Scan thermal camera ===== ===== Notes on using the Seek Scan thermal camera =====
  
-{{:wiki:screenshot_20250223_102424-1.png|Thermal image showing the top of a water heater. It is mostly orange}}+{{:wiki:screenshot_20250223_102424-1.png|Thermal image showing the top of a water heater. It is mostly orange}}Camera: Seek Thermal Seek Scan 
 + 
 +PN: YW-AAA
  
 My configuration: raspberry pi 4 64-bit My configuration: raspberry pi 4 64-bit
Line 29: Line 31:
   - Run seek_viewer   - Run seek_viewer
     - <code ->     - <code ->
- ./seek_viewer + seek_viewer --colormap=2 --mode=v4l2 --output=/dev/video5
 </code> </code>
 +    - Colormap 2 is the jet colormap from opencv.
 +      - [[https://docs.opencv.org/4.x/d3/d50/group__imgproc__colormap.html#ga9a805d8262bcbe273f16be9ea2055a65]]
   - Run mediamtx   - Run mediamtx
     - <code ->     - <code ->
Line 38: Line 42:
     - [[http://192.168.1.100:8889/cam/]]     - [[http://192.168.1.100:8889/cam/]]
   - Open in VLC   - Open in VLC
-    - rtsp://192.168.1.100:8554/cam//+    - <code -> 
 + rtsp://192.168.1.100:8554/cam 
 +</code>
   - Open in chrome android   - Open in chrome android
     - [[http://192.168.1.100:8888/cam/]]     - [[http://192.168.1.100:8888/cam/]]
Line 95: Line 101:
 Unload kernel module index. Unload kernel module index.
 Unloaded link configuration context. Unloaded link configuration context.
 +</code>
 +
 +==== go2rtc ====
 +
 +I initially tried this setup using go2rtc instead of mediamtx, but ran in to a problem where only 1 client could join and only at the start of the stream. See  [[https://github.com/RPi-Distro/ffmpeg/pull/10]]
 +
 +==== Frigate ====
 +
 +If you want to add this camera to Frigate, the rtsp stream needs to be in yuv420p format.
 +
 +This requires the video to be in a resolution divisible by 2 (the default resolution is 154x207).
 +
 +I used the answer from [[paths:   # example:   # my_camera:   #   source: rtsp://my_camera   cam:     runOnInit: ffmpeg -f v4l2 -i /dev/video5 -vf "crop=trunc(iw/2)*2:trunc(ih/2)*2" -c:v libx264 -pix_fmt yuv420p -preset ultrafast -f rtsp rtsp://localhost:$RTSP_PORT/$MTX_PATH   # Settings under path "all_others" are applied to all paths that|here]] which will crop it to 154x206.
 +
 +<code - mediamtx.yml>
 +  cam:
 +    runOnInit: ffmpeg -f v4l2 -i /dev/video5 -vf "crop=trunc(iw/2)*2:trunc(ih/2)*2" -c:v libx264 -pix_fmt yuv420p -preset ultrafast -f rtsp rtsp://localhost:$RTSP_PORT/$MTX_PATH
 +</code>
 +
 +In the Frigate config:
 +
 +<code ->
 +  Seek:
 +    ffmpeg:
 +      inputs:
 +        - path: rtsp:192.168.1.100:8554/cam 
 +          roles:
 +            - record
 +    detect:
 +      enabled: false
 +</code>
 +
 +==== Visual camera ====
 +
 +The Seek Scan includes a visual camera as well. It's not very high quality.
 +
 +On my system it was automatically set up as /dev/video0
 +
 +Use the [[https://github.com/bluenviron/mediamtx?tab=readme-ov-file#generic-webcam|default usb webcam config.]]
 +
 +Seek_viewer has a default image rotation. To have the visual camera match the rotation of the thermal camera, I used the transpose=2 option.
 +
 +<code - mediamtx.yml>
 +  vcam:
 +    runOnInit: ffmpeg -f v4l2 -i /dev/video0 -vf "transpose=2" -c:v libx264 -pix_fmt yuv420p -preset ultrafast -b:v 600k -f rtsp rtsp://localhost:$RTSP_PORT/$MTX_PATH
 </code> </code>