leswright1977 / PyThermalCamera

Python Software to use the Topdon TC001 Thermal Camera on Linux and the Raspberry Pi
Apache License 2.0
195 stars 41 forks source link

TypeError: Argument 'value' must be double, not bool in line 61 (?) #5

Open sunrise1873 opened 1 year ago

sunrise1873 commented 1 year ago

unfortunately it doesn't work under Debian stable.

command:

tc001v4.2.py --device 0

says:

Traceback (most recent call last): File "/home/norman/Downloads/PyThermalCamera-main/src/tc001v4.2.py", line 61, in cap.set(cv2.CAP_PROP_CONVERT_RGB, False) TypeError: Argument 'value' must be double, not bool

What is wrong?

sunrise1873 commented 1 year ago

under Debian 12, line 61 need to be changed:

cap.set(cv2.CAP_PROP_CONVERT_RGB, 0)

u4y0u commented 11 months ago

This version 4.2 with the modification of line 61 works perfectly with an OS ubuntu desktop 23.04. THANKS. Capture d’écran du 2023-10-20 17-02-45

ubuntu #Topdon #TC001

  v4l2-ctl --list-devices
  USB Camera: USB Camera (usb-0000:03:00.3-2.3):
    /dev/video0
    /dev/video1
    /dev/media0
python3 tc001v4.2a.py --device 0
Les Wright 21 June 2023
https://youtube.com/leslaboratory
A Python program to read, parse and display thermal data from the Topdon TC001 Thermal camera!

Tested on Debian all features are working correctly
This will work on the Pi However a number of workarounds are implemented!
Seemingly there are bugs in the compiled version of cv2 that ships with the Pi!

Key Bindings:

a z: Increase/Decrease Blur
s x: Floating High and Low Temp Label Threshold
d c: Change Interpolated scale Note: This will not change the window size on the Pi
f v: Contrast
q w: Fullscreen Windowed (note going back to windowed does not seem to work on the Pi!)
r t: Record and Stop
p : Snapshot
m : Cycle through ColorMaps
h : Toggle HUD
QSocketNotifier: Can only be used with threads started with QThread
qt.qpa.wayland: Wayland does not support QWindow::requestActivate()