Author Topic: Software for Xtherm T3s and HT-301  (Read 13156 times)

0 Members and 1 Guest are viewing this topic.

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Software for Xtherm T3s and HT-301
« on: January 26, 2020, 04:56:46 pm »
For Xtherm T3s (almost identical to HT-301), here is the link to the SDK
LINK REMOVED FOR PRIVACY CONSIDERATION (pm me to request it, tks)
(I may remove or disable the link anytime if I'm notified of a copyright infringement)
You can pass frames grabbed with UVC protocol to the binary library (XthermDll.dll or libthermometry.so) to get radiometric temperature data.
Unfortunately, documentation is Chinese only and the demo programs are crappy, but I can help you with Chinese if there is something too difficult for Google Translate.

I also reverse engineered the binary XthermDll.dll to make it work with x64 programs and wrote some utilities for grabbing frames with OpenCV, doing NUC, naive removal of the vertical and horizonal line pattern. See XthermToolkit.zip in the link.

Enjoy the great camera on any platform you prefer ;)

EDIT: I will NOT send the files to Zero Posters in the forum, unless they can show a proof of purchase.
« Last Edit: November 11, 2020, 12:17:34 pm by zrq »
 
The following users thanked this post: carpin, blueskull, Ambassador, NinetySix, Stephmw, RBsonic, henrylucken, RoshV, rmp94, 123Dante123, ericb

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #1 on: January 26, 2020, 06:36:34 pm »
I just uploaded a modified app for HT-301 and Xtherm T3s without the logo.
LINK REMOVED FOR PRIVACY CONSIDERATION (pm me to request it, tks)

What I did is
0.generate a self-signed certificate
1.apktool d
2.replace hti_logo.png with a transparent png
3.apktool b
4.jarsigner
« Last Edit: February 17, 2020, 02:45:04 pm by zrq »
 
The following users thanked this post: carpin, Ambassador, NinetySix, rpg22, Stephmw, RBsonic, rmp94, vazkus, ericb

Offline alex871

  • Regular Contributor
  • *
  • Posts: 58
  • Country: it
Re: Software for Xtherm T3s and HT-301
« Reply #2 on: January 26, 2020, 10:52:14 pm »
Hi, unfortunately I'm not very practical about these things. What is the procedure? Which file should I download? Should the .apk file be opened with the android cell?
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #3 on: January 27, 2020, 04:29:02 am »
Hi, unfortunately I'm not very practical about these things. What is the procedure? Which file should I download? Should the .apk file be opened with the android cell?
Install HT-301_nologo.apk on your phone and it's done.
I posted the procedure to help others who want to do this after new versions are released.
« Last Edit: March 06, 2020, 03:54:02 pm by zrq »
 
The following users thanked this post: carpin, RBsonic

Offline alex871

  • Regular Contributor
  • *
  • Posts: 58
  • Country: it
Re: Software for Xtherm T3s and HT-301
« Reply #4 on: January 27, 2020, 03:31:58 pm »
Ok, if it's just for the logo it's okay to keep it. I'm interested in the processing of thermal images with PC software.

Thank you
Alessio
 

Offline alex871

  • Regular Contributor
  • *
  • Posts: 58
  • Country: it
Re: Software for Xtherm T3s and HT-301
« Reply #5 on: February 13, 2020, 11:27:45 pm »
xinfrared offers much more complete software. How do you get it ?


http://www.xinfrared.com/index.php?m=content&c=index&a=show&catid=50&id=7
 

Offline alex871

  • Regular Contributor
  • *
  • Posts: 58
  • Country: it
Re: Software for Xtherm T3s and HT-301
« Reply #6 on: February 16, 2020, 02:46:27 am »
This software aviable for hti 301 ?

http://www.grayess.com/software/irt-analyzer/
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #7 on: February 16, 2020, 10:14:59 am »
No.
The official app for Xtherm is almost the same of the app for HT-301 but slightly older, there is no need to try it.
You should stop dreaming for a existing perfect software for this new Chinese camera. Try to develop your own analysis software with the SDK and reference code I posted, or you can grab the raw frame and do analysis with matlab or python.
 

Offline alex871

  • Regular Contributor
  • *
  • Posts: 58
  • Country: it
