Poll

Has the hackabiliy of the E4 made you buy one :  

Yes, I was already looking at the competition at a similar price, but the hack swung it to E4
277 (28.1%)
Yes, I'd not considered buying a TIC before, but 320x240 resolution at this price justifies it (as either tool or toy!)
444 (45.1%)
Yes, I was going to buy an E5/6/8 class of unit but will now get the E4
49 (5%)
No, but am looking out for a cheap i3 to hack
51 (5.2%)
Not yet, but probably will if now that a closed-box hack becomes is possible
164 (16.6%)

Total Members Voted: 807

Author Topic: Flir E4 Thermal imaging camera teardown  (Read 4077275 times)

0 Members and 24 Guests are viewing this topic.

Offline Taucher

  • Frequent Contributor
  • **
  • Posts: 456
  • Country: de
  • 1DsaYDGWXEYhEKL rfrbFyYsehaAtfBWawf
Re: Flir E4 Thermal imaging camera teardown
« Reply #2525 on: December 22, 2013, 10:26:22 am »
Hi People!
How make  my FLIR E8+ working as the webcam in Skype?
Ensure it's in VC-mode and then select it at the Skype settings? (untested)

Offline daves

  • Regular Contributor
  • *
  • Posts: 103
  • Country: cz
Re: Flir E4 Thermal imaging camera teardown
« Reply #2526 on: December 22, 2013, 10:30:11 am »
@daves
we are a great team
Well, I think we everyone here are great team. I like to share my work, as others shared their work.

I just changed original flir.php yet more. It is preserving create time from original images to output file. Also it can read GPS file and save coordinates to out file. It makes javascript file with data and then place photos on google map. More over it generates html report with real, ir and combined image on page. And last option I added is logo in image. All in automatic batch process. For easy start I plan to do exe wrapper with windows gui for runing flir.php. Wrapper for wrapper :-D

I do not know if anyone is interested in this functions. I do not want to mess this forum with new versions, so I will only update my original post with batch flir.php time by time.

Today, I was on another walk outside. Camera freezed two times, with some mess on screen. In both cases it freezed while saving picture. After restart it showed gray palette squares. In first case image was not saved and after restart it was ok. In second case image was saved, but ghost image of mess remained and combined with actual picture. I had to remove battery. Battery was charged. I guess there is some problem with low temperature or some possible condensation.

UPDATE: Seems also time is very unstable when cold, on 1 hour trip it shifted by 2 minutes and after freeze and reboot it went back to normal. This made GPS synchronization useless.
« Last Edit: December 22, 2013, 03:38:22 pm by daves »
Batch Thermal Images Editor (JPG, BMT, SNP, IRI, ISI, IS2, PGM, TIF, IMG, BMP):  https://www.eevblog.com/forum/testgear/flir-e4-thermal-imaging-camera-teardown/msg350556/#msg350556
 

Offline tomas123

  • Frequent Contributor
  • **
  • Posts: 832
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2527 on: December 22, 2013, 11:35:31 am »
hi daves,

I'm very interested in your work and sticked your post to watch further changing (gpx, reports etc.)
https://www.eevblog.com/forum/testgear/flir-e4-thermal-imaging-camera-teardown/msg350556/#msg350556

How do you stitched the panorama?

My "old" E40 freezes also sometimes (remove battery) until second firmware update. Now it works stable but not unwavering.



look at your color space sRGB/RGB for best palette colors

some background informations:

you can also open a *.pal and convert the values with excel etc. (stretch to 255,255,255)
Code: [Select]
[version]
name=Iron
major=1
minor=1
edit=1
date=07-Oct-2010
[noOfColors]
224
[stretch]
0
[method]
0
[specialColors]
# Values in Y Cr Cb order
# overflow, red
67, 216, 98
# underflow, blue
41, 110, 240
#above, light gray
170, 128, 128
#below, dark gray
50, 128, 128
# isotherm 1, gray
100, 128, 128
# isotherm 2, blue
100, 110, 240
[palette]
#palette (224 colors)
16,101,140
17,103,142
18,105,145
19,106,147
20,108,149
21,110,152
22,112,154
23,114,156
24,116,158
25,118,160
26,120,162
27,121,164
28,123,165
29,125,167
30,127,169
31,128,170
32,130,172
33,132,173
34,133,174
35,135,175
36,136,177
37,138,178
38,140,179
39,141,180
40,143,181
41,144,181
42,145,182
43,147,183
44,148,183
44,150,184
45,151,185
46,152,185
47,154,185
48,155,186
49,156,186
50,157,186
51,159,186
52,160,186
53,161,186
54,162,186
55,163,186
56,165,186
57,166,186
58,167,186
59,168,186
60,169,185
61,170,185
62,171,185
63,172,184
64,173,184
65,174,183
66,175,182
67,176,182
68,177,181
69,177,180
70,178,180
71,179,179
72,180,178
73,181,177
74,182,176
75,182,175
76,183,174
77,184,173
78,184,172
79,185,171
80,186,170
81,186,169
82,187,168
83,188,166
84,188,165
85,189,164
86,189,163
87,190,161
88,190,160
89,191,159
90,191,157
91,192,156
92,192,154
93,193,153
94,193,151
95,194,150
96,194,148
97,194,147
98,195,145
99,195,144
99,195,142
100,196,140
101,196,139
102,196,137
103,197,135
104,197,134
105,197,132
106,197,130
107,197,129
108,198,127
109,198,125
110,198,123
111,198,122
112,198,120
113,198,118
114,198,117
115,198,115
116,198,113
117,198,111
118,198,109
119,198,108
120,198,106
121,198,104
122,198,102
123,198,101
124,198,99
125,198,97
126,198,96
127,198,94
128,198,92
129,198,90
130,198,89
131,197,87
132,197,85
133,197,84
134,197,82
135,197,80
136,196,79
137,196,77
138,196,75
139,196,74
140,195,72
141,195,71
142,195,69
143,194,68
144,194,66
145,194,65
146,193,63
147,193,62
148,193,60
149,192,59
150,192,58
151,191,56
152,191,55
153,191,54
154,190,53
154,190,51
155,189,50
156,189,49
157,188,48
158,188,47
159,187,46
160,187,45
161,186,44
162,186,43
163,185,42
164,184,41
165,184,40
166,183,40
167,183,39
168,182,38
169,181,37
170,181,37
171,180,36
172,179,36
173,179,35
174,178,35
175,177,34
176,177,34
177,176,34
178,175,33
179,175,33
180,174,33
181,173,33
182,172,33
183,172,33
184,171,33
185,170,33
186,169,33
187,168,33
188,168,34
189,167,34
190,166,34
191,165,35
192,164,35
193,163,36
194,163,37
195,162,37
196,161,38
197,160,39
198,159,40
199,158,41
200,157,42
201,156,43
202,155,44
203,155,45
204,154,46
205,153,48
206,152,49
207,151,51
208,150,52
209,149,54
209,148,56
210,147,58
211,146,60
212,145,62
213,144,64
214,143,66
215,142,68
216,141,70
217,140,73
218,139,75
219,138,78
220,137,80
221,136,83
222,135,86
223,134,89
224,133,91
225,131,95
226,130,98
227,129,101
228,128,104
229,127,108
230,126,111
231,125,115
232,124,118
233,123,122
234,122,126
235,121,130

the converting of embedded palette with exiftool/convert goes from jpg(YCbCr) to RGB/sRGB
here is a sample with a rainbow palette

Code: [Select]
$ exiftool -Palette* FLIR0074.jpg
Palette Colors                  : 224
Palette Method                  : 0
Palette Stretch                 : 2
Palette File Name               : \FlashBFS\system\iron.pal
Palette Name                    : Iron
Palette                         : (Binary data 672 bytes, use -b option to extract)

$ exiftool -b -Palette FLIR0074.jpg | convert -size 224X1 -depth 8 YCbCr:- -separate -swap 1,2 -set colorspace YCbCr -combine -colorspace sRGB -compress none sRGB.ppm

//open sRGB.ppm in texteditor (RGB values)
P3         //see http://en.wikipedia.org/wiki/Portable_graymap
224 1     //224 pixel = colors
255
17 15 17  //first value: blue or gray
17 15 17
18 15 23
17 16 30
...
231 235 230
233 235 233
236 234 236  //last value

now convert the first value (dark blue:Y Cr Cb =25/122/159) with online color converter
http://www.picturetopeople.org/color_converter.html
Code: [Select]
Input Color :  YCbCr = (235, 130, 121)
Output:
RGB = (244, 255, 255);
CMY = (11, 0, 0)

RGB = (244, 255, 255) is the correct white yellow from flirtools.

I have not found a better solution with imagemagick.

another sample for RGB
Code: [Select]
$ exiftool -b -Palette FLIR0074.jpg | convert -size 224X1 -depth 8 YCbCr:- -separate -swap 1,2 -set colorspace YCbCr -combine -colorspace RGB -resize 448x30! RGB.pngresult:


and sRGB
Code: [Select]
$ exiftool -b -Palette FLIR0074.jpg | convert -size 224X1 -depth 8 YCbCr:- -separate -swap 1,2 -set colorspace YCbCr -combine -colorspace sRGB -resize 448x30! sRGB.pngresult:


here you see a screenshot from FlirTools GUI, resized to 448x30 (yellow goes to white)


I have no idea how convert colors better


only for fun (swap channels)

Quote
$ echo -n ABCDEF | convert -size "2X1" -depth 8  ycbcr:- -separate -swap 1,2 -combine -set colorspace ycbcr  - | hexdump -C
00000000  41 43 42 44 46 45                                 |ACBDFE|
« Last Edit: December 23, 2013, 11:06:11 pm by tomas123 »
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8429
Re: Flir E4 Thermal imaging camera teardown
« Reply #2528 on: December 22, 2013, 01:04:56 pm »
Hi People!
How make  my FLIR E8+ working as the webcam in Skype?
I knew someone was going to do this sooner or later... IR webcam chat! Show off how cool (or hot) you are to your friends! :-DD
 

Offline IRspector

  • Newbie
  • Posts: 5
  • Country: ru
Re: Flir E4 Thermal imaging camera teardown
« Reply #2529 on: December 22, 2013, 01:55:50 pm »

Ensure it's in VC-mode and then select it at the Skype settings? (untested)

Certainly I tried to do so.  But when I select Flir  Ex series in Skype or WebcamMax - than program freezes and requires a restart  :-- Somebody had positive experience using Flir Ex as webacam?
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2530 on: December 22, 2013, 02:37:13 pm »
Somebody had positive experience using Flir Ex as webacam?
Sure, just not in skype. UVC mode is pretty universal, so it should work with lots of software. So far I haven't encountered any issues.
 

Offline IRspector

  • Newbie
  • Posts: 5
  • Country: ru
Re: Flir E4 Thermal imaging camera teardown
« Reply #2531 on: December 22, 2013, 02:59:57 pm »
Sure, just not in skype. UVC mode is pretty universal, so it should work with lots of software. So far I haven't encountered any issues.

OK. What software do you use for this purpose? I try 3 programs - Skype, WebacamMax and Movavi Video Suite. And install newest Flir Driver - But it  doesn't work :wtf:
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2532 on: December 22, 2013, 03:30:04 pm »
OK. What software do you use for this purpose? I try 3 programs - Skype, WebacamMax and Movavi Video Suite. And install newest Flir Driver - But it  doesn't work :wtf:
For viewing, recording and streaming I use mplayer, mencoder and ffmpeg+ffserver respectively.


 

Offline uwe

  • Newbie
  • Posts: 6
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2533 on: December 22, 2013, 04:23:01 pm »
And another one upgraded from E4 to E8. Many thanks to Mike  :clap:

For the records:

Version E4 1.1
Firmware 1.19.8
Calibrated 03.12.2013

:q! Uwe
 

Offline Myself

  • Contributor
  • Posts: 21
Re: Flir E4 Thermal imaging camera teardown
« Reply #2534 on: December 23, 2013, 03:03:24 am »
Well, hello, megathread!

Purchased my E4 from flir-direct.com on 2013-12-11, they shipped on the 12th, it arrived on my doorstep on the 16th, but I wasn't home, picked it up from the UPS depot on the 17th.

E4 1.1
Serial 639085xx
Software 1.19.8
Manufacture/calibration date 2013-11-28.

Got mine in the $995 bundle including the Reed tachometer, which is cheaply built for its suggested retail price, but seems to work and makes a nice addition to the lab. :)

Hack was easier than I expected, I came in over RNDIS and skipped all the .cmd and .fif stuff, just dropped the crc'd e8.cfg into config.d and rebooted, et voila! I then immediately lost USB connection (windows "device has malfunctioned" error) and nearly soiled myself with dread.  :-BROKE Nope, my USB cable was just on the brink! Grabbed a better cable and it's been smooth sailing ever since.

Haven't even done the menus yet. Been having too much fun taking pictures of kilns, watching board temperatures during soldering, and diagnosing 3D printer heat-bed problems.  :-+

Q: What do you call a thermal infrared sensor who's totally harshing your mellow?
A: Na hapbby zvpebobybzrgre.
(That's rot13, in case you're new to the internet.)
 

Offline Myself

  • Contributor
  • Posts: 21
Re: Flir E4 Thermal imaging camera teardown
« Reply #2535 on: December 23, 2013, 06:11:06 am »
I can't open the battery stats on the Flir E4.
What do you mean with "hold LEFT + RIGHT cursor"?
When the E4 is busy charging you press the LEFT button and the RIGHT button at the same time for a while.

Edit: to clarify, the camera should be attached to usb or charger (obviously) and powered down.

Not sure if anyone's still interested, but I just checked using an HP 6220B, and I'm seeing a curious discrepancy: The HP supply shows almost exactly 300mA being drawn (maybe 310) over the USB connection, but the E4 reports 496mA on that screen. I wonder if it might have a buck converter in there? I haven't gone in to measure the actual battery current.

(I've got banana leads connected to a USB jack, with the data pins shorted. Ran the camera down to about 20% before starting this.)

After throwing another ammeter inline on the supply, the HP reports 195mA, the inline 327mA, and the E4 170mA. I suspect that voltage drop in the longer leads may be coming into play...

Well, sorta! I upped the voltage a bit to compensate for that (back from 4.6 to 4.9 at the terminals) and charging current *dropped*.

...tf? I've decided I don't care that much!
 

Offline amyk

  • Super Contributor
  • ***
  • Posts: 8429
Re: Flir E4 Thermal imaging camera teardown
« Reply #2536 on: December 23, 2013, 06:15:27 am »
After throwing another ammeter inline on the supply, the HP reports 195mA, the inline 327mA
Have you calibrated the ammeters? Because I have a hard time believing you've broken Kirchhoff's current law...
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2537 on: December 23, 2013, 07:04:24 am »
After throwing another ammeter inline on the supply, the HP reports 195mA, the inline 327mA, and the E4 170mA. I suspect that voltage drop in the longer leads may be coming into play...
If your HP supply says outgoing current is 195 mA and your other meter says it's 327 mA then this measurement is a wee bit suspect. What the E4 says at that point is irrelevant because the logic chain already went tits up way before we even got to the E4. Anyways, the E4 indicating a current higher than the current drawn over USB is not that strange. I don't know, but I would expect the E4 to monitor the actual current flowing into the battery (single cell Li-Ion right?) because that is what matter for making sure the battery lives a long happy life, and also doesn't blow up in your face or burns the house down. Like the charger pod Aurora took apart the E4 could have an LTC4001 or something similar in there.
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2538 on: December 23, 2013, 09:36:53 am »
I have no idea how convert colors better
An alternative is to read the YUV values from the .pal file, and then use your own function to do the conversion. I use a slightly modified version of the yuv2rgb method in this stackoverflow page to do just that. Should be easy enough to port to php for inclusion in your tool.

 

Online mikeselectricstuffTopic starter

  • Super Contributor
  • ***
  • Posts: 14033
  • Country: gb
    • Mike's Electric Stuff
Re: Flir E4 Thermal imaging camera teardown
« Reply #2539 on: December 23, 2013, 10:03:48 am »
I can't open the battery stats on the Flir E4.
What do you mean with "hold LEFT + RIGHT cursor"?
When the E4 is busy charging you press the LEFT button and the RIGHT button at the same time for a while.

Edit: to clarify, the camera should be attached to usb or charger (obviously) and powered down.

Not sure if anyone's still interested, but I just checked using an HP 6220B, and I'm seeing a curious discrepancy: The HP supply shows almost exactly 300mA being drawn (maybe 310) over the USB connection, but the E4 reports 496mA on that screen. I wonder if it might have a buck converter in there?
Easy enough to  test - just adjust the PSU  voltage & see if current increases as voltage drops
Youtube channel:Taking wierd stuff apart. Very apart.
Mike's Electric Stuff: High voltage, vintage electronics etc.
Day Job: Mostly LEDs
 

Offline daves

  • Regular Contributor
  • *
  • Posts: 103
  • Country: cz
Re: Flir E4 Thermal imaging camera teardown
« Reply #2540 on: December 23, 2013, 02:59:16 pm »
An alternative is to read the YUV values from the .pal file, and then use your own function to do the conversion.
I will try to implement it.

UPDATE... I DID. I used formulas from Wiki. Result is pretty same as IM. See. I will try to play with it.

Code: [Select]
Y:16 Cr:128 Cb:128 = R:0 G:0 B:0
Y:17 Cr:128 Cb:131 = R:1 G:-0 B:7
Y:18 Cr:127 Cb:134 = R:1 G:1 B:14
Y:19 Cr:126 Cb:137 = R:0 G:2 B:22
Y:20 Cr:126 Cb:142 = R:1 G:1 B:33
Y:21 Cr:125 Cb:148 = R:1 G:0 B:46
Y:22 Cr:124 Cb:154 = R:1 G:0 B:59
Y:23 Cr:123 Cb:156 = R:0 G:1 B:65
Y:24 Cr:122 Cb:158 = R:-0 G:2 B:70
Y:25 Cr:121 Cb:160 = R:0 G:4 B:75
Y:26 Cr:120 Cb:162 = R:0 G:5 B:80
Y:27 Cr:121 Cb:164 = R:2 G:4 B:85
Y:28 Cr:123 Cb:165 = R:6 G:4 B:89
Y:29 Cr:125 Cb:167 = R:10 G:2 B:94
Y:30 Cr:127 Cb:169 = R:15 G:1 B:99
Y:31 Cr:128 Cb:170 = R:17 G:1 B:102
Y:32 Cr:130 Cb:172 = R:22 G:-0 B:107
Y:33 Cr:132 Cb:173 = R:26 G:0 B:111
Y:34 Cr:133 Cb:174 = R:29 G:0 B:114
Y:35 Cr:135 Cb:175 = R:33 G:0 B:117
Y:36 Cr:136 Cb:177 = R:36 G:0 B:122
Y:37 Cr:138 Cb:178 = R:40 G:0 B:125
Y:38 Cr:140 Cb:179 = R:45 G:0 B:128
Y:39 Cr:141 Cb:180 = R:48 G:0 B:132
Y:40 Cr:143 Cb:181 = R:52 G:0 B:135
Y:41 Cr:144 Cb:181 = R:55 G:0 B:136
Y:42 Cr:145 Cb:182 = R:57 G:0 B:139
Y:43 Cr:147 Cb:183 = R:62 G:0 B:142
Y:44 Cr:148 Cb:183 = R:65 G:0 B:144
Y:44 Cr:150 Cb:184 = R:68 G:0 B:146
Y:45 Cr:151 Cb:185 = R:70 G:0 B:149
Y:46 Cr:152 Cb:185 = R:73 G:0 B:150
Y:47 Cr:154 Cb:185 = R:78 G:0 B:151
Y:48 Cr:155 Cb:186 = R:80 G:0 B:154
Y:49 Cr:156 Cb:186 = R:83 G:0 B:155
Y:50 Cr:157 Cb:186 = R:86 G:0 B:157
Y:51 Cr:159 Cb:186 = R:90 G:0 B:158
Y:52 Cr:160 Cb:186 = R:93 G:0 B:159
Y:53 Cr:161 Cb:186 = R:96 G:0 B:160
Y:54 Cr:162 Cb:186 = R:99 G:0 B:161
Y:55 Cr:163 Cb:186 = R:101 G:0 B:162
Y:56 Cr:165 Cb:186 = R:106 G:0 B:164
Y:57 Cr:166 Cb:186 = R:108 G:0 B:165
Y:58 Cr:167 Cb:186 = R:111 G:0 B:166
Y:59 Cr:168 Cb:186 = R:114 G:0 B:167
Y:60 Cr:169 Cb:185 = R:117 G:0 B:166
Y:61 Cr:170 Cb:185 = R:119 G:0 B:167
Y:62 Cr:171 Cb:185 = R:122 G:0 B:169
Y:63 Cr:172 Cb:184 = R:125 G:0 B:168
Y:64 Cr:173 Cb:184 = R:128 G:0 B:169
Y:65 Cr:174 Cb:183 = R:130 G:0 B:168
Y:66 Cr:175 Cb:182 = R:133 G:0 B:167
Y:67 Cr:176 Cb:182 = R:136 G:0 B:168
Y:68 Cr:177 Cb:181 = R:139 G:-0 B:167
Y:69 Cr:177 Cb:180 = R:140 G:2 B:167
Y:70 Cr:178 Cb:180 = R:143 G:2 B:168
Y:71 Cr:179 Cb:179 = R:145 G:3 B:167
Y:72 Cr:180 Cb:178 = R:148 G:3 B:166
Y:73 Cr:181 Cb:177 = R:151 G:4 B:165
Y:74 Cr:182 Cb:176 = R:154 G:5 B:164
Y:75 Cr:182 Cb:175 = R:155 G:6 B:164
Y:76 Cr:183 Cb:174 = R:158 G:7 B:163
Y:77 Cr:184 Cb:173 = R:160 G:8 B:162
Y:78 Cr:184 Cb:172 = R:162 G:9 B:161
Y:79 Cr:185 Cb:171 = R:164 G:10 B:160
Y:80 Cr:186 Cb:170 = R:167 G:11 B:159
Y:81 Cr:186 Cb:169 = R:168 G:12 B:158
Y:82 Cr:187 Cb:168 = R:171 G:13 B:158
Y:83 Cr:188 Cb:166 = R:174 G:14 B:155
Y:84 Cr:188 Cb:165 = R:175 G:16 B:154
Y:85 Cr:189 Cb:164 = R:178 G:17 B:153
Y:86 Cr:189 Cb:163 = R:179 G:18 B:152
Y:87 Cr:190 Cb:161 = R:182 G:19 B:149
Y:88 Cr:190 Cb:160 = R:183 G:21 B:148
Y:89 Cr:191 Cb:159 = R:186 G:22 B:148
Y:90 Cr:191 Cb:157 = R:187 G:24 B:145
Y:91 Cr:192 Cb:156 = R:189 G:24 B:144
Y:92 Cr:192 Cb:154 = R:191 G:26 B:141
Y:93 Cr:193 Cb:153 = R:193 G:27 B:140
Y:94 Cr:193 Cb:151 = R:195 G:29 B:137
Y:95 Cr:194 Cb:150 = R:197 G:30 B:136
Y:96 Cr:194 Cb:148 = R:198 G:32 B:133
Y:97 Cr:194 Cb:147 = R:200 G:33 B:133
Y:98 Cr:195 Cb:145 = R:202 G:34 B:130
Y:99 Cr:195 Cb:144 = R:204 G:36 B:129
Y:99 Cr:195 Cb:142 = R:204 G:37 B:125
Y:100 Cr:196 Cb:140 = R:206 G:38 B:122
Y:101 Cr:196 Cb:139 = R:208 G:39 B:121
Y:102 Cr:196 Cb:137 = R:209 G:41 B:118
Y:103 Cr:197 Cb:135 = R:211 G:42 B:115
Y:104 Cr:197 Cb:134 = R:213 G:44 B:115
Y:105 Cr:197 Cb:132 = R:214 G:46 B:112
Y:106 Cr:197 Cb:130 = R:215 G:48 B:109
Y:107 Cr:197 Cb:129 = R:216 G:49 B:108
Y:108 Cr:198 Cb:127 = R:219 G:51 B:105
Y:109 Cr:198 Cb:125 = R:220 G:53 B:102
Y:110 Cr:198 Cb:123 = R:221 G:55 B:99
Y:111 Cr:198 Cb:122 = R:222 G:56 B:99
Y:112 Cr:198 Cb:120 = R:224 G:58 B:96
Y:113 Cr:198 Cb:118 = R:225 G:60 B:93
Y:114 Cr:198 Cb:117 = R:226 G:62 B:92
Y:115 Cr:198 Cb:115 = R:227 G:63 B:89
Y:116 Cr:198 Cb:113 = R:228 G:65 B:86
Y:117 Cr:198 Cb:111 = R:229 G:67 B:83
Y:118 Cr:198 Cb:109 = R:230 G:69 B:80
Y:119 Cr:198 Cb:108 = R:232 G:71 B:80
Y:120 Cr:198 Cb:106 = R:233 G:73 B:77
Y:121 Cr:198 Cb:104 = R:234 G:75 B:74
Y:122 Cr:198 Cb:102 = R:235 G:77 B:71
Y:123 Cr:198 Cb:101 = R:236 G:78 B:70
Y:124 Cr:198 Cb:99 = R:237 G:80 B:67
Y:125 Cr:198 Cb:97 = R:239 G:82 B:64
Y:126 Cr:198 Cb:96 = R:240 G:84 B:64
Y:127 Cr:198 Cb:94 = R:241 G:86 B:61
Y:128 Cr:198 Cb:92 = R:242 G:88 B:58
Y:129 Cr:198 Cb:90 = R:243 G:90 B:55
Y:130 Cr:198 Cb:89 = R:244 G:91 B:54
Y:131 Cr:197 Cb:87 = R:244 G:94 B:51
Y:132 Cr:197 Cb:85 = R:245 G:96 B:48
Y:133 Cr:197 Cb:84 = R:246 G:97 B:47
Y:134 Cr:197 Cb:82 = R:248 G:99 B:45
Y:135 Cr:197 Cb:80 = R:249 G:101 B:42
Y:136 Cr:196 Cb:79 = R:248 G:104 B:41
Y:137 Cr:196 Cb:77 = R:249 G:106 B:38
Y:138 Cr:196 Cb:75 = R:251 G:108 B:35
Y:139 Cr:196 Cb:74 = R:252 G:109 B:34
Y:140 Cr:195 Cb:72 = R:251 G:112 B:31
Y:141 Cr:195 Cb:71 = R:252 G:113 B:31
Y:142 Cr:195 Cb:69 = R:254 G:115 B:28
Y:143 Cr:194 Cb:68 = R:253 G:118 B:27
Y:144 Cr:194 Cb:66 = R:254 G:120 B:24
Y:145 Cr:194 Cb:65 = R:255 G:121 B:23
Y:146 Cr:193 Cb:63 = R:255 G:124 B:20
Y:147 Cr:193 Cb:62 = R:255 G:126 B:19
Y:148 Cr:193 Cb:60 = R:255 G:127 B:17
Y:149 Cr:192 Cb:59 = R:255 G:130 B:16
Y:150 Cr:192 Cb:58 = R:255 G:131 B:15
Y:151 Cr:191 Cb:56 = R:255 G:134 B:12
Y:152 Cr:191 Cb:55 = R:255 G:136 B:11
Y:153 Cr:191 Cb:54 = R:255 G:137 B:10
Y:154 Cr:190 Cb:53 = R:255 G:140 B:9
Y:154 Cr:190 Cb:51 = R:255 G:140 B:5
Y:155 Cr:189 Cb:50 = R:255 G:143 B:5
Y:156 Cr:189 Cb:49 = R:255 G:144 B:4
Y:157 Cr:188 Cb:48 = R:255 G:147 B:3
Y:158 Cr:188 Cb:47 = R:255 G:148 B:2
Y:159 Cr:187 Cb:46 = R:255 G:151 B:1
Y:160 Cr:187 Cb:45 = R:255 G:152 B:0
Y:161 Cr:186 Cb:44 = R:255 G:155 B:0
Y:162 Cr:186 Cb:43 = R:255 G:156 B:0
Y:163 Cr:185 Cb:42 = R:255 G:159 B:0
Y:164 Cr:184 Cb:41 = R:255 G:161 B:0
Y:165 Cr:184 Cb:40 = R:255 G:162 B:0
Y:166 Cr:183 Cb:40 = R:255 G:164 B:0
Y:167 Cr:183 Cb:39 = R:255 G:166 B:0
Y:168 Cr:182 Cb:38 = R:255 G:168 B:0
Y:169 Cr:181 Cb:37 = R:255 G:171 B:0
Y:170 Cr:181 Cb:37 = R:255 G:172 B:0
Y:171 Cr:180 Cb:36 = R:255 G:174 B:0
Y:172 Cr:179 Cb:36 = R:255 G:176 B:0
Y:173 Cr:179 Cb:35 = R:255 G:178 B:0
Y:174 Cr:178 Cb:35 = R:255 G:180 B:0
Y:175 Cr:177 Cb:34 = R:255 G:182 B:0
Y:176 Cr:177 Cb:34 = R:255 G:183 B:0
Y:177 Cr:176 Cb:34 = R:255 G:185 B:0
Y:178 Cr:175 Cb:33 = R:255 G:188 B:0
Y:179 Cr:175 Cb:33 = R:255 G:189 B:0
Y:180 Cr:174 Cb:33 = R:255 G:191 B:0
Y:181 Cr:173 Cb:33 = R:255 G:193 B:0
Y:182 Cr:172 Cb:33 = R:255 G:195 B:2
Y:183 Cr:172 Cb:33 = R:255 G:196 B:3
Y:184 Cr:171 Cb:33 = R:255 G:198 B:4
Y:185 Cr:170 Cb:33 = R:255 G:200 B:5
Y:186 Cr:169 Cb:33 = R:255 G:202 B:6
Y:187 Cr:168 Cb:33 = R:255 G:204 B:7
Y:188 Cr:168 Cb:34 = R:255 G:205 B:11
Y:189 Cr:167 Cb:34 = R:255 G:207 B:12
Y:190 Cr:166 Cb:34 = R:255 G:209 B:13
Y:191 Cr:165 Cb:35 = R:255 G:210 B:16
Y:192 Cr:164 Cb:35 = R:255 G:212 B:17
Y:193 Cr:163 Cb:36 = R:255 G:214 B:21
Y:194 Cr:163 Cb:37 = R:255 G:214 B:24
Y:195 Cr:162 Cb:37 = R:255 G:216 B:25
Y:196 Cr:161 Cb:38 = R:255 G:218 B:28
Y:197 Cr:160 Cb:39 = R:255 G:220 B:31
Y:198 Cr:159 Cb:40 = R:255 G:221 B:34
Y:199 Cr:158 Cb:41 = R:255 G:223 B:38
Y:200 Cr:157 Cb:42 = R:255 G:224 B:41
Y:201 Cr:156 Cb:43 = R:255 G:226 B:44
Y:202 Cr:155 Cb:44 = R:255 G:228 B:47
Y:203 Cr:155 Cb:45 = R:255 G:228 B:50
Y:204 Cr:154 Cb:46 = R:255 G:230 B:53
Y:205 Cr:153 Cb:48 = R:255 G:231 B:59
Y:206 Cr:152 Cb:49 = R:255 G:233 B:62
Y:207 Cr:151 Cb:51 = R:255 G:234 B:67
Y:208 Cr:150 Cb:52 = R:255 G:235 B:70
Y:209 Cr:149 Cb:54 = R:255 G:237 B:75
Y:209 Cr:148 Cb:56 = R:255 G:237 B:79
Y:210 Cr:147 Cb:58 = R:255 G:238 B:85
Y:211 Cr:146 Cb:60 = R:255 G:239 B:90
Y:212 Cr:145 Cb:62 = R:255 G:240 B:95
Y:213 Cr:144 Cb:64 = R:255 G:241 B:100
Y:214 Cr:143 Cb:66 = R:254 G:243 B:105
Y:215 Cr:142 Cb:68 = R:254 G:244 B:111
Y:216 Cr:141 Cb:70 = R:254 G:245 B:116
Y:217 Cr:140 Cb:73 = R:253 G:246 B:123
Y:218 Cr:139 Cb:75 = R:253 G:247 B:128
Y:219 Cr:138 Cb:78 = R:252 G:248 B:136
Y:220 Cr:137 Cb:80 = R:252 G:249 B:141
Y:221 Cr:136 Cb:83 = R:251 G:250 B:148
Y:222 Cr:135 Cb:86 = R:251 G:251 B:155
Y:223 Cr:134 Cb:89 = R:251 G:251 B:162
Y:224 Cr:133 Cb:91 = R:250 G:253 B:168
Y:225 Cr:131 Cb:95 = R:248 G:254 B:177
Y:226 Cr:130 Cb:98 = R:248 G:255 B:184
Y:227 Cr:129 Cb:101 = R:247 G:255 B:191
Y:228 Cr:128 Cb:106 = R:247 G:255 B:202
Y:229 Cr:127 Cb:111 = R:246 G:255 B:214
Y:230 Cr:126 Cb:115 = R:246 G:255 B:223
Y:231 Cr:125 Cb:120 = R:246 G:255 B:234
Y:232 Cr:125 Cb:123 = R:247 G:255 B:241
Y:233 Cr:126 Cb:126 = R:249 G:255 B:249
Y:234 Cr:127 Cb:127 = R:252 G:255 B:252
Y:235 Cr:128 Cb:128 = R:255 G:255 B:255
« Last Edit: December 23, 2013, 06:32:13 pm by daves »
Batch Thermal Images Editor (JPG, BMT, SNP, IRI, ISI, IS2, PGM, TIF, IMG, BMP):  https://www.eevblog.com/forum/testgear/flir-e4-thermal-imaging-camera-teardown/msg350556/#msg350556
 

Online Fraser

  • Super Contributor
  • ***
  • Posts: 13417
  • Country: gb
Re: Flir E4 Thermal imaging camera teardown
« Reply #2541 on: December 23, 2013, 07:41:22 pm »
Regarding the charging current. The chip in the external charger (L4001) uses a linear trickle charger to trickle charge a battery at 50mA in order to meet the minimum charge voltage. It then switches to a PWM charger. PWM will likely confuse a DC current monitoring device as it isn't dc it is switched DC  ;)
You would need to monitor the charge current with a dc current probe and oscilloscope.
If I have helped you please consider a donation : https://gofund.me/c86b0a2c
 

Offline tomas123

  • Frequent Contributor
  • **
  • Posts: 832
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2542 on: December 23, 2013, 10:45:11 pm »
@daves

your file FLIR0040_palette_FLIR.png and  FLIR0040_palette_BT601.png looks great (your yellow goes to white).
Converted with which formulas from Wikipedia?
I think you stretched the footroom and headroom (killed offset of 16)

for information:
I discussed the IM YCbCr conversion with the IM site admin  :-+ here in may:
http://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=23404

you wrote for the brightest value of iron scale
Quote
Y:235 Cr:128 Cb:128 = R:255 G:255 B:255
but http://en.wikipedia.org/wiki/YCbCr#JPEG_conversion

goes to gray R:235 G:235 B:235 (=Y) and not white

this is exact the IM convert formula (see my forum link above)
Code: [Select]
$ convert xc:'sRGB(235,128,128)' -set colorspace ycbcr -colorspace srgb -format "rgb(%[fx:round(255*u.r,1)],%[fx:round(255*u.g)],%[fx:round(255*u.b)])" info:
rgb(236,234,236)
or simply
Code: [Select]
$ convert "xc:sRGB(235,128,128)" -set colorspace YCbCr -colorspace srgb -depth 8 -verbose info: | grep "#"
         1: (236,234,236) #ECEAEC srgb(236,234,236)
« Last Edit: December 24, 2013, 12:52:50 am by tomas123 »
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2543 on: December 24, 2013, 12:52:51 am »
you wrote for the brightest value of iron scale
Quote
Y:235 Cr:128 Cb:128 = R:255 G:255 B:255
but http://en.wikipedia.org/wiki/YCbCr#JPEG_conversion

goes to gray R:235 G:235 B:235 (=Y) and not white
You have to be careful converting back and forth, since there are two "standards". I think I posted about that eons ago in this thread. One is the crappy (IMO) clipped range, and the other is the full 0-255 range. Anyways, daves' result looks like a correct implementation of the bit of code I suggested. He now gets the exact same pretty non-washed out full range colors I get.

Check out the "## ITU-R BT.601 version (SDTV)" bit in yuv2rgb on the stackoverflow page. If you fill in Y:235 Cr:128 Cb:128, then you do in fact get R:255 G:255 B:255.

I love standards. There's so many of them, you can always pick one you like...
 

Offline tomas123

  • Frequent Contributor
  • **
  • Posts: 832
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2544 on: December 24, 2013, 01:08:35 am »
you are right,
with the palette from Daves BT.601 give the best result (clip offset of 16) for Y:235 Cr:128 Cb:128 (bright value)

but my FlirTools from Mac and IOS using a iron palette, where the white value is YCrCb=235,121,130   
BT.601 goes to RGB=243,259,259 (out of 8 Bit Range)

I think Flir uses different palettes on Mac and Windows.
I asked Daves to post his iron.pal file (Windows?)

As attachment my (Mac/IOS) palettes and a excel sheet for converting jpg and BT.601
« Last Edit: December 24, 2013, 01:13:20 am by tomas123 »
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2545 on: December 24, 2013, 01:19:44 am »

but my FlirTools from Mac and IOS using a iron palette, where the white value is YCrCb=235,121,130   
BT.601 goes to RGB=243,259,259 (out of 8 Bit Range)

I think Flir uses different palettes on Mac and Windows.
Ey? What happened to ignoring all that and just grabbing the .pal files from your E4?
 

Offline tomas123

  • Frequent Contributor
  • **
  • Posts: 832
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2546 on: December 24, 2013, 01:36:05 am »
I answer myself:

the embedded palette in Flir jpg is compatible with BT.601 footroom and headroom (range 16...238)

Code: [Select]
$ exiftool -PaletteFileName FLIR0078.jpg
Palette File Name               : \FlashBFS\system\iron.pal

$ exiftool -b -Palette FLIR0078.jpg | hexdump -v -e '/3 "YCrCb ="' -e '3/1 " %03u ""\n"'
YCrCb = 016  128  128
YCrCb = 017  128  131
YCrCb = 018  127  134
YCrCb = 019  126  137
YCrCb = 020  126  142
YCrCb = 021  125  148
YCrCb = 022  124  154
YCrCb = 023  123  156
YCrCb = 024  122  158
YCrCb = 025  121  160
YCrCb = 026  120  162
YCrCb = 027  121  164
YCrCb = 028  123  165
YCrCb = 029  125  167
YCrCb = 030  127  169
YCrCb = 031  128  170
YCrCb = 032  130  172
YCrCb = 033  132  173
YCrCb = 034  133  174
YCrCb = 035  135  175
YCrCb = 036  136  177
YCrCb = 037  138  178
YCrCb = 038  140  179
YCrCb = 039  141  180
YCrCb = 040  143  181
YCrCb = 041  144  181
YCrCb = 042  145  182
YCrCb = 043  147  183
YCrCb = 044  148  183
YCrCb = 044  150  184
YCrCb = 045  151  185
YCrCb = 046  152  185
YCrCb = 047  154  185
YCrCb = 048  155  186
YCrCb = 049  156  186
YCrCb = 050  157  186
YCrCb = 051  159  186
YCrCb = 052  160  186
YCrCb = 053  161  186
YCrCb = 054  162  186
YCrCb = 055  163  186
YCrCb = 056  165  186
YCrCb = 057  166  186
YCrCb = 058  167  186
YCrCb = 059  168  186
YCrCb = 060  169  185
YCrCb = 061  170  185
YCrCb = 062  171  185
YCrCb = 063  172  184
YCrCb = 064  173  184
YCrCb = 065  174  183
YCrCb = 066  175  182
YCrCb = 067  176  182
YCrCb = 068  177  181
YCrCb = 069  177  180
YCrCb = 070  178  180
YCrCb = 071  179  179
YCrCb = 072  180  178
YCrCb = 073  181  177
YCrCb = 074  182  176
YCrCb = 075  182  175
YCrCb = 076  183  174
YCrCb = 077  184  173
YCrCb = 078  184  172
YCrCb = 079  185  171
YCrCb = 080  186  170
YCrCb = 081  186  169
YCrCb = 082  187  168
YCrCb = 083  188  166
YCrCb = 084  188  165
YCrCb = 085  189  164
YCrCb = 086  189  163
YCrCb = 087  190  161
YCrCb = 088  190  160
YCrCb = 089  191  159
YCrCb = 090  191  157
YCrCb = 091  192  156
YCrCb = 092  192  154
YCrCb = 093  193  153
YCrCb = 094  193  151
YCrCb = 095  194  150
YCrCb = 096  194  148
YCrCb = 097  194  147
YCrCb = 098  195  145
YCrCb = 099  195  144
YCrCb = 099  195  142
YCrCb = 100  196  140
YCrCb = 101  196  139
YCrCb = 102  196  137
YCrCb = 103  197  135
YCrCb = 104  197  134
YCrCb = 105  197  132
YCrCb = 106  197  130
YCrCb = 107  197  129
YCrCb = 108  198  127
YCrCb = 109  198  125
YCrCb = 110  198  123
YCrCb = 111  198  122
YCrCb = 112  198  120
YCrCb = 113  198  118
YCrCb = 114  198  117
YCrCb = 115  198  115
YCrCb = 116  198  113
YCrCb = 117  198  111
YCrCb = 118  198  109
YCrCb = 119  198  108
YCrCb = 120  198  106
YCrCb = 121  198  104
YCrCb = 122  198  102
YCrCb = 123  198  101
YCrCb = 124  198  099
YCrCb = 125  198  097
YCrCb = 126  198  096
YCrCb = 127  198  094
YCrCb = 128  198  092
YCrCb = 129  198  090
YCrCb = 130  198  089
YCrCb = 131  197  087
YCrCb = 132  197  085
YCrCb = 133  197  084
YCrCb = 134  197  082
YCrCb = 135  197  080
YCrCb = 136  196  079
YCrCb = 137  196  077
YCrCb = 138  196  075
YCrCb = 139  196  074
YCrCb = 140  195  072
YCrCb = 141  195  071
YCrCb = 142  195  069
YCrCb = 143  194  068
YCrCb = 144  194  066
YCrCb = 145  194  065
YCrCb = 146  193  063
YCrCb = 147  193  062
YCrCb = 148  193  060
YCrCb = 149  192  059
YCrCb = 150  192  058
YCrCb = 151  191  056
YCrCb = 152  191  055
YCrCb = 153  191  054
YCrCb = 154  190  053
YCrCb = 154  190  051
YCrCb = 155  189  050
YCrCb = 156  189  049
YCrCb = 157  188  048
YCrCb = 158  188  047
YCrCb = 159  187  046
YCrCb = 160  187  045
YCrCb = 161  186  044
YCrCb = 162  186  043
YCrCb = 163  185  042
YCrCb = 164  184  041
YCrCb = 165  184  040
YCrCb = 166  183  040
YCrCb = 167  183  039
YCrCb = 168  182  038
YCrCb = 169  181  037
YCrCb = 170  181  037
YCrCb = 171  180  036
YCrCb = 172  179  036
YCrCb = 173  179  035
YCrCb = 174  178  035
YCrCb = 175  177  034
YCrCb = 176  177  034
YCrCb = 177  176  034
YCrCb = 178  175  033
YCrCb = 179  175  033
YCrCb = 180  174  033
YCrCb = 181  173  033
YCrCb = 182  172  033
YCrCb = 183  172  033
YCrCb = 184  171  033
YCrCb = 185  170  033
YCrCb = 186  169  033
YCrCb = 187  168  033
YCrCb = 188  168  034
YCrCb = 189  167  034
YCrCb = 190  166  034
YCrCb = 191  165  035
YCrCb = 192  164  035
YCrCb = 193  163  036
YCrCb = 194  163  037
YCrCb = 195  162  037
YCrCb = 196  161  038
YCrCb = 197  160  039
YCrCb = 198  159  040
YCrCb = 199  158  041
YCrCb = 200  157  042
YCrCb = 201  156  043
YCrCb = 202  155  044
YCrCb = 203  155  045
YCrCb = 204  154  046
YCrCb = 205  153  048
YCrCb = 206  152  049
YCrCb = 207  151  051
YCrCb = 208  150  052
YCrCb = 209  149  054
YCrCb = 209  148  056
YCrCb = 210  147  058
YCrCb = 211  146  060
YCrCb = 212  145  062
YCrCb = 213  144  064
YCrCb = 214  143  066
YCrCb = 215  142  068
YCrCb = 216  141  070
YCrCb = 217  140  073
YCrCb = 218  139  075
YCrCb = 219  138  078
YCrCb = 220  137  080
YCrCb = 221  136  083
YCrCb = 222  135  086
YCrCb = 223  134  089
YCrCb = 224  133  091
YCrCb = 225  131  095
YCrCb = 226  130  098
YCrCb = 227  129  101
YCrCb = 228  128  106
YCrCb = 229  127  111
YCrCb = 230  126  115
YCrCb = 231  125  120
YCrCb = 232  125  123
YCrCb = 233  126  126
YCrCb = 234  127  127
YCrCb = 235  128  128
the last value is YCrCb = 235  128  128  :)

