Appendix B. Campbell Scientific File Formats
B.1.8.1 A Short Introduction to JSON
Much like XML, JSON is a recursive structure with a root object (represented
by an opening and closing curly brace (‘{‘ and ‘}’). This root object can
contain named strings, numbers, objects, and arrays. A simple object
specification follows:
{
"head": {
"signature": xxxx,
"transaction": "xxxxyyyy",
"environment": {
}
"fields": [
]
},
"data": [ ]
}
This declaration declares an object that contains two empty sub-objects, head,
and data. In a JavaScript program, a string in this format can be easily parsed
using the Eval() function or the newer ParseJSON() function. Once parsed, the
data contained therein can be accessed using standard JavaScript notation.
B.1.8.2 File Syntax
CSIJSON contains two subordinate objects: “head” and “data”. The head
object contains the station meta-data and field descriptions while the data
object is an array of record objects.
B.1.8.2.1 The head Object
The head object contains information about the datalogger and program that is
responsible for generating the data as well as information about the fields in the
data.
B.1.8.2.1.1 head.signature
This numeric value is the signature calculated on the table definitions. This
value can be used by the web client to determine whether the table definitions
have changed while that client is monitoring or polling for data. If the web
client is using the DataQuery command in the datalogger web services and
specifies a tablesig value that matches this value, the server will not send the
head.environment or head.fields values.
B.1.8.2.1.2 head.transaction
This optional value specifies a transaction identifier that can be sent by a web
client in the DataQuery parameter. This value can help the client route
responses to the correct object.
B-15
Summary of Contents for LoggerNet
Page 2: ......
Page 30: ...Preface What s New in LoggerNet 4 xxvi...
Page 32: ...Section 1 System Requirements 1 2...
Page 44: ...Section 2 Installation Operation and Backup Procedures 2 12...
Page 136: ...Section 4 Setting up Datalogger Networks 4 80...
Page 227: ...Section 7 Creating and Editing Datalogger Programs 7 9...
Page 298: ...Section 7 Creating and Editing Datalogger Programs 7 80...
Page 402: ...Section 9 Automating Tasks with Task Master 9 12...
Page 406: ...Section 9 Automating Tasks with Task Master 9 16...
Page 450: ...Section 11 Utilities Installed with LoggerNet Admin and LoggerNet Remote 11 22...
Page 454: ...Section 12 Optional Client Applications Available for LoggerNet 12 4...
Page 462: ...Section 13 Implementing Advanced Communications Links 13 8...
Page 482: ...Section 14 Troubleshooting Guide 14 20...
Page 570: ...Appendix F Calibration and Zeroing F 16...
Page 578: ...Appendix G Importing Files into Excel G 8...
Page 579: ......