# Wrapper MMIO in C++ is possible?

**URL:** <https://discuss.pynq.io/t/wrapper-mmio-in-c-is-possible/6575>\
**Category:** Support\
**Created:** [January 25, 2024, 7:16pm UTC](https://discuss.pynq.io/t/wrapper-mmio-in-c-is-possible/6575 "2024-01-25T19:16:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Salo\_Moreno](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/salo_moreno/32/5559_2.png) [@Salo\_Moreno](https://discuss.pynq.io/u/Salo_Moreno)\
**Post date:** [January 25, 2024, 7:16pm UTC](https://discuss.pynq.io/t/wrapper-mmio-in-c-is-possible/6575/1 "2024-01-25T19:16:49Z")

</div>

Good afternoon, excuse me, does anyone have an example for wrapping MMIO read and write in C or C++ and then calling it in Python with CFFI, or is this not possible?

---

<div class="post-metadata">

**Author:** ![cathalmccabe](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/cathalmccabe/32/3348_2.png) [@cathalmccabe](https://discuss.pynq.io/u/cathalmccabe)\
**Post date:** [February 13, 2024, 3:38pm UTC](https://discuss.pynq.io/t/wrapper-mmio-in-c-is-possible/6575/2 "2024-02-13T15:38:06Z")

</div>

This is what PYNQ does in a few places with C or C++ code (e.g. peripheral drivers).  
Have a look through the repo for CFFI:  
[https://github.com/search?q=repo%3AXilinx%2FPYNQ%20cffi&type=code](https://github.com/search?q=repo%3AXilinx%2FPYNQ%20cffi&type=code)

Cathal
