将Button组件从V3.3.1升级到V4.1.2
Is your feature request related to a problem?
大佬们好, 小智项目目前使用的Button组件版本是V3.3.1 espressif/button: "^3.3.1" , 该版本GPIO Button没啥问题,ADC Button有较大缺陷,默认使用 ADC_UNIT_1 ,无法使用ADC_UNIT_2,即使在代码中改了也没用。在最新的版本 V4.1.2 中,允许用户选择使用ADC1或者ADC2,适用性更强。
Describe the solution you'd like.
将Button组件由V3.3.1升级到V4.1.2, 不过这两个版本API变化较大,需要修改小智项目中的封装好的Button类, 不过似乎还影响到了 espressif__esp_lvgl_port组件 ,不知道大佬是否有升级该组件的计划,期待大佬更新
Describe alternatives you've considered.
No response
Additional context.
No response
不过似乎还影响到了 espressif__esp_lvgl_port组件
esp_lvgl_port 2.5.0 以上版本已适配 button v4,详见 esp_lvgl_port CHANGELOG
@laride 确实,这样只需要改动项目中的Button就可以了,我先试试
可以,麻烦测试成功了提个PR
@78 先膜拜一下大佬
已经提了,https://github.com/78/xiaozhi-esp32/pull/470
测试没有问题,用了一个粗暴的方式,用户代码现在是兼容V3.x和V4.x Button组件的。