RN-XV Wifly and BS2 through XBee SIP Adapter
piole
Posts: 8
Hi,
I'm connecting my BS2 to my Wifly with the help of the XBee SIP adapter http://www.parallax.com/tabid/768/ProductID/691/Default.aspx
so that the adapter does the 5V / 3.3V conversion.
Using the SERIN command I managed to make the BS2 read serial data sent by the Wifly - no problem there.
But I can't get the serial out to work properly.
I tried all possible values of baud settings on the WiFly and the BS2.
If I use the value 84 (which works perfectly for SERIN) for SEROUT, the Wifly does not receive anything : the "show stats" command says zero byte received, zero error, and the RX LED is not blinking.
If I use the value 16468 (inverted) the Wifly seems to receive data but it is garbled (weird characters displayed in Wifly console, and "show stats" reports many errors).
If I add a 10 ms pace in the SEROUT I can reduce the amount of errors, but the characters are still garbled.
Tried to reduce baud rate to 4800 and 2400 with no luck...
The only thing I didn't try is to use flow control, but I can't see why it would help.
Anyone has every made this work ?
Any idea ?
Could the problem come from the XBee SIP adapter ?
Thanks
Paul
I'm connecting my BS2 to my Wifly with the help of the XBee SIP adapter http://www.parallax.com/tabid/768/ProductID/691/Default.aspx
so that the adapter does the 5V / 3.3V conversion.
Using the SERIN command I managed to make the BS2 read serial data sent by the Wifly - no problem there.
But I can't get the serial out to work properly.
I tried all possible values of baud settings on the WiFly and the BS2.
If I use the value 84 (which works perfectly for SERIN) for SEROUT, the Wifly does not receive anything : the "show stats" command says zero byte received, zero error, and the RX LED is not blinking.
If I use the value 16468 (inverted) the Wifly seems to receive data but it is garbled (weird characters displayed in Wifly console, and "show stats" reports many errors).
If I add a 10 ms pace in the SEROUT I can reduce the amount of errors, but the characters are still garbled.
Tried to reduce baud rate to 4800 and 2400 with no luck...
The only thing I didn't try is to use flow control, but I can't see why it would help.
Anyone has every made this work ?
Any idea ?
Could the problem come from the XBee SIP adapter ?
Thanks
Paul
Comments
I contacted Tech support, waiting for their answer.
Just guessing : I think I read somewhere that in the beginning a few customers received adapters with an inverted diode.
On my adapter, with Baud 84 the LED is always off and that with 16468 (inverted polarity) the LED is always on... sounds like the same issue, no ?
The tech support says : "The adapters have logic level buffers on them to protect the XBee modules, which are most likely the cause of your corrupted data. The buffers are not spec'd to work with a WiFly module".
You said it has worked for you, meaning BS2 + SIP Adapter + WiFly ?
Paul
Thanks in advance,
Damen
Thanks a lot Mike and Chris for your answers.
There must be something I'm doing incorrectly but i can't find out what.
It doesn't seem to be a baud issue, I lowered it to 2400 (using Wifly telnet).
I never get the RX LED to blink and never get any RX on the wifly (unless in inverted mode, or a few random bytes at BS2 powerup).
Damen, I even did like you and tried with a bs2p(x) but still no improvement. Did you do anything special to make it work ?
Maybe I'll try to get rid of the adapter and plug the Wifly directly (I read somewhere that some arduino guy even managed to get it work without any voltage divider)...
There is a 3.3V adapter to power the Wifly and a simple 2-resistor divider for the 5V basic stamp SEROUT.
If anyone's interested the tutorial is here
http://dlnmh9ip6v2uc.cloudfront.net/datasheets/Wireless/Zigbee/maxstreaminterface3.pdf
Paul