it's a nice sample for using hexdump, but they are the same values, like from Flir E4 file system \FlashBFS\system\iron.pal  |O
Code: [Select]
[version]
name=Iron
major=1
minor=2
edit=1
date=21-Nov-2012
[noOfColors]
224
[stretch]
2
[method]
0
[specialColors]
# Values in Y Cr Cb order
# overflow, red
67, 216, 98
# underflow, blue
41, 110, 240
#above, light gray
170, 128, 128
#below, dark gray
50, 128, 128
# isotherm 1, gray
100, 128, 128
# isotherm 2, blue
100, 110, 240
[palette]
#palette (224 colors)
16,128,128
17,128,131
18,127,134
19,126,137
20,126,142
21,125,148
22,124,154
23,123,156
24,122,158
25,121,160
26,120,162
27,121,164
28,123,165
29,125,167
30,127,169
31,128,170
32,130,172
33,132,173
34,133,174
35,135,175
36,136,177
37,138,178
38,140,179
39,141,180
40,143,181
41,144,181
42,145,182
43,147,183
44,148,183
44,150,184
45,151,185
46,152,185
47,154,185
48,155,186
49,156,186
50,157,186
51,159,186
52,160,186
53,161,186
54,162,186
55,163,186
56,165,186
57,166,186
58,167,186
59,168,186
60,169,185
61,170,185
62,171,185
63,172,184
64,173,184
65,174,183
66,175,182
67,176,182
68,177,181
69,177,180
70,178,180
71,179,179
72,180,178
73,181,177
74,182,176
75,182,175
76,183,174
77,184,173
78,184,172
79,185,171
80,186,170
81,186,169
82,187,168
83,188,166
84,188,165
85,189,164
86,189,163
87,190,161
88,190,160
89,191,159
90,191,157
91,192,156
92,192,154
93,193,153
94,193,151
95,194,150
96,194,148
97,194,147
98,195,145
99,195,144
99,195,142
100,196,140
101,196,139
102,196,137
103,197,135
104,197,134
105,197,132
106,197,130
107,197,129
108,198,127
109,198,125
110,198,123
111,198,122
112,198,120
113,198,118
114,198,117
115,198,115
116,198,113
117,198,111
118,198,109
119,198,108
120,198,106
121,198,104
122,198,102
123,198,101
124,198,99
125,198,97
126,198,96
127,198,94
128,198,92
129,198,90
130,198,89
131,197,87
132,197,85
133,197,84
134,197,82
135,197,80
136,196,79
137,196,77
138,196,75
139,196,74
140,195,72
141,195,71
142,195,69
143,194,68
144,194,66
145,194,65
146,193,63
147,193,62
148,193,60
149,192,59
150,192,58
151,191,56
152,191,55
153,191,54
154,190,53
154,190,51
155,189,50
156,189,49
157,188,48
158,188,47
159,187,46
160,187,45
161,186,44
162,186,43
163,185,42
164,184,41
165,184,40
166,183,40
167,183,39
168,182,38
169,181,37
170,181,37
171,180,36
172,179,36
173,179,35
174,178,35
175,177,34
176,177,34
177,176,34
178,175,33
179,175,33
180,174,33
181,173,33
182,172,33
183,172,33
184,171,33
185,170,33
186,169,33
187,168,33
188,168,34
189,167,34
190,166,34
191,165,35
192,164,35
193,163,36
194,163,37
195,162,37
196,161,38
197,160,39
198,159,40
199,158,41
200,157,42
201,156,43
202,155,44
203,155,45
204,154,46
205,153,48
206,152,49
207,151,51
208,150,52
209,149,54
209,148,56
210,147,58
211,146,60
212,145,62
213,144,64
214,143,66
215,142,68
216,141,70
217,140,73
218,139,75
219,138,78
220,137,80
221,136,83
222,135,86
223,134,89
224,133,91
225,131,95
226,130,98
227,129,101
228,128,106
229,127,111
230,126,115
231,125,120
232,125,123
233,126,126
234,127,127
235,128,128
« Last Edit: December 24, 2013, 01:58:28 am by tomas123 »
 

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2547 on: December 24, 2013, 01:41:50 am »
I answer myself:

