Measurement Computing DASYLab User Manual User Manual
Page 57

DASYLab
© National Instruments Ireland Resources Limited
|
6-3
the dependencies between the settings, for example, in order to first
select the Color and then enable the color selection. In DlgOK you
transfer the values the user entered into the module to the variables
when the user clicks OK. In DlgCancel you reset the module
initializations if the user clicks Cancel.
•
SetupFifo — This module function specifies the channel properties of
the data blocks. In SetupFifo you check whether the module can
process the incoming data and transfer the properties of the data to be
output to the subsequent modules. If the module has no inputs, the
output channels receive the default values. If the module has no inputs,
DASYLab does not call the SetupFifo.
•
ProcessData, ProcessValue — These module functions process the
data. DASYLab calls the main function ProcessData regularly during
the measurement in order to read or process data from a measurement
hardware or to write the data into a file, or to output data to the
measurement hardware. ProcessData can call ProcessValue in order to
process single values.
•
Start, Stop — These module functions refer to the measurement. In
Start you define the measurement preparation and in Stop the
measurement feedback.
•
Load, Save — These module functions specify the loading and saving
of the module in the worksheet. In Load you prepare the module for the
measurement. In Save you prepare the module for the storage.
•
Create, Delete — These module functions specify how the script
module is created and deleted in the worksheet. In Create you specify
the number of inputs and outputs and also the channel assignment. In
Delete you define clean up operations such as closing files or
disconnecting hardware.
You program the individual module functions in the Python programming
language. Python has a simple syntax and a complex command structure.
DASYLab provides special script functions for data handling, channel
definitions, and the settings in the module dialog box. During the
programming process, you test the functionality of your module in the
worksheet and save the module with the worksheet.
If you have programming experience, you can also edit the script in an
external editor. In an external editor you can view the complete script and use
the editing functions of the selected editor for programming. Click Use
External Editor in the module dialog box and save the script as a file.