Lora-net / sx1302_hal

SX1302/SX1303 Hardware Abstraction Layer and Tools (packet forwarder...)
Other
219 stars 271 forks source link

Allow configuring the i2c device at runtime #88

Open dberlin opened 1 year ago

dberlin commented 1 year ago

This patch adds the i2c device to the board configuration, so it can be configured at runtime, rather than just being a static macro.

It defaults to the value of the static macro for compatibility.

smtc-bot commented 1 year ago

Thank you for your inquiry.

Customers are encouraged to submit technical questions via our dedicated support portal at https://semtech.force.com/ldp/ldp_support.

We invite all users to visit the LoRa Developer Portal Forum at https://forum.lora-developers.semtech.com and to join the thriving LoRa development community!

joelguittet commented 1 year ago

Duplicated from my https://github.com/Lora-net/sx1302_hal/pull/63

dberlin commented 1 year ago

It's actually not - yours tries to do a lot more complicated of a thing that involves separating out where various sensors can be accessed, etc.

Mine simply makes i2c configurable.

It is a subset of the functionality of yours, for sure, but not sure that means anything.

joelguittet commented 1 year ago

I agree with you. Hope you will have more chance to get this integrated in the repo. I guess unfortunately Semtech d'ont take public contribution... as indicated by the bot.

dberlin commented 1 year ago

Yes, it seems unfortunate. I did get one accepted over on the loramac project (SX12XX code), so maybe there is hope.

If worst comes to worst, i will just start a version of this project that is a little more flexible/open.