Build an open future with us.

Invest in Mycroft and become a community partner.

Is it even possible to expect a fixed-rate wireless data transmission using HC05 Bluetooth module?


#1

I have a 3 node system (and a PC). Central node asks the other 2 nodes for some data (and also sends to them) wirelessly using nRF24 (2.4Ghz Nordic propriety protocol datahsheet: http://www.kynix.com/uploadfiles/pdf65976/NRF2401AG.pdf). Central node then sends a packet to a software I’ve written using Java. This transmission is done using HC05 Bluetooth module using SPP profile.

Java listens on PC serial port. When data is available, it attaches a timestamp to it, then processes and saves the data somewhere. The problem is, I’m not getting a fixed-rate response from my central node.
Here is the structure of the central node code:

void loop() {
current = millis();
if (current - prev > 20) {
prev = current;
talkToOtherNodes();
sendToPCViaBluetooth();
}

1- I’ve done debugging in central node using prints. main loop is running in fixed-rate 20 ms.
2- talkToOtherNodes() takes 15ms max. So I have ~5 ms headroom
3- I’m talking to HC05 via a bit-banged UART. My required baudrate is ~32000 but it is set at 57600 (its max possible value)

Here is a plot showing my low-level debug sample rate (it is ~20 ms):

And here is a plot showing my Java-side sample rate (first 200 samples are invalid):

Questions:

  • 1- Is it even possible to expect a fixed-rate wireless data transmission using HC05 Bluetooth module with SPP profile?
  • 2- In general (WiFi, BLE,…) ?
  • 3- If not, is there something wrong with my Java-side codes or is it the limitation of Java/PC/Windows ?

Thanks for your help.