Re: Software for Xtherm T3s and HT-301
« Reply #8 on: February 16, 2020, 11:48:21 am »
No.
The official app for Xtherm is almost the same of the app for HT-301 but slightly older, there is no need to try it.
You should stop dreaming for a existing perfect software for this new Chinese camera. Try to develop your own analysis software with the SDK and reference code I posted, or you can grab the raw frame and do analysis with matlab or python.

As already said I am not a computer scientist, I do not understand much of these things so I would not be able to process the images with the information you have given me. Thank you all the same but it's all out of my reach
 

Offline RBsonic

  • Regular Contributor
  • *
  • Posts: 63
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #9 on: March 04, 2020, 07:42:17 am »
If someone wants to play with HTI apk  file, I recommend for this "APK Editor Studio" https://qwertycube.com/apk-editor-studio/
May be you need latest Java: https://java.com/en/download/manual.jsp

I changed cursors for temperature measurement.
There are two versions:

1. I made cursors smaller and added border https://yadi.sk/d/nGgIERvTW_YQGA
2. I made round cursors like in Thermviewer https://yadi.sk/d/s_skZGN0-Pg9zQ

Both versions have no logo. Now cursors are more visible on some palletes.
P.S. If someone knows how can I change color of digits and add border, please let me know.

HT-301 Other cursors. All palletes
https://youtu.be/IoVj6wSQZ34











« Last Edit: April 24, 2020, 04:02:08 pm by RBsonic »
 
The following users thanked this post: haizaar, zrq, Ambassador, Nicky

Offline ssytn

  • Newbie
  • Posts: 1
  • Country: ae
Re: Software for Xtherm T3s and HT-301
« Reply #10 on: April 23, 2020, 04:33:41 pm »
Hello wonder if you managed to get the SDK for this camera
 

Offline rmp94

  • Newbie
  • Posts: 4
  • Country: 00
Re: Software for Xtherm T3s and HT-301
« Reply #11 on: May 16, 2020, 01:56:11 am »
Also looking to work with the SDK and docs. Is it re-posted somewhere?
 

Offline jerry12335

  • Newbie
  • Posts: 1
  • Country: hk
Re: Software for Xtherm T3s and HT-301
« Reply #12 on: May 20, 2020, 03:57:55 pm »
May I have those SDK and apps of HT-301?
I think the apps could be enhance by DIY.
Just pmed
Thanks.
 

Offline haizaar

  • Contributor
  • Posts: 44
  • Country: au
Re: Software for Xtherm T3s and HT-301
« Reply #13 on: June 03, 2020, 01:14:05 am »
Trying to use my shining HT-301 here on Galaxy S10 Android 10.

The official app from the Play Store doesn't detect the camera at all.
Download link on the HTI web site is broken but Mr Lin was quite responsive in sending me the fixed link: http://124.225.183.134/12488881.s21d-12.faiusrd.com/0/ABUIABBKGAAgqsXG7wUonOaatQQ?f=HT-301_Please+remove+the+old+version+software+before+install.apk&v=1576116906&wsiphost=local&wsrid_tag=5ed6f58a_PS-HAK-01vNQ133_14229-19466


However video recording doesn't work in the above app - it just exits when I try to record. Same for those altered by RBsonic (thank you!) - work perfectly except for video recording. Did anyone encounter this issue? Something to do with Android 10? (I double-checked and no permissions are denied for the app)
 
The following users thanked this post: RBsonic

Offline haizaar

  • Contributor
  • Posts: 44
  • Country: au
Re: Software for Xtherm T3s and HT-301
« Reply #14 on: June 03, 2020, 03:59:59 am »
Mr Lin updated that their HTI app indeed doesn't support video recording on Galaxy S10 with Android 10. He sent me apk for Xtherm but it has exactly the same issue - app exists once you try recording. Here is the apk if anyone is interested. As a bonus, settings have a toggle to control logo on/off.

http://124.225.183.133/12488881.s21d-12.faiusrd.com/0/ABUIABBKGAAg4v3b9gUo96f7SA?f=com.infiRay.Xtherm.apk&v=1591148259&wsiphost=local&wsrid_tag=5ed6ff03_PS-HAK-01mEe140_30926-3425

Mr Lin frankly stated that they won't fix the issue with S10/ Android 10.

On the bright side, video recording works just fine with ThermView which I planned to purchase anyway.

 
The following users thanked this post: struggles, RBsonic

