All Projects → tobozo → Esp32 Blecollector

tobozo / Esp32 Blecollector

Licence: mit
ᛡᛒ BLE Scanner + Data persistence on SD Card for M5Stack, Odroid-Go, ESP32-Wrover-Kit and other models

Projects that are alternatives of or similar to Esp32 Blecollector

Esp32marauder
A suite of WiFi/Bluetooth offensive and defensive tools for the ESP32
Stars: ✭ 233 (+60.69%)
Mutual labels:  arduino, esp32, bluetooth, scanner
Esp32 Ble Keyboard
Bluetooth LE Keyboard library for the ESP32 (Arduino IDE compatible)
Stars: ✭ 533 (+267.59%)
Mutual labels:  arduino, esp32, ble, bluetooth
Esp32 Ble Mouse
Bluetooth LE Mouse library for the ESP32 (Arduino IDE compatible)
Stars: ✭ 180 (+24.14%)
Mutual labels:  arduino, esp32, ble, bluetooth
Nimble Arduino
A fork of the NimBLE library structured for compilation with Ardruino, designed for use with ESP32.
Stars: ✭ 108 (-25.52%)
Mutual labels:  esp32, ble, bluetooth
Bluetooth-ble-beamer-and-scanner-for-tracing-corona-virus-infected-individual
Bluetooth ble beacon beamer and scanner for tracing corona virus infected person similar to Trace Together app
Stars: ✭ 26 (-82.07%)
Mutual labels:  scanner, bluetooth, ble
Blynk Library
Blynk library for embedded hardware. Works with Arduino, ESP8266, Raspberry Pi, Intel Edison/Galileo, LinkIt ONE, Particle Core/Photon, Energia, ARM mbed, etc.
Stars: ✭ 3,305 (+2179.31%)
Mutual labels:  arduino, esp32, bluetooth
Openmqttgateway
MQTT gateway for ESP8266, ESP32, Sonoff RF Bridge or Arduino with bidirectional 433mhz/315mhz/868mhz, Infrared communications, BLE, Bluetooth, beacons detection, mi flora, mi jia, LYWSD02, LYWSD03MMC, Mi Scale, TPMS, BBQ thermometer compatibility, SMS & LORA.
Stars: ✭ 2,413 (+1564.14%)
Mutual labels:  arduino, esp32, ble
Rf24ble
RF24BLE is the library that makes an nrf24L01+ chip (1$) into a BLE advertising beacon and can be used for LOW payload advertising like sensor data etc.
Stars: ✭ 129 (-11.03%)
Mutual labels:  arduino, ble, bluetooth
Esp32 Ble2mqtt
A BLE to MQTT bridge running on an ESP32
Stars: ✭ 301 (+107.59%)
Mutual labels:  esp32, ble, bluetooth
Web Bluetooth Terminal
Progressive Web Application for serial communication with your own Bluetooth Low Energy (Smart) devices
Stars: ✭ 130 (-10.34%)
Mutual labels:  arduino, ble, bluetooth
Esp32 ble wedo
A library to control LEGO wedo 2.0 with the ESP32 through Bluetooth low energy
Stars: ✭ 16 (-88.97%)
Mutual labels:  arduino, esp32, ble
arduino-ble-gadget
Create your own Do-It-Yourself BLE enabled sensor gadget on the ESP32 platform.
Stars: ✭ 31 (-78.62%)
Mutual labels:  esp32, bluetooth, ble
ESP32BleAdvertise
Simple library for BLE advertise using ESP32 in Arduino
Stars: ✭ 39 (-73.1%)
Mutual labels:  esp32, bluetooth, ble
Blueborne Scanner
Bluetooth scanner for local devices that may be vulnerable to Blueborne exploit
Stars: ✭ 125 (-13.79%)
Mutual labels:  ble, bluetooth, scanner
Open Home Automation
Open Home Automation with Home Assistant, ESP8266/ESP32 and MQTT
Stars: ✭ 820 (+465.52%)
Mutual labels:  arduino, esp32, ble
Blinker Library
An IoT Solution,Blinker library for embedded hardware. Works with Arduino, ESP8266, ESP32.
Stars: ✭ 1,095 (+655.17%)
Mutual labels:  arduino, esp32, ble
M5stack Sd Updater
💾 Customizable menu system for M5Stack and ESP32-Chimera-Core - loads apps from the Micro SD card. Easily add you own apps
Stars: ✭ 175 (+20.69%)
Mutual labels:  arduino, esp32, sd-card
Blinker Doc
blinker中文文档
Stars: ✭ 139 (-4.14%)
Mutual labels:  arduino, esp32, ble
Esp32 ble arduino
The library source for the ESP32 BLE support for Arduino.
Stars: ✭ 552 (+280.69%)
Mutual labels:  arduino, esp32, ble
Esp32 soundrecorder
ESP32 Sound recorder with simple code in arduino-esp32. (I2S interface)
Stars: ✭ 96 (-33.79%)
Mutual labels:  arduino, esp32, sd-card

ESP32-BLECollector

Join the chat at https://gitter.im/ESP32-BLECollector/ESP32-BLECollector Build Status

A BLE Scanner with persistence.

ESP32 BLECollector running on Wrover-Kit ESP32 BLECollector running on M5Stack

🎬 Demo video

BLECollector is just a passive BLE scanner with a fancy UI. All BLE data found by the BLE Scanner is collected into a sqlite3 format on the SD Card.

Public Mac addresses are compared against OUI list, while Vendor names are compared against BLE Device list.

Those two database files are provided in a db format (mac-oui-light.db and ble-oui.db).

