Home/Support/Support Forum/Energy Consumption Project with Xbee Pro 804.15.4 : Question about data collision

Energy Consumption Project with Xbee Pro 804.15.4 : Question about data collision

0 votes
Hello everyone !

I'm a student in BTS IRIS ( Information Technology ) and I have to do a project to get my degree in my last year ( 2 years ).

So my project consist to get the electricity and water consumption of each buildings of the school and store it in a database.
Once the informations stored my team-mate will execute SQL query to get the average of energy consumed in the last week, month or year.
The energy consumption will be retrieve and send using Xbee technology.

So here is my problem : I need to send the information using some Xbee Emettor ( much as Xbee, as building -> End Device ) to the Xbee Receptor ( Main Server - > Coordinator ).

The protocol I'll use will be build like this :
Code:
$ENERGY_METER_ID|PHASE1|PHASE2|PHASE3|WATER|OFF-PEAK|FULL-HOUR#

Example : $239239|010|005|002|10.3|0000063|0000080#

Here is the situation like I see it for the future ( But I'm not sure if I'm doing in the right way ! )

xbeediagramme.png

What I want to know is how the data is retrieve from the Coordinator.
In class, I can connect only two Xbee device for the moment, which works fine but I don't really know how the Coordinator will be retrieve the information of two ( And more ) Xbee End Device Emettor at the same time ?

I need to store each information ( in a array ) from the End devices in the Coordinator ( Which will be connected to a simple PC ) like this for example :

$1|010|005|002|10.3|0000063|0000080#
$2|010|005|002|10.3|0000063|0000080#

Because I need to get these informations from another client ( in TCP/IP ) in real-time !

I'm still new ( and lost ! ) about this new technology so sorry if my question is stupid.

I hope my explaination is understandable thought !

Thank you in advance for the help.

( And sorry for my english..)
asked Feb 11, 2012 in IEEE 802.15.4 by rom1415 New to the Community (6 points)

Please log in or register to answer this question.

14 Answers

0 votes
konbanwa,

Please let me know.
you are trying to use the series 1 or trying to use the series 2? .

Although it seems that a star topology will be used if a figure is seen, is it a thing as which this topology may be sufficient? .
answered Feb 11, 2012 by chobichan Community Contributor (100 points)
0 votes
Hello.

Firstly, thank you for the reply :)

I forgot to mention it but I use Serie 1 I think.

Well, I choose this topology because I have one server ( a PC ) where the Xbee is connected. This server will retrieve the data and save it in the database, so the data need to be retrieve by this one.
The others Xbee are located on each building which they'll send energy information to the coordinator.
The things is that, I'll need to connect on the server to get the information in real-time but I don't know to get all the data from the Xbee's emettor and store it in the server as an array or somethings ( So I can get it with TCP/IP ).
Well, I can retrieve information and store in an array but how do I know when an Xbee emettor is offline ?

It's a bit complicated but if you have another ( simple ) solution I'll take it for sure :-)
answered Feb 11, 2012 by rom1415 New to the Community (6 points)
0 votes
Here is how I see things but maybe it's not possible ?

xbeeexplication.png

Edit : The energy and water meters are not connected directly with the Xbee for sure there is a FEZ Rhino board in the middle to get the data from the meters :) This is just to simplify the system.
answered Feb 11, 2012 by rom1415 New to the Community (6 points)
0 votes
konbanwa,
Quote:
Well, I choose this topology because I have one server ( a PC ) where the Xbee is connected. This server will retrieve the data and save it in the database, so the data need to be retrieve by this one.
The others Xbee are located on each building which they'll send energy information to the coordinator.

I can consider the demand so that topology (Peer to Peer) of the standard of the series 1 may also be made.
And a end device goes into sleep and is a message sometimes sent to a end device by the coordinator? .

If it uses by standard Peer to Peer topology further when using series 1, common ID and CH will be set up.

Moreover, a server sets it as MY=1 as an example, and it sets the data side as MY=2 and MY=3.

