NRF51-DK and Ubuntu 14.04: pt2, UART BLE Loopback with Android 4.4.4

Reading Time: 2 minutes
NRF Toolbox UART log showing sent and received messages
NRF Toolbox UART log showing sent and received messages

In the previous post I described three quick steps (well… sometimes mbed is pretty slow) to get started with NRF51-DK on Ubuntu 14.04.

Yesterday I was able to get the NRF51-DK to talk to my phone, which was pretty exciting.

In short

For NRF51-DK:

  • Open mbed compiler
  • Import > Click on “programs” tab instead of “libraries”
  • Search for “BLE_LoopbackUART” > Import
    Note: Do NOT check “update libraries”, unlike what this Evothings post suggests, checking “update libraries” actually threw errors and failed to compile in the next step, whereas if I went back and re-imported checking “update libraries”, it compiled fine
  • Compile and save file
  • Copy to JLINK to upload.
    Note: Make the NRF51-DK is turned ON and connected to laptop

On Android:

  • Using Google Play, install NRF Toolbox from Nordic
  • Open and click on UART
  • Click Connect (say “yes” to turning on bluetooth if you haven’t already)
  • Click the “…” > Show log
  • Write “hello” > SEND
  • Click “↵” on your android phone or scroll to the bottom of the log
  • You should see it say “hey” sent and “hey received” :)

In Long (with screenshots)

  • Open mbed compiler
  • Import > Click on “programs” tab instead of “libraries”
  • Search for “BLE_LoopbackUART” > Import
    Note: Do NOT check “update libraries”, unlike what this Evothings post suggests, checking “update libraries” actually threw errors and failed to compile in the next step, whereas if I went back and re-imported checking “update libraries”, it compiled fine
    Screenshot from 2015-08-27 11:39:13
  • Compile and save file
  • Copy to JLINK to upload.
    Note: Make the NRF51-DK is turned ON and connected to laptop

On Android:

  • Using Google Play, install NRF Toolbox from Nordic
    Screenshot_2015-08-27-11-25-04
  • Open and click on UART
    Screenshot_2015-08-27-11-25-58
  • Click Connect (say “yes” to turning on bluetooth if you haven’t already) and select the “BLE UART” device near you
    Screenshot_2015-08-27-11-26-44
  • Click the “…” > Show log
    Screenshot_2015-08-27-11-27-02
  • Write “hello” > SEND
  • Click “↵” on your android phone or scroll to the bottom of the log
  • You should see it say “hey” sent and “hey received” :)

    NRF Toolbox UART log showing sent and received messages
    NRF Toolbox UART log showing sent and received messages

Tada! That’s it.

Next, servos and robots! Then, many hours of porting code from Arduino to ARM.

social medialulz

facebooktwittergoogle_plusredditpinterestmail

Leave a Reply

Your email address will not be published. Required fields are marked *