iio: frequency: ad9783: fix calibration array values #2608
+2
−3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Description
Run loop in accordance with the method described in section "building the array" of the datasheet[1] rev C. page 26. The loop shall be continued until the seek bit toggles, not until the seek bit goes low.
For the case where a value for SET or HLD is not found that would make the SEEK bit toggle, the value should be set to 15. The loop did not break out until HLD == 16, causing overflowing value to be written to the HLD field[0..3] of register 0x4.
[1] https://www.analog.com/media/en/technical-documentation/data-sheets/AD9780_9781_9783.pdf
PR Type
PR Checklist