@@ -160,11 +160,7 @@ void handleGpioCallback(const struct device *port, struct gpio_callback *cb, uin
160
160
161
161
#ifdef CONFIG_PWM
162
162
163
- #define PWM_DT_SPEC (n,p,i ) PWM_DT_SPEC_GET_BY_IDX(n, i)
164
- #define PWM_PINS (n, p, i ) \
165
- DIGITAL_PIN_GPIOS_FIND_PIN ( \
166
- DT_REG_ADDR (DT_PHANDLE_BY_IDX(DT_PATH(zephyr_user), p, i)), \
167
- DT_PHA_BY_IDX(DT_PATH(zephyr_user), p, i, pin))
163
+ #define PWM_DT_SPEC (n, p, i ) PWM_DT_SPEC_GET_BY_IDX(n, i)
168
164
169
165
const struct pwm_dt_spec arduino_pwm[] =
170
166
{ DT_FOREACH_PROP_ELEM_SEP (DT_PATH (zephyr_user), pwms, PWM_DT_SPEC, (,)) };
@@ -186,12 +182,8 @@ size_t pwm_pin_index(pin_size_t pinNumber) {
186
182
187
183
#ifdef CONFIG_ADC
188
184
189
- #define ADC_DT_SPEC (n,p,i ) ADC_DT_SPEC_GET_BY_IDX(n, i)
190
- #define ADC_PINS (n, p, i ) \
191
- DIGITAL_PIN_GPIOS_FIND_PIN ( \
192
- DT_REG_ADDR (DT_PHANDLE_BY_IDX(DT_PATH(zephyr_user), p, i)), \
193
- DT_PHA_BY_IDX(DT_PATH(zephyr_user), p, i, pin))
194
- #define ADC_CH_CFG (n,p,i ) arduino_adc[i].channel_cfg
185
+ #define ADC_DT_SPEC (n, p, i ) ADC_DT_SPEC_GET_BY_IDX(n, i)
186
+ #define ADC_CH_CFG (n, p, i ) arduino_adc[i].channel_cfg
195
187
196
188
const struct adc_dt_spec arduino_adc[] =
197
189
{ DT_FOREACH_PROP_ELEM_SEP (DT_PATH (zephyr_user), io_channels, ADC_DT_SPEC, (,)) };
0 commit comments