zephyrproject-rtos / zephyr

Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
https://docs.zephyrproject.org
Apache License 2.0
10.84k stars 6.6k forks source link

adc: test adc_api: Use a generic board configuration #54530

Open erwango opened 1 year ago

erwango commented 1 year ago

Is your enhancement proposal related to a problem? Please describe. Each time a board is configured with ADC support, a change is required in tests/drivers/adc/adc_api/src/test_adc.c See: https://github.com/zephyrproject-rtos/zephyr/pull/54486/commits/ca66f3652d17bc45218ab63ffbf84811d2ebefd7#diff-ebf7c5c3760fc22a16388b3ff18c241ebaef25d0d6847847f56f302eb000a88d

Describe the solution you'd like A solution that doesn't imply to update test each time a board wth adc support is added upstream.

Given that this test is only testing api, can we consider using a default configuration which would apply to all boards? Obviously, it wouldn't allow to provide accurate adc sampling, but this is not what we are testing here, and I guess this would not fail in CI (test is performed w/o any harness, so sampling accuracy is not tested). It would maybe require a disclaimer to avoid people reporting sampling issues.

samples/drivers/adc would the only example of correct adc configuration for accurate sampling. But I guess one is enough

Describe alternatives you've considered In samples/drivers/adc, this is done using board overlays, this is better but I'm not sure this is really scaling.

zephyrbot commented 8 months ago

Hi @anangl,

This issue, marked as an Enhancement, was opened a while ago and did not get any traction. Please confirm the issue is correctly assigned and re-assign it otherwise.

Please take a moment to review if the issue is still relevant to the project. If it is, please provide feedback and direction on how to move forward. If it is not, has already been addressed, is a duplicate, or is no longer relevant, please close it with a short comment explaining the reason.

@erwango you are also encouraged to help moving this issue forward by providing additional information and confirming this request/issue is still relevant to you.

Thanks!