04.01.2015 Views

CR1000 Manual - Campbell Scientific

CR1000 Manual - Campbell Scientific

CR1000 Manual - Campbell Scientific

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Appendix A. CRBasic Programming Instructions<br />

CallTable<br />

Calls a data table, typically for output processing.<br />

Syntax<br />

CallTable [TableName]<br />

Delay<br />

Delays the program.<br />

Syntax<br />

Delay(Option, Delay, Units)<br />

Do / Loop<br />

Repeats a block of statements while a condition is true or until a condition<br />

becomes true.<br />

Syntax<br />

Do [{While | Until} condition]<br />

[statementblock]<br />

[ExitDo]<br />

[statementblock]<br />

Loop<br />

-or-<br />

Do<br />

[statementblock]<br />

[ExitDo]<br />

[statementblock]<br />

Loop [{While | Until} condition]<br />

EndSequence<br />

Ends the current sequence that started at BeginProg or after a SlowSequence<br />

and accompanying declaration sequences.<br />

Syntax<br />

EndSequence<br />

Exit<br />

Exits program.<br />

Syntax<br />

Exit<br />

For / Next<br />

Repeats a group of instructions for a specified number of times.<br />

Syntax<br />

For counter = start To end [ Step increment ]<br />

[statement block]<br />

[ExitFor]<br />

[statement block]<br />

Next [counter [, counter][, ...]]<br />

If / Then / Else / ElseIf / EndIf<br />

Allows conditional execution, based on the evaluation of an expression. Else is<br />

optional. ElseIf is optional. Note that EndSelect and EndIf call the same<br />

function).<br />

Syntax<br />

If [condition] Then [thenstatements] Else [elsestatements]<br />

480

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!