sensorweaver:bluetooth-feeder
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
sensorweaver:bluetooth-feeder [2017-09-26 07:42] – created michele | sensorweaver:bluetooth-feeder [2017-09-26 08:01] (current) – michele | ||
---|---|---|---|
Line 1: | Line 1: | ||
===== Bluetooth Feeder ===== | ===== Bluetooth Feeder ===== | ||
- | The Bluetooth Feeder is an OSGi bundle designed to log BLE beacon messages. Specifically, | + | The Bluetooth Feeder is an OSGi bundle designed to log BLE beacon messages. Specifically, |
- | * iBeacon | + | * Detect |
- | * EddyStone | + | * Publish the beacon messages on the middleware |
- | * EddyStone TLM | + | * (optionally to test) write the beacon messages on a DB |
+ | * log on a file the beacon messages | ||
+ | * enable the USB dongle to send beacon messages | ||
- | The bundle requires to interact with a BLE USB dongle (detected via RXTX serial lib) through which the Bluetooth Feeder can listen for BLE messages. The Bluetooth Feeder interacts with the USB dongle by means of the bglib protocol[[https:// | + | The bundle requires to interact with a BLE USB dongle (detected via RXTX serial lib) through which the Bluetooth Feeder can listen for BLE messages. The Bluetooth Feeder interacts with the USB dongle by means of the bglib protocol[[https:// |
The topic used for publishing the messages is: | The topic used for publishing the messages is: | ||
Line 11: | Line 13: | ||
dataFeed/ | dataFeed/ | ||
</ | </ | ||
- | Where X is the ID of the receiving device (see below). | + | Where X is the ID of the receiving device (see below). |
The data feed describing the messages is: | The data feed describing the messages is: | ||
Line 22: | Line 24: | ||
==== Installation ==== | ==== Installation ==== | ||
- | You need an BLE USB dongle plugged on the instance you are provisioning with the Bluetooth Feeder. | + | You need a BLE USB dongle plugged on the instance you are provisioning with the Bluetooth Feeder. |
* On windows OS: the USB dongle is usually recognized as COM port (ex: COM3) | * On windows OS: the USB dongle is usually recognized as COM port (ex: COM3) | ||
* On Unix OS: the USB dongle is added to the /dev dir (ex / | * On Unix OS: the USB dongle is added to the /dev dir (ex / | ||
- | Add the following feature URL: | + | Be sure the following MVN repositories are added on your karaf instnace |
+ | <code console> | ||
+ | http:// | ||
+ | http:// | ||
+ | http:// | ||
+ | http:// | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | Add the following feature URL on the Karaf console: | ||
<code console> | <code console> | ||
feature: | feature: | ||
</ | </ | ||
+ | |||
<code console> | <code console> | ||
Line 45: | Line 58: | ||
</ | </ | ||
+ | Please not that, since the Bluetooth Feeder relies on a configuration file, such file might contain default settings not valid for you instance. If you need to update the configuration: | ||
+ | - edit the file (KARAF_HOME/ | ||
+ | - stop the bluetooth-feeder bundle | ||
+ | - start the bluetooth-feeder bundle | ||
+ | |||
==== Configuration ==== | ==== Configuration ==== | ||
Line 57: | Line 74: | ||
#Bluetooth dongle | #Bluetooth dongle | ||
- | serial_port=COM3 | + | serial_port=COM3 |
#Logging | #Logging | ||
- | id_receiver = 0 | + | #The ID used to build an unique topic, every instance must have a different ID) |
- | logging_hour=00: | + | id_receiver = 0 |
- | hour_format=HH: | + | |
- | + | #DB Not used, it is possibile to enable a db writer together with the middleware publisher | |
- | #DB | + | enable_db_writer=false |
- | properties | + | |
- | enable_db_writer=false | + | |
# | # | ||
jdbc_class=com.mysql.cj.jdbc.Driver | jdbc_class=com.mysql.cj.jdbc.Driver | ||
Line 76: | Line 90: | ||
remove_file_after_upload=true | remove_file_after_upload=true | ||
- | #Sender properties | + | #Sender properties: it is possibile to enable the dongle beaconing |
sender_enabled=false | sender_enabled=false | ||
+ | #adv frequency as range. Minimum advertisement interval in units of 625us Range: 0x20 to 0x4000 | ||
+ | Default: 0x200 (320ms) | ||
adv_interval_min=300 | adv_interval_min=300 | ||
adv_interval_max=340 | adv_interval_max=340 | ||
+ | #power of transmission | ||
tx_power=15 | tx_power=15 | ||
+ | #Type of beacon sent | ||
beacon_type=iBeacon | beacon_type=iBeacon | ||
- | #Eddystone frame_type: UUID, | + | |
- | TLM, URL | + | #Settings for EddyStone beacon format |
+ | #Eddystone frame_type: UUID, TLM, URL | ||
frame_type=UUID | frame_type=UUID | ||
# EddystoneUUID | # EddystoneUUID | ||
namespace_id=2f234454f4911ba9ffa6 | namespace_id=2f234454f4911ba9ffa6 | ||
instance_id=15 | instance_id=15 | ||
+ | |||
+ | #Settings of iBeacon format | ||
# iBeacon | # iBeacon | ||
- | # | ||
uuid=ef977fc020c64e1c9141f6dd2eeb7e49 | uuid=ef977fc020c64e1c9141f6dd2eeb7e49 | ||
major=0 | major=0 |
sensorweaver/bluetooth-feeder.1506411753.txt.gz · Last modified: 2017-09-26 07:42 by michele