Creating data tables in a program
Data is stored in tables as directed by theCRBasicCampbell Scientific's BASIC-like programming language that supports analog and digital measurements, data processing and analysis routines, hardware control, and many communications protocols.program. InShort CutA CRBasic programming wizard suitable for many data logger applications. Knowledge of CRBasic is not required to use Short Cut., data tables are created in theOutputstepsDataTable()/EndTable
instructions. They are placed after variable declarations and before theBeginProg
instruction. BetweenDataTable()
andEndTable()
are instructions that define what data to store and under what conditions data is stored. A data table must be called by the CRBasic program for data processing and storage to occur. Typically, data tables are called by theCallTable()
instruction once each Scan. These instructions include:
|
See theCRBasicEditorhelp for detailed instruction information and program examples:
Use theDataTable()
instruction to define the number of records, or rows, allocated to a data table. You can set a specific number of records, which is recommended for conditional tables, or allow your data logger to auto-allocate table size. With auto-allocation, the data logger balances the memory so the tables “fill up” (newest data starts to overwrite the oldest data) at about the same time. It is recommended you reserve the use of auto-allocation for data tables that store data based only on time (tables that store data based on theDataInterval()
instruction). Event or conditional tables are usually set to a fixed number of records. View data table fill times for your program on theStation Status>Table Fill Times选项卡(参见Checking station statusfor more information). An example of the Table Fill Times tab follows. For information on data table storage seeData memory.