Skip to content

Commit 051cce4

Browse files
divipillairlubos
authored andcommitted
doc: Update testing steps of the Peripheral UART sample
Update testing steps (testing_with_nrf_connect_for_mobile) of the Peripheral UART sample: * Added testing steps for ioS and Android devices. * Provided detailed steps as the sample is featured in Quick Start. Signed-off-by: divya pillai <[email protected]>
1 parent b6f1858 commit 051cce4

File tree

1 file changed

+141
-51
lines changed

1 file changed

+141
-51
lines changed

samples/bluetooth/peripheral_uart/README.rst

Lines changed: 141 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -265,60 +265,150 @@ To perform the test, complete the following steps:
265265

266266
.. group-tab:: nRF21, nRF52 and nRF53 DKs
267267

268-
1. Connect the device to the computer to access UART 0.
269-
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
270-
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter.
271-
#. |connect_terminal|
272-
#. Optionally, you can display debug messages.
273-
See :ref:`peripheral_uart_debug` for details.
274-
#. Install and start the `nRF Connect for Mobile`_ application on your smartphone or tablet.
275-
#. Connect to the device using nRF Connect for Mobile.
276-
Observe that **LED 2** is lit.
277-
#. Optionally, pair or bond with the device with MITM protection.
278-
This requires using the passkey value displayed in debug messages.
279-
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
280-
To confirm pairing or bonding, press **Button 1** on the device and accept the passkey value on the smartphone.
281-
#. In the application, observe that the services are shown in the connected device.
282-
#. Select the UART RX characteristic value in nRF Connect for Mobile.
283-
You can write to the UART RX and get the text displayed on the COM listener.
284-
#. Type "0123456789" and tap :guilabel:`SEND`.
285-
Verify that the text "0123456789" is displayed on the COM listener.
286-
#. Tap the three-dot menu below the device name, and select **Enable CCCDs**.
287-
This enables the notifications on the UART TX characteristic on the peripheral (DK) to allow sending UART characters to the phone or tablet.
288-
#. To send data from the device to your phone or tablet, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
289-
Observe that a notification is sent to the peer.
290-
#. Disconnect the device in nRF Connect for Mobile.
291-
Observe that **LED 2** turns off.
268+
.. tabs::
269+
270+
.. group-tab:: Android
271+
272+
1. Connect the device to the computer to access UART 0.
273+
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
274+
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter.
275+
#. |connect_terminal|
276+
#. Optionally, you can display debug messages.
277+
See :ref:`peripheral_uart_debug` for details.
278+
#. Install and start the `nRF Connect for Mobile`_ application on your Android device or tablet.
279+
#. If the application does not automatically start scanning, tap the Play icon in the upper right corner.
280+
#. Connect to the device using nRF Connect for Mobile.
281+
282+
Observe that **LED 2** is lit.
283+
#. Optionally, pair or bond with the device with MITM protection.
284+
This requires using the passkey value displayed in debug messages.
285+
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
286+
To confirm pairing or bonding, press **Button 1** on the device and accept the passkey value on the smartphone.
287+
#. In the application, observe that the services are shown in the connected device.
288+
#. Select the **UART RX characteristic** option in nRF Connect for Mobile and tap the up arrow button.
289+
You can write to the UART RX and get the text displayed on the COM listener.
290+
#. Type "0123456789" and tap :guilabel:`SEND`.
291+
292+
Verify that the text "0123456789" is displayed on the COM listener.
293+
#. To send data from the device to your phone or tablet, in the terminal emulator connected to the sample, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
294+
295+
The text is sent through the development kit to your mobile device over a Bluetooth LE link.
296+
#. On your Android device or tablet, tap the three-dot menu next to **Disconnect** and select **Show log**.
297+
298+
The device displays the text in the nRF Connect for Mobile log.
299+
#. Disconnect the device in nRF Connect for Mobile.
300+
301+
Observe that **LED 2** turns off.
302+
303+
.. group-tab:: iOS
304+
305+
1. Connect the device to the computer to access UART 0.
306+
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
307+
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter.
308+
#. |connect_terminal|
309+
#. Optionally, you can display debug messages.
310+
See :ref:`peripheral_uart_debug` for details.
311+
#. Install and start the `nRF Connect for Mobile`_ application on your iOS device or tablet.
312+
#. If the application does not automatically start scanning, tap the Play icon in the upper right corner.
313+
#. Connect to the device using nRF Connect for Mobile.
314+
315+
Observe that **LED 2** is lit.
316+
#. Optionally, pair or bond with the device with MITM protection.
317+
This requires using the passkey value displayed in debug messages.
318+
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
319+
To confirm pairing or bonding, press **Button 1** on the device and accept the passkey value on the smartphone.
320+
#. In the application, observe that the services are shown in the connected device.
321+
#. Select the **UART RX characteristic** option in nRF Connect for Mobile and tap the up arrow button.
322+
323+
The **Write Value** window opens.
324+
You can write to the UART RX and get the text displayed on the COM listener.
325+
#. Type "0123456789" and tap **Write**.
326+
327+
Verify that the text "0123456789" is displayed on the COM listener.
328+
#. To send data from the device to your phone or tablet, in the terminal emulator connected to the sample, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
329+
330+
The text is sent through the development kit to your mobile device over a Bluetooth LE link.
331+
#. On your iOS device or tablet, select the **Log** tab.
332+
333+
The device displays the text in the nRF Connect for Mobile log.
334+
#. Disconnect the device in nRF Connect for Mobile.
335+
336+
Observe that **LED 2** turns off.
292337

293338
.. group-tab:: nRF54 DKs
294339

295340
.. note::
296341
|nrf54_buttons_leds_numbering|
297342

298-
1. Connect the device to the computer to access UART 0.
299-
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
300-
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter to it.
301-
#. |connect_terminal|
302-
#. Optionally, you can display debug messages.
303-
See :ref:`peripheral_uart_debug` for details.
304-
#. Install and start the `nRF Connect for Mobile`_ application on your smartphone or tablet.
305-
#. Connect to the device using nRF Connect for Mobile.
306-
Observe that **LED 1** is lit.
307-
#. Optionally, pair or bond with the device with MITM protection.
308-
This requires using the passkey value displayed in debug messages.
309-
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
310-
To confirm pairing or bonding, press **Button 0** on the device and accept the passkey value on the smartphone.
311-
#. In the application, observe that the services are shown in the connected device.
312-
#. Select the UART RX characteristic value in nRF Connect for Mobile.
313-
You can write to the UART RX and get the text displayed on the COM listener.
314-
#. Type "0123456789" and tap :guilabel:`SEND`.
315-
Verify that the text "0123456789" is displayed on the COM listener.
316-
#. Tap the three-dot menu below the device name, and select **Enable CCCDs**.
317-
This enables the notifications on the UART TX characteristic on the peripheral (DK) to allow sending UART characters to the phone or tablet.
318-
#. To send data from the device to your phone or tablet, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
319-
Observe that a notification is sent to the peer.
320-
#. Disconnect the device in nRF Connect for Mobile.
321-
Observe that **LED 1** turns off.
343+
.. tabs::
344+
345+
.. group-tab:: Android
346+
347+
1. Connect the device to the computer to access UART 0.
348+
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
349+
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter.
350+
#. |connect_terminal|
351+
#. Optionally, you can display debug messages.
352+
See :ref:`peripheral_uart_debug` for details.
353+
#. Install and start the `nRF Connect for Mobile`_ application on your Android device or tablet.
354+
#. If the application does not automatically start scanning, tap the Play icon in the upper right corner.
355+
#. Connect to the device using nRF Connect for Mobile.
356+
357+
Observe that **LED 1** is lit.
358+
#. Optionally, pair or bond with the device with MITM protection.
359+
This requires using the passkey value displayed in debug messages.
360+
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
361+
To confirm pairing or bonding, press **Button 0** on the device and accept the passkey value on the smartphone.
362+
#. In the application, observe that the services are shown in the connected device.
363+
#. Select the **UART RX characteristic** option in nRF Connect for Mobile and tap the up arrow button.
364+
You can write to the UART RX and get the text displayed on the COM listener.
365+
#. Type "0123456789" and tap :guilabel:`SEND`.
366+
367+
Verify that the text "0123456789" is displayed on the COM listener.
368+
#. To send data from the device to your phone or tablet, in the terminal emulator connected to the sample, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
369+
370+
The text is sent through the development kit to your mobile device over a Bluetooth LE link.
371+
#. On your Android device or tablet, tap the three-dot menu next to **Disconnect** and select **Show log**.
372+
373+
The device displays the text in the nRF Connect for Mobile log.
374+
#. Disconnect the device in nRF Connect for Mobile.
375+
376+
Observe that **LED 1** turns off.
377+
378+
.. group-tab:: iOS
379+
380+
1. Connect the device to the computer to access UART 0.
381+
If you use a development kit, UART 0 is forwarded as a COM port (Windows) or ttyACM device (Linux) after you connect the development kit over USB.
382+
If you use Thingy:53, you must attach the debug board and connect an external USB to UART converter.
383+
#. |connect_terminal|
384+
#. Optionally, you can display debug messages.
385+
See :ref:`peripheral_uart_debug` for details.
386+
#. Install and start the `nRF Connect for Mobile`_ application on your iOS device or tablet.
387+
#. If the application does not automatically start scanning, tap the Play icon in the upper right corner.
388+
#. Connect to the device using nRF Connect for Mobile.
389+
390+
Observe that **LED 1** is lit.
391+
#. Optionally, pair or bond with the device with MITM protection.
392+
This requires using the passkey value displayed in debug messages.
393+
See :ref:`peripheral_uart_debug` for details on how to access debug messages.
394+
To confirm pairing or bonding, press **Button 0** on the device and accept the passkey value on the smartphone.
395+
#. In the application, observe that the services are shown in the connected device.
396+
#. Select the **UART RX characteristic** option in nRF Connect for Mobile and tap the up arrow button.
397+
398+
The **Write Value** window opens.
399+
You can write to the UART RX and get the text displayed on the COM listener.
400+
#. Type "0123456789" and tap **Write**.
401+
402+
Verify that the text "0123456789" is displayed on the COM listener.
403+
#. To send data from the device to your phone or tablet, in the terminal emulator connected to the sample, enter any text, for example, "Hello", and press Enter to see it on the COM listener.
404+
405+
The text is sent through the development kit to your mobile device over a Bluetooth LE link.
406+
#. On your iOS device or tablet, select the **Log** tab.
407+
408+
The device displays the text in the nRF Connect for Mobile log.
409+
#. Disconnect the device in nRF Connect for Mobile.
410+
411+
Observe that **LED 1** turns off.
322412

323413
.. _nrf52_computer_testing:
324414
.. _peripheral_uart_testing_ble:
@@ -344,19 +434,19 @@ To perform the test, complete the following steps:
344434
When the connection is established, the device appears in the main view.
345435

346436
#. Click :guilabel:`Start scan`.
347-
#. Find the DK you want to test and click the corresponding :guilabel:`Connect` button.
437+
#. Find the development kit you want to test and click the corresponding :guilabel:`Connect` button.
348438

349439
The default name for the Peripheral UART sample is *Nordic_UART_Service*.
350440

351441
#. Select the **Universal Asynchronous Receiver/Transmitter (UART)** RX characteristic value.
352442
#. Write ``30 31 32 33 34 35 36 37 38 39`` (the hexadecimal value for the string "0123456789") and click :guilabel:`Write`.
353443

354444
The data is transmitted over Bluetooth LE from the app to the DK that runs the Peripheral UART sample.
355-
The terminal emulator connected to the DK then displays ``"0123456789"``.
445+
The terminal emulator connected to the development kit then displays ``"0123456789"``.
356446

357447
#. In the terminal emulator, enter any text, for example ``Hello``.
358448

359-
The data is transmitted to the DK that runs the Peripheral UART sample.
449+
The data is transmitted to the development kit that runs the Peripheral UART sample.
360450
The **UART TX** characteristic displayed in the app changes to the corresponding ASCII value.
361451
For example, the value for ``Hello`` is ``48 65 6C 6C 6F``.
362452

0 commit comments

Comments
 (0)