Cameras & sensorsHow-to

Integrate a thermal camera into a DAQ application via its SDK

Integrate a thermal camera into your DAQ application: load the SDK DLL, grab radiometric frames, convert counts to °C, and size the PC for the frame rate.

LumaSpec Vision11 min read Share on LinkedIn

On this page 9 sections
  1. 01What do you need before you integrate a thermal camera into a DAQ application?
  2. 02How do you call the camera's SDK from a DAQ program with no native driver?
  3. 03Which camera and PC keep up with your frame rate?
  4. 04How do you get true temperatures instead of the palette picture?
  5. 05How do you convert raw thermal counts to °C?
  6. 06How do you stop frames from tearing or dropping mid-run?
  7. 07How do you verify the temperatures you logged are right?
  8. 08When should you skip the SDK and pick a GigE Vision camera instead?
  9. 09Questions

Here is the whole decision in one line: if the camera ships a documented DLL or C API, your DAQ program needs four to six library calls — initialize, start streaming, copy each frame, stop — and a buffer budget of 640 × 512 pixels × 2 bytes × 50 frames/s ≈ 33 MB/s per camera, about a quarter of a GigE link. Load the SDK at runtime, pull radiometric 16-bit counts instead of palette pictures, convert each count to °C with the scale and offset the SDK reports, and size the host PC, link and storage from that 33 MB/s figure. You have a process or a test rig that already logs pressures, currents and speeds, and now it needs temperature as an image: one thermal camera, one DAQ program, and a maker SDK your DAQ software has never heard of. This guide gives the order of operations, so you can redo the arithmetic with your own camera's pixel count and frame rate before you commit.

What do you need before you integrate a thermal camera into a DAQ application?

Three things decide the project before you write any code: a camera whose maker ships a documented DLL or C API, a PC with one free GigE or USB3 port, and the camera's calibration range in °C — the DAQ package you run matters far less than those three.

Gather four items first:

  • the SDK package, taken from the camera maker's own download area or your distributor: the DLL, the header file with every function signature, and the manual;
  • your DAQ environment's mechanism for calling an external library;
  • the connection settings — for a TCP/IP camera, its IP address and port on your subnet;
  • the temperature range the camera is calibrated for, which tells you what the raw counts will span.

For the host, a fanless vision controller is the usual choice, because it puts several LAN ports, industrial power and I/O in one box. The MV-VC3301H-128G66 covers a single-camera bench: 5+ LAN ports, an Intel Core i3, 8 GB of RAM and a 128 GB SSD, with PCIe expansion if you later add interface cards.

Vision controllersHikrobot MV-VC3301H-128G66 I3-8100, 8GB+128G SSD, No PoE, PCIe expansion supported, Incl. VM6200Pro licenseMV-VC3301H-128G66
LAN ports
5+ LAN ports
USB 3 ports
3-4 USB 3 ports
Light outputs
4 built-in channels
Memory
8 GB
$2,419.00View partBuild a system with it

How do you call the camera's SDK from a DAQ program with no native driver?

You load the vendor DLL at runtime and call its functions in a fixed order — initialize, start streaming, copy each frame into your own memory, stop and release — usually four to six calls, whatever DAQ package sits on top.

The sequence is the same for every thermal SDK:

  1. Install the SDK from the maker's package. You get the DLL, the header and the manual. The DLL name and each function's exact signature come from the header; declare them exactly, because a wrong argument list is the classic cause of an access violation on the first call.
  2. Declare the functions in your DAQ environment. Many packages have a single library-call mechanism for this — extern() in one well-known DAQ package — where you declare the return type and argument types once, then call each function by name.
  3. Load the DLL and resolve the function addresses. On Windows the calls are LoadLibraryA and GetProcAddress:
/* Illustrative flow: <angle brackets> stand in for names
   in your SDK's header file and manual. */
HMODULE lib  = LoadLibraryA("<dll name from the SDK manual>");
FARPROC init = GetProcAddress(lib, "<initialize function from the header>");
FARPROC grab = GetProcAddress(lib, "<frame function from the header>");
  1. Open the connection with the manual's settings. A TCP/IP camera takes an IP address and port on the same subnet as the DAQ PC; a USB module takes a device enumeration call.
  2. Start the stream and copy each frame into your own buffer inside the callback, before you log, plot or convert anything.
  3. Shut down in reverse order: stop the stream, close the camera, free the library.

