CCSAIL®

CCSAIL® Communications Information and Command Set

CCSAIL® is an ASCII-based bi-directional command-acknowledgment protocol used to set parameters or request data from a ZENO®3200 system. In this application note, the base station terminal initiating the CCSAIL® commands will be referred to as the HOST, and the ZENO® datalogger will be referred to as the REMOTE. It should be noted that we are continually adding commands. If you need one that you do not see below please give us a call. It may already be in the most current version.

Frame Format

All communication within the CCSAIL® system is asynchronous and uses the 256 character IBM standard character set, including control characters. The data transfer protocol is: one start bit, 8 data bits, one stop bit, no parity bit. The use of an end-of-message checksum provides message and data verification. All communications are to be Half Duplex to accommodate the phone or radio modem constraints.

CCSAIL® Command Format

All CCSAIL commands and messages begin with an attention character and end with an end-of-transmit character. In most instances a CCSAIL® command is addressed to a particular REMOTE unit from a particular HOST unit, though there are global commands which are not addressed and are intended for all REMOTE units listening. The CCSAIL® protocol includes a response or acknowledgment sequence for every non-global command to insure the proper receipt of each message. In addition, every CCSAIL® message contains a checksum value to insure that the message itself is not corrupt. If a received message has an incorrect checksum then the message is ignored.

Message Definition

A CCSAIL® message is comprised of:

  • attention character, ATN
  • address, ADR
  • return address, RTN
  • message string, MSG
  • checksum, CHK
  • end-of-transmission character, ETX.

Attention (ATN):

The # (ASCII decimal 35) is the attention character (ATN) for all messages defined by the CCSAIL® protocol. This character marks the beginning of a CCSAIL® command or response message.

Address (ADR):

This is a four character field indicating the message destination unit ID number. The ID value 9999 is a universal number which can address all REMOTE units which are listening for commands. This ID value should be used with caution when there is more than one REMOTE unit capable of simultaneously responding to HOST commands. The universal ID number feature is typically utilized in situations where there is only one REMOTE unit on the communication line.

Return Address (RTN):

This is a four character field indicating the message originator's ID number.

Message string (MSG):

The MSG is any string of characters which will be interpreted by the receiving device in a particular way. The string can be a simple command or it can be an extensive ASCII data output with embedded control characters. If the message string contains command or data parameters, each field should be comma delimited from each other and from the concluding checksum value field. The ATN and ETX characters are excluded from any outputs.

Checksum (CHK):

The checksum is a two digit ASCII decimal number. The checksum is computed by adding the ASCII value of all characters in ADR, RTN, and MSG. The checksum does not include the ATN or ETX characters. The ASCII sum is divided by 100 and the remainder is the checksum: CHK = SUM(ASCII characters) mod 100.

End-Of-Transmission (ETX):

The ETX character has an ASCII value of 3, and marks the end of every CCSAIL command or response message.

Global Commands

When the first character of the CCSAIL address is a letter A-Z rather than a digit 0-9, the message is not addressed to a particular unit but rather is a global command intended for all units on the network. REMOTE units will not return an acknowledgment to the global command.

Retrieval

The data retrieval sequence is set up to allow both senders and receivers full ability to confirm that the command and reply was done properly. The sequence is as follows:

  • Data Retrieval Command. The HOST sends a command requesting data from the REMOTE.
  • Data Reply. The REMOTE replies to the data request command by sending the requested data stream as a CCSAIL® message, or with special commands, as an X-Modem file transfer.
  • Host Acknowledgment. If the HOST receives the data and checksum intact, it returns a CCSAIL® OK message. Otherwise if the data or checksum are invalid, the HOST re-sends the data retrieval command.
  • Remote Acknowledgment. On receipt of the HOST OK message, depending on the specific data retrieval command, the REMOTE may mark the recently transmitted data sets as having been successfully transferred. No message is returned from the REMOTE in response to the HOST acknowledgment. The HOST may now either request more data sets, issue other CCSAIL® command, or cease communications.

CCSAIL® Commands         CCSAIL® Commands – Examples

Please contact us for complete information on Coastal's Automatic Weather Stations.