Offline haizaar

  • Contributor
  • Posts: 44
  • Country: au
Re: Software for Xtherm T3s and HT-301
« Reply #15 on: June 03, 2020, 05:45:40 am »
Wow, HTI kindly suggested to reimburse me for TermView license cost, since they couldn't get my cam to record videos with their app on Galaxy S10. Totally impressed with this kind of service!
 

Offline Michael82

  • Newbie
  • Posts: 2
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #16 on: June 03, 2020, 03:03:03 pm »
I got my T3s a week ago.
All apps working on my Note10+ N975f Android 10

Great camera compared to my old FlirOne gen2 160x120
App is very simple (i prefer the Hti App) , so i need a better... thermviewer.
But the Thermviewer images are less sharp than HTI and Xtherm app.
Image quality is very poor.
And its not possible to activate TV "link adress error"
« Last Edit: June 09, 2020, 10:33:20 am by Michael82 »
 

Offline alexwhittemore

  • Frequent Contributor
  • **
  • Posts: 358
Re: Software for Xtherm T3s and HT-301
« Reply #17 on: June 03, 2020, 09:19:04 pm »
I got my T3s a week ago.
All apps working on my Note10+ N975f Android 10

Great camera compared to my old FlirOne gen1 160x120
App is very simple (i prefer the Hti App) , so i need a better... thermviewer.
But the Thermviewer images are less sharp than HTI and Xtherm app.
Image quality is very poor.
And its not possible to activate TV "link adress error"

How'd you find one and what'd you pay? I see we're in different countries, but I can't seem to find a price or purchase link for a T3s/Pro anywhere, JUST HT-301 (which is a bummer since I think one of the T3s or pro is supposed to be cheaper?)
 

Offline RBsonic

  • Regular Contributor
  • *
  • Posts: 63
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #18 on: June 04, 2020, 01:48:59 am »
How'd you find one and what'd you pay? I see we're in different countries, but I can't seem to find a price or purchase link for a T3s/Pro anywhere, JUST HT-301 (which is a bummer since I think one of the T3s or pro is supposed to be cheaper?)

I found T3s on aliexpress, but it is not cheaper.
 

Offline Michael82

  • Newbie
  • Posts: 2
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #19 on: June 04, 2020, 03:38:12 pm »
For Germany:
liemke.shop T3s 750€ (paypal)
Amazon.de Ht301 818€ (Creditcard mandatory)

Important: T3s and HT301 have different housings!
HT301 owns an extended/longer USB plug.

Any ideas why TV is so blurry compared to Hti/xtherm app?
We need a better app for the cameras, developers! ;-)
 

Offline RBsonic

  • Regular Contributor
  • *
  • Posts: 63
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #20 on: June 04, 2020, 04:47:41 pm »
Also T3s can official measure tempetarure only up to 120°C.
HT-301 - up to 400-600°C
 
The following users thanked this post: Nicky

Offline Nyx_

  • Contributor
  • Posts: 5
Re: Software for Xtherm T3s and HT-301
« Reply #21 on: June 18, 2020, 01:06:15 pm »
Hello Folks. Good day.

I've read on this thread that we can capture some metadata for the HT-301 by analyzing the USB stream. It was stated also that we can send commands via the Zoom channel.

I'm wondering how can I get started to capture the individual pixel temperature values with the camera connected to a USB Linux PC. I see about 4 green lines on the bottom of the video stream that, I believe, might contain some relevant information like the temperature range or something else that might help put together the temperature matrix.

Does anyone can kindly point me to something resource that will help get the thermometric information out of this camera via a USB connection?

I believe it's possible to obtain this information but so far, I'm clueless on how to get started with capturing the information and commanding the camera via USB.

Any help is highly appreciated.

Thank you.
 
The following users thanked this post: Tavana

Offline RBsonic

  • Regular Contributor
  • *
  • Posts: 63
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #22 on: June 18, 2020, 04:01:40 pm »


If you understand android software, you can try  a reverse engineering with HTI Imager and Thermviewer Apps to find programm code for control thermal camera.
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #23 on: June 19, 2020, 05:28:46 am »
I sent you the link to the SDK in PM.
For the Zoom Channel commands, I had a note in XthermToolkit.zip (in XthermDll调用说明.docx), you may also refer to the xthermpyshowpyqt.py for some usage.
You can derive the temperature mapping from the 4 lines, using the XthermDll.dll(the original one or the one from the decompiled source). I also succeeded in making this a .so and run on Ubuntu. See the XthermDll调用说明.docx for its usage or look at xthermpyshowpyqt.py as an example.
 
