cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

How Thingworx connect socket server

CZ_9645217
15-Moonstone

How Thingworx connect socket server

Dear Community,

 

There are dozens of devices in the lab, the device can only use sockets to connect, each device is a socket server, how to use Thingworx to connect to sockets and send or receive messages? Can Kepware connect to socket servers or need use SDK to connect?

 

Thanks!

 

 

ACCEPTED SOLUTION

Accepted Solutions

1. Are your devices using UDP or TCP as a socket server?

2. What kind of protocol is used at the higher levels in the stack (>=session) ? Is it your own internal custom protocol, or one of the classic protocols out there? Kepware can be a solution if you use one of the supported protocols from its drivers suite.

3. Can you deploy additional agents in your devices (does it have user storage and memory)? If yes, using one of our Edge SDKs to create an implementation which you will deploy on the devices is one option which is optimal from the flexibility standpoint.

If you can't deploy agents on the device, then you essentially have two options: Option A: if you are looking for a fast proof of concept, creating a server-side extension using the ThingWorx Extension SDK works (I did that in the past for multiple PoCs). However, this typically does not scale in case of tens of thousands of devices (exceptions exist though). Option B: develop an edge implementation using one of the ThingWorx Edge SDKs that will live out of process, typically in a separate VM to the one where the ThingWorx platform resides. Same task or logic as the Option A, the only difference is where it lives. This option scales better than the server-side extension since it does not share the same resources with the platform server.

 

 

View solution in original post

7 REPLIES 7
CZ_9645217
15-Moonstone
(To:VladimirN)

Each device needs to create a Thing, if each device installs an EMS, it will be a lot of work, is there another better solution, thank you!

slangley
23-Emerald II
(To:CZ_9645217)

Hi @CZ_9645217.

 

You can use our EMS or one of the SDK's for collecting data but you'll still need an agent running on each device.  Here's a link to the Help Center where you can review each of the edge options available.  Here's an article that may also be helpful.

 

Regards.

 

--Sharon

Dear Sharon,

 

My understanding of @CZ_9645217 question is about "Socket TCP", So EMS based WebSocket is not option for him.

 

Regards

Ray

slangley
23-Emerald II
(To:CZ_9645217)

Hi @zManRay.

 

The EMS should still be an option.  It might be possible to add a lua script agent on the device that interfaces with an EMS connected to ThingWorx for sending property or event data to and from the ThingWorx server.

 

Regards.

 

--Sharon

 

 

 

Thanks Sharon.

1. Are your devices using UDP or TCP as a socket server?

2. What kind of protocol is used at the higher levels in the stack (>=session) ? Is it your own internal custom protocol, or one of the classic protocols out there? Kepware can be a solution if you use one of the supported protocols from its drivers suite.

3. Can you deploy additional agents in your devices (does it have user storage and memory)? If yes, using one of our Edge SDKs to create an implementation which you will deploy on the devices is one option which is optimal from the flexibility standpoint.

If you can't deploy agents on the device, then you essentially have two options: Option A: if you are looking for a fast proof of concept, creating a server-side extension using the ThingWorx Extension SDK works (I did that in the past for multiple PoCs). However, this typically does not scale in case of tens of thousands of devices (exceptions exist though). Option B: develop an edge implementation using one of the ThingWorx Edge SDKs that will live out of process, typically in a separate VM to the one where the ThingWorx platform resides. Same task or logic as the Option A, the only difference is where it lives. This option scales better than the server-side extension since it does not share the same resources with the platform server.

 

 

Announcements


Top Tags