Iam working with gyroscope and Iam trying to send its values from one bluetooth(HC-05) module to another bluetooth module but the data exchange is not happening and I have used 2 arduino boards to do it.
Is there a simple way to do it?
-
You will get your required details here.vinay kulkarni– vinay kulkarni2016年04月20日 05:25:23 +00:00Commented Apr 20, 2016 at 5:25
1 Answer 1
I think there is no simple answer for that. First you have to pair 2 HC-05 modules. To do so, you have to configure one HC-05 as slave, and other HC-05 as master.
Steps for SLAVE:
- Be sure to select correct Baudrate in your Terminal Emulator (Arduino IDE or Terraterm etc.) for your module. There is no default baudrate... Different manufacturers set the baudrate on their HC-05's differently... 9600 and 38400 are good starting points.
- Enter AT mode, by providing high level(3.3V or 5V) signal on KEY pin(PIO11)
- Note the values of
AT+PSWD?
,AT+NAME?
andAT+ADDR?
(let's say .&checktime(1111,22,12,':')3456) commands. You might set the password to 1234 for easy remembering. IssueAT+PSWD=0000
... - Be sure to set the module to slave mode by issuing
AT+ROLE=0
command.
Steps for MASTER:
- Be sure to select correct Baudrate in your Terminal Emulator (Arduino IDE or Terraterm etc.) for your module. There is no default baudrate... Different manufacturers set the baudrate on their HC-05's differently... 9600 and 38400 are good starting points.
- Enter AT mode, by providing high level(3.3V or 5V) signal on KEY pin(PIO11)
- Reset the module to its original state by issuing
AT+ORGL
command. - Remove the previous parings(if any) by issuing
AT+RMAAD
command. - Set same password as slave by issuing
AT+PASSWD=0000
command. - Change the role to master;
AT+ROLE=1
- Set connecting mode to any address it sees;
AT+CMODE=1
- Initialize the SPP profile lib ;
AT+INIT
- Be sure that you see the slave HC-05 module,
AT+INQ
command will list the modules you see. - Be sure that you see address of the slave module(.&checktime(1111,22,12,':')3456).
- Last of all enter
AT+LINK=1111,22,123456
(note the commas).
With these steps you should exchange data...
-
Sure @szahin will try to do itzerocommaclub– zerocommaclub2016年04月20日 02:26:53 +00:00Commented Apr 20, 2016 at 2:26
Explore related questions
See similar questions with these tags.