On first run, a default blemacs.db file is created, this is where BLE data will be stored. When a BLE device is found by the scanner, it is populated with the matching oui/vendor name (if any) and eventually inserted in the blemasc.db file.

⚠️ This sketch is big! Use the "No OTA (Large Apps)" or "Minimal SPIFFS (Large APPS with OTA)" partition scheme to compile it. The memory cost of using sqlite and BLE libraries is quite high.

⚠️ Builds using ESP32-Wrover can eventually choose the 3.6MB SPIFFS partition scheme, and have the BLECollector working without the SD Card. Experimental support only since SPIFFS tends to get slower and buggy when the partition becomes full.

Hardware requirements

  • [mandatory] ESP32-Wroom or ESP32-Wrover (Wrover is recommended)
  • [mandatory] SD Card (breakout or bundled in Wrover-Kit, M5Stack, Odroid-Go, LoLinD32 Pro)
  • [mandatory] Micro SD (FAT32 formatted, max 4GB)
  • [mandatory] mac-oui-light.db and ble-oui.db files copied on the Micro SD Card root
  • [mandatory] ST7789/ILI9341 320x240 TFT (or bundled in Wrover-Kit, M5Stack, Odroid-Go, LoLinD32 Pro, D-Duino32-XS)
  • [optional] (but recommended) I2C RTC Module (see #define HAS_EXTERNAL_RTC in Settings.h)
  • [optional] Serial GPS Module (see #define HAS_GPS in Settings.h)
  • [⚠ NEW][optional] XPad Buttons Shield from Radomir Dopieralski

Software requirements (updated)

Behaviours (auto-selected except for WiFi):

  • Hobo: when no TinyRTC module exists in your build, only uptime will be displayed
  • Rogue: TinyRTC module adjusted after flashing (build DateTime), shares time over BLE
  • Chronomaniac: TinyRTC module adjusts itself via GPS, shares time over BLE
  • With WiFi: Temporary dual BLE/WiFi mode to allow downloading or serving .db files, see #define WITH_WIFI in Settings.h

Optional I2C RTC Module requirements

  • Wire your TinyRTC to RTC_SDA/RTC_SCL (see Settings.h or Display.h to override)
  • Insert the SD Card
  • Set #define HAS_EXTERNAL_RTC true in Settings.h
  • Flash the ESP with partition scheme Minimal SPIFFS (Large APPS with OTA)

Optional Serial GPS Module requirements

  • Wire your GPS module to TX1/RX1 (edit GPS_RX and GPS_TX in GPS.h
  • Set #define HAS_GPS true in Settings.h
  • Flash the ESP with partition scheme Minimal SPIFFS (Large APPS with OTA)
  • Wait for the GPS to find a fix
  • issue the command gpstime in the serial console

Optional XPad Buttons Shield requirements

  • Wire your XPad Buttons Shield to XPAD_SDA/XPAD_SCL (see HID_XPad.h to override)
  • Enable the module in Display.h : #define hasXPaxShield() (bool) true
  • Controls are:
    • Down / Up : brightness
    • Right / Left : unassigned (yet)
    • A : start/stop scan
    • B / C : toggle mac filter
    • D : unassigned (yet)

Time Sharing

  • Once the time is set using RTC, GPS or NTP, the BLECollector may start the TimeSharing service and advertise a DateTime characteristic for other BLECollectors to sync with.
  • Builds with no RTC/GPS will try to identify this service during their scan duty cycle and subscribe for notifications.

File Downloading (still experimental)

Sending the DownloadDB command will:

  • Stop BLE
  • Start WiFi
  • Synchronize time to a nearby NTP server
  • Download the latest oui/vendors database from github

Serial command interface

Available Commands:

01)             help : Print this list
02)             halp : Same as help except it doesn't print anything
03)            start : Start/resume scan
04)             stop : Stop scan
05)     toggleFilter : Toggle vendor filter on the TFT (persistent)
06)       toggleEcho : Toggle BLECards in the Serial Console (persistent)
07)      setTimeZone : Set the timezone for next NTP Sync (persistent)
08)    setSummerTime : Toggle CEST / CET for next NTP Sync (persistent)
09)             dump : Dump returning BLE devices to the display and updates DB
10)    setBrightness : Set brightness to [value] (0-255) (persistent)
11)               ls : Show [dir] Content on the SD
12)               rm : Delete [file] from the SD
13)          restart : Restart BLECollector ('restart now' to skip replication)
14)       screenshot : Make a screenshot and save it on the SD
15)       screenshow : Show screenshot
16)           toggle : toggle a bool value
17)          resetDB : Hard Reset DB + forced restart
18)          pruneDB : Soft Reset DB without restarting (hopefully)
19)         bleclock : Broadcast time to another BLE Device (implicit)
20)          bletime : Get time from another BLE Device (explicit)
21)          gpstime : Sync time from GPS
22)           latlng : Print the GPS lat/lng
23)          stopBLE : Stop BLE (use 'restart' command to re-enable)
24)        startWiFi : Start WiFi (will stop BLE)
25)      setPoolZone : Set NTP Pool Zone for next NTP Sync (persistent)
26)          NTPSync : Update time from NTP (will start WiFi)
27)       DownloadDB : Download or update db files (will start WiFi and update NTP first)
28)      setWiFiSSID : Set WiFi SSID
29)      setWiFiPASS : Set WiFi Password

Contributions are welcome :-)

Known issues / Roadmap

Implementing both LovyanGFX and Nimble-Arduino was such a huge optimization that none of the previous blockers exist any more!

Some ideas I'll try to implement in the upcoming changes:

Other ESP32 security related tools:

Credits/requirements:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].