2-way communication w/ Series1 - python

Hello,
I’ve been collecting data from xbee s1 modules for a while now and feel I’ve got this down. My setup uses python-xbee and serial libs to poll the various radios (a dozen or so) from a central radio through the serial port. Typically I’m using D0-D3 as analog inputs for different sensor types, collecting the data, averaging it over 5 minutes, then sending the data to web services like pachube.com.

The question now, how to control actuators with this same basic configuration.

I’ve gone through the various libraries and I’m just trying to turn on an LED on a DIO 1 pin as a proof of concept.

Ideally I would be able to use the MY address to direct a value to the specific xbee radio and turn a pin to high or low. (eventually to be able to send PWM for variable settings)

Alternatively, I suppose I could send a text string on the serial port and have an arduino receive that string that translates to some action (turn on/off LED).

I’m pretty sure this kind of thing is possible because I’ve looked at the Digi Smart Plug and it can send out electric current and light sensor readings and also respond to an input that sets a relay. I just don’t understand the collection of settings and python code to make it happen.

I’ve tried using commands like:

xbee.remote_at(dest_addr='\x00\x06',command='D1',parameter='\x05')

to try to turn pin DIO 1 high on a xbee series 1 with MY code set to 6… but to no avail.

Can someone please lead me to some meaningful documentation or sample code that shows how this might work?

Thanks in advance for any tips,
Chris.

Really? Nobody? Is what I’m doing not possible, or too difficult for XBee radios?

I am glad to read this topic. Thank you.



RS GoldCheap WOW Gold

Great… looks like the thread I started got spammed. Cheap Gold?

I don’t know what library you are using, but will need to ‘Apply’ the setting as well. If you use At mode, that means (I think) sending the AC command, With API mode there is a bit one sets in the remote AT frame

In the Python library, is the destination address the 16-bit network address, or the 64-bit MAC address of the XBee module? Are you sure it’s using the correct address to send the command? You could try sending a remote “FR” command and see if the remote XBee receives it and restarts.