Posted 2017-05-09 14:20:22 +0100

blogs->nordicers

Bluetooth 5 2Mbps Demo with nRF52 Series and Samsung Galaxy S8

Bluetooth 5 - now arriving in smartphones

As we know, Bluetooth 5 was launched last December by the Bluetooth SIG. The nRF52 Series from Nordic have always had Bluetooth 5 and its arrival in the mix for the nRF52 Series and this family of SoCs was designed early on to be able to meet the exciting new features of Bluetooth 5. Smartphones play such a key role in most Bluetooth products that their adoption of new Bluetooth features is always eagerly anticipated, as this is fundamental to the use of new Bluetooth features.

The Big News: Samsung Galaxy S8 supports Bluetooth 5 2Mbps

This is big news because over 90% of all Bluetooth low energy applications have a smartphone as either, a part of their primary use-case, or as a secondary use-case. The phone is part of the application. Therefore, when significant changes come to Bluetooth technology, we cannot really put the benefits into the hands of the public until the phones have support for it. Samsung, the world’s biggest phone maker by volume released their flagship Samsung Galaxy S8 a few weeks ago, and it has Bluetooth 5!

We got our hands on one as fast as we could and decided to make something really cool to demonstrate where Bluetooth 5’s great new features can take us.

Our demo: Moving images over Bluetooth 5

We wanted something that clearly demonstrated what Bluetooth 5’s new high throughput mode means. What could be better than trying to push moving images across a technology associated with simple sensor measurement and actuation communication? Therefore, that is what we did. So check out the video below for yourself, and get excited about the possibilities of Bluetooth 5.

Posted May 10, 2017, 9:27 p.m.

Hi,

Good presentation :)

Is it possible to have all features (High throughput + Advertising extensions + long range) of Bluetooth 5 in the same application ?

if yes, it is always "low energy" or not ?

for your application in the video, have you measured the power consumption of the nrf52840 DK ?

Thanks for your work Nordic Team.

regards, Y.

Posted May 10, 2017, 9:51 p.m.

Yes, it is possible to use all 3 features within an application but not of course at exactly the same time. There is a PHY level switchover going from 2Mbps to say 125kbps for the long range mode, for example.

To put this in context, perhaps you have an outside camera relaying to a display behind the door in the hallway, this might run at at 2 Mbps when the doorbell is pressed. The doorbell button itself might connect over long range mode at 125kbps to a central home alarm unit to inform someone has pressed the doorbell.

These two operations would run in the same application, but there would be an switchover on the device between the PHYs (very quick and completely transparent to the user). The same principle applies to the use of Advertising Extensions.

The peak power remains pretty much the same for any of these operations so from peak power perspective, yes, unchanged and still very low. when we look at average power then to go to 2Mbps your on-air time will typically be halved, and so will your average energy consumption, so here even less power.

In long range the on air bit time is longer as it will typically be at 125kbps, so average current used per bit will be x 8. However long range will largely be used for sensing/actuating functions requiring short packets transmitted infrequently, so overall current consumption should still average out as very low.

Posted May 11, 2017, 9:58 a.m.

Which camera sensor are you using here?

Posted May 11, 2017, 10:21 a.m.

Hi, we used an Arducam Mini module such as this here:

Posted May 11, 2017, 10:52 a.m.

Awesome thanks. This is a great tutorial. Also could you explain a bit about how you switch from 1Mbps to 2Mbps speed when the devices are connected to each other? Is it done by updating the connection parameters or something else? I haven't read the Bluetooth 5.0 spec which is why I am asking you here.

Posted May 11, 2017, 11:47 a.m.

A request to use a different data-rate is passed to the SoftDevice from the application via the softDevice API. Further details than that I suggest you contact our technical support via Nordic Mypage and they can elaborate. Additionally all you need to know about the S132 SoftDevice is available in online documentation.

Posted May 12, 2017, 4:20 p.m.

Also, the source code for the demo is now available on Github if you want to have a look at it; https://github.com/NordicSemiconductor/nrf52-ble-image-transfer-demo

Posted May 15, 2017, 4:24 p.m.

Have you tested letting the nrf52 devkit be the central/master and the phone the peripheral/slave? Maybe you can get even higher throughput if you as the master decides to keep the connection event open for a longer time. I suspect the S8 as master closes the connection event a bit before the whole connection interval has passed, since you're not achieving 1.4 Mbps?

Posted May 18, 2017, 3:24 a.m.

Great demo, I wish other smartphone vendors to adopt Bluetooth 5 soon.

