Target Communication Framework Services
Copyright (c) 2007 Wind River Systems, Inc. Made available under the EPL v1.0
Direct comments, questions to the dsdp-tm-dev@eclipse.org mailing list
Table of Contents
TCF communication model is based on the idea of services. A service is a group of related commands, events and semantics.
For example, Memory Service defines group of command and events for
reading and writing target memory.
Service definitions are not part of the framework specification, and new services
are expected to be defined by developers of tools and target agents.
Defenitions of standard services are provided to achieve certain level of compatibility between tools and targets.
Format of the protocol messages is defined by syntax rules. Syntax is described
using a simple variant of Backus-Naur Form. In particular:
- Italic lower case words in a courier font, enclosed into angular brackets, are
used to denote syntactic categories, for example: <token>.
Category name can be followed by colon and a text, which explains semantics
of the category, for example: <int:
error code> has same meaning as <int>,
but denotes that the integer number used to indicate an "error code".
- A syntax rule consists of a category designation followed by one or more syntax
definitions for the category. The category name and each definition are placed on
separate lines, bullets are used to denote definitions, for example:
<chars>
⇒ <char>
⇒ <chars> <char>
- Spaces are added for readability only and they are not part of the syntax.
- All text in the category definition, other than categories and spaces, is UTF-8
based representation of a message bytes.
- The symbol ‘•’ designates a zero byte.
Most of TCF standard services use same format for error reporting:
<error report>
⇒ <int: error code> • <error description>
Error code zero means success. Error description provides a short, localizable,
human readable explanation of error.
<error description>
⇒ null
⇒ <string>
⇒ { "format" : <string> , "params" : [ <params> ] }
<params>
⇒ <value>
⇒ <params> , <value>
For <string>
and <value> encoding see
JSON - Preferred Marshaling.
Error description format supports separation between constant and variable parts
of the message ("format" and "params"). This is done to support localization. See
Java class java.text.MessageFormat for details.