Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions samples/drivers/adc/adc_stream/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@ sample:
name: ADC stream sample
common:
tags: adc
depends_on: adc
filter: dt_alias_exists("adc0") and dt_node_has_prop("/zephyr,user","io-channels")
harness: console
harness_config:
type: one_line
regex:
- "^ADC data for [^@]+@\\d+ \\([0-9.]+\\) \\d+n$"
tests:
sample.driver.adc_stream:
Comment thread
natto1784 marked this conversation as resolved.
filter: dt_alias_exists("adc0")
sample.driver.adc_stream: {}
sample.driver.adc_stream.ad4052-stream:
extra_args:
- SHIELD=eval_ad4052_ardz
Expand Down
2 changes: 0 additions & 2 deletions samples/drivers/adc/adc_stream/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@

#define SAMPLE_DT_SPEC_AND_COMMA(node_id, prop, idx) ADC_DT_SPEC_GET_BY_IDX(node_id, idx),

#if DT_NODE_HAS_PROP(DT_PATH(zephyr_user), io_channels)
/* Data of ADC io-channels specified in devicetree. */
static const struct adc_dt_spec adc_channels[] = {
DT_FOREACH_PROP_ELEM(DT_PATH(zephyr_user), io_channels, SAMPLE_DT_SPEC_AND_COMMA)
};
static const int adc_channels_count = ARRAY_SIZE(adc_channels);
#endif

static void init_adc(void)
{
Expand Down