On Fri, 08 May 2026 18:00:23 +0100 Rodrigo Alencar via B4 Relay <[email protected]> wrote:
> From: Rodrigo Alencar <[email protected]> > > Add OSK channel with amplitude envelope control capabilities: > - OSK enable/disable via IIO_CHAN_INFO_ENABLE; > - Amplitude ramp rate control via IIO_CHAN_INFO_SAMP_FREQ; > - Amplitude scale readback via IIO_CHAN_INFO_SCALE (ASF register); > - Automatic OSK step size configurable througth the scale_roc extended > attribute, which allows for selectable step sizes in nano-units: > - 0: no step, means manual mode (NOT pin controlled) > - 61035: 1/2^14 step, automatic mode (pin controlled) > - 122070: 2/2^14 step, automatic mode (pin controlled) > - 244141: 4/2^14 step, automatic mode (pin controlled) > - 488281: 8/2^14 step, automatic mode (pin controlled) > - 1000000000: 1.0 step, manual mode (pin controlled) > > The ASF register is initialized with a default amplitude ramp rate during > device setup to ensure valid readback. > > Signed-off-by: Rodrigo Alencar <[email protected]> > > +#define AD9910_OSK_EXT_INFO(_name, _ident) \ > + AD9910_EXT_INFO_TMPL(_name, _ident, IIO_SEPARATE, osk_attrs) > + > static const struct iio_chan_spec_ext_info ad9910_phy_ext_info[] = { > AD9910_EXT_INFO("powerdown", AD9910_POWERDOWN, IIO_SEPARATE), > { } > @@ -1018,6 +1154,12 @@ static const struct iio_chan_spec_ext_info > ad9910_drg_ramp_ext_info[] = { > { } > }; > > +static const struct iio_chan_spec_ext_info ad9910_osk_ext_info[] = { > + AD9910_OSK_EXT_INFO("scale_roc", AD9910_OSK_AUTO_ROC), > + AD9910_OSK_EXT_INFO("scale_roc_available", AD9910_OSK_AUTO_ROC_AVAIL), same questions about whether we can transform these to voltages and hence not scale (though arguably the main unit of an altvoltage channel is a scale of a 1V peak amplitude sine wave but meh). > + { } > +};

