| 전자부품 데이터시트 검색엔진 |
|
AN2335 데이터시트(PDF) 34 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN2335 데이터시트(HTML) 34 Page - STMicroelectronics |
|
34 / 40 page ![]() Application Information AN2335 34/40 FF_WU_CFG(LIR) bit permits to decide if the interrupt request has to be latched or not. If LIR bit is ‘0’ (default value) interrupt signal goes high when the interrupt condition is satisfied and comes back low immediately if the interrupt condition is no more verified. Otherwise if LIR bit is ‘1’ whenever a interrupt condition is applied the interrupt signal remains high even if the condition comes back to non-interrupt status until a reading to FF_WU_SRC register is performed. The remaining bits of FF_WU_CFG register permits to decide on which axis the interrupt decision has to be performed and on which direction the threshold has to be passed to generate the interrupt request. 9.5 INERTIAL WAKE-UP 9.5.1 HP Filter Bypassed This paragraph provides a basic algorithm which shows the practical use of the inertial wake-up feature. In particular, with the code below, the device is configured to recognize when the absolute acceleration along either X or Y axis exceeds a preset threshold (180mg used in the example). The event which triggers the interrupt is latched inside the device using FF_WU interrupt source 1 and its occurrence is signalled through the usage of the INT2 pin. 1 write C7h into CTRL_REG1 // Turn on the sensor and set ODR=400Hz 2 write 00h into CTRL_REG2 // Default value: High Pass filter bypassed 3 write 08h into CTRL_REG3 // FF_WU1 interrupt sent to INT2 pin 4 write 0Ah into FF_WU_THS_1 reg // Set wake-up threshold = 180 mg 5 write 00h into FF_WU_DURATION_1 reg // No filtering/confirmation on the event 6 write 4Ah into FF_WU_CFG_1 // Configure desired wake-up event 7 poll INT2 pin; if INT2=0 then goto 7 // Poll INT2 pin waiting for the wake-up event 8 read FF_WU_SRC_1 reg // Return the event that has triggered the interrupt // Clear interrupt request 9 (Wake-up event has occurred; insert your code here) // Event handling 10 goto 7 |
|
링크 URL |
| ALLDATASHEET 가 귀하에 도움이 되셨나요? [ DONATE ] |
Alldatasheet는? | 광고문의 | 운영자에게 연락하기 | 개인정보취급방침 | 링크 투 데이터시트 | 링크교환 | 제조사별 검색 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |