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

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

How can I use python code in one thing?

picho_mx
6-Contributor

How can I use python code in one thing?

How can I use python code in one thing?

1 ACCEPTED SOLUTION

Accepted Solutions

Not out of the box on the ThingWorx Instance, it supports Server Side Javascript, Java and SQL (if it's a Remote BDD Thing).

 

"Workarounds", just thinking loud:

  • You can do an extension in Java which triggers the desired Python code.
  • You can do a Remote Thing which Implements ThingWorx Edge SDK and executes your Python Code -> Actually the Edge Microserver can execute LuaScript for instance. And you have Edge SDK for C, Dot.net and Java.

Just my two cents,

Carles.

 

View solution in original post

2 REPLIES 2

Not out of the box on the ThingWorx Instance, it supports Server Side Javascript, Java and SQL (if it's a Remote BDD Thing).

 

"Workarounds", just thinking loud:

  • You can do an extension in Java which triggers the desired Python code.
  • You can do a Remote Thing which Implements ThingWorx Edge SDK and executes your Python Code -> Actually the Edge Microserver can execute LuaScript for instance. And you have Edge SDK for C, Dot.net and Java.

Just my two cents,

Carles.

 

Adding to Carles' post, you should think how large is the overall impact on your system in terms of consumed resources. If it's a big impact, I would suggest to use the Edge Microserver or SDK's to do this processing in another container/VM. Nevertheless, regardless if you use an Extension or the Edge SDK, the difference in terms of implementation difference should be relatively minor.

Top Tags