Community news, upcoming events and general discussions
Threads: 36 Posts: 88
Get technical support from the community
Threads: 1416 Posts: 7560
Threads: 18 Posts: 64
Tell us how to make XDK better!
Threads: 36 Posts: 119
Share and discuss community member projects
Threads: 78 Posts: 343
I have the same question / concern as Christine. There are various statements throughout the documentation and demos that suggest only a limited sampling + data TX frequency is possible. This thread: "http://xdk.bosch-connectivity.com/community/-/message_boards/message/133124" establishes 2 things:
In the documentation it states under known issues that "WLAN/BLE transfers at high frequences is not supported". This statement seems to be evidenced by #1, but does not specify what is considered 'high'.
Touching upon #2, the Sensor Monitor demo uses 100ms (ie, X=10) collection rate as the fastest sample when only 1 sensor is being triggered. For most applications, 10Hz is not adequate enough though. Like Christine, I also need to trigger a sensor and then send the data via BLE or WiFi, possibly at 100-200Hz. Is this able to be accomplished using the XDK? Would it require a more sophisticated approach of writing locally to the SD card and then in separate thread writing to BLE or Wifi? I understand in the demo the actual sensor 'bandwidth' rate can be set anywhere from 7 to 1000Hz, but if it is bottlenecked by a much slower data outrate, then it seems by all intensive purposes the effective bandwidth is greatly reduced.
welcome to the XDK community. The sampling rate is indeed limited to the data transfer frequency of the SPI data bus that connects the sensors with the MCU. The transfer frequencies of WLAN and BLE are much faster than the 1KHz restriction of the SPI bus. But in all cases the transfer frequency of the SPI bus is the limiting factor to get sensor values for the required time interval. The bus frequency is also divided by the number of enabled sensors. This makes it more complicated if you enable more than one sensor to stream data with a certain transfer frequency. Based on this it makes no sense to temporarily store sensor data on the SD card unless you get more than one measurement every 5 milli seconds.
The SensorMonitorDemo is not meant to display the XDK’s limits and boundaries. As Florian already mentioned, it rather is a playground to explore implementation possibilities with the XDK.
In general it is possible to send data with 100-200Hz, but this depends on whether you are using Wi-Fi or BLE. In terms of Wi-Fi, you have to be aware which transfer protocol (UDP,HTTP, CoAP, etc.) you are using. This can slow down your transfer frequency, depending on the used protocol header. BLE is much slower than Wi-Fi. But given its short overhead it should provide transfer frequencies between 100 to 200 Hz. Only the data size is significant if you use 100 or 200Hz.
In summary, both Wi-Fi and BLE should work with 100-200Hz, but it depends on which requirements your application has. This includes the amount of used sensors and, in case of Wi-Fi, the used transfer protocol and the general data size of the measured values for BLE.
I hope this brought some insight.
Kind regards, Franjo