The callback pattern — grab, copy, hand off to a worker — matches the one used with standard industrial cameras: calling a camera SDK DLL with callbacks, buffers and a snap walks through it call by call. If the first call fails with a missing-module error, matching the DLL to the target OS is the fix plan. When the DAQ PC later moves to production, running your application without the SDK installed lists which runtime files to ship with it.

Which camera and PC keep up with your frame rate?

Do the buffer math first: 640 × 512 pixels × 2 bytes per count × 50 frames/s ≈ 33 MB/s, about a quarter of a GigE link, so one camera per port is comfortable and the DAQ PC needs buffered LAN plus a disk that sustains 33 MB/s of writes.

The LS-IRC-0044 is exactly that stream: a 640 × 512 LWIR camera delivering 50 Hz over GigE, sensing 8-14 μm, with an 88.5° × 73.2° field of view, a C-mount lens mount and a 9-24 V DC supply.

Infrared cameras640 x 512 thermal camera, 8-14 μm, 50 Hz, GigE, FOV 88.5° × 73.2°, 9-24 V DC (LS-IRC-0044)LS-IRC-0044
Lens mount
C-mount
Interface
GigE
Resolution
Up to 3 MP
Spectrum
LWIR
$5,885.00 · quotedView and quote

When the camera hangs on a short bench cable instead of the plant network, the LS-IRC-0016 is a 640 × 512 LWIR module that streams over USB3.

Infrared camerasLWIR thermal camera module, USB3, 640×512 resolution (LS-IRC-0016)LS-IRC-0016
Interface
USB3
$3,999.00 · quotedView and quote

Scale is linear. Four cameras of that class write 4 × 32.8 ≈ 131 MB/s, so put each camera on its own LAN port and log to a fast SSD. The MV-VC5525-256G70-NN carries that load: 5+ LAN ports, a 12th-generation Intel Core i5, 32 GB of RAM, a 256 GB SSD, PoE camera ports and 8 built-in light channels.

Vision controllersHikrobot MV-VC5525-256G70-NN VC5000 Vision Controller, 12th-I5, 32GB+256G SSD, Supported PCIEMV-VC5525-256G70-NN
LAN ports
5+ LAN ports
USB 3 ports
3-4 USB 3 ports
PoE
PoE camera ports
Light outputs
8 built-in channels
$4,479.00 · quotedView and quoteBuild a system with it

The camera finder filters the infrared cameras by interface, resolution and shutter, so you can shortlist models that match the arithmetic above.

How do you get true temperatures instead of the palette picture?

Ask the SDK for the radiometric stream, not the rendered image: each pixel then arrives as a 16-bit count proportional to the infrared the sensor received, and you log °C instead of decoding the 8-bit palette colors the viewer draws.

Radiometric output is a capability of the camera class, not code you add on. Two habits make it pay off. If the SDK offers a structured payload that already carries calibrated values per pixel or per ROI, parse that and skip the conversion step — reading a camera's temperature data with structured types shows the parsing pattern. Keep the 16-bit grayscale for analysis and render color only for the operator's screen: exporting high-bitdepth grayscale from thermal cameras covers the file formats that preserve every bit, and a pseudocolor map from 16-bit counts to a palette makes the live view readable without touching what you store.

How do you convert raw thermal counts to °C?

Use the scale and offset the SDK reports with every frame: °C = count × scale + offset, so a frame reporting scale 0.01 and offset −50.00 turns a count of 8,000 into 30.00 °C — and read the pair per frame, because it follows the camera's calibration range.

temperature (°C) = raw count × scale + offset

The pair 0.01 and −50.00 is illustrative; your SDK reports the real values, and some report a range instead. If the calibration spans −20 to +150 °C over 65,536 counts, derive the pair yourself: scale = (150 − (−20)) / 65,536 = 0.00259 °C per count, with offset = −20 °C at count 0. The multiplication never changes, so either form of report lands in the same line of code.

Converting raw thermal counts to temperature covers the calibration side of that formula — what the factory calibration fixes and what you set on site.

How do you stop frames from tearing or dropping mid-run?

Copy the frame buffer your callback receives before anything else touches it: the SDK reuses that memory the moment the callback returns, and two to four buffers in flight ride out the disk and display hiccups of a long DAQ run.

