SESTILIO  3.0.2
C Library for SESTILIO a smart A/D and D/A interface on USB 2.0
Instrument applications

Functions

CTYPE int DLL SE_TransientResponse (int da, int daValue, unsigned period, int samples, int usbDevice)
 Perform transient response analysis. Sampling of data is performed with AD0 and AD1, data is stored in RAM0. More...
 
CTYPE int DLL SE_LinearScanner (int dir, long rows, unsigned short int *outBuffer, int usbDevice)
 With the optional module LINCAM-1 SESTILIO can be used to implement an image scanner. The optical module is based on SONY ILX553B, a linear CCD sensor of 5150 pixel (7um pitch).
To achieve maximum performance there are several constraints:
. More...
 
CTYPE unsigned int DLL SE_ReadTemperature (int adSource, int muxChan, int average, int usbDevice)
 This command enables the realization of an accurate thermometer employing a AD590 sensor to that end. More...
 
CTYPE unsigned int DLL SE_ReadCurrent (int adSource, int highVoltChan, int lowVoltChan, int range, double refResistence, int average, int usbDevice)
 This command enables the realization of an accurate ammeter using an external resistance and two A/D channels. More...
 

Detailed Description

Functions that can implements a complete instruments.

Function Documentation

◆ SE_LinearScanner()

int SE_LinearScanner ( int  dir,
long  rows,
unsigned short int *  outBuffer,
int  usbDevice 
)

With the optional module LINCAM-1 SESTILIO can be used to implement an image scanner. The optical module is based on SONY ILX553B, a linear CCD sensor of 5150 pixel (7um pitch).
To achieve maximum performance there are several constraints:
.

  • Used A/D 0 on available inputs from 0 to 7
  • Used motor output B.
  • One step of the motor for one line sampled.
    Parameters
    dirMotor direction for the scanning.
    rowsNumber of rows for the sampled image.
    outBufferImage buffer. This buffer must be created according to the image dimension. The image is sampled at 16 bit an the image dimension is: 5150 * rows * 2
    usbDeviceSpecify a SESTILIO USB identifier.
    See also
    SE_SetMotorSlope, SE_MotorPositioning, SE_MotorCalibrate, SE_ReadMotorCount.
    Returns
    The number of steps still to be executed.
    #include "sest.h"
    if(SE_Open('0', 0) == SE_S_SUCCESS)
    {
    unsigned short int * mem;
    mem = malloc(5150 * 1024 * sizeof(unsigned short int));
    // Acquire 1024 lines by 5150 pixel
    }

Definition at line 643 of file sestilio.cpp.

◆ SE_ReadCurrent()

unsigned int SE_ReadCurrent ( int  adSource,
int  highVoltChan,
int  lowVoltChan,
int  range,
double  refResistence,
int  average,
int  usbDevice 
)

This command enables the realization of an accurate ammeter using an external resistance and two A/D channels.

Parameters
adSourceUsed A/D (0/1).
highVoltChanMultiplexer channel for Vi input voltage measurement.
lowVoltChanMultiplexer channel for Vo output voltage measurement.
rangeReadout multiplier: 0 = 1A, 1 = 100mA, 2 = 10mA, 3 = 1mA, 4 = 100uA, 5 = 10uA
refResistenceReference resistance in mOhm
averageNumber of samples for average.
usbDeviceSpecify a SESTILIO USB identifier.
// Four channel ammeter
for(int i = 0; i < 4; i++)
printf("I[%2d] = %5.3lf A\n", i, (double) SE_ReadCurrent(0, i, i + 4, 3, 0.1, usbDevice) / 1000.0);
Returns
The current value.

Definition at line 661 of file sestilio.cpp.

◆ SE_ReadTemperature()

unsigned int SE_ReadTemperature ( int  adSource,
int  muxChan,
int  average,
int  usbDevice 
)

This command enables the realization of an accurate thermometer employing a AD590 sensor to that end.

Parameters
adSourceUsed A/D (0/1).
muxChanSelected multiplexer channel.
averageNumber of samples for average.
usbDeviceSpecify a SESTILIO USB identifier.
// Optional instruction
SE_AuxPower(1, 0); // Turn on the power (+5V) on pin Y4.16 for DCDC converter
// Read temperature (K) on 16 channels
for(int i = 0; i < 16; i++)
printf("CH[%2d] = %5.1lf K\n", i, (double) SE_ReadTemperature(i % 2, i % 8, 10, usbDevice) / 1000.0);
Returns
The temperature as milliKelvin.

Definition at line 650 of file sestilio.cpp.

◆ SE_TransientResponse()

int SE_TransientResponse ( int  da,
int  daValue,
unsigned  period,
int  samples,
int  usbDevice 
)

Perform transient response analysis. Sampling of data is performed with AD0 and AD1, data is stored in RAM0.

Parameters
daD/A selection: 0 = DA0, 1 = DA1. D/A Selection
daValue0:4095 D/A value. Conversion Macros
periodSampling frequency in us. Accepted range 1 to 1E8.
samplesNumber of samples to be acquired.
usbDeviceSpecify a SESTILIO USB identifier.
See also
SE_ReadRAM.
Returns
Operation status. Operation Status

Definition at line 525 of file sestilio.cpp.