Scilab Home Page | Wiki | Bug Tracker | Forge | Mailing List Archives | Scilab Online Help | ATOMS
File : Details
Login with GitLab

thermaSnap

Driver for the ThermaSnap infrared thermographic camera (Inframetrics)
(2488 downloads for this version - 2488 downloads for all versions)
Details
Version
1.0
Author
Samuel Gougeon
Maintainer
Samuel Gougeon
Categories
License
Supported Scilab Version
5.0
Creation Date
March 28, 2012
Description
            For Windows, Linux and Unix. Mac OS X not supported (TCL required)

function out = thermaSnap(command, parameters,...)

 INFRARED CAMERA THERMASNAP
 ==========================
 * STARTING the CAMERA
   - by hand. Remote starting is not supported
   - Sometimes the camera freezes during the boot. It is then impossible
     to restart it, even with the power button. In this case, unplug and
     replug the power cable in order to stop, and then reboot.

  * CONNEXION : The camera must be connected to a serial port through its
     dedicated data cable (LEMO connector on the camera side, sub-D9 on the
     computer side). The initial data rate must be tuned to 115200 bauds
     (menu SETUP/BAUD RATE on the firmware inboard).

 * COMMANDS
    . Command names are case-unsensitive
    . There is no command to query the camera parameters
     (=> settings go to a bound and then increment by the desired quantity)

 * DATA
   Data delivered through the serial connexion are radiometric ones:
     . They do not depend on the emissivity tuned on the camera
     . They do not depend on the background temperature tuned on the camera
     . Their variations are ~4 times larger than the observed variations
        of temperatures.

  * DEPENDENCIES
   - This driver may be used with Scilab > 5.0
   - The Serial TCL toolbox must be installed and loaded:
     http://atoms.scilab.org/toolboxes/serial

 ========================================================================

 out = thermaSnap(command, parameters,...)

 command  : String specifying action to be done. Case doesn't mind.
             For available commands : See table hereafter.
 data     : Parameter(s), according to command. See below for details

 COMMANDS       DATA & ACTION
 --------       -------------
 (none)         thermaSnap without argument displays this help
 'open',port#   Open the RS-232 connexion to the camera.
                The given serial port number is used. The default temperature
                unit is set to °C.
                Return the handle of the serial communication (string),
                whether the connexion is set without error.
 'close'        Close the RS-232 connexion and clear related data. Data ignored
 'shoot'        Trigger the shoot. The thermogram is not returned. Data ignored
 'save'         Record the current image onto the memory card. Data ignored.
 'recall',i     i = rank of the image to be recall and displayed, among the
                  full list of stored images. First = 1. Default = first.
                  i > total number of stored images => last is displayed
 'delete',i     i>0 = rank of the image to be deleted, among the full
                  list of stored images. First = 1. Default = first.
                  i > total number of stored images => last is deleted.
                  After deletion, the first remaining image is displayed.
                i<0 = number of stored images to be deleted, starting from
                  the first (oldest) one. If |i|>total number of stored
                  images, all images are deleted (except the last one)

 'getImage' [, newShot [, display [,colormap]]] :
                 newShot: boolean.
                   If true, a new shot is triggered before being got
                   Else, the last image is got
                 display : boolean. %T to display the thermogram after
                           recovering it. default is %F (false).
                 colormap: may be
                   . a positive integer   = number of colors (in jet colormap)
                   . a Nx3 matrix of reals = the colormap to be used.
                      If it contains at least one value>255, it is initially
                      divided by 255 (values must be in [0,255].
                      Otherwise, it is used as is (values in [0, 1])
                   . a string = name of the colormap to be used (100 colors)
                     Existing colormaps are: autumn, bone, cool, copper, gray,
                     hot, hsv, [jet], ocean, pink, rainbow, spring, summer,
                     winter.
                 out.image   : Radiometric image = 120x120 of uint16()
                 out.datetime: datetime of the shoot.
                               Format: [ 'YYYY-MM-DD' 'HH:MN:SS' ]
                 out.utime   : unix time of the shoot = number of seconds
                               elapsed since 1/1/1970 00:00:00

 'getSet', n, Dt : Return a set of n thermograms shot every Dt seconds
                 (minimal sampling period)
                 out = struct('images','datetimes','utimes')  where
                  out.images   : (n,120,120) hypermat of reals
                                 the ith thermogram is in out.images(i,:,:)
                  out.datetimes: (n,2) text-column = dates of recorded images
                  out.utimes   : unix times [s] of returned images:
                                 (1,n) line-vector of reals.
 'getSet','all' :
               Return all images stored in the memory card.
               out.images out.datetimes out.utimes: As for 'getSet' hereabove

 'getAverage', n : Shot n consecutive thermograms (as fast as possible)
                 out.average: Average thermogram (120x120 matrix of reals)
                 out.sigma  : Standard deviation for each pixel (idem)

 'focus'        Start / stop narrow sweep for tuning the focus (by hand)
 'focusWidth', width: 0 <  width <=  1          (= fraction) or
                      1 <  width <= 100   (= %)
                   out: focusing width actually set
 'setEmissiv', e  Set the emissivity e:  0.01 <= e <= 1.00
 'T_backgrd', Tb  Set the Background temperature Tb (in current unit).
                  Tb must be in [-20, 150-300[°C
                             =  [-4, 302-572[°F  =  [253, 323-573[ K
 'T_unit', Tu     Set the Temperature unit: Tu = 'C' (default) | 'K' | 'F'
 'setVideoOut'  'OFF' | 'PAL' | 'NTSC'   Set the video format
 'setBaud'       rate: 300 1200 2400 4800 9600 19200 38400 57600 115200
 'setDate' [,[YYYY MM DD HH MN]]. Default date = now.
 'APM', [Type, Duration]  Advanced Power Management :
                 Type = 1  : set Display diminution time (default)
                        2  : set Display off time
                        3  : set camera  off time
                      else : default = 1
                 Duration  : Duration = 0 : OFF (default)
                             0 < Duration < 256 (unit = s ?)
            
Files (2)
[144.70 kB]
Screenshot
ThermaSnap camera (front and back sides) (for thumbnail)
[33.61 kB]
Miscellaneous file
thermaSnap driver (1.1). exec() this file. Then in Scilab, enter
-->thermaSnap
to display the help (see the main description above)
News (0)
Comments (1)     Leave a comment 
Comment from Samuel Gougeon -- April 11, 2012, 09:25:39 PM    
1.1 Release notes
-----------------
* The Datetime of a thermogram is now extracted from its header (for new ones, as well as
  for recorded ones on the memory card)
* 'getimage' now returns a structure out.image, out.datetime = ['YYYY-MM-DD' 'HH:MN:SS'] 
  and out.utime, instead of only the image matrix.
* 'getSet' now returns out.images, out.datetimes and out.utimes, 
   instead of only an hypermat images of thermograms. 
   Displaying the series of thermograms was buggeg: Fixed
* getimage/Plot: New possibility to add xlabel and ylabel. 
  The default xlabel is set to Date Time.
* Explicit disclaimer added to the header
Leave a comment
You must register and log in before leaving a comment.
Login with GitLab
Email notifications
Send me email when this toolbox has changes, new files or a new release.
You must register and log in before setting up notifications.