No ACL setup yet! Denying access to everyone.
en:edu:zmitac:s2:iotn:esp32ble4
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en:edu:zmitac:s2:iotn:esp32ble4 [2024/04/01 19:47] – ktokarz | en:edu:zmitac:s2:iotn:esp32ble4 [2024/04/01 20:08] (current) – [FAQ] ktokarz | ||
|---|---|---|---|
| Line 109: | Line 109: | ||
| pBLEScan-> | pBLEScan-> | ||
| | | ||
| - | // Start the scan for 5 seconds | + | // Start the scan for 30 seconds |
| - | pBLEScan-> | + | pBLEScan-> |
| } | } | ||
| </ | </ | ||
| + | < | ||
| + | In the original example, the scan time is 5 seconds only. It can be too short to connect to a remote device, especially if there are other devices in the neighbourhood. | ||
| + | </ | ||
| In the loop function, we wait for the information that the server with the service UUID we were interested in was found. It is signalled with the use of " | In the loop function, we wait for the information that the server with the service UUID we were interested in was found. It is signalled with the use of " | ||
| < | < | ||
| Line 169: | Line 171: | ||
| ==== Result validation ==== | ==== Result validation ==== | ||
| - | You should be able to find the device in the BLE neighbourhood. It should allow us to establish a connection, read the characteristic data and write a new value. After enabling | + | You should be able to find the server |
| ===== FAQ ===== | ===== FAQ ===== | ||
| - | **What is the difference between notification and indication?**: As it was mentioned in the beginning the notification is an unacknowledged message while an indication is an acknowledged message. It means that if the indication message remains unacknowledged, | + | **Can we connect to the same peripheral with more than one central device?**: No, it's not possible. The BLE standard allows only one connection for the peripheral device. It was defined to ensure that BLE will work on constrained devices with small memory. |
| - | **Is the notification/ | + | **May I use the data in another way than printing it on the console?**: Of course. |
| <WRAP noprint> | <WRAP noprint> | ||
en/edu/zmitac/s2/iotn/esp32ble4.1711993655.txt.gz · Last modified: by ktokarz
