Zigbee Tranceiver and atmel AVR Controller

Go To Last Post
36 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Folks,
I have used TI's CC2530 Zigbee SOC with ZStack on it. But i want to use Different Host microcontroller which will communicate to zigbee transceiver for sending and receiving data. Then i looked this Xbee. So i planned to buy Atmel Zigbee Transceiver. Before that i need some clarification.
As per my understanding we need to communicate host controller and Xbee through UART. We need to send that through AT commands or API. But i did't see in the manual how Xbee receive data and sends to host microcontroller. So my questions are.

1. Which Zigbee stack should use for AVR and where i will get that Stack?

2.Will Atmel Provide all the feature like TI provides like child aging, stack itself form Mesh network to router and star to End device.

Please help me to start in this platform

Regards
Allen

Last Edited: Fri. Oct 16, 2015 - 01:46 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I don't understand what Xbee is doing here. It is not an Atmel product, it is a standalone module, with its own API. This API does not give you a full access to the stack, they don't even emphasize that it is ZigBee a lot.

1. There is only one ZigBee stack for AVR, it is called BitCloud, and it can be downloaded from atmel.com. It only works with Atmel transceivers.
2. Yes, BitCloud is a fully-featured ZigBee stack.

Note that for proprietary application Atmel recommends Lightweight Mesh stack.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

OP: be sure you know how the Zigbee network layer fits into a protocol stack based on IEEE 802.15.4. Zigbee is not a synonym for 802.15.4. Nor is TCP/IP a synonym for Ethernet which is IEEE 802.3.

Zigbee has little applicability to student/hobbyist projects that don't need the sophistication and complexity of the Zigbee network routing (mesh) protocols.

This applies to all vendors' 802.15.4 products. The XBee Series 2 is Zigbee; Series 1 is not. The two series use different chipsets (Freescale and Ember), and neither have any Atmel content.

TI's CC2530 is available with and without Zigbee too.

Same for Atmel.

For a non-Zigbee mesh routing layer, if you must, Atmel has their lightweight mesh, and Digi has Digimesh. I don't think T.I. has an equivalent.

There are a couple of other vendors in the frey, not mentioned here.

These differ in co-processor interface: SPI or UART is most common.

For some apps, no co-processor is needed as the D/A or A/D and reporting/control is within the proprietary firmware (sans Zigbee's complex profiles).

I think you have to mostly do your own homework and study to choose what suits your needs best.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I think protocol is not what we are more interested in.. The approach should be like, we discuss the application and choose an appropriate protocol for that... If you have 2 nodes and want to communicate between them, the bitcloud doesnt make much sense for that...

If there are going to be 1000's of nodes... then it makes sense.. so people here can give you a better suggestion, if you can tell us what the end application is

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Using zigbee (vs. simple 802.15.4 messages) for two or a few nodes, especially if they are immobile, is a complex overkill. Like using a satellite to talk next door.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks for suggestions,
My Application may have two End device with two or more router. One End device Contains different sensors. And other will send a image file. I know zigbee has low data rate, but i am sending packet by packet with appropriate delay between each packet.
So if i use atmel product, i mean an AVR controller and any atmel transceiver.
1. Which stack i should use. I am confuse with bitcloud and lightweight mesh. What is difference between these two.
2.Since i am new to atmel world. Can you tell me which atmel avr controller i should use(should have 2 or more UARTs) and which zigbee transceiver.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1. Which stack i should use. I am confuse with bitcloud and lightweight mesh. What is difference between these two.
Use LwMesh, it is specifically designed for simple proprietary applications.

BitCloud implements ZigBee PRO protocol.

You might be confused because of the name "ZigBee transceiver". There is no such thing. All those transceivers are IEEE 802.15.4. Both LwMesh and ZigBee are built on top of this standard.

allen_poper wrote:
2.Since i am new to atmel world. Can you tell me which atmel avr controller i should use(should have 2 or more UARTs) and which zigbee transceiver.
Almost any will work. If you want to make your life easier, then use something like ATmega256RFR2 - two in one MCU and TRX.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Mr.Alex,
1. But i need zigbee pro only, because it has some additional features like many to routing, stochastic addressing. I have already used zigbee pro stack provided by TI.What is your view on this. Is light weight stack
2. I want a microcontroller on which the zigbee(bitcloud or lwmess)stack should run if i connect zigbee transceiver for data transmisssion.
And that controller should capable to run barometric application(without zigbee stack or Osal independant) if i connect gsm for data transmisssion instead of zigbee transceiver.

overall i can tell is i am using host controller and zigbee tranceiver in one application and in other host controller and gsm in other application. So i don't need SOC which has controller and zigbee transceiver integrated.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Mr.Alex,
1. But i need zigbee pro only, because it has some additional features like many to routing, stochastic addressing. I have already used zigbee pro stack provided by TI.What is your view on this. Is light weight stack will support for more than 100 nodes.
2. I want a microcontroller on which the zigbee(bitcloud or lwmess)stack should run if i connect zigbee transceiver for data transmisssion.
And that controller should capable to run barometric application(without zigbee stack or Osal independant) if i connect gsm for data transmisssion instead of zigbee transceiver.

overall i can tell is i am using host controller and zigbee tranceiver in one application and in other host controller and gsm in other application. So i don't need SOC which has controller and zigbee transceiver integrated.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If you sure that you need ZigBee, then go with BitCloud.

For the list of supported microcontroller go to atmel.com. I'm on the phone, so can't give you a direct link.

But I think that BitCloud support will be limited to single chip solutions soon.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

1.What do you mean BitCloud support will be limited soon. You mean software help?

2. My End application is to monitor some sensor and send to user. This can be done in two method according to place where the device is fixed(home or industries). The host controller should remain same but Transceiver may get vary.

Method 1: In this Method i will use just simple C program to monitor sensor and send those value to uart(GSM) through AT commands in serial. Host controller should give flexibility to run simple c program on it as atmel 8051 does, like

->Add header file for 8051.

->In a while(1) loop, make gpio pin as output where the sensor in connected(can be polling or interrupt).

->Send sensor value to gsm using AT commands.

In this method there is no role of ZAP or Zigbee stack related things.

Method 2: In this the Zigbee stack will run on the host controller and zigbee transceiver used to send and receive data.

Can you suggest this type of host controller, where i can run Bitcloud on it if connect zigbee transceiver and it also capable to run barametic application on it, if i connect GSM.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1.What do you mean BitCloud support will be limited soon. You mean software help?
No, there is not going to be a new releases for many currently supported platforms.

allen_poper wrote:
Can you suggest this type of host controller, where i can run Bitcloud on it if connect zigbee transceiver and it also capable to run barametic application on it, if i connect GSM.
You did not list anything resource intensive, any MCU will work, just pick the one you like.

Again, the better approach is to select any MCU you like and have it run your application. And put ZigBee stuff inside a megaRF, so it looks just like your GSM modem. You don't run GSM stack on your main MCU, right? Why run ZigBee on the main MCU in this case?

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Because my intention is to make host controller same. only transceiver should vary. The main thing i didn't use SOC with RF transceiver is cost. As a designer that also a main concern. If i don't want to use Zigbee, There will soc with Rf and GSM so cost of that product will increase.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Because my intention is to make host controller same. only transceiver should vary. The main thing i didn't use SOC with RF transceiver is cost. As a designer that also a main concern. If i don't want to use Zigbee, There will soc with Rf and GSM so cost of that product will increase.
That's why i asked suggestion from expert like you. Tell me one host controller where i will connect Zigbee tranceiver(AT86RF233). Like in TI there is controller called MSP430 or TIVA C,on which ZStack will run and send data through Zigbee transceiver(CC2520).That controller also is capable to run barometric application.So i request you to suggest me on this.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

AT86RF233 at the moment is not supported with ZigBee stack on any platform.

I don't want to recommend anything except for the SoC, because I'm not completely sure what platforms will make it to the next release. The only thing I have some confidence about is an SoC.

List of currently supported platforms can be found here

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

OP - suggest that you organize your requirements - functional, cost, power consumption, size, percent COTS module vs. chip level, Regulatory approvals of wireless, sourcing, etc.

IEEE 802.15.4 is mentioned in your same sentence as GSM/GPRS. the former is short range WPAN and the latter is cellular. Apples/oranges as they say.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Mr.alexru,
1. I have seen the link, which you have given. I think there is a Bit-Cloud for AVR 32-bit. That is also a SOC?
2.Which Zigbee transceiver is used now. Because i have seen that in atmel website only.http://www.atmel.in/products/wir....

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1. I have seen the link, which you have given. I think there is a Bit-Cloud for AVR 32-bit. That is also a SOC?
No, that is a 32-bit version of AVR. Support in BitCloud for which is being discontinued.

allen_poper wrote:
2.Which Zigbee transceiver is used now.
Transceivers are IEEE 802.15.4, only ZigBee. Different stacks support different transceivers, but if you want ZigBee, then ATmega256RFR2 is your only option.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

If i use Lightweight mesh stack, then can i use different atmel's host microcontroller and wireless transceiver.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes. There is a range of MCUs already supported in the stack. Porting to a new one is easy as well.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Mr.Alexru,
I have some more points need to be clarify,

1. Is there any ARM Core SOC which supports Zigbee Pro(Bitcloud).

2. I have seen the Light Weight Mesh doesn't have Coordinator, router, End device. Then how the Device will send the data packet in a large network.

3. Can i use Light Weight Mesh stack on any Atmel 32-bit microcontroller and transceiver like AT86RF231, 32, 33.

4. ATmega256RFR2 is AVR. If i use this, it has prolonged? I mean, i will get support min 4-5 yrs in market(Availability and stack support).

5.There is AT32UC3A0512 and AT32UC3A0512AU 32-bit AVR. But you told 32-bit AVR are discontinued for Zigbee. You mean no more avail in market?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1. Is there any ARM Core SOC which supports Zigbee Pro(Bitcloud).
No, there is not.

allen_poper wrote:
2. I have seen the Light Weight Mesh doesn't have Coordinator, router, End device. Then how the Device will send the data packet in a large network.
You don't need all this to send data. You send data to a specific address, not to a device type. Size of the network does not matter in this case.

allen_poper wrote:
3. Can i use Light Weight Mesh stack on any Atmel 32-bit microcontroller and transceiver like AT86RF231, 32, 33.
Yes, you can. But in case you select an MCU that is not supported out of the box, you will have to create a port. Also by "Atmel 32-bit microcontroller" I'm understanding ARM-based devices, not AVR32-based.

allen_poper wrote:
4. ATmega256RFR2 is AVR. If i use this, it has prolonged? I mean, i will get support min 4-5 yrs in market(Availability and stack support).
I can't answer this question, I'm not even close to making decisions like this.

allen_poper wrote:
5.There is AT32UC3A0512 and AT32UC3A0512AU 32-bit AVR. But you told 32-bit AVR are discontinued for Zigbee. You mean no more avail in market?
MCUs are available, but ZigBee stack for them is not.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You don't need all this to send data. You send data to a specific address, not to a device type. Size of the network does not matter in this case.

So, what would be the distance range between two nodes? example zigbee can communicate 60 meter. So router needed for zigbee network. what will be in Lightweight Mesh.

So, which 32-bit Atmel microcontroller(ARM Core). which support lightweight Mesh and which transceiver used for tht.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
So, what would be the distance range between two nodes? example zigbee can communicate 60 meter. So router needed for zigbee network. what will be in Lightweight Mesh.
On the same hardware ZigBee has the same distance as LwMesh for one hop. It can be much greater than 60 m. But in any case, all nodes in LwMesh can route the data.

allen_poper wrote:
So, which 32-bit Atmel microcontroller(ARM Core). which support lightweight Mesh and which transceiver used for tht.
For example SAMD20 + AT86RF231 or AT86RF233.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks Mr.Alexru,
After your all suggestions, i came to know that, i will get much stack support if i use Lightweight Mesh instead of Bitcloud(Correct me if am wrong). Before entering in to application, i need to know some points.

1. If i am having 4 nodes, node 1, 2, 3 and node 4. The main communication should be between node 1 and node 4. Due to not in radio coverage i have brought node 2, node 3 and node 4 in the network. If i send a data from node 2 to the address of node 1. LightWeight Mesh will have capability to route the data. Can you tell how or give me any link where i will get this information.

2.How LightWeight Mesh is different from zigbee.

3. I want Arm core with cortex M3. So can i use ATSAM3U4C + AT86RF231 or AT86RF233.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1. If i am having 4 nodes, node 1, 2, 3 and node 4. The main communication should be between node 1 and node 4. Due to not in radio coverage i have brought node 2, node 3 and node 4 in the network. If i send a data from node 2 to the address of node 1. LightWeight Mesh will have capability to route the data. Can you tell how or give me any link where i will get this information.
Documentation supplied with the SDK describes routing in a very detailed way. But it all boils down to the following: you don't need to worry about anything, just enter the destination address and stack will figure out how to deliver the data.

allen_poper wrote:
2.How LightWeight Mesh is different from zigbee.
The same way as BMW is different from a tractor. They are just different and designed to fulfill different needs.

allen_poper wrote:
3. I want Arm core with cortex M3. So can i use ATSAM3U4C + AT86RF231 or AT86RF233.
If you do the port yourself. It is not hard, but obviously depends on your general experience with C and microcontrollers.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In what way porting effort is needed? I didn't get. Can you specify clearly. I need to change the Lightweight stack? if Yes, then can you suggest me, how?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You don't need to change the core stack, but you need to tell it how to talk to the external radio. This is where HAL (Hardware Abstraction Level) comes in. You will have to create a HAL for your platform. To estimate amount of code that has to be created, download the SDK and have a look at the existing HALs.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

1.Only HAL drivers only need to change if i use ATSAM3U4C + AT86RF231 or any other effort is required.

2. I have gone through the development guide of LW Mesh Stack. In that document, the application service is not in scope. I want to know how OTA upgrade will be done in LW Mesh.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

allen_poper wrote:
1.Only HAL drivers only need to change if i use ATSAM3U4C + AT86RF231 or any other effort is required.
Yes, only HAL has to be changed. The rest of it is platform-independent.

allen_poper wrote:
2. I have gone through the development guide of LW Mesh Stack. In that document, the application service is not in scope. I want to know how OTA upgrade will be done in LW Mesh.
It is entirely up to you. There is a sample implementation in the SDK, but it is implemented only for ATmega, because it relies on the bootloader.

I recommend implementing your own implementation that works for your specific application based on the sample implementation.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

2. Implementing OTA is much complex. Is there any document to implement from the scratch? SAMD20 also doesn't support OTA?

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

OTA is not that complex. It is just transferring the data. How exactly you do the transfer depends on the application a lot. For example sleeping devices prevent you from pushing the image from the server directly to the devices, you need to negotiate when device is awake, etc.

The tricky part is interacting with the hardware - storing image in the temporary storage (usually second half of the embedded flash or external flash chip), switching from the stored image.

OTA itself, even the way it is implemented right now, is platform independent and will work on any MCU, but low level routines are only implemented for ATmega.

Implementing lower-level things yourself will be a requirement for pretty much any stack, because it all very much depends on the hardware used.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Will ATSAM3U4C or SAMd20 support SD card interface.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

In SPI mode, any MCU with SPI peripheral will, but that has nothing to do with wireless.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes that is nothing to do with wireless. But i want to maintain some log of Sensor Data. That's why i planned to store in SD Card for some purpose.
Is file operation is possible in SAMd20 or any thin kernal that i can port in SAMd20

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

There are a lot of examples of how to work with SD cards on microcontrollers.

If you also want this card to be readable by regular computers, then you will need something like FatFs. Again, plenty of descriptions on how to work with FatFs on the web.

SAMD20 is a modern microcontroller it is capable of doing any reasonable task. Whether you can do it or not, I can not say, it very much depends on your skills with microcontrollers and using third-party libraries.

NOTE: I no longer actively read this forum. Please ask your question on www.eevblog.com/forum if you want my answer.