LSM6DS33 LPF(Low Pass Filter)低通滤波和高通滤波器
↓↓↓ 想了解更加详细的内容吗?请参考以下文章 ↓↓↓
此处的“低”和“高”指的是频率的高低。
“低通”就是指频率比较低的可以通过,高频的信号给滤除掉。
相应的去理解“高通”的意思。
分为硬件滤波和软件滤波,此处只分析硬件滤波。
名词解释:
ODR:OutputData Rates, 输出数据率, 就是每秒钟输出的比特速率。
Acc:加速度计
GYRO:陀螺仪
SLOPE:斜率
HPF:高通滤波器
LPF:低通滤波器
LPF2:低通滤波器2
其他。
下图解释:
17H代表CTRL8_XL这个寄存器的地址。是8位的
如下表格有8个格子,左边代表高位,右边代表低位。
比如如果写11100101(其中有的必须写0)到0x17这个寄存器。
对应16进制就是,写0xE5到0x17地址。
LSM6DS33LP(Low Pass)低通滤波和高通滤波
*以下为应用手册Application note加速度计相关*
2.6 Accelerometerbandwidth--Application note相关加速度计的频带宽度
The accelerometer sampling chain (Figure 1) is representedby a cascade of four blocks: an analog low-pass filter, an ADC converter, a digital low-pass filter andthe composite group of digital filters described in Figure 2.
加速度计数据处理链由四部分串联而成,1低通抗锯齿滤波器,2模数转换,3数字低通滤波器,4组合数字波器。
*上图第一个方框:1低通抗锯齿滤波器*
Figure 1. Accelerometer sampling chain diagram
The analog signal coming from the mechanical parts is filtered by alow-pass anti-aliasing filter before being converted by the ADC. The anti-aliasing filter isenabled in High-Performance mode only.
从微机械部分来的模拟信号,通过一个低通抗锯齿滤波器(只能在高性能模式使用),再进行模数转换。
If the XL_BW_SCAL_ODR bit in CTRL4_C register is set to 1, the bandwidthof this analog filter is determined by setting the BW_XL bits of CTRL1_XL register;relative filter cutoff frequency values are given in Table 6.
如果CTRL4_C(13h)中的XL_BW_SCAL_ODR位被设置为1,则模拟滤波器的带宽的设置由CTRL1_XL的BW_XL[1:0]位决定。见下图。
If the XL_BW_SCAL_ODR bit is set to0, the bandwidth of the analog filter is determined by the ODR_XL selection (Table 7).
如果CTRL4_C中的XL_BW_SCAL_ODR位被设置为0,则模拟滤波器的带宽的设置由ODR_XL位决定。见下图。
简单来说:为0的时候,简单一点,是固定的。
为1的时候是可以配置的,每种都可以分别配置为50,100,200,400Hz。
* 第三个方框:3数字低通滤波器*
The digital signal is then filtered by a low-pass digital filter (LPF1)whose cutoff frequency depends on the selected accelerometer ODR, as shown in Table 8.
然后数字信号经过一个低通滤波器(LPF1),不同的ODR对应不同的截止频率。见下图:
*第四个方框:组合数字波器*
Finally, the digital signal is processed by the composite group of filterscomposed of a lowpass digital filter (LPF2), a high-pass digital filter and a slope filter. Asshown in Figure 2,
最后,数字信号会通过组合滤波器。由低通数字滤波器(LPF2),高通数字滤波器,以及一个斜率滤波器组成。
It is possible to independentlyapply these filters to the accelerometer output data (and to the FIFO data) and/or to the interrupt generators.
这三个滤波器是独立的,每种数据都可以用来单独输出芯片外(或者芯片的FIFO),也能用来产生中断。
The enable signal of these high-pass and low-pass digital filters is thelogic “OR” of the SLOPE_FDS bit of the TAP_CFG register and the FUNC_EN bit of the CTRL10_Cregister.
高通滤波器和低通滤波器的启动信号,“TAP_CFG寄存器的SLOPE_FDS”和“CTRL10_C的FUNC_EN”是“或”的关系。
The SLOPE_FDS bit is also used to select the filter (high-pass or slope)used for the wakeup interrupt functionality. For this reason, if the wake-up functionality isimplemented using the slope filter and also the LPF2 filter is required, the latter has tobe enabled by setting the FUNC_EN bit to 1.
SLOPE_FDS位也通过选择滤波器,用来配置唤醒中断。
因此,如果用唤醒功能,可用斜率滤波器(slope)和低通滤波器2(LPF2)。
使用LPF2的时候要设置FUNC_EN= 1.
In all other cases, to enable the high-pass and low-pass digital filtersit’s recommended to set to 1 the SLOPE_FDS bit and set to 0 the FUNC_EN bit (ifthe embedded functions, such as the Android functions, are not used).
其他情况,建议设置SLOPE_FDS=1,FUNC_EN =0.
The bits LPF2_XL_EN, HP_SLOPE_XL_EN and HPCF_XL [1:0] of CTRL8_XL are usedto select the filter applied to the accelerometer output data and to the FIFOdata:
1.if both the LPF2_XL_EN bit and the HP_SLOPE_XL_EN bit are set to 0, nofilter is applied;
2.if the LPF2_XL_EN bit is set to 1, the LP digital filter is applied,regardless of the HP_SLOPE_XL_EN bit configuration;
3.if theLPF2_XL_EN bit is set to 0 and the HP_SLOPE_XL_EN bit is set to 1, the appliedfilter depends on the configuration of the HPCF_XL [1:0] bits, as shown in Table 9.
CTRL8_XL 寄存器中的LPF2_XL_EN,HP_SLOPE_XL_EN 和 HPCF_XL [1:0] 位用来选择数据是递交给芯片输出,还是传输给芯片的FIFO。
1.如果LPF2_XL_EN 和 theHP_SLOPE_XL_EN都设置为0,Figure2中没有滤波器打开。
2.如果LPF2_XL_EN= 1,低通滤波器(LPF2)打开。(HP_SLOPE_XL_EN置1)
3.如果LPF2_XL_EN= 0,并且HP_SLOPE_XL_EN=1,哪个滤波器打开还要看HPCF_XL [1:0]如何配置,请参考Table9.
斜率滤波器和高通滤波器只能二选一
The HPCF_XL [1:0] bits of CTRL8_XL are also used to selectthe cutoff frequency of the LPF2 filter, as shown in Table 10.
CTRL8_XL寄存器中的HPCF_XL [1:0]位,也可以用来选择LPF2的截止频率。请见Table10。
This low-pass filter can also be used in the 6D/4D functionality bysetting the LOW_PASS_ON_6D bit of CTRL8_XL register to 1.
低通滤波器也可以用来识别 6D/4D功能,要设置CTRL8_XL寄存器中的LOW_PASS_ON_6D=1。
Accelerometer slope filter
加速度计斜率滤波器
As shown in Figure 2, the LSM6DS33 device embeds adigital slope filter which is used for activity/inactivity and single/double-tap features; it can also be usedfor wake-up detection when the SLOPE_FDS bit of the TAP_CFG register is set to 0.
The slope filter output data is computed using the following formula:
slope(tn) = [ acc(tn) - acc(tn-1) ] / 2
An example of a slope data signal is illustrated in Figure 3.
如Figure2所示,LSM6DS33里面嵌入了一个数字斜率滤波器,用来检测运动/静止,以及单击/双击。当TAP_CFG寄存器的SLOPE_FDS=1时,也可以用来唤醒检测。
斜率滤波器的输出数据由如下公式计算:slope(tn) = [ acc(tn) - acc(tn-1) ] / 2
如下图所示:
更多ST传感器产品信息,可通过以下渠道获得——
1.意法半导体授权代理商
2.ST MEMS 技术讨论QQ群:415506792
欢迎您关注意法半导体AMSChina微信公众平台。
意法半导体(ST;STMicroelectronics)是全球领先的半导体解决方案供应商,为客户提供传感器、功率器件、汽车产品和嵌入式处理器解决方案。从能源管理和节能技术,到数字信任和数据安全,从医疗健身设备,到智能消费电子,从家电、汽车,到办公设备,从工作到娱乐,意法半导体的微电子器件无所不在,在丰富人们的生活方面发挥着积极、创新的作用。
联系邮箱:st_amschina@st.com
官方网站:http://www.st.com/web/cn/home.html