If you want to set both pin 0 and pin 1 to high, the third parameter should
be 0x0003.

In this case:
If your last parameter is 0xFFFF, both pin 0 and pin 1 will be set to high,
while all other pins will be set to low.
However, if your last parameter is 0x0003, only pin 0 and pin 1 will change
to high, and the values of the other pins will remain unchanged.


hui cj <cjh416593...@gmail.com> 于2024年11月21日周四 15:24写道:

> In your last example, it should be
> usrp->set_gpio_attr("FP0", "OUT",  0xFFF  , 0xFFF);
> The third parameter should also be a mask.
>
>
> Will Haftel via USRP-users <usrp-users@lists.ettus.com> 于2024年11月21日周四
> 05:38写道:
>
>> This doesn’t quite work for me - in the last example I gave, I try using
>> 1 mask to set all of the bits high but still only pin 0 is set. I am able
>> to control all of the pins using ATR, but am not sure why the manual api
>> isn’t giving me the same results.
>> _______________________________________________
>> USRP-users mailing list -- usrp-users@lists.ettus.com
>> To unsubscribe send an email to usrp-users-le...@lists.ettus.com
>>
>
_______________________________________________
USRP-users mailing list -- usrp-users@lists.ettus.com
To unsubscribe send an email to usrp-users-le...@lists.ettus.com

Reply via email to