Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
D
developer.puri.sm
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
69
Issues
69
List
Boards
Labels
Milestones
Merge Requests
5
Merge Requests
5
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Librem5
developer.puri.sm
Commits
23800ce0
Commit
23800ce0
authored
Feb 06, 2019
by
David Boddie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add guide to testing Bluetooth pairing with another device
parent
3f393767
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
91 additions
and
1 deletion
+91
-1
Development_Environment/Boards/HowTo.rst
Development_Environment/Boards/HowTo.rst
+1
-0
Development_Environment/Boards/HowTo/Bluetooth_Connections.rst
...opment_Environment/Boards/HowTo/Bluetooth_Connections.rst
+86
-0
Development_Environment/Boards/imx8.rst
Development_Environment/Boards/imx8.rst
+4
-1
No files found.
Development_Environment/Boards/HowTo.rst
View file @
23800ce0
...
...
@@ -9,6 +9,7 @@ how to perform routine tasks.
.. toctree::
:maxdepth: 2
HowTo/Bluetooth_Connections
HowTo/Data_Connections
HowTo/Location_Services
HowTo/SSH_Access
...
...
Development_Environment/Boards/HowTo/Bluetooth_Connections.rst
0 → 100644
View file @
23800ce0
.. _devkit_howto_bluetooth:
Bluetooth Connections
=====================
Once you have :ref:`configured Bluetooth <imx8_devkit_configure_bluetooth>` for
the development board, you can check that it can be paired with other devices
and used for data transfer with the following instructions.
.. contents::
:local:
Finding Another Device
----------------------
From a workstation, log in to the development board using either ``ssh`` or
``picocom``. Ensure that the Bluetooth module is enabled then enter the
following command::
purism@pureos:~$ sudo bluetoothctl
You should see output like this::
Agent registered
[bluetooth]
At the prompt, enter this command to start scanning for devices::
[bluetooth]# scan on
You should see a ``Discovery started`` message and a list of devices should
begin to appear. When the device you want to connect to, stop the scan with
this command::
[bluetooth]# scan off
Make a note of the address of the device you want to access. This takes the
form of six comma-separated hexadecimal numbers, such as ``88:DA:1A:9E:BA:95``.
Pairing with a Device
---------------------
At the prompt, initiate a pairing request with the device, replacing
``88:DA:1A:9E:BA:95`` with the address you want to use::
[bluetooth]# pair 88:DA:1A:9E:BA:95
You should see output like this::
Attempting to pair with 88:DA:1A:9E:BA:95
[CHG] Device 88:DA:1A:9E:BA:95 Connected: yes
Request confirmation
[agent] Confirm passkey 936222 (yes/no):
The last line is a question that requires you to type ``yes`` or ``no`` to
verify that the passkey shown has been presented to you by the other device.
This passkey will be different to the one you see. The other device will also
expect you to confirm the pairing request, typically using the notification it
used to present the passkey.
If the passkey is the same then confirm the pairing request on the other device
and enter ``yes`` at the prompt. Otherwise enter ``no``.
If you completed the pairing request, you should see this output::
Pairing successful
You can test this by using the ``paired-devices`` command at the prompt.
It should now be possible to use the device for data transfers without needing
to enter a passkey again for the current session. You can exit the tool by
entering this command::
[bluetooth]# quit
When you have finished with the data connection, start ``bluetoothctl`` again
and unpair the device::
[bluetooth]# remove 88:DA:1A:9E:BA:95
You should see the following output::
Device has been removed
If you want to access the device again you will need to perform another pairing
request.
Development_Environment/Boards/imx8.rst
View file @
23800ce0
...
...
@@ -365,6 +365,8 @@ directly::
nmcli device wifi list
nmcli device wifi connect SSID-Name password wireless-password
.. _imx8_devkit_configure_bluetooth:
Configure Bluetooth
-------------------
...
...
@@ -384,4 +386,5 @@ This should produce output like this::
Devices:
hci0 88:DA:1A:9E:BA:95
The exact device address will be different for your board.
The exact device address will be different for your board. See :ref:`devkit_howto_bluetooth`
for further ways to test and use the Bluetooth module.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment