Skip to content

Commit 4a369c7

Browse files
author
Daisuke Baba
committed
Modify entire structure
1 parent 0f8a568 commit 4a369c7

File tree

1 file changed

+45
-35
lines changed

1 file changed

+45
-35
lines changed

README.md

Lines changed: 45 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,47 @@ Supported operations are as follows:
1010
- Write without Response
1111
- Notify
1212

13-
Read and Write operations are performed asynchronously and they're stored into the separate queues (read queue and write queue). Each queue has up to 10 operation requests. The parameter can be modified by providing `GENERIC_BLE_MAX_REQUESTS`.
13+
Read and Write operations are performed asynchronously and they're stored into the separate queues (read queue and write queue). Each queue has up to 10 operation requests. The parameter can be modified by providing an environmental variable `GENERIC_BLE_MAX_REQUESTS`.
14+
15+
# How to use
16+
17+
## How to configure a new BLE peripheral
18+
19+
At first, drag either a `generic ble in` node or a `generic ble out` node to the workspace from the node palette and double-click the node. And you can find the following dialog. Here, click the pencil icon (`1`) to add a new BLE peripheral or edit the existing one.
20+
21+
![ble in node](images/ble1.png)
22+
23+
Then the new config node dialog appears like this.
24+
25+
![ble config node](images/ble2.png)
26+
27+
The `Scan Result` shows the scanned BLE peripherals. It can be empty when no peripherals are found.
28+
29+
In order for the dialog to list your device, turn BLE on prior to open the dialog. Close the dialog then re-open it if you'd like to get the latest scan result.
30+
31+
By default, you have to enter either MAC address or UUID manually to configure your BLE peripheral. However, by checking `Select from scan result`(`2`), you can choose the peripheral if it exists in the scan result.
32+
33+
![ble config node](images/ble3.png)
34+
35+
When you choose the peripheral, `GATT Characteristics` shows all characteristics discovered in it, and `Local Name`, `MAC` and `UUID` are automatically resolved as well.
36+
37+
If you cannot find your peripheral in the `Scan Result`, you can reload the result by closing this dialog and re-opening it as described above.
38+
39+
Click `Add` (`3`) when the information on the dialog looks good.
40+
41+
![ble config node](images/ble4.png)
42+
43+
Click `Done` (`4`) to finish the `ble in` node settings.
44+
45+
## BLE in and out nodes
46+
47+
See `info` tab for detail on the editor UI.
48+
49+
# Example Flow
50+
51+
You can import [the example flow](examples/01.read-write.json) on Node-RED UI. You need to change Generic BLE config node named `nRF5x` or add a new config node for your device.
52+
53+
# Systemwide Configuration
1454

1555
These are environmental variables for systemwidely configuring this node:
1656

@@ -61,40 +101,6 @@ sudo systemctl restart candy-red
61101
```
62102
The above command performs `hciconfig hci0 reset` as well. So you don't have to run `hciconfig` command separately.
63103

64-
# How to use
65-
66-
## How to configure a new BLE peripheral
67-
68-
At first, drag either a `generic ble in` node or a `generic ble out` node to the workspace from the node palette and double-click the node. And you can find the following dialog. Here, click the pencil icon (`1`) to add a new BLE peripheral or edit the existing one.
69-
70-
![ble in node](images/ble1.png)
71-
72-
Then the new config node dialog appears like this.
73-
74-
![ble config node](images/ble2.png)
75-
76-
The `Scan Result` shows the scanned BLE peripherals. It can be empty when no peripherals are found.
77-
78-
In order for the dialog to list your device, turn BLE on prior to open the dialog. Close the dialog then re-open it if you'd like to get the latest scan result.
79-
80-
By default, you have to enter either MAC address or UUID manually to configure your BLE peripheral. However, by checking `Select from scan result`(`2`), you can choose the peripheral if it exists in the scan result.
81-
82-
![ble config node](images/ble3.png)
83-
84-
When you choose the peripheral, `GATT Characteristics` shows all characteristics discovered in it, and `Local Name`, `MAC` and `UUID` are automatically resolved as well.
85-
86-
If you cannot find your peripheral in the `Scan Result`, you can reload the result by closing this dialog and re-opening it as described above.
87-
88-
Click `Add` (`3`) when the information on the dialog looks good.
89-
90-
![ble config node](images/ble4.png)
91-
92-
Click `Done` (`4`) to finish the `ble in` node settings.
93-
94-
# Example Flow
95-
96-
You can import [the example flow](examples/01.read-write.json) on Node-RED UI. You need to change Generic BLE config node named `nRF5x` or add a new config node for your device.
97-
98104
# Appendix
99105

100106
## How to build
@@ -124,6 +130,10 @@ sudo hcidump -t -x
124130
Set `GENERIC_BLE_TRACE=true` on starting Node-RED and you can find the precise log in `/var/log/syslog`.
125131

126132
# Revision History
133+
* 1.0.2
134+
- Improve README
135+
- Add an example flow file available from the editor UI
136+
127137
* 1.0.1
128138
- Fix an issue where custom characteristics cannot be listed on the Generic BLE config node dialog
129139

0 commit comments

Comments
 (0)