simmsb / tyrfing

Firmware for flashlights using loneoceans attiny1616 drivers
6 stars 0 forks source link

ADC included in firmware but not in HAL #1

Open DerZade opened 1 month ago

DerZade commented 1 month ago

Looking at your project it seems like there is an ADC implementation in your firmware, but not directly in your HAL. What is the reasoning behind this? Is there any chance the HAL will directly support ADC? 🙃

Thanks a lot for the great lib and reference project :)

simmsb commented 3 weeks ago

Hey, I can't remember the reasoning exactly. At some point I was trying not to use forked dependencies, and so I added an ADC implementation in the firmware instead of upstream. Then later I hit a point where I had to modify some dependencies (and decided to vendor them in the repository as to minimise testing time), and so I have this mix of peripheral implementations in the firmware (ADC, and the async gpio implementation) and the HAL.

Some of my changes can easily be upstreamed (the ADC implementation, and potentially also the async implementations), but I've also applied quite a few changes that potentially only minimise code size for my project, which I'm not sure would be easily upstreamed.