I'm working with the FMCOMMS5 board connected to a ZC706. I'm currently trying to get a feel for what will be involved if I wanted to customize the FPGA by inserting my own IP into the pre-existing ADL HDL code. I don't want to use the HDL Coder from MathWorks at this time, although I definitely see the benefit of such a tool.
I've found a couple of resources so far (Mainly this How Do I insert custom IP into the AD-FMCOMMS2-EBZ Linux reference design), but one of my last major hold ups is how to integrate with Libiio. I would like to add a new function to the channel that is toggleable/custom from the user. As far as I can see, the best way to do this would be to add a new channel attribute (or channel) into the linux /sys/bus/iio/devices/iio:deviceX directory. This device tree is (if I'm understanding things correctly) auto generated from the FPGA code when I export it to the SDK. So my question is, how do I go about implementing an FPGA change that will be accessible by Libiio?
For a basic example, let's say for some reason I wanted to offset the data coming out of channel Y by X amount. And I wanted to do that by writing X to a new channel attribute called "custom_offset_amount". How would I make sure there is an attribute in Libiio that I could write too?
Thanks in advance,