# How to use MC2301-E/SP I2C I/O expander with Digi XBee 3 (Python)

**URL:** <https://forums.digi.com/t/how-to-use-mc2301-e-sp-i2c-i-o-expander-with-digi-xbee-3-python/21563>\
**Category:** XBee - Zigbee\
**Tags:** clock, pinout, data, port, gpio\
**Created:** [July 18, 2020, 7:52am UTC](https://forums.digi.com/t/how-to-use-mc2301-e-sp-i2c-i-o-expander-with-digi-xbee-3-python/21563 "2020-07-18T07:52:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![edunn106](https://avatars.discourse-cdn.com/v4/letter/e/dc4da7/32.png) [@edunn106](https://forums.digi.com/u/edunn106)\
**Post date:** [July 18, 2020, 7:52am UTC](https://forums.digi.com/t/how-to-use-mc2301-e-sp-i2c-i-o-expander-with-digi-xbee-3-python/21563/1 "2020-07-18T07:52:57Z")

</div>

Just got some MC23017-E/SP I2C I/O expanders. Hoping to use them with my XBee 3 RF router modules. Am I write to think that I would use Micropython to interface with the I2C I/O expander chips? How would I communicate with the extra “pins” that the expander chip provides?.. Would that be in the data sheet on how to call the pins or something. any system overview would be helpful thanks!

---

<div class="post-metadata">

**Author:** ![mathur](https://avatars.discourse-cdn.com/v4/letter/m/eada6e/32.png) [@mathur](https://forums.digi.com/u/mathur)\
**Post date:** [July 20, 2020, 4:28am UTC](https://forums.digi.com/t/how-to-use-mc2301-e-sp-i2c-i-o-expander-with-digi-xbee-3-python/21563/2 "2020-07-20T04:28:12Z")

</div>

Correct, I2C master operation is supported on Digi XBee3 modules using MicroPython.

Please check below link from MicroPython programming guide for details:  
[https://www.digi.com/resources/documentation/Digidocs/90002219/#reference/r\_class\_i2c.htm](https://www.digi.com/resources/documentation/Digidocs/90002219/#reference/r_class_i2c.htm)

Mathur  
Digi Technical Support

---

<div class="post-metadata">

**Author:** ![edunn106](https://avatars.discourse-cdn.com/v4/letter/e/dc4da7/32.png) [@edunn106](https://forums.digi.com/u/edunn106)\
**Post date:** [July 20, 2020, 5:33am UTC](https://forums.digi.com/t/how-to-use-mc2301-e-sp-i2c-i-o-expander-with-digi-xbee-3-python/21563/3 "2020-07-20T05:33:46Z")

</div>

Ok that makes sense. I guess I’m wondering how you would manipulate a particular pin on the I/O expander that’s connected to the XBee’s I2C bus.  
So the master would see the I/O expander as a slave device on the I2C bus correct?
