Hello
I have a working custom system based on Petalinux and the ADRV9002 evaluation board. I can control most of the device features (such as changing LO frequencies) through IIO (either through IIO Oscilloscope) or by accessing the IIO files in /sys/.
I would now like to find out about configuring the GPIOs. The ADRV9002 Device Driver customization page includes the following:
GPIO Settings
All the gpios configurations should be done under adi,gpios node as shown in the next example:
adi,gpios { #address-cells = <1>; #size-cells = <0>; gpio@0 { reg = <0>; adi,signal = <2>; adi,polarity = <1>; adi,master = <2>; }; };
I can't work out how to relate this device tree entry to all the options offered by the ADRV9002 API (as detailed in the user guide). For example, say I wanted to configure a specific AGPIO pin for manual control, how would I go about doing this though the device tree? How would I then control this GPIO pin through IIO?
According to the ADRV9001 user guide:
"The API commands adi_adrv9001_gpio_ControlInit_Configure() and adi_adrv9001_gpio_Configure() are used to configure the digital or analog GPIO work modes"
How do I perform the equivalent through IIO? I would like to continue to use IIO as this is working for all the other aspects of the ADRV9002.
According to the wiki, adi,signal defines the function of the GPIO pin (0 to 19). Where can I find the definition of what each of the signal values (0 to 19) mean?
In the ADRV9009 I controlled the GPIOs through the debugfs. I cannot see any GPIO pins in the ADRV9002 debugfs.
Thank you.