The following users thanked this post: Nyx_, rmp94

Offline petr

  • Newbie
  • Posts: 1
  • Country: cz
Re: Software for Xtherm T3s and HT-301
« Reply #24 on: June 19, 2020, 11:45:46 am »
Hi can I ask you for the link too zrq? I sent you PM some time ago  ;) Thank you.
 

Offline Nyx_

  • Contributor
  • Posts: 5
Re: Software for Xtherm T3s and HT-301
« Reply #25 on: June 19, 2020, 03:34:55 pm »
Thank you zrq. Appreciate your help. I'll take a look into it and see if I can make it to work. Appreciate your help.
 

Offline bermak

  • Newbie
  • Posts: 1
  • Country: 00
Re: Software for Xtherm T3s and HT-301
« Reply #26 on: June 20, 2020, 05:09:39 pm »
Does HT-201 also work as usb webcam?
I’m thinking of getting a thermal camera to see which part of my notebook caused GPU/CPU throttling while use.
ht-201 is almost half price of 301 which is more budget friendly.
 

Offline PachekoVA

  • Newbie
  • Posts: 1
  • Country: br
Re: Software for Xtherm T3s and HT-301
« Reply #27 on: June 20, 2020, 07:51:35 pm »
can you send me the example xthermDLL?
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #28 on: June 21, 2020, 03:37:59 am »
For some reason, I feel a bit relutant to send the files to Zero Posters, unless they can show a proof of purchase.
 

Offline rmp94

  • Newbie
  • Posts: 4
  • Country: 00
Re: Software for Xtherm T3s and HT-301
« Reply #29 on: July 20, 2020, 10:53:14 pm »
Were you able to reverse out compute_atmo_trans() from the compiled DLL or did you use that book's equation as your own atmospheric transmission function? That's pretty neat and not that obvious of an equation.
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #30 on: July 21, 2020, 01:39:16 am »
I reversed it and found it coincident with what I found in the book.
« Last Edit: July 23, 2020, 03:44:12 pm by zrq »
 

Offline SaitComplete

  • Newbie
  • Posts: 1
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #31 on: July 23, 2020, 05:11:40 am »
hello can you send yours ubuntu files ? i can buy it
 

Offline Zhao

  • Contributor
  • Posts: 7
  • Country: us
Re: Software for Xtherm T3s and HT-301
« Reply #32 on: September 06, 2020, 10:29:37 pm »
Hello, I am planning to order an Xtherm T3s from alibaba to save ~150 bucks over the HT-301, which is available on Amazon with fast shipping. I wonder if there are any major quirks with T3s compared to HT-301?

One thing I have noticed is the difference in temperature range:
 - HT-301 claims to work for -20 to 400 deg C (there are some sources citing -20 to 300 and -20 to 120+ deg C).
 - T3S only officially support -20 to 120 deg C. Higher temperature range is reserved for T3Pro.
I wonder if this is strictly enforced in the FW or it can be walked around with 3rd party software such as ThermViewer. T3Pro is much more expensive compared to T3s or HT-301. If T3s is hard-capped in temperature range, it will make more sense to get the HT-301 instead.

The other thing is about the permanent logo. According to cnxunuo, the logo seems to be baked into the raw data. I wonder if there are ways to get around. I plan to play with the raw data in OpenCV so it will be pretty nasty if there is a logo on the corner. I wonder if HT-301 has the same issue.
noise:
t3s wins, by a huge margin, mostly noise even in low contrast days, with its knockoff 17um VOx.
Thermapp losed, very bad pixel noise,
however BOSON 640is a 12um core, it has extra noise and streak pattern than tau2 etc, but usable. note that this is the industrial (40mK version of boson)


lens:
t3s is a piece of garbage, its lens is so bad that when you focus on the center, the edge has weird out-of-focus artifact, dot becomes weird smudge.
BOSON 640 has weird issue of one corner became noticeably less sharp, which has already happened out of the box when new, very dissapointed.
Thermapp wins, its lens is the best.

boson uses a NV21 YUV webcam protocol, works without any trouble
thermapp uses proprietary protocol, needs linux software to trick it
t3s also uses YUV webcam protocol, however some idiot decided to permanently put their ugly logo on screen...

Thanks!
 

Dave92F1

  • Guest
Re: Software for Xtherm T3s and HT-301
« Reply #33 on: September 10, 2020, 01:12:11 am »
Mind sending me a link to your SDK?

I have a HT-301; would like to interface it to a Windows PC and analyze images in NumPy.
 

Offline valerian

  • Newbie
  • Posts: 1
  • Country: fr
Re: Software for Xtherm T3s and HT-301
« Reply #34 on: September 11, 2020, 07:44:27 am »
Hello,
Can you send me the SDK link please
Regards,
 

Offline Zhao

  • Contributor
  • Posts: 7
  • Country: us
Re: Software for Xtherm T3s and HT-301
« Reply #35 on: September 21, 2020, 12:36:07 am »
Hello, I wonder if I can get a copy of your code that converts the raw data from HT301 / T3s / T3Pro to temperature readings.

I have recently purchased a T3Pro after knowing how hackable it is. Based on your posts, I'm now able to stream the 16-bit raw data from the camera (code and result attached).

I appreciate your work!

Code: [Select]
import numpy as np
import cv2

cap = cv2.VideoCapture(1)
cap.set(cv2.CAP_PROP_CONVERT_RGB, 0)
# Use raw mode
cap.set(cv2.CAP_PROP_ZOOM, 0x8004)
# Calibrate
#cap.set(cv2.CAP_PROP_ZOOM, 0x8000)
while(True):
    ret, frame = cap.read()

    frame = frame.reshape(292,384,2) # 0: LSB. 1: MSB
    # Remove the four extra rows
    frame = frame[:288,...]
    # Convert to uint16
    dt = np.dtype(('<u2', [('x', np.uint8, 2)]))
    frame = frame.view(dtype=dt).astype(np.float32)
    # Sketchy auto-exposure
    frame -= frame.min()
    frame /= frame.max()
    gray = np.clip(frame, 0, 1) ** (1/2.2)

    cv2.imshow('frame',gray)
    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

cap.release()
cv2.destroyAllWindows()
« Last Edit: September 21, 2020, 12:44:47 am by Zhao »
 
The following users thanked this post: therwp, racketballer08

Offline therm_space

  • Newbie
  • Posts: 1
  • Country: kr
Re: Software for Xtherm T3s and HT-301
« Reply #36 on: October 14, 2020, 11:34:32 pm »
Zrq:
I joined EEVvblog yesterday to find some information to read images and thermal data from T3s from my linux PC. Can you share any information to create dynamic library?
Thanks in advance.
 

Offline alexwhittemore

  • Frequent Contributor
  • **
  • Posts: 358
Re: Software for Xtherm T3s and HT-301
« Reply #37 on: October 17, 2020, 02:45:07 am »
Mr Lin frankly stated that they won't fix the issue with S10/ Android 10.

Are you freaking kidding? How is this company SO bad at software?

For Xtherm T3s (almost identical to HT-301), here is the link to the SDK

Now that I've got one of these 301s in my hands, I'd love a copy of your SDK!
 

Offline alexwhittemore

  • Frequent Contributor
  • **
  • Posts: 358
Re: Software for Xtherm T3s and HT-301
« Reply #38 on: October 25, 2020, 05:09:12 am »
Enjoy the great camera on any platform you prefer ;)

Thanks for sending along the SDK! I'm trying to run the Python example under linux (Ubuntu 20.04, x86_64 desktop VM). I've managed to install opencv and pyqt5, but I'm running into an error here:

Code: [Select]
if not (rawFrame.size == 292 * 384 * 2):
                print('ERROR: Incorrect frame size, wrong camera selected?')
                print('Frame size: {}'.format(rawFrame.size))
                exitNow()

rawFrame.size appears to be 336384, which is actually 292 * 384 * 3. I think that means 3 bytes per pixel instead of the expected 2? It doesn't make any sense to me why that'd be.
 

Offline zrq

  • Contributor
  • Posts: 31
  • Country: cn
