TQL Introduction
April 2016
Atomiton
2© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
If you are developing IoT,
one of two things can
happen…
3© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
1. You are writing a lot of code…
Java
Python
JS
C
Create proxies for a list of sensors/devices
Open ports, re-open ports, receive messages, manage time-
outs, and/or manage scheduled requests
Maintain and manage message queue (to decouple
receiving and processing)
Process messages (parse,
transform, format)
Publish messages
Managing multiple threads
Maintain and manage queue for outbound
messages
Listen to/request confirmations of actuation
Write logic for retry in case of failures
Create schema
Construct queries to save
data to database
Write queries, parse query results to update respective
objects
...
4© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
2. OR, you spend 90% of your time collecting
and presenting data...
5© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
1. Impact: it should cause
things to behave
differently, more
intelligently (not just
watching them)
2. Time: you should spend
80% of your time on
business logic and UI, not
bogged down at lower
levels…
3. Things: you should
easily turn it from one-
app : one-thing to
many-things
But a real IoT application should…
6© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
The type of software we designed for
the “Internet of People” (IoP) will not
work for the Internet of Things...
Why so hard??
7© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
Three major roles in software
1. Actors: interact with applications and
exhibit their own autonomous behaviors (not
controlled by your applications)
2. Objects: logical entities within
your applications to represent the
outside world
3. Subjects: those whose behaviors and
states are controlled by your applications
An IP camera
Application
Invoices, orders,
addresses,
customers, sales,
shipments, members,
tickets…
Sensors, valves,
pipes, motors,
machines…
A centrifugal
pump…
IoP IoT
Users
Database
8© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
The actors are different in IoT
• People create interface
applications (UI) for people
• Using elements all people
understand (menus, windows,
buttons… e.g. HTML)
• Using frameworks (e.g. MVC) for
sophisticated interactions
• People have to create interface
applications for things
• Trying to translate into elements
things understand (messages,
baud rates, voltage...)
• No framework for sophisticated
interactions
9© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
The objects are different in IoT
• Objects are defined in ways
people understand
• People (user) update the states of
objects
• At least one system is considered
to have the “source of truth”
• Objects are defined in ways things
don’t understand
• But things have to update the states of
objects (we cannot reply on people all
the time)
• Source of truth is outside
10© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
The subjects are different in IoT
• People have developed well
matured ways to manipulate data
(SQL, NoSQL)
• If a transaction on data is not
successful, roll back
• There is no well-matured,
consistent way to manipulate
things
• If a transaction on things goes
awry, there is no rolling back
11© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
the “HTML” + “SQL” for things
 A platform to develop IoT applications – fast and easy
 A language that defines interactions with things
 A middleware engine you can download and run on any
local computer (server, laptop, Raspberry Pi…)
That’s why you need TQL…
TQL stands
for Thing
Query
Language
12© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
Inside a TQL application
1
2
3
1. ThingFacets are a framework
to interface with things – it
translates your instructions into
concepts things understand
(ports, messages, baud rates…)
You don’t have to code those
interactions directly
2. Models are “objects” and
data that are automatically
updated by things (via
ThingFacets). You don’t
have to update them
yourself
3. TQL Queries are a way
to manipulate both data
and things. When your
query changes data, things
will be actuated (and
again, you don’t have to
write the code) TQL SUBSCRIPTIONS 4
4. TQL Subscriptions let
you receive on any
“topic” related to your
model changes
13© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
Temperature sensor
ThingFacet has attributes
Its action will invoke serial
communication port
Serial protocol
parameters to be
given at run time
Create ThingModel
to persist data
Parse message
(Xpath)
This is all you need for a serial sensor…
And you will be
able to...
Subscribe to any
instance or
attribute
Query any
instance or
attribute
14© Atomiton, Inc., 2015 – All rights reserved – Confidential and proprietary information
From TQL developers
“Clearly crashes the time required for
development thereby freeing up
developers’ time to do more projects and
with greater complexity.”
“Brilliant…”
“Beautifully designed!”
“Cut my IoT development time
by 80%. It is the fastest I’ve
seen among all platforms.”
Thank you.
- Atomize, Assemble, Automate
Go to http://atomiton.com/ and sign up

