Connecting your device with TCP

Posted by Jarrah Watson on Aug 18, 2016 3:08:00 PM
Jarrah Watson
Find me on:

So you’re ready to connect your device to eagle.io over TCP/IP but how do you decide which transport is most appropriate for your application?

Connecting environmental monitoring device with TCP Client callback scout

TCP Client

TCP client transport - initiating connection to your device

The TCP Client transport requires your device to have an internet connection with a public internet address and is the simplest method to configure.

Typically, your fixed-line internet service will include a public address, though you may need to use port forwarding to connect to your device. Most cellular data services (such as your smartphone or wireless modem) do not include a public address, though carriers in the USA generally still provide this as an option.

If you choose TCP Client transport, eagle.io will initiate the connection to your device at the schedule you define on the Collection tab of your Data Source properties.

Eagle.io TCP client transport - Collection tab Data Source properties

TCP Callback

Eagle.io TCP Callback transport

The TCP Callback transport requires your device to have an internet connection but it does not need a public address.

If you choose TCP Callback transport, your device must initiate the connection to device.eagle.io:4332 at the schedule defined by your device.

Because the connection is initiated by your device, the device must identify itself to eagle.io before data can be transferred. For this purpose, we generate a unique Device ID that must be sent by your device (followed by a carriage return) at the start of each TCP session.

Once the connection is initialised, the device should keep the TCP session open and eagle.io will immediately begin acquiring data. Your device can trigger data collection at any time simply by reconnecting the TCP session.

One disadvantage of this approach is that each device in your network will require unique configuration. The upside is your device has more control over when data collection is performed.

TCP Callback transport will work in more scenarios but will require a programmable device that can initiate a TCP connection.

So which transport should I use?

Use TCP Client if your device can obtain a public internet address, otherwise thank your lucky stars eagle.io invented TCP Callback :)

Topics: IoT Devices & Sensors, TCP Client transport

    Connect, configure and control your data loggers from the cloud

    Eagle.io is an all-in-one cloud software for hardware integrators involved in remote environmental monitoring. We believe it is critical to monitor natural assets smartly to protect and manage them effectively.

    • Bulletproof IoT networks. Relevant data anytime, from any hardware, to anyone, on any device.

    • Scalable cloud database collection, storage, analysis, mapping, alarming, editing and visualisation of time series sensor data.

    • Trusted by AECOM, CSIRO, Qld Department of Natural Resources, BMT Global, Ecotech, Xylem, Geosyntec, Specto.

    • Easy integration with standard industry loggers.

    • Simple management of discrete networks: White-labeling, managed accounts, in-app customer support, intuitive data configuration and scalable pricing.

    To learn more, register for a 30-day trial and personalised walkthrough at https://eagle.io/trial

    Subscribe Here!

    Resent Posts