Re: Software for Xtherm T3s and HT-301
« Reply #39 on: October 25, 2020, 04:32:39 pm »
This looks weird to me, when I was using Ubuntu 18.04, I never have such an issue. Sorry but I don't really have an idea. Is the acquisition mode wrong and OpenCV is getting some RGB data?
 

Offline alexwhittemore

  • Frequent Contributor
  • **
  • Posts: 358
Re: Software for Xtherm T3s and HT-301
« Reply #40 on: October 25, 2020, 05:24:20 pm »
This looks weird to me, when I was using Ubuntu 18.04, I never have such an issue. Sorry but I don't really have an idea. Is the acquisition mode wrong and OpenCV is getting some RGB data?

Oh definitely an interesting though to chase down. Sounds extremely plausible.
 

Offline Tavana

  • Contributor
  • Posts: 9
  • Country: 00
Re: Software for Xtherm T3s and HT-301
« Reply #41 on: November 10, 2020, 04:31:12 pm »
May I ask you to please send me SDK for ht-301 ?
 

Offline Zhao

  • Contributor
  • Posts: 7
  • Country: us
Re: Software for Xtherm T3s and HT-301
« Reply #42 on: November 14, 2020, 08:32:18 pm »
I have the same issue. A simple reshape worked for me. See my previous post with code.

This looks weird to me, when I was using Ubuntu 18.04, I never have such an issue. Sorry but I don't really have an idea. Is the acquisition mode wrong and OpenCV is getting some RGB data?

Oh definitely an interesting though to chase down. Sounds extremely plausible.
 

Offline rasselfast

  • Newbie
  • Posts: 4
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #43 on: December 18, 2020, 07:51:39 pm »
Received my copy of HT-301, found fixed pixels. Pixels have a halo. Dust on the matrix? It was not possible to unscrew the lens, rested against the retainer. I will disassemble.

I made an adapter and connected it to a Windows computer, found two dead pixels. In the official application, they are not visible, probably interpolation overwrites them, or a map of dead pixels is loaded. I am interested in the ability to get RAW data for extracting temperature data in Windows environment.

LINK REMOVED FOR PRIVACY CONSIDERATION (pm me to request it, tks)

I would be grateful for your SDK!

« Last Edit: December 18, 2020, 07:53:41 pm by rasselfast »
 

Offline mell

  • Newbie
  • Posts: 1
  • Country: ru
Re: Software for Xtherm T3s and HT-301
« Reply #44 on: January 13, 2021, 10:13:33 am »
Hi everybody!
Hi Mr. zrq!
Mr. zrq,
let me ask you to check your forum mailbox.
 
 

Offline Odiug

  • Contributor
  • Posts: 9
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #45 on: January 30, 2021, 09:41:39 pm »
Hi All,

Since yesterday I am also a proud owner of an HT-301. And I also would like to use it freely under Linux preferably with temperature information.

@Zhao: Thanks for the Python OpenCV script. Works fine for me.

So what do we know about the device already? From Zhao's script I deduce that with some UVC properties we can control certain things. The "calibrate" or shutter (the clicking sound) is also something I can confirm from looking at the APK with jadx-gui. I guess it takes a dark frame for calibration. In the app you can manually trigger it by touching the shutter symbol (lower left of UI).
From the apk, I also learned that most of the interesting stuff happens in libUVCCamera.so, which also calls libthermometry.so. I will probably try to continue my reverse engineering, but it is a bit tedious as my Android programming experience is rather limited.

I saw that eric in another thread has the palette working. Is this also something being controlled by a property setting, or does this happen in libUVCCamera.so?

@zrq: What can I do to convince you sharing the SDK with me?  :) How did you obtain it? NDA?

Regards
Guido
 

Offline stawel

  • Newbie
  • Posts: 3
  • Country: pl
Re: Software for Xtherm T3s and HT-301
« Reply #46 on: January 30, 2021, 09:57:35 pm »
This is my first  message, so hello everyone! :)

I recently bought a HT-301 thermal camera, unfortunately I couldn't find a software which would meet my needs,
so I wrote my own, maybe some of you will be interested:

https://github.com/stawel/ht301_hacklib/tree/master

it's a very simple (hacked) python script which is able to display the temperature in Celsius
and runs on ubuntu 20.04 (not sure if it will run on windows).

The temperature calculation is based on this project:
https://github.com/mcguire-steve/ht301_ircam
currently the values are probably a little bit off, but are good enough for me.
I've tried to 'decipher' what is going on there with little success, but found some useful papers:
https://www.mdpi.com/1424-8220/17/8/1718

unfortunately I don't have time to develop it further, as the current state meets my needs, so do what you want with it.

best regards,
Pawel
 
The following users thanked this post: Odiug

Offline Odiug

  • Contributor
  • Posts: 9
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #47 on: January 30, 2021, 10:21:18 pm »
Hi Pawel

Thanks a lot for sharing your software and the other references. That's just what I was looking for.
Ah, I see, ht301_ircam contains a decompiled version of Xtherm.dll.  ;)

Regards
Guido
 

Offline stawel

  • Newbie
  • Posts: 3
  • Country: pl
Re: Software for Xtherm T3s and HT-301
« Reply #48 on: January 30, 2021, 11:34:22 pm »
what a interesting suggestion :)
hm.. I myself was wondering what a strange code standard they have in the original ros project ;)

but to be honest, the only part that was not changed (or only slightly changed) is:
https://github.com/stawel/ht301_hacklib/blob/master/ht301_hacklib.py#L74-L94
which I don't fully understand (and variable names associated with this code)

