Eclipse.org Eclipse.org - Device Kit

Connections

A connection is an encapsulation of an input and output byte streams. A connection connects a transport to the hardware device. The connection provides input bytes from the hardware device and the transport parses these bytes into messages. The transport uses the connection to write bytes to the hardware device. While the transport understands the message format of the bytes, the connection does not understand the meaning of the bytes.

The ConnectionService provides a common interface for all connection implementations. This interface provides open, close, read and write methods. These APIs enable uniform interfaces to communicate with the following connections:

You might need to customize the setup for each connection type in the previous list. Custom setup might include changing the baud rate of the Serial Port or specifying an IP Address for a TCP/IP connection. You can use a custom constructor for each connection type to customize your setup.