Skip to main content
Mar 8, 2020 3:48 PM UTC
Solved

update rate

Hi Forum,

We have successfully connected Arduinos and Raspberries toTW with REST-API (https PUT requests). It is clear that the Raspberry can achiev a higher update rate than an Arduino. We have achieved an update rate of one second with the Raspberry.

To monitor accelerations or movements of a CNC router for example 1Hz sampling rate is not very high.

My question is if there is an other posipility to connect the Arduinos to TW to get higher update rates. My desired update rate is 10 to 5Hz.

My idea is that we use a Raspberry as an Edge MicroServer (EMS) and several Arduinos which deliver the data.

I read the "Setup a Raspberry Pi as an IoT Device" article but I found no way to feed the Arduino data to the EMS.

Is there an other way to connect the Arduinos (ESP32) in an always on connection to achiev higher update rates?

Thank you for your help

Martin

Mar 16, 2020 6:44 AM UTC

Hello Martin,

 

Take a look at this Help Center, it does go into all details about reading and writing properties: http://support.ptc.com/help/thingworx_hc/thingworx_edge/index.html#page/thingworx_edge_sdks_ems%2Fc_sdk%2Fc_csdk_push_properties.html%23

 

The SDKs should be available here (if you have access to Support > Downloads, you should be able to download a more recent 2.2.8 version): https://developer.thingworx.com/en/sdks

 

Regards,
Constantine

8 replies

Mar 9, 2020 10:49 AM UTC

Hi,

 

Check this thread for Arduino connecting with MQTT to Thingworx: https://community.ptc.com/t5/IoT-Tech-Tips/DeliveringArduinoDataToThingworx-pdf/m-p/533839/thread-id/884

Although it is not the same model, but could be a starting point.

 

Hope it helps,

Raluca Edu

TgmMartinAuthor
Mar 11, 2020 5:32 PM UTC

Hi,

Thank you for this link. Because the thinkworx instance is not mine I have to check the MQTT functionality with the server team. Unfortunately I have no MQTT like Base Thing Template in the New Thing Window...

Thanks

Martin

Mar 12, 2020 7:57 AM UTC

Hello Martin,

 

Depending on your experienced with developing embedded software, you may try to port Edge C SDK to ESP32. The latter is a rather capable board, with its own GNU toolchain and a somewhat-POSIX-compatible standard library, so it might be a doable task.

 

The SDK developer's guide has a section on porting it to other platforms, it might help as well. Even though the task is very interesting, I've never attempted it myself.

 

The MQTT way suggested by @raluca_edu will definitely be easier, at least for prototyping purposes.

 

/ Constantine