1) Can you share the timeline for PCA10056 version 1 (a production version)? I wish to buy a stable version rather than the preview kit.

2) Torbjørn has shared the Github Link.

Are you going to share the Android demo app as well?

-Best Regards, MANGO

Posted May 19, 2017, 8:50 p.m.

Hello, dear Nordic community !!! I wanted to ask correctly that this example can work with 4.2 BLE phone, for example with a nexus 5x? Because in the description for the repository on the Githab like this is implied, or am I wrong? And in general, Bluetooth 5 is compatible with BLE 4.2 immediately, for example, all services from Bluetootn 5 will be visible on BLE 4.2?

I just tried to launch your application on Android 7 (Nexus 5 X) and did not see this application of more than one device BLE (stm, TI, Silicone labs) although in the program the device search is implemented just like that from all the applications for android only TI saw all the devices (at least saw;) What is the reason I can not understand( thanks.

Posted May 23, 2017, 9:15 a.m.

Hi all

Emil:
I haven't tried making the phone the peripheral, but I doubt this would provide any higher throughput. You don't have to be the master device to end the connection event, either device can just stop ACK'ing the packets. Since most use cases require the phone to be the central I expect the performance to be better in this case.

Mango:
1) I think the production chip is expected for a Q1 2018 release.

2) Yes, the Android app is also available on Github: Android-Image-Transfer-Demo

Dmitry:
Yes, the example should work with any phone back to Bluetooth 4.0. BLE is designed to allow newer devices running a newer version of the standard to communicate with older devices, simply by disabling features not supported on both sides.

The device list in the app will only show devices advertising the right unique UUID. Unless you have programmed a kit with the image transfer firmware you will not see any devices in the list.

Best regards
Torbjørn

Posted May 31, 2017, 10:26 p.m.

Has anyone been able to get this to build? I pulled down the code and tried to build it with my version of IAR. I get a bunch of errors that appear to be associated with ringbuffer.h, which appears to be for ringbuffer.cpp.
The default settings for the project are:

If tried to change the project to C++ and it resulted in large number of errors.

Does it matter where the additional files (found in the cpplib) folder is placed? Do the files in the cpplib folder need to be built differently?

Please let me know if anyone else has success.

Thanks.

Posted Aug. 11, 2017, 9:14 a.m.

Great job and the potential is unlimited. Thanks for sharing.

Posted Sept. 22, 2017, 1:17 p.m.

I also have the ringbuffer errors. How is it possible that main.c uses classes inside (myCamera)? Isn't .c suposed to be compiled with gcc and .cpp with c++?

Posted Oct. 17, 2017, 4 p.m.

I see some odd behavior specifically with the S8 - for some reason it appears to be reserving two bytes of payload. I've tried:

• Negotiate ATT MTU of 69 and try to send 66 bytes, since there should be 3 bytes of ATT overhead: truncated to 64 bytes
• Negotiate ATT MTU of 158 and try to send 155 bytes: truncated to 153 bytes

This doesn't occur on an S7, am I missing a source of overhead?

All of these tests are done with a PDU max size large enough to fit the ATT packet in one PDU.

Recent blog posts

• Difference between nRF52840 Engineering A and B reference designs

Posted 2018-01-15 12:27:08 by Martin Børs-Lind
• [For Hire] Expert development services of custom Hardware devices | IoT solutions | Mobile Apps

Posted 2018-01-15 09:08:42 by Ilya Surinsky
• Rust bindings to nrf52 series

Posted 2018-01-12 23:23:07 by Coleman McFarland
• Show And Tell: Poly - Building an RC Airplane The Hard Way

Posted 2018-01-05 01:17:57 by Daniel Veilleux
• Bluetooth on a desktop computer (Windows, Mac, Linux)

Posted 2018-01-04 17:56:57 by kbaud

Recent questions

• nrfutil, nRF Connect: Thingy52 DFU fails with message "FW version failure (Code = 5)"

Posted 2018-01-23 18:06:26 by Till
• nrf_sniffer_2.0.0-beta-1_51296aa/PCA10040/windows 7 not working

Posted 2018-01-23 18:03:32 by BramPeeters
• How send message to all from peripheral to peripheral in the multiperipheral example?

Posted 2018-01-23 17:20:07 by Renato Silva
• Soft Devices s310 Central and Peripheral

Posted 2018-01-23 17:05:52 by fede99
• Is nrf_drv_spi_transfer interrupt safe?

Posted 2018-01-23 16:27:39 by samer