If data is sent to MY=1 from MY=2 and MY=3, data will be outputted from DOUT of MY=1.

Probably, it will be better for the server side to use API mode, in order to distinguish two addressees.
answered Feb 11, 2012 by chobichan Community Contributor (100 points)
0 votes
The XBee take care of collissions (to some extent) internally. If you use the API mode, then you can detect if the message was not sent.

I think the greater question is, "Can every building in your school-campus even 'see' the coordinator?" 802.15.4 is a hub-design. Suppose you have 4 buildings, and only 2 of the 3 out-buildings have an RF line-of-sight path back to the 'coordinator'? In that case, do you pack up and go home? Fail your project?

I think you would be far better to use either the Zigbee (as router) or DigiMesh Xbee. These would allow the lost-building to use one of the other 2 buildings to 'route' or mesh the messages back to your coordinator.

As for addressing, one usually uses the MAC address of the sender as the key.
answered Feb 11, 2012 by lynnl Veteran of the Digi Community (1,047 points)
0 votes
Quote:
konbanwa,
Quote:
Well, I choose this topology because I have one server ( a PC ) where the Xbee is connected. This server will retrieve the data and save it in the database, so the data need to be retrieve by this one.
The others Xbee are located on each building which they'll send energy information to the coordinator.

I can consider the demand so that topology (Peer to Peer) of the standard of the series 1 may also be made.
And a end device goes into sleep and is a message sometimes sent to a end device by the coordinator? .

Mhh actually I don't know what to do yet.
I have too options :

- Each end device send data every seconds ( or more ) to the coordinator
- The coordinator send a command ( example : "?" ) every seconds ( or more ) to "ask" the end devices to send the information. I think this will be realizable with the broadcast adress from the coordinator. The advantdage of this method is that I could modify the frequency of sending from the coordinator and not modify every end device.

Quote:
The XBee take care of collissions (to some extent) internally. If you use the API mode, then you can detect if the message was not sent.

I think the greater question is, "Can every building in your school-campus even 'see' the coordinator?" 802.15.4 is a hub-design. Suppose you have 4 buildings, and only 2 of the 3 out-buildings have an RF line-of-sight path back to the 'coordinator'? In that case, do you pack up and go home? Fail your project?

I think you would be far better to use either the Zigbee (as router) or DigiMesh Xbee. These would allow the lost-building to use one of the other 2 buildings to 'route' or mesh the messages back to your coordinator.

As for addressing, one usually uses the MAC address of the sender as the key.


I think you're totally right about the routing system but I don't know if I can configure my Xbee Pro like that, I try to configure it with X-CTU but I only saw Coordinator Enable (CE) which have two options ( Coordinator or end device I think ) but I really don't know how to configure it as a router or as a DigiMesh Xbee.


Thank you for you propositions ;-)
answered Feb 11, 2012 by rom1415 New to the Community (6 points)
0 votes
ohayougozaimasu,
Quote:
I think you're totally right about the routing system but I don't know if I can configure my Xbee Pro like that, I try to configure it with X-CTU but I only saw Coordinator Enable (CE) which have two options ( Coordinator or end device I think ) but I really don't know how to configure it as a router or as a DigiMesh Xbee.

DigiMesh is realizable by not change of configurations but rewriting of another firmware.
answered Feb 12, 2012 by chobichan Community Contributor (100 points)
0 votes
and more informations in this page.

http://www.digi.com/support/kbase/kbaseresultdetl?id=3150
answered Feb 12, 2012 by chobichan Community Contributor (100 points)
0 votes
Thank you for the information chobichan, so if I want to make a DigiMesh network I need to update the firmware to XB24-DM or XBP24-DM ?

I'll try this tomorrow when I'll be able to work with the Xbee's device :)

Thank you for the help guys ! !
answered Feb 12, 2012 by rom1415 New to the Community (6 points)
0 votes
konbanwa,

XBP24-DM
answered Feb 12, 2012 by chobichan Community Contributor (100 points)
...