the embedded palette in Flir jpg is compatible with BT.601 footroom and headroom (range 16...238)
Yup. :)

Quote
... are the same values, like from Flir E4 folder \FlashBFS\system\iron.pal  |O
Well obviously. Where do you think those palettes embedded in the jpegs come from?  ;D
 

Offline tomas123

  • Frequent Contributor
  • **
  • Posts: 832
  • Country: de
Re: Flir E4 Thermal imaging camera teardown
« Reply #2548 on: December 24, 2013, 01:58:08 am »

IM convert has Rec601YCbCr color space, but it doesn't stretch the offset of 16

http://www.imagemagick.org/script/command-line-options.php#colorspace
Quote
$ convert xc:'sRGB(235,128,128)' -set colorspace Rec601YCbCr -colorspace srgb -format "rg(%[fx:round(255*u.r,1)],%[fx:round(255*u.g)],%[fx:round(255*u.b)])" info:
rg(236,234,236)
$ convert xc:'sRGB(235,128,128)' -set colorspace ycbcr -colorspace srgb -format "rgb(%[fx:round(255*u.r,1)],%[fx:round(255*u.g)],%[fx:round(255*u.b)])" info:
rgb(236,234,236)

I think, IM convert can BT.601 conversion with the fx operator
http://www.imagemagick.org/script/fx.php
http://www.imagemagick.org/Usage/transform/#fx
but I have to sleep on it

Offline mrflibble

  • Super Contributor
  • ***
  • Posts: 2051
  • Country: nl
Re: Flir E4 Thermal imaging camera teardown
« Reply #2549 on: December 24, 2013, 02:05:21 am »
IM convert has Rec601YCbCr color space, but it doesn't stretch the offset of 16
In the past I tried convert as well for the color conversion, but it didn't do what I wanted... It was much easier to just read the .pal file and output a temp png file with the palette (with proper RGB values) for use with -clut.

One of those days I really should cut out the intermediate -clut step, but what the hell, it works...
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf