-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ad77681 pyadi-iio support #433
base: master
Are you sure you want to change the base?
Conversation
86d7bdc
to
3c94451
Compare
adi/ad77681.py
Outdated
from adi.rx_tx import rx | ||
|
||
|
||
class ad77681(rx, context_manager): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use _ to separate part number and derivative: ad7768_1
Please add the emulation context for the new device |
3c94451
to
148360c
Compare
V1.0: Review comments fixes
|
V2.0: Added iio emu context and minor updates to attributes getter/setters
|
@tfcollins Any further review comments? |
cca31eb
to
9be2a37
Compare
@tfcollins I have added the context xml file. Can you please review the changes? |
V3.0: Added xml context file |
adi/ad7768_1.py
Outdated
# All rights reserved. | ||
# | ||
# Redistribution and use in source and binary forms, with or without modification, | ||
# are permitted provided that the following conditions are met: | ||
# - Redistributions of source code must retain the above copyright | ||
# notice, this list of conditions and the following disclaimer. | ||
# - Redistributions in binary form must reproduce the above copyright | ||
# notice, this list of conditions and the following disclaimer in | ||
# the documentation and/or other materials provided with the | ||
# distribution. | ||
# - Neither the name of Analog Devices, Inc. nor the names of its | ||
# contributors may be used to endorse or promote products derived | ||
# from this software without specific prior written permission. | ||
# - The use of this software may or may not infringe the patent rights | ||
# of one or more patent holders. This license does not release you | ||
# from the requirement that you obtain separate licenses from these | ||
# patent holders to use this software. | ||
# - Use of the software either in source or binary form, must be run | ||
# on or directly connected to an Analog Devices Inc. component. | ||
# | ||
# THIS SOFTWARE IS PROVIDED BY ANALOG DEVICES "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, | ||
# INCLUDING, BUT NOT LIMITED TO, NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A | ||
# PARTICULAR PURPOSE ARE DISCLAIMED. | ||
# | ||
# IN NO EVENT SHALL ANALOG DEVICES BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, | ||
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, INTELLECTUAL PROPERTY | ||
# RIGHTS, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR | ||
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, | ||
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF | ||
# THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be removed since you have the SPDX definition at the top
######################################### | ||
@pytest.mark.iio_hardware(hardware) | ||
@pytest.mark.parametrize("classname", [(classname)]) | ||
def test_ad7768_1_rx_data(test_dma_rx, iio_uri, classname, channel): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove the "channel" argument
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I missed out to add channel parameter. This device has 1 channel, so I think we would need channel argument there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test needs fixing
9be2a37
to
27bc393
Compare
Implemented ad7768-1 pyadi-iio device driver class and example script Signed-off-by: MPhalke <[email protected]>
27bc393
to
76e26b5
Compare
This is fixed. There was syntax error with hardware parameter in test_ad7768_1.py file |
V2.0: Review comment fixes and resolved test issues
|
@tfcollins Can we get this PR merged please if everything is okay? |
@tfcollins Do you think changes are good to merge now into main branch? |
Description
Implemented ad7768-1 pyadi-iio device driver class and example script
Fixes # (issue)
Type of change
Please delete options that are not relevant.
How has this been tested?
Tested with ad7768-1 tinyiiod FW with SDP-K1 MCU platform
Test Configuration:
Documentation
NA
Checklist: