-
Notifications
You must be signed in to change notification settings - Fork 8.2k
drivers: adc: Add support for RaspberryPi Pico ADC #45363
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
7a2bc7a to
a61bbd1
Compare
|
@soburi The STM32 series has a similar temperature sensor, implemented in |
|
You can keep it in this PR if you want, just do it in a separate commit if you do. The point is to have a compatible and a "sensor" implementation. |
|
Hi, @yonsch,
I removed the temperature-related code from this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this here? It looks unnecessary to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed it. It's my carelessness.
I implemented it without interrupts firstly,
and I forgot to remove it after the implementation changed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
|
@soburi thank you for your update. Do you think you can also rebase this PR? There is a conflict in rpi_pico.dts. |
|
Hi, @anangl @mbolivar-nordic @galak @stephanosio @carlescufi @nashif I would like to proceed with this PR (and, also below), so could you give a review this PR if possible? zephyrproject-rtos/hal_rpi_pico#2 (comment) As you can see in the conversation log, the points pointed out in the review have solved. I would like to put it into the next release if possible. |
nordicjm
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, will approve once pull link is replaced with commit ID.
Future update to support the 5th channel (temperature) would be ideal
|
@soburi zephyrproject-rtos/hal_rpi_pico#2 is merged now. |
adc_read() that defined in adc.h of PICO-SDK conflicts with zephyr's ADC API. Rename it to avoid compile errors. Signed-off-by: TOKITA Hiroshi <[email protected]>
Enable ADC driver. Add the path of the ADC driver header into include paths. Signed-off-by: TOKITA Hiroshi <[email protected]>
Define RaspberryPi Pico ADC. The ADC has internally connected temperature sensor, Add property to enable this. The ADC has a single VREF. VCC usually connects to it, but it may not be in a case. Add property to make configurable it. Signed-off-by: TOKITA Hiroshi <[email protected]>
Introducing RaspberryPi Pico ADC driver. This driver was created with reference to the adc_emul implementation. Signed-off-by: TOKITA Hiroshi <[email protected]>
Make ADC available. Also enable internal temperature sensor. Signed-off-by: TOKITA Hiroshi <[email protected]>
Add support for rpi_pico board to adc_api test. At this time, twister couldn't with rpi_pico board, Test it built with west and checked the console output. Signed-off-by: TOKITA Hiroshi <[email protected]>
Add support for rpi_pico board to adc driver sample. Signed-off-by: TOKITA Hiroshi <[email protected]>
Add ADC shell support for RaspberryPi Pico. Signed-off-by: TOKITA Hiroshi <[email protected]>
cb9a7d2 to
38c2ba4
Compare
|
@soburi Are you still planning to work on the temperature sensor? |
|
@yonsch |
|
Thanks @soburi , I didn't start working on it. If you want to finish it yourself go ahead, it's not urgent. If it's too much trouble I can do it no problem. |
Add myself as codeowner of previously committed driver. - zephyrproject-rtos#45363 Signed-off-by: TOKITA Hiroshi <[email protected]>
Add myself as codeowner of previously committed driver. - #45363 Signed-off-by: TOKITA Hiroshi <[email protected]>
Add myself as codeowner of previously committed driver. - zephyrproject-rtos#45363 Signed-off-by: TOKITA Hiroshi <[email protected]>
Adding RaspberryPi Pico ADC driver.
The ADC has internally connected temperature sensor,
Add property to enable this.
The ADC has a single VREF. VCC usually connects to it,
but it may not be in a case.
Add property to make configurable it.
This driver was created with reference to the adc_emul implementation.
This PR testing with tests/drivers/adc/adc_api.
At this time, twister couldn't with rpi_pico board.
samles/driver/adc is also worked.