# Dual Mode Bluetooth&#x20;

### Introduction

The Bluetooth module is a standard transparent transmission module, which sends serial port data to devices connected to Bluetooth.

You can wirelessly upload firmware or control the motion of the robot through a Bluetooth connection. You can even control the robot using our smartphone app [Petoi](https://docs.petoi.com/mobile-app/app-guide). We have included our official Bluetooth module in the standard robot kit. As shown below:

![](/files/ScFYjgMRW07CMkuXx444)

### Connection with NyBoard

The connection between the Bluetooth module and the NyBoard is shown in the figure below, you need to plug the Bluetooth module into the 6-pin socket on the NyBoard. Note the pin order of the Bluetooth module. Once the battery is connected to the NyBoard, press and hold the button on the battery to power the robot. A blinking LED on the Bluetooth module indicates waiting for a connection.

![](/files/QdIjG3X96goIBLCXnOzF)

### Connect the dongle with your phone

You need to connect the dongle within the Petoi App, rather than your phone's system Bluetooth settings. On some phones, you need to grant Bluetooth and location services permissions to the app.&#x20;

A more detailed setup can be found in the [mobile app](https://docs.petoi.com/mobile-app/app-guide) section.&#x20;

### Connect the dongle with your computer

In your system's Bluetooth settings, search for a Bluetooth device name started with Petoi or Bittle, and connect. The default PIN for pairing is “0000“ or “1234”. After the pairing is successful, the system will assign a serial port name.

{% hint style="info" %}
On Mac, go to System Preference -> Bluetooth, find a device name started with Petoi or Bittle, and connect.&#x20;
{% endhint %}

![](/files/t61GHUxTUSKRtnB0eere)

{% hint style="info" %}
On Windows, add the Bluetooth device in the system settings.
{% endhint %}

![](/files/Sd4sWOhn2nTQao06i6fR) ![](/files/suIIb5TLgNCchrpn55su)

![](/files/LSSCsL5b1nzMC5rqbNVH)

![](/files/7VCSfZSeDJyD9U5PYTzj) ![](/files/SmAwi3kOIaT8n0BFd2uN)

![](/files/31P8YHy0IRIFUX8o8OAG)

![](/files/GmEfmoBOSL3xH2zgfZpv)

{% hint style="info" %}
For Win10 users, the system will assign the "incoming" COM port and the "outgoing" COM port to Bluetooth. Please use the "outgoing" COM port. For details, please check in the "More Bluetooth options" of Win10 as below:
{% endhint %}

![](/files/IpJiAAsBZuNEAluSi6XG)

![](/files/sfmoB7BTYA1vrwQkur5Q)

You can then select it under **Tools**->**Port** in the Arduino IDE, using the same method as the USB uploader. After opening the serial monitor, please select: **No line ending**, and the baud rate is set to **115200**.

{% hint style="info" %}
The Bluetooth connection with the computer may occasionally drop. Keeping the serial monitor open can make it more stable. But note it will also occupy the port and block other applications that want to connect.&#x20;
{% endhint %}

### Configure the Bluetooth module

If you want to configure the Bluetooth module, please refer to "JDY-23 AT Command List". Plug the Bluetooth module into the USB adapter debugging interface. As shown below:

![](/files/6qbVBGm1nV1TIL7cjRCK)

The commonly used commands are listed below:

| Usage                        | Command                                           | Demo                                                                                            |
| ---------------------------- | ------------------------------------------------- | ----------------------------------------------------------------------------------------------- |
| Check BT module version      | AT+VER                                            | <p>AT+VER</p><p>>+VER=JDY-23A-V2.21,Bluetooth V3.0+BLE</p><p>（BT module version infomation）</p> |
| Check BT broadcast name      | AT+NAME                                           | <p>AT+NAME</p><p>>+NAME=BITTLE</p>                                                              |
| Change BT broadcast name     | AT+NAME(name)                                     | <p>AT+NAMEPuppy</p><p>>+OK</p><p>AT+NAME</p><p>>+NAME=Puppy</p>                                 |
| Change BT BLE broadcast name | AT+NAM<mark style="color:red;">**B**</mark>(name) | <p>AT+NAMBPuppy</p><p>>+OK</p><p>AT+NAMB</p><p>>+NAMB=Puppy</p>                                 |
| Check serial baud rate       | AT+BAUD                                           | <p>AT+BAUD</p><p>>+BAUD=8 （8 = 115200， 7=57600）</p>                                             |
| Change serial baud rate      | AT+BAUD                                           | <p>AT+BAUD7</p><p>>+OK （Set serial monitor to 57600）</p><p>AT+BAUD</p><p>>+BAUD=7</p>           |

When you use the serial terminal like "Arduino serial monitor" to set JDY-23 with AT commands, you must set "**NL and CR**",  and the baud rate is set to **115200,** or the JDY-23 module will not identify any AT command you send.

![](/files/-MX5he3vsd-zAJM-lcTT)

{% hint style="info" %}
If you are a developer, you can use Lightblue or other tools to connect the dongle's BLE service.
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.petoi.com/communication-modules/dual-mode-bluetooth.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
