ad7172: Correct postfilter rates and rejection #166

Open
atse wants to merge 1 commits from atse/thermostat:correct-postfilter-rate into master
Contributor

The AD7172-2 Rev. A datasheet is inconsistent on the 50/60 Hz postfilter rates and rejection figures between the ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS and the FILTER CONFIGURATION REGISTER 0 sections. Use the former section's figures instead.

The latter section is wrong since the 21.25 SPS figure is incorrect, as the output data rate = 1 / (settling time), and 1 / (40 ms) = 25 Hz. This seems to have been corrected in the datasheets for the rest of the AD717x family, which have the same filter.

The AD7172-2 Rev. A datasheet is inconsistent on the 50/60 Hz postfilter rates and rejection figures between the *ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS* and the *FILTER CONFIGURATION REGISTER 0* sections. Use the former section's figures instead. The latter section is wrong since the 21.25 SPS figure is incorrect, as the output data rate = 1 / (settling time), and 1 / (40 ms) = 25 Hz. This seems to have been corrected in the datasheets for the rest of the AD717x family, which have the same filter.
atse added 1 commit 2025-01-27 16:17:01 +08:00
The AD7172-2 Rev. A datasheet is inconsistent on the 50/60 Hz postfilter
rates and rejection figures between the *ENHANCED 50 Hz AND 60 Hz
REJECTION FILTERS* and the *FILTER CONFIGURATION REGISTER 0* sections.
Use the former section's figures instead.

The latter section is wrong since the 21.25 SPS figure is incorrect, as
the output data rate = 1 / (settling time), and 1 / (40 ms) = 25 Hz.
This seems to have been corrected in the datasheets for the rest of the
AD717x family, which have the same filter.
atse force-pushed correct-postfilter-rate from accd634963 to 81112e429b 2025-01-27 16:18:07 +08:00 Compare
Author
Contributor

For reference, here's a screengrab of the ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS section:
ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS
The enhanced filters provide rejection of 50 Hz and 60 Hz
simultaneously and allow the user to trade off settling time and
rejection. These filters can operate up to 27.27 SPS or can reject
up to 90 dB of 50 Hz ± 1 Hz and 60 Hz ± 1 Hz interference.
These filters are realized operated by postfiltering the output of the
sinc5 + sinc1 filter. For this reason, the sinc5 + sinc1 filter must
be selected when using the enhanced filters to achieve the
specified settling time and noise performance. Table 24 shows the
output data rates with the accompanying settling time,
rejection, and rms noise. Figure 62 to Figure 69 show the
frequency domain plots of the responses from the enhanced filters.
Table 24. Enhanced Filters Output Data Rate, Noise, Settling Time, and Rejection Using the Enhanced Filters
Output Data Rate (SPS)
27.27
25
20
16.667
1
Settling
Time (ms)
36.67
40.0
50.0
60.0
Simultaneous Rejection of
50 Hz ± 1 Hz and 60 Hz ± 1 Hz (dB) 1
47
62
85
90
Noise
(µV rms)
0.45
0.44
0.41
0.417
Master clock = 2.00 MHz.
Rev. A | Page 34 of 60
Peak-to-Peak
Resolution (Bits)
21.4
21.4
21.7
21.7
Comments
See Figure 62 and Figure 65
See Figure 63 and Figure 66
See Figure 64 and Figure 67
See Figure 68 and Figure 69

...and the figures in the FILTER CONFIGURATION REGISTER 0 section:
[10:8]
ENHFILT0
010
011
101
110
These bits select between various postfilters for enhanced 50 Hz and 60
Hz rejection for Setup 0.
27 SPS, 47 dB rejection, 36.7 ms settling
21.25 SPS, 62 dB rejection, 40 ms settling
20 SPS, 86 dB rejection, 50 ms settling
16.67 SPS, 92 dB rejection, 60 ms settling
0x5RW

The same section in the AD7173-8 Rev. B datasheet:
[10:8]
ENHFILT0
010
011
101
110
These bits select between various postfilters for enhanced 50 Hz and 60
Hz rejection for Setup 0.
27.27 SPS, 47 dB rejection, 36.67 ms settling
25 SPS, 62 dB rejection, 40 ms settling
20 SPS, 86 dB rejection, 50 ms settling
16.67 SPS, 92 dB rejection, 60 ms settling
0x5RW

For reference, here's a screengrab of the *ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS* section: ![ENHANCED 50 Hz AND 60 Hz REJECTION FILTERS The enhanced filters provide rejection of 50 Hz and 60 Hz simultaneously and allow the user to trade off settling time and rejection. These filters can operate up to 27.27 SPS or can reject up to 90 dB of 50 Hz ± 1 Hz and 60 Hz ± 1 Hz interference. These filters are realized operated by postfiltering the output of the sinc5 + sinc1 filter. For this reason, the sinc5 + sinc1 filter must be selected when using the enhanced filters to achieve the specified settling time and noise performance. Table 24 shows the output data rates with the accompanying settling time, rejection, and rms noise. Figure 62 to Figure 69 show the frequency domain plots of the responses from the enhanced filters. Table 24. Enhanced Filters Output Data Rate, Noise, Settling Time, and Rejection Using the Enhanced Filters Output Data Rate (SPS) 27.27 25 20 16.667 1 Settling Time (ms) 36.67 40.0 50.0 60.0 Simultaneous Rejection of 50 Hz ± 1 Hz and 60 Hz ± 1 Hz (dB) 1 47 62 85 90 Noise (µV rms) 0.45 0.44 0.41 0.417 Master clock = 2.00 MHz. Rev. A | Page 34 of 60 Peak-to-Peak Resolution (Bits) 21.4 21.4 21.7 21.7 Comments See Figure 62 and Figure 65 See Figure 63 and Figure 66 See Figure 64 and Figure 67 See Figure 68 and Figure 69](/attachments/7128ea31-eb46-43d6-b0f8-9e82b5fe65d7) ...and the figures in the *FILTER CONFIGURATION REGISTER 0* section: ![[10:8] ENHFILT0 010 011 101 110 These bits select between various postfilters for enhanced 50 Hz and 60 Hz rejection for Setup 0. 27 SPS, 47 dB rejection, 36.7 ms settling 21.25 SPS, 62 dB rejection, 40 ms settling 20 SPS, 86 dB rejection, 50 ms settling 16.67 SPS, 92 dB rejection, 60 ms settling 0x5RW](/attachments/e79a1991-a521-4170-8c6d-f940eafa01f4) The same section in the AD7173-8 Rev. B datasheet: ![[10:8] ENHFILT0 010 011 101 110 These bits select between various postfilters for enhanced 50 Hz and 60 Hz rejection for Setup 0. 27.27 SPS, 47 dB rejection, 36.67 ms settling 25 SPS, 62 dB rejection, 40 ms settling 20 SPS, 86 dB rejection, 50 ms settling 16.67 SPS, 92 dB rejection, 60 ms settling 0x5RW](/attachments/d228de36-84c5-4cec-a8aa-38a15b6e6bc8)
Owner

It is indeed 25 SPS instead of 21.25 SPS.
(Verified on Kirdy with a MCU timer)

It is indeed 25 SPS instead of 21.25 SPS. (Verified on Kirdy with a MCU timer)
This pull request can be merged automatically.
You are not authorized to merge this pull request.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u correct-postfilter-rate:atse-correct-postfilter-rate
git checkout atse-correct-postfilter-rate
Sign in to join this conversation.
No reviewers
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: M-Labs/thermostat#166
No description provided.