using an Xbee Module with a Propeller
Dgswaner
Posts: 795
I've looked for some info on connecting/using a propeller with an Xbee Pro, and have had little luck. perhaps it's too simple to need a tutorial, but I've never used an Xbee module and I've very green when it comes to serial communication.
Can someone answer a few questions, or direct me to a site addressing this.
I'm pretty sure I can connect it to the propeller, and plan on using the Xbee object so I think most of the work done, a Post someone else said made me worry,
Do I need the development kit to configure the modules? I thought that I read (can't find it now) that the pro models come preset to point to point communication? I just want to talk from one propeller to another.... for now.
I'd love a tutorial or advise as my learn curve usually ends up costing me!
Thanks for any help
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
Can someone answer a few questions, or direct me to a site addressing this.
I'm pretty sure I can connect it to the propeller, and plan on using the Xbee object so I think most of the work done, a Post someone else said made me worry,
Do I need the development kit to configure the modules? I thought that I read (can't find it now) that the pro models come preset to point to point communication? I just want to talk from one propeller to another.... for now.
I'd love a tutorial or advise as my learn curve usually ends up costing me!
Thanks for any help
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
Comments
To flash the firmware requires a full DTR etc serial interface but otherwise it's two-wire, with AFAIR handshaking supported if you want that. Once configured, it's largely a case of send serial, that arrives at serial-out on the receiving XBees.
To configure point-to-point comms it's mainly a matter of setting the channel and network group. It may be a bit more complicated for Mark II XBees.
Thanks
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
My XBee object you mentioned works pretty well for configuring & comms. I use it in projects all the time, and it's pretty simple.
Please contact me off-line if you'd like:· martin@ selmaware. com· · (take out spaces)
-Martin (SelmaWare)
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
SelmaWare Solutions - StampPlot GUI for controllers, XBee and Propeller Application Boards
Southern Illinois University Carbondale, Electronic Systems Technologies
American Technical Educator's Assoc. Conference·- April, Biloxi, MS. -- PROPELLER WORKSHOP!
Post Edited (Martin Hebel) : 3/18/2008 11:09:28 PM GMT
sorry wasn't trying to imply that you hadn't sent them... I'm excited and can wait to get them!
Dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
-Martin
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
SelmaWare Solutions - StampPlot GUI for controllers, XBee and Propeller Application Boards
Southern Illinois University Carbondale, Electronic Systems Technologies
American Technical Educator's Assoc. Conference·- April, Biloxi, MS. -- PROPELLER WORKSHOP!
It's on my list of things to update, but works fine for Xbee testing.
OBC
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?
Getting started with the Protoboard? - Propeller Cookbook 1.4
Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
Got an SD card? - PropDOS
A Living Propeller FAQ - The Propeller Wiki
(Got the Knowledge? Got a Moment? Add something today!)
I just finished a project using xbee modules with the propeller. I bought the Appbee sip carrier board from Martin and added the jumpers to skip the 5V buffering. I purchased a couple of xbee modules and the maxstream usb xbee board. Made it really easy to trouble shoot. The maxstream usb board allows you to easily program the firmware and change settings on the xbee modules with maxstream's x-ctu software. x-ctu also has a terminal window so you can use it to send and recieve data from the xbee on your prop.
With the xbee and full duplex serial objects on the object exchange, it's all pretty easy to get going.
FYI, I'll have the AppBee Proto PCB's tomorrow, so if you'd like to order, you are welcome to. I still need to take a picture for the pages, but it's listed.
http://store.kagi.com/cgi-bin/store.cgi?storeID=J1A_LIVE&&
You did need 100, right? [noparse]:)[/noparse]
Thanks,
Martin
·
I have a question, is API mode the best option? this is for web control via a pink. I need bi-directional communication sending input from the user and receiving sensor data from the bot. As I understand it API mode sends "a packet" for lack of a better term. a pre-sized amount of data containing data from the x-bee modules as well as user data. this is kinda what I was going to set up for communication with the parallax RF adapters. so I think that it's a good match, but on the receiving side I need to receive the whole packet and then extrapolate out the message part of it. is this correct?
from what I read on the forum, I though I could just send data by just using one of the serial objects. and not have to set an ID, or CH (channel?). this might be a preferable option, but do I loose buffering and flow control if I go that route?
any help would be appreciated! The X-bee manual isn't for the casual hobbiest!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
-Martin
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
SelmaWare Solutions - StampPlot GUI for controllers, XBee and Propeller Application Boards
Southern Illinois University Carbondale, Electronic Systems Technologies
American Technical Educator's Assoc. Conference·- April, Biloxi, MS. -- PROPELLER WORKSHOP!
Sounds like we're working on a very similar project. I'm trying to use a prop and xbee to read some weather sensors then send them inside to a prop and the Pink module to read over the internet. I just spent the weekend trying to get my DSL modem and router set up to let me port forward some ports. I have a little weekend cabin and am trying to monitor/control some environmental stuff over the internet.
My final dream is to have some type of remote control robot I could run around outside via xbee.
Have you had any luck setting up the Pink to talk with the prop yet?
It does sound like we are working toward the same goal. my ultimate goal is an autonomous bot with mapping capabilities, but I wanted to be able to remotely monitor sensors, and processes first. so making it web enabled took care of that while adding a fun ability.
Martain, to tell my experience briefly, I got your boards didn't have any of the Xbee dev boards. I built your break out boards, wired them up and was able to get them to work propeller to propeller, in about 1 hour (not counting my learning curve).
With your break out boards and your help, figuring out the serial object was harder than getting the Xbee's to work. I'm up and running, I should be web enabled by weeks end! Thanks again for all your help.
added the code:
XB_out: sends hello world
XB_in: receives data and sends what it receives to a computer via the propeller programing port.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
Post Edited (Dgswaner) : 4/1/2008 5:46:44 AM GMT
What type of sensors are you working with and plan to put on the bot?
for my bot, I'm using a PING, some Sharp Ir sensors, the compass from parallax, and I will be adding wheel encoders. I also have 2 channel sound output, 10 LED Headlights, and LCD display to show status and sensor readings, a USB camera with pan and tile servos, and a servo for the Ping. I also want to add Ir remote control functionality. and even further down the road I want to add an Emic text to speech module. But at that point I think I'll be adding another prop to handle the required I/O pins.
I don't have the Ir sensors connected to the bot yet, but I'm going through the Basic Analog and Digital booklet so i can get it figured out. lack of sensors if my bots biggest down fall. the codes works for navigating but the one PING I have doesn't always "see" everything.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
"A complex design is the sign of an inferior designer." - Jamie Hyneman, Myth Buster
DGSwaner
It seems like you got your project working. In the end did you uses the XBee AT interface in Martin's object?
I'm working on a wireless project using XBee that (I believe) requires the API mode. I've looked over your posted code for examples of using Martin's object for its API features, but it looks like you are using it in AT mode. Is that correct?
Martin-
Do you have any example programs, showing how one uses the API stuff you built? My XBee manual has several API Frames defined in it which aren't in your object. Presumably I could add any additional frames I need to the object you have on the OBEX based on your example. That seems pretty straight forward. What I seem to be missing is how one utilizes the object in an "upper-level" program. Any examples you could share would be great. I feel a bit like Dgswaner must have when he started this: "perhaps this is too simple for a tutorial", nonetheless I'm a little lost.
Thanks,
pgb
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
DGSwaner
"When in doubt, use C4" - Jamie Hyneman, Myth Buster
I tried the AT mode and I got some basic tests done. However, I need the mesh and point-to-multipoint capabilities which I think are only available with the API mode. I have the programming module so changing the firmware isn't a problem.
Maybe Martin has an example or two he can share.
Thanks,
pgb