Skip to main content
1-Visitor
May 11, 2017
Solved

Thingworx service doubts

  • May 11, 2017
  • 1 reply
  • 2428 views

Hi,

Am getting continuous data from simulator for example: Temperature property. I need to write service where if temperature goes out of range for 3 consecutive times in 10 minutes then that records need to be added in data-table but where do i write this service on template or thing? also records added in data-table will get displayed on mashup so how this service will get executed on TW platform? how continuous check will happen(or service will get called) on data so that out of range records should get added to data-table?

Am unable to figure out where to write that service and how that service will get invoked?

Please help

Best answer by ankigupta

Nisha Bhagtani​,

As per my understanding; you can write the Service on Thing Template level if there if there are multiple devices and at Thing level if there is single device.

You can subscribe to the Data Change event and call your Service in the Subscription so that it runs every time any data changes.

I hope it helps.

1 reply

ankigupta5-Regular MemberAnswer
5-Regular Member
May 11, 2017

Nisha Bhagtani​,

As per my understanding; you can write the Service on Thing Template level if there if there are multiple devices and at Thing level if there is single device.

You can subscribe to the Data Change event and call your Service in the Subscription so that it runs every time any data changes.

I hope it helps.

nbhagtani1-VisitorAuthor
1-Visitor
May 12, 2017

Thanks it helped.

5-Regular Member
May 12, 2017

I am Glad it helped.