Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

BLE-Scanner

Overview

This example shows how to scan and print the broadcast information and MAC address of nearby Bluetooth enabled devices using RAK4600 BLE-Scanner.

Description

This example is developed on the basis of standard firmware. The added code is in the comment range of /* User code */ and / *End User code */ of "user_app.c".

The module uses Bluetooth to automatically scan for nearby Bluetooth enabled devices and prints broadcast information and MAC address at specific intervals.

  • In the example, an auxiliary test module was used as a Bluetooth device which contains specific broadcast data:
    0x4C, 0x00, 0x02. <0x004C>-Company: Apple, Inc. <0x02>-Type: Beacon

  • Scan interval can be set based on the requirement

    Example: Setting the scan interval to 1 second

    uint32_t timer_interval = 1 //in second

  • Once the firmware was flashed to the RAK4600 node, open the serial port tool to view the printed logs. Make sure that the configured baud rate on the source code and serial port is the same.

    Results shown that RAK4600 was able to retrieve the broadcast information and MAC address of the auxiliary test module.