How to send data to Xbee with redboard

Redboard — serial —> Xbee

How do I send any data to an xbee from a redboard. I’ve tried software serial and hardware serial. Its directly connected to the XBee rx and tx and nothing happens.

I have another Xbee connected to my computer listening for this, so if the data successfully got sent it would show up there on the serial monitor. I have already tested them that they send data to each other (right configurations)

SoftwareSerial XBee(13, 14); // RX, TX
XBee.begin(9600);
XBee.println("setups");

nothing happens.

Which Xbee module are you using?

its on firmware version 3012

its one of these but its black colored edit sorry i keep changing it i keep finding differences


Heres what it says in the XCTU

Yo i figured it out heres a bare bones example:

#include <SoftwareSerial.h>

// Define SoftSerial TX/RX pins
uint8_t ssRX = 13; //connect our pin 13 to the xbees TX
uint8_t ssTX = 4;

// Remember to connect all devices to a common Ground
SoftwareSerial nss(ssRX, ssTX);

String expectedResponse = "";

void setup() {
  Serial.begin(9600);
  nss.begin(9600);
  Serial.println("XBee Test Started");
  nss.print("hello"); //this line sends over xbee
}

void loop() {
      //receiving data
      String receivedData = "";
      if (nss.available()) {
        char c = nss.read();
        receivedData += c;
      }

     delay(10);
}
1 Like