Arduino Zero HC-05 Bluetooth help


hi all,

i've connected hc-05 bluetooth module arduino zero.

arduino pins           bluetooth pins

rx (pin 0)     ------->      tx

tx (pin 1)      ------->      rx

5v                ------->      vcc

gnd             ------->      gnd


this code have.

code: [select]

char data = 0;            //variable storing received data
void setup()
{
    serial.begin(9600);   //sets baud serial data transmission                               
}
void loop()
{
   if(serial.available() > 0)      // send data when receive data:
   {
      data = serial.read();        //read incoming data & store data
      serial.print(data);          //print value inside data in serial monitor
      serial.print("\n");       
   }
}


when paired hc-05 , trying send on serial data of 0 or 1 not seem pick up. can not see in serial monitor. using same setup , code arduino uno work's perfectly. missing zero?

i think might need change serial.xxx commands serial1.xxx. glad if confirm this. have published basic notes on bluetooth, don't need, , update them


Arduino Forum > Using Arduino > Networking, Protocols, and Devices (Moderator: fabioc84) > Arduino Zero HC-05 Bluetooth help


arduino

Comments

Popular posts from this blog

DHT11 Time out error using v0.4.1library

Sketch upload fails with Java error (___REMOVE___/bin/avrdude)!

Arduino Uno + KTY81/210 temperature sensor