![]() ![]() Uint8_t read(void *inbuf, uint8_t maxlen) // Read contents of RX buffer up to 'maxlen' bytes, return final length. Uint8_t read(void *inbuf) // Read contents of RX buffer, return length * (true always if autoACK disabled or 250Kbps rate used) Void end() // Shut it off, clear the library's stateīoolean available() // Check if incoming data is ready to be readīoolean write(void *buf, uint8_t len) /* Send packet, return true/false for autoACK Void begin(uint32_t datarate, uint8_t channel) // Specify bitrate & channel Void begin(uint32_t datarate) // Specify bitrate ![]() Nrf24(uint8_t cePin, uint8_t csnPin, uint8_t irqPin) I want to know what some of you guys think should go in here.įor now, here's an example of my "Nrf24.h" class definition (public's only, I haven't drafted the private's and probably won't until I really start writing the code): To that end, I'd like some feedback on the API choices I've made. I'm rewriting it from scratch, trying to make it simpler & feel more like a native C++ energia lib.Įdit: This has been written and the latest version is up on Github. So I'm a little new to Energia, but since I wrote a library for the nRF24L01+ digital transceivers for native C-based apps I figured it'd be a great idea to port this to Energia.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |