adafruit / Adafruit_CircuitPython_Register

Python data descriptor classes to represent hardware registers on I2C devices.
MIT License
47 stars 22 forks source link

Add SPI bit(s) support #54

Open jerryneedell opened 1 month ago

jerryneedell commented 1 month ago

Add RWBit/ROBit and RWBits/ROBits for SPI devices. I am planning to use this in the Adafruit_CurcuitPython_RFM library for RFM69/RFM9x boards.

Is there any need for the other classes. (Struct/Struct_Array) or the BCD clock support? I don't need them for the RFM library.

tannewt commented 1 month ago

I'd just start with what you need! We can always add more later.

FoamyGuy commented 1 month ago

At one point in time I think there was some discussion around this idea and at that time a seperate library / repo was created for it https://github.com/adafruit/Adafruit_CircuitPython_Register_SPI

I'm not certain of the state of that implementation but it may be worth doing any additional work over in that repo instead of here. Or if there is now a feeling that it'd be better combined maybe the Register_SPI one should get archived?

jerryneedell commented 1 month ago

At one point in time I think there was some discussion around this idea and at that time a seperate library / repo was created for it https://github.com/adafruit/Adafruit_CircuitPython_Register_SPI

I'm not certain of the state of that implementation but it may be worth doing any additional work over in that repo instead of here. Or if there is now a feeling that it'd be better combined maybe the Register_SPI one should get archived?

Wow -- I had totally missed that -- I'w ill see how it works and hopefully understand what I am doing wrong!