Project tutorial

Interacting with a TI SensorTag from an Intel NUC © CC BY-NC-SA

This project shows you how setup an Intel NUC to interact with a TI SensorTag device using BLE (Bluetooth Low Energy).

  • 1,690 views
  • 1 comment
  • 5 respects

Components and supplies

Intel NUC
×1
Sensortag wifi img 03
TI SensorTag CC2650STK SensorTag Kit
×1
Monitor with HDMI input
×1
HDMI cable
×1
USB Keyboard
×1
Bluetooth 4.0 USB Adapter
×1

Apps and online services

About this project

Overview

In this tutorial, we'll learn how to setup an Intel NUC to interact with a TI SensorTag using BLE (Bluetooth Low Energy). The littleb library will be used for Bluetooth communications.

Setup

  • Once the NUC has been setup and rebooted, connect the Bluetooth 4.0 USB adapter to the NUC.
  • Open a terminal session, by pressing CTRL+ALT+F1 on the keyboard attached to the NUC.
  • Login using the credentials you set up previously.
  • By default, the Ubuntu install does not include the required Bluetooth software, it can be installed by running the following command:
sudo apt-get update && sudo apt-get install bluez
  • The littleb library requires you to enable bluetoothd experimental support. This can be done by editing the /etc/systemd/system/bluetooth.target.wants/bluetooth.service file on your NUC. Change the:
ExecStart=/usr/lib/bluetooth/bluetoothd

line to:

ExecStart=/usr/lib/bluetooth/bluetoothd -E

(add -E ).

  • Once this change is complete, reboot the NUC:
sudo reboot

Loading the sketch

Now that the NUC has been configured with the necessary requirements for the littleb library, we can load the sketch using Arduino Create.

Inside Arduino Create, open the Arduino Web Editor and select your Intel NUC device from the drop down. Then click the Examples menu item, followed by From Libraries , and then select the SensortagButton example from the littleb library.

Next, click the Monitor menu item on the left hide side. This will allow you to monitor the output of DebugSerial entries that are inside the sketch.

Once the monitor section is open, click the Upload (-> ) button to build and upload the sketch to your Intel NUC. After, sketch has been uploaded to the Intel NUC, press the button on the left on the TI SensorTag to make it advertise. When advertising, a green LED will start to blink.

The SensortagButton sketch, scans for SensorTag's continuously in 15 second intervals. Once a SensorTag is discovered it will try to connect to it, discover it's services and subscribe to the button characteristic (0000ffe1-0000-1000-8000-00805f9b34fb ) for notifications.

Now you can press the left or right button on the SensorTag, and it will send a notification Intel NUC. The SensortagButton sketch processes the notification and prints out the button that has been pressed (if any).

Next steps

This tutorial has walked you through how to setup your NUC and use the littleb library to interact with a TI SensorTag over BLE. The button characteristic was monitored and events were printed to the Arduino Create monitor area.

The TI SensorTag exposes many other features over BLE, you can use the example SensortagButton sketch as a starting point to interact with them.

Code

Sensor Tag Button

Comments

Similar projects you might like

Home Automation System for a Camp with Cellular Internet

Project tutorial by Dana Mah

  • 7,575 views
  • 4 comments
  • 26 respects

IR Proximity Sensors with Simulink and Arduino (Part 1)

Project tutorial by MATLAB Makers

  • 188 views
  • 3 comments
  • 2 respects

Morse Code Transceiver

Project tutorial by Achindra Bhatnagar

  • 5,263 views
  • 8 comments
  • 26 respects

Magnetically Levitated Ball with MATLAB and Arduino

Project tutorial by MATLAB Makers

  • 3,737 views
  • 1 comment
  • 5 respects

IR Proximity Sensors with Simulink and Arduino (Part 2)

Project tutorial by MATLAB Makers

  • 77 views
  • 0 comments
  • 0 respects

Alexa Based Smart Home Monitoring

Project tutorial by Adithya TG

  • 4,439 views
  • 10 comments
  • 22 respects
Add projectSign up / Login