Não é possível conectar-se ao Bluetooth Mate Silver

0

Estou tentando conectar meu laptop executando o Ubuntu 12.04 a um Bluetooth Mate Silver conectado a um arduino.

A fiação é:

  • CTS-I- > Sem conexão (deixar flutuante)
  • VCC- > 5V
  • GND- > GND
  • TX-O- > D2
  • RX-I- > D3
  • RTS-O- > Sem conexão (deixar flutuante)

Código em execução no arduino:

    $include <SoftwareSerial.h>  

    int bluetoothTx = 2;  // TX-O pin of bluetooth mate, Arduino D2
    int bluetoothRx = 3;  // RX-I pin of bluetooth mate, Arduino D3

    SoftwareSerial bluetooth(bluetoothTx, bluetoothRx);

    void setup()
    {
      Serial.begin(9600);  // Begin the serial monitor at 9600bps

      bluetooth.begin(115200);  // The Bluetooth Mate defaults to 115200bps
      bluetooth.print("$$$");  // Enter command mode
      delay(100);  // Short delay, wait for the Mate to send back CMD
      bluetooth.println("U,9600,N");  // Temporarily Change the baudrate to 9600, no parity
      // 115200 can be too fast at times for NewSoftSerial to relay the data reliably
      bluetooth.begin(9600);  // Start bluetooth serial at 9600
    }

    void loop()
    {
      if(bluetooth.available())  // If the bluetooth sent any characters
      {
        // Send any characters the bluetooth prints to the serial monitor
        Serial.print((char)bluetooth.read());  
      }
      if(Serial.available())  // If stuff was typed in the serial monitor
      {
        // Send any characters the Serial monitor prints to the bluetooth
        bluetooth.print((char)Serial.read());
      }
      // and loop forever and ever!
    }

Quando eu abro o gerenciador de bluetooth no ubuntu eu acho que o posicionamento do bluetooth é visível, mas desconhecido e não há nenhuma opção de conexão SPP quando clico nele com o botão direito. Todos os tutoriais e blogs pelos quais passei conectaram-se ao bluetooth mate através da opção SPP.

Pic do meu gerenciador de bluetooth: link

Então, como eu me conecto ao parceiro Bluetooth?

    
por Nithin Kumar Biliya 20.01.2013 / 06:18

1 resposta

0

Depois de pesquisar muito e ler vários blogs, deparei com este comando:

    sudo rfcomm bind 0 00:06:66:48:71:0C

onde 00: 06: 66: 48: 71: 0C é o endereço mac do silver mate do bluetooth.

Uma vez que eu fiz isso, descobri que a opção de porta serial para o meu dispositivo no gerenciador bluetooth estava habilitada. Eu continuo de lá para me conectar ao dispositivo.

    
por Nithin Kumar Biliya 23.01.2013 / 04:42