unfortunately this also means that I probably introduced my own mistakes  :-[
 
The following users thanked this post: ericb

Offline stawel

  • Newbie
  • Posts: 3
  • Country: pl
Re: Software for Xtherm T3s and HT-301
« Reply #49 on: February 06, 2021, 12:29:18 am »

I was asked what I was able to figure out about the XthermDll.cpp code so here it is, maybe it will be useful to some of you.
(bare in mind that I may have introduced some errors to the code)

useful materials:
https://en.wikipedia.org/wiki/Stefan%E2%80%93Boltzmann_law
https://www.mdpi.com/1424-8220/17/8/1718   (sensors-17-01718-v2.pdf)
https://github.com/mcguire-steve/ht301_ircam
https://github.com/stawel/ht301_hacklib


#################### sub_10001010 ###################################
sub_10001010: - calculate: water vapour content coefficient, transmittance of atmosphere and part of object temperature equation (formula (2))

code mapping:
https://github.com/mcguire-steve/ht301_ircam/blob/fd6daa8fcee96835d52e200f53451d613718cc66/src/XthermDll.cpp#L13-L48
https://github.com/stawel/ht301_hacklib/blob/a54853a62323c5d6d2befac636568590f433a87b/ht301_hacklib.py#L34-L64
sensors-17-01718-v2.pdf  page:4
    variables in 'ht301_hacklib.py code', [XthermDll.cpp code]:
    'w', [v0] - water vapour content coefficient, formula (4)
    't', [flt_100133AC] - transmittance of atmosphere, formula (3)
    'part_emi_t_1', [flt_100133A8] - part of formula (2) (denominator without the Stefan-Boltzmann constant)
    'part_Tatm_Trefl', [flt_100033A0] - part of formula (2) (part of the numerator without the Stefan-Boltzmann constant)

note 1: h0, h1, h2, h3 coefficients from paper differ from XthermDll.cpp code
note 2: XthermDll.cpp code uses mostly 32 bit floats so numbers have bigger rounding errors

#################### sub_10001180 #####################################
sub_10001180 - generate lookup table (LUT)
sensor raw values are mapped from [0, 16384] -> object temperature (floats)

code mapping:
https://github.com/mcguire-steve/ht301_ircam/blob/fd6daa8fcee96835d52e200f53451d613718cc66/src/XthermDll.cpp#L72-L141
https://github.com/stawel/ht301_hacklib/blob/a54853a62323c5d6d2befac636568590f433a87b/ht301_hacklib.py#L74-L94
this is the part which I don't fully understand, but it's essentially formula (2) with some addons:
    variables (which I understand) in 'ht301_hacklib.py code', [XthermDll.cpp code]:
    'np_Ttot', [v20] - Total radiation temperature (is the name correct?) (Wtot = o*Ttot^4, formula (2))
    'np_Tobj_C', [v18] - object temperature in Celsius (formula (2), note Stefan-Boltzmann constant is not needed because we are using Ttot^4 instead of Wtot)
    'np_result', [*p] - np_result = np_Tobj_C + distance_c * (np_Tobj_C - airtmp_)  - some "magic" addon, this is the temperature presented to user, probably not needed (?)
    'distance_c', [(v16 - 1.125) / 100.] - helper variable used in "magic" addon

some additional info:
      result = 4;
      v17 = 1.0;
      while (1) {
         v12 = v20;
         if (result & 1)
            v17 = v17 * v12;
         result >>= 1;
         if (!result)
            break;
         v20 = v12 * v12;
      }
   is a fancy way of saying: v17 = v20**4, or np_Ttot**4

#################### UpdateParam #####################################
read calibration data (Non-uniformity correction (NUC) data(?), shutter closed) and calculate LUT

code mapping:
https://github.com/mcguire-steve/ht301_ircam/blob/fd6daa8fcee96835d52e200f53451d613718cc66/src/XthermDll.cpp#L143-L199
https://github.com/stawel/ht301_hacklib/blob/a54853a62323c5d6d2befac636568590f433a87b/ht301_hacklib.py#L118-L137
(the two lines: https://github.com/mcguire-steve/ht301_ircam/blob/fd6daa8fcee96835d52e200f53451d613718cc66/src/XthermDll.cpp#L198-L199
are here: https://github.com/stawel/ht301_hacklib/blob/a54853a62323c5d6d2befac636568590f433a87b/ht301_hacklib.py#L70-L71 )

################## GetTmpData  #######################################
get min, max,.. temperatures in the current frame
code mapping:
https://github.com/mcguire-steve/ht301_ircam/blob/fd6daa8fcee96835d52e200f53451d613718cc66/src/XthermDll.cpp#L252-L295
https://github.com/stawel/ht301_hacklib/blob/a54853a62323c5d6d2befac636568590f433a87b/ht301_hacklib.py#L163-L187

 
The following users thanked this post: RBsonic, Odiug

Offline Odiug

  • Contributor
  • Posts: 9
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #50 on: February 06, 2021, 10:20:59 pm »
Pawel, thanks a lot for your detailed explanation. I need to have a closer look.

I am still wondering what those are:
Code: [Select]
    flt_10003360 = f32(m3, 6);
    flt_1000335C = f32(m3, 10);
    flt_1000339C = f32(m3, 14);
    flt_10003398 = f32(m3, 18);
    flt_10003394 = f32(m3, 22);

Seems they go into the calculation of np_Ttot by calculating these coefficients from those polynoms:
Code: [Select]
    v23 = flt_10003360 * coretmp_**2 + flt_1000335C * coretmp_;
    v22 = flt_1000339C * fpatmp_**2 + flt_10003398 * fpatmp_ + flt_10003394;

Is there information out there about the values in the frame meta data? Besides what as been figured out so far.
I assume the SDK also does not provide anymore details and the DLL is just a black box to be fed with frames.

I remember I have seen something about which bolometer is used in the HT-301. Does someone know?
But I assume there is no publicly available information aka datasheets about that one. Pretty much the same situation as with CMOS sensors nowadays.

Regards
Guido
 
The following users thanked this post: stawel

Offline Messers

  • Newbie
  • Posts: 3
  • Country: de
Re: Software for Xtherm T3s and HT-301
« Reply #51 on: April 24, 2021, 04:27:47 am »
Hi!
As in this thread much information about both HTI-301 and T3s can be found, following question:
I have both thermal cameras and what I really love is HTI-301 is working out of the box as an UVC Webcam with a white-hot color palette. The T3s is recognized as a Webcam, too, but it outputs some green-greyish crumble, which is totally unusable. On the Android app both cameras produce the same thermal image quality (at least in my eyes). So, if anyone in here can give me a hint how to get a UVC video stream out of the T3s, this would be really great!
Greetings,
Marcel
 

Offline therwp

  • Contributor
  • Posts: 25
  • Country: us
Re: Software for Xtherm T3s and HT-301
« Reply #52 on: May 20, 2021, 03:52:28 pm »
You can just plug your HT-301 into your computer and stream it to VLC?
 

Offline ArsenioDev

  • Regular Contributor
  • *
  • Posts: 97
  • Country: us
Re: Software for Xtherm T3s and HT-301
« Reply #53 on: May 20, 2021, 04:31:40 pm »
VLC or any other UVC supporting app, you can even do Zoom calls with it (I did that for a semester, confused the hell out of my professors)
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf