BLUETOOTH AT COMMANDS

CHANGE INTERNAL SETTING OF BLUETOOTH MODULE LIKE PASSWORD, NAME ETC

To change internal settings we need to set Bluetooth in AT command mode, follow the steps below to set Bluetooth (BT) in AT command mode to use Bluetooth AT commands.

What is AT Command in Bluetooth? It means Attention Command, make attention to the controller, now we are using you not as simple data but for commands.

STEPS TO SET BLUETOOTH IN AT COMMAND MODE

Caution: If the module is connected to any other Bluetooth device, it starts to communicate with that device and fails to work in AT command mode.

  1. To enable AT command mode, take arduino, BT – HC05, 5 male to female connectors
  2. Upload a blank program to arduino
    void setup() {
    }
    void loop() {
    }
    
  3. Then, connect pins as follows
S.N. Arduino Bluetooth HC05
1. + 5V + 5V
2. GND GND
3. Rx Rx
4. Tx Tx
5. Enable + 5/3.3V

After all connection made, pick out ground pin of BT from arduino

  1. Press the button switch (of Bluetooth module) for a second and connect ground wire (which was picked out in previous step) to arduino. Then you will observe BT module led blinks once for every 2 second rather than continuous blinking. If you find continuously blinking for every half of a second it means you didn’t enter in AT command mode, don’t worry try again same step.
  2. As you entered in AT command mode, opens Serial monitor in Arduino IDE and sets the baud rate of 38400 in serial monitor
    BLUETOOTH AT COMMANDS
    SET BAUD RATE TO 38400

  3. Then type AT and send it, you will receive OK on serial monitor, means you successfully entered in AT command mode.
INPUT
BLUETOOTH AT COMMANDS
AT COMMAND: AT
OUTPUT
COMMAND AT: RETURN STATUS - "OK"
AT COMMAND, AT : RETURN STATUS – “OK”

SOME BLUETOOTH AT COMMANDS

1) TO SEE EXISTING NAME:

After entering in AT command mode:

To see the existing name of the Bluetooth device type “AT+NAME” and send it will returns back name of the Bluetooth device here is “HC-05” shown in fig.

INPUT
AT command NAME
AT COMMAND: NAME
OUTPUT
 
AT COMMAND NAME
AT COMMAND, NAME : RETURN STATUS – “+NAME: HC-05” “OK”

2) TO CHANGE NAME:

To change the existing name of the Bluetooth device type “AT+NAME=name you want” here SHOOLIN LABS and send it will returns back OK that your command accepted successfully shown in fig.

INPUT
AT COMMAND NAME CHANGE
AT COMMAND TO CHANGE NAME
OUTPUT
AT COMMAND NAME CHANGE: RETURN STATUS
AT COMMAND NAME CHANGE: RETURN STATUS – “OK”

Re-check updated name of device by command AT+NAME. Yes it is updated

INPUT

BLUETOOTH AT COMMANDS

OUTPUT

3) TO SEE EXISTING PASSWORD:

To see the existing password of the Bluetooth device type “AT+PSWD” and send it will returns back password of the Bluetooth device here is “1234” shown in fig.

INPUT
AT COMMAND: PSWD
OUTPUT

4) TO CHANGE PASSWORD

To change the existing passwords of the Bluetooth device type [AT+PSWD=”password you want”] in double course, here PASSWORD and send it will returns back OK that your command accepted successfully shown in fig.

INPUT
BLUETOOTH AT COMMANDS
AT COMMAND TO CHANGE PASSWORD
OUTPUT

Re-check updated password of device by command AT+PSWD. Yes it is updated

INPUT
BLUETOOTH AT COMMANDS
OUTPUT

FEW MORE BLUETOOTH AT COMMANDS

1) TEST

Command

Response

Parameter

AT

OK

NONE

2) Reset

Command

Response

Parameter

AT+RESET

OK

NONE

3) Get the soft version

Command

Response

Parameter

AT+VERSION

+VERSION: <Version Parameter> OK

Parameter: Version number

+VERSION:2.0-20100601 OK

4) Restore default status

Command

Response

Parameter

AT+ORGL

OK

NONE

Default status:

  • Device type: 0
  • Module work mode: Slave Mode
  • Serial parameter: Baud rate: 38400 bits/s; Stop bit: 1 bit; Parity bit: None.
  • Passkey: “1234”
  • Device name: “HC-05”

For more commands we will update a PDF file soon

Total Visits: 359
0 0 vote
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
Translate »
0
Would love your thoughts, please comment.x
()
x