# Difference between the Python Libraries online

**URL:** <https://forums.digi.com/t/difference-between-the-python-libraries-online/20310>\
**Category:** Python\
**Tags:** python-xbee, micropython, xbee3\
**Created:** [March 4, 2019, 10:09am UTC](https://forums.digi.com/t/difference-between-the-python-libraries-online/20310 "2019-03-04T10:09:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tanayrastogi](https://avatars.discourse-cdn.com/v4/letter/t/da6949/32.png) [@tanayrastogi](https://forums.digi.com/u/tanayrastogi)\
**Post date:** [March 4, 2019, 10:09am UTC](https://forums.digi.com/t/difference-between-the-python-libraries-online/20310/1 "2019-03-04T10:09:29Z")

</div>

On some searching online, I found that there are two different libraries for Python for the XBee.

Xbee Python Library  
[https://github.com/digidotcom/python-xbee](https://github.com/digidotcom/python-xbee)  
This seems to be official as it is released by the Digi.

Xbee 2.3.2  
[https://pypi.org/project/XBee/#description](https://pypi.org/project/XBee/#description)  
This is from niolabs

But the Official documentation from the Digi XBee3 shows the examples from Niolab library, not the Digi official python library.  
[https://www.digi.com/resources/documentation/digidocs/90001539/#reference/r\_at\_command\_example\_mp.htm%3FTocPath%3DGet%2520started%2520with%2520MicroPython|MicroPython%2520examples|\_\_\_\_\_4](https://www.digi.com/resources/documentation/digidocs/90001539/#reference/r_at_command_example_mp.htm%3FTocPath%3DGet%2520started%2520with%2520MicroPython%7CMicroPython%2520examples%7C _____ 4)

So now I am confused.  
Which one is correct and I should follow for working.

I have,  
Digi XBee3 ZigBee Mesh Kit, worldwide  
and using Spyder3 for Python Scripting

---

<div class="post-metadata">

**Author:** ![DigiFan23](https://avatars.discourse-cdn.com/v4/letter/d/b38774/32.png) [@DigiFan23](https://forums.digi.com/u/DigiFan23)\
**Post date:** [March 4, 2019, 10:47am UTC](https://forums.digi.com/t/difference-between-the-python-libraries-online/20310/2 "2019-03-04T10:47:06Z")

</div>

I understand the confusion. The documentation you linked is an example which would run on the device itself (using MicroPython) and the libraries you linked are host libraries that would run on a host machine.  
To elaborate, XBee3 devices support running MicroPython code on the device itself. The documentation gives examples on how to interface with the XBee3 rf module with the on-board MicroPython REPL and not from a host machine.  
I assume there is separate documentation for those host libraries.  
Best,  
Matt

---

<div class="post-metadata">

**Author:** ![tanayrastogi](https://avatars.discourse-cdn.com/v4/letter/t/da6949/32.png) [@tanayrastogi](https://forums.digi.com/u/tanayrastogi)\
**Post date:** [March 5, 2019, 4:24pm UTC](https://forums.digi.com/t/difference-between-the-python-libraries-online/20310/3 "2019-03-05T16:24:23Z")

</div>

Ahh, thanks for the reply. Now I understand better.

Yes, there is a documentation for the python library in Micropython.  
[https://pypi.org/project/XBee/#description](https://pypi.org/project/XBee/#description)
