Xbee + XBee Adapter + Yun Compatibility

XBee projects like the adapter, xBee tutorials, tweetawatt/wattcher, etc. from Adafruit

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

Hello everyone,

I have recently been trying to create a network of XBees using my Arduino boards. All of my XBees are using the Adapters sold by Adafruit. I have one XBee connected to an FTDI cable to my computer, another one connected through my Arduino Uno, and the last one connected through my Arduino Yun. The one on the Uno and the FTDI cable work fine. They transmit data back and forth between the two of them perfectly, but my XBee on the Yun is a little troubled. It is having trouble sending and receiving data from the other XBees.

Both of the Arduino XBees are set up identical to this picture. Except without a Due and instead with an Uno and Yun, respectively.
http://www.ladyada.net/images/xbee/ardu ... simple.jpg

Is there some sort of issue specifically with the Yun communicating with an XBee? Maybe in how the Yun handles its serial data? Also, is there anyway to fix this or do I just have to use another board. I would like to keep the Yun for its SD card slot for storing collected data.

Thanks,
Tyler

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

Tresky wrote:It is having trouble sending and receiving data from the other XBees.
Does it work a little bit, or not at all?
Tresky wrote:Both of the Arduino XBees are set up identical to this picture.
So, you have RX and TX connected to Digital 2 and 3? That should work.

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

Does it work a little bit, or not at all?
It is able to send data out to the XBees around it, but not able to receive it. I'm even using the example code provided http://www.ladyada.net/make/xbee/point2point.html both of the Arduinos.
So, you have RX and TX connected to Digital 2 and 3? That should work.
Yeah, that's how I have it set up. It works on the Uno, but not on the Yun. :/

Does the Yun handle serial data differently in a way that would prevent it from working?

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

Switch the XBee module on the Yun for a different module. See if the problem is with the module itself.

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

It's not the module. Just tried another one; same problem. :/

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

It may be a problem with your particular Yun. There's nothing about the Yun design that would cause this

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

Hmm... weird. I tried another Yun and got the same problem.

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

So much for that theory. What about trying a different pair of pins for RX and TX.

Actually, are you connected to I2C for anything? D2 and D3 are shared with SCL and SDA

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

Actually, are you connected to I2C for anything? D2 and D3 are shared with SCL and SDA
I am not. I understand that the TX and RX pins on the Yun are used, by the board, for communicating with the Linux Kernal onboard. Could that be interfering in any way?
What about trying a different pair of pins for RX and TX.
I tried using D0 and D1. No luck. :(

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

I think D0 and D1 are used for communicating with linux.

Try D8 for RX and D7 for TX

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

D7 and D8 didn't work either. :(

I decided to do another little test and just try basics to see if they would work and the board won't even print to Serial. What could that signify?

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

I have no idea. Have you tried this over at the Arduino.cc forums?

User avatar
tresky
 
Posts: 18
Joined: Tue Sep 18, 2012 12:47 pm

Re: Xbee + XBee Adapter + Yun Compatibility

Post by tresky »

Got an answer from searching around, so I thought I'd share it here for everyone's benefit.

It turns out that the Yun is similar to the Leonardo in the fact that pins 0 and 1, and 2 and 3 don't support change interrupts, so we simply need to use different ports. Ports 8 and 9 seem to work great. :)

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Xbee + XBee Adapter + Yun Compatibility

Post by adafruit_support_rick »

Good find!

Locked
Please be positive and constructive with your questions and comments.

Return to “XBee products (discontinued)”