TQL - an IoT application platform

  • 1.
  • 2.
    2© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information If you are developing IoT, one of two things can happen…
  • 3.
    3© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information 1. You are writing a lot of code… Java Python JS C Create proxies for a list of sensors/devices Open ports, re-open ports, receive messages, manage time- outs, and/or manage scheduled requests Maintain and manage message queue (to decouple receiving and processing) Process messages (parse, transform, format) Publish messages Managing multiple threads Maintain and manage queue for outbound messages Listen to/request confirmations of actuation Write logic for retry in case of failures Create schema Construct queries to save data to database Write queries, parse query results to update respective objects ...
  • 4.
    4© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information 2. OR, you spend 90% of your time collecting and presenting data...
  • 5.
    5© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information 1. Impact: it should cause things to behave differently, more intelligently (not just watching them) 2. Time: you should spend 80% of your time on business logic and UI, not bogged down at lower levels… 3. Things: you should easily turn it from one- app : one-thing to many-things But a real IoT application should…
  • 6.
    6© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information The type of software we designed for the “Internet of People” (IoP) will not work for the Internet of Things... Why so hard??
  • 7.
    7© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information Three major roles in software 1. Actors: interact with applications and exhibit their own autonomous behaviors (not controlled by your applications) 2. Objects: logical entities within your applications to represent the outside world 3. Subjects: those whose behaviors and states are controlled by your applications An IP camera Application Invoices, orders, addresses, customers, sales, shipments, members, tickets… Sensors, valves, pipes, motors, machines… A centrifugal pump… IoP IoT Users Database
  • 8.
    8© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information The actors are different in IoT • People create interface applications (UI) for people • Using elements all people understand (menus, windows, buttons… e.g. HTML) • Using frameworks (e.g. MVC) for sophisticated interactions • People have to create interface applications for things • Trying to translate into elements things understand (messages, baud rates, voltage...) • No framework for sophisticated interactions
  • 9.
    9© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information The objects are different in IoT • Objects are defined in ways people understand • People (user) update the states of objects • At least one system is considered to have the “source of truth” • Objects are defined in ways things don’t understand • But things have to update the states of objects (we cannot reply on people all the time) • Source of truth is outside
  • 10.
    10© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information The subjects are different in IoT • People have developed well matured ways to manipulate data (SQL, NoSQL) • If a transaction on data is not successful, roll back • There is no well-matured, consistent way to manipulate things • If a transaction on things goes awry, there is no rolling back
  • 11.
    11© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information the “HTML” + “SQL” for things  A platform to develop IoT applications – fast and easy  A language that defines interactions with things  A middleware engine you can download and run on any local computer (server, laptop, Raspberry Pi…) That’s why you need TQL… TQL stands for Thing Query Language
  • 12.
    12© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information Inside a TQL application 1 2 3 1. ThingFacets are a framework to interface with things – it translates your instructions into concepts things understand (ports, messages, baud rates…) You don’t have to code those interactions directly 2. Models are “objects” and data that are automatically updated by things (via ThingFacets). You don’t have to update them yourself 3. TQL Queries are a way to manipulate both data and things. When your query changes data, things will be actuated (and again, you don’t have to write the code) TQL SUBSCRIPTIONS 4 4. TQL Subscriptions let you receive on any “topic” related to your model changes
  • 13.
    13© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information Temperature sensor ThingFacet has attributes Its action will invoke serial communication port Serial protocol parameters to be given at run time Create ThingModel to persist data Parse message (Xpath) This is all you need for a serial sensor… And you will be able to... Subscribe to any instance or attribute Query any instance or attribute
  • 14.
    14© Atomiton, Inc.,2015 – All rights reserved – Confidential and proprietary information From TQL developers “Clearly crashes the time required for development thereby freeing up developers’ time to do more projects and with greater complexity.” “Brilliant…” “Beautifully designed!” “Cut my IoT development time by 80%. It is the fastest I’ve seen among all platforms.”
  • 15.
    Thank you. - Atomize,Assemble, Automate Go to http://atomiton.com/ and sign up