At the example rate the timing is tight: one frame period is 1/50 s = 20 ms, so the callback must finish inside 20 ms and exposure must stay below 20 ms as well. Keep the callback to a single copy, log from a separate consumer thread draining a ring buffer of two to four frames, and let the display path wrap the original buffer without a second copy — wrapping an SDK frame buffer in an OpenCV Mat without copying shows that split line by line. When frames still tear, the cause is almost always buffer lifetime, and copying the buffer before you queue it is the diagnosis path. If the SDK lacks an exposure setter, setting exposure through sensor registers is the register-level fallback.

How do you verify the temperatures you logged are right?

Check the chain once against a reference of known temperature — a stirred water bath near ambient or a calibration source — at the same distance and focus as production, and expect agreement within about ±2 °C or ±2% of reading, the accuracy class industrial thermal cameras print.

Set emissivity to the real surface before the run, because it dominates the error: matte painted and non-metal surfaces sit near 0.95, while polished metals fall to 0.1-0.2 and reflect the background rather than their own heat. If the check lands outside that band, work down the list: emissivity first, then the background the surface reflects, then any window or extended optics in front of the lens.

When should you skip the SDK and pick a GigE Vision camera instead?

If the camera choice is still open, pick a thermal model that speaks GigE Vision: any GenICam-aware library opens it like a standard industrial camera, and you skip the vendor DLL, its callbacks and its runtime housekeeping entirely.

A GigE Vision camera is discovered, opened and streamed through the GenICam standard that many DAQ environments already support, which removes the DLL declarations and the callback plumbing from the project. The infrared camera range includes GigE models alongside USB3 and Camera Link, so this route is usually available rather than exceptional. The SDK route stays right when the camera's value is its proprietary radiometric payload, when you want a compact USB module, or when the model is a special-purpose imager such as a gas-leak camera, where the maker's library is part of the instrument.

The decision, one line per case: the camera ships a documented DLL and your DAQ package can call a library — integrate through the SDK, four to six calls, and plan roughly 33 MB/s per 640 × 512 camera at 50 Hz. You still get to choose the camera and a GigE model covers your spectrum — skip the SDK and open it like any GenICam camera. Either way, you log calibrated °C at the full frame rate.

Next step: shortlist the host in the vision controllers category — the filters there sort by LAN port count, memory and PoE — or contact us for help matching a specific camera's SDK to your DAQ package. The cameras topic page collects the camera-side guides.

Questions

Can I log a single spot instead of the full frame?

Yes, and you usually should when only a few zones matter. Most thermal SDKs report statistics such as minimum, maximum and mean for a defined ROI each frame, so the DAQ channel receives a few °C values at the full 50 Hz instead of 327,680 pixels per frame. Keep the full radiometric stream writing to disk in parallel whenever you might need to re-analyze the scene later, because a spot log cannot be recomputed for a different ROI.

How much disk space does a thermal recording consume?

At the worked rate — 640 × 512 pixels × 2 bytes × 50 frames/s ≈ 32.8 MB/s — one recorded hour is about 118 GB and an eight-hour shift near 944 GB. Triggered capture or ROI logging cuts that by one to two orders of magnitude. Size the recorder drive from the sustained write rate, roughly 33 MB/s, not from the drive's headline sequential speed.

Does the camera need on-site calibration before I trust its °C values?

No. The factory calibration stored in the camera delivers absolute temperature within its stated accuracy, about ±2 °C or ±2% of reading for industrial measurement cameras. What you must set on site is emissivity, and you must account for any protective window in front of the lens, because those change the received radiation rather than the calibration. For audits or traceable records, check the camera against a calibration source on a yearly schedule instead of before every run.

Can thermal frames be synchronized with my other DAQ channels?

Timestamp both streams from one clock and align during post-processing; at 50 Hz the worst-case alignment error is one frame period of 20 ms. If the SDK exposes a hardware trigger or strobe output, wire it to the DAQ card instead, and the error drops to trigger propagation, microseconds on a short cable. The manual's timing section lists which signals the camera actually exposes, so check it before designing the harness.

What if the SDK has no function for a setting my application needs?

Look in the manual's advanced or register-level section first: many thermal cameras accept direct register access over the same connection, which is the documented fallback when the API stops short. If neither an API call nor a register exists, the feature is not available on that model, and choosing a different camera is faster and safer than probing a closed interface.