Closed AhmedM-Dev closed 1 year ago
@AhmedM-Dev I checked the MicroPython spi.readinto function and I think it can be implemented by the spi.transfer() function of Kaluma.
Both function read and write the data through SPI. Here's the difference.
In this example, the self.buf = bytearray(1), that means it's one byte buffer, so spi.readinfo send and receive only one byte. Here's the code for Kaluma
Thanks.
@communix Thank you so much for your well explained reply. I will try to implement the nRF24L01 driver based on the MicroPython driver using your suggestion and send you feedback as soon as possible.
Thanks.
I am trying to clone the MicroPython NRF24L01 (https://github.com/iottrends/NRF24l01_MicroPython/blob/main/nrf24l01.py) driver using KalumaJS.
My issue is that I could not replicate the exact behavior of spi.readinto using KalumaJS SPI interface.
Can someone guide me how to do it ?