Q: What is the default value of a variable? And, how do I change it?
A: By default, variables are set equal to zero at the time the datalogger program compiles. Variables can be initialized to non-zero values in the declaration portion of a CRBasic program.
CRBasic Examples:
Public aaa As Long = 1
Public bbb (2) As String *20 = {"String_1", "String_2"}
Public ccc As Boolean = True
Dim eee = 1.5
Source: CR1000 manual section 7.7.3.4.1 Variables
Tip: FALSE is the Boolean translation of zero. By default, Boolean variables initialize to FALSE.
Next week: Power budgets