vsergeev / python-periphery

A pure Python 2/3 library for peripheral I/O (GPIO, LED, PWM, SPI, I2C, MMIO, Serial) in Linux.
MIT License
519 stars 139 forks source link

[request] MicroPython support #66

Open biemster opened 9 months ago

biemster commented 9 months ago

For resource constrained devices, who often run OpenWrt which has MicroPython in its repo, this package would make a lot of sense since for example I2C and SPI are used a lot on those.

I've been trying to get the SPI code working on this, as a drop in replacement for machine.SPI, and need to make a couple adjustments since ctypes is missing a couple types, array has no buffer_info() and stuff like that. Also machine.SPI has several read and write functions, not just transfer.

It would be awesome to see the other peripherals ported as well.