| 数据搜索系统,热门电子元器件搜索 |
|
AFE8220TPZPQ1 数据表(PDF) 29 Page - Texas Instruments |
|
|
|
|||||||||||||||||||||||||||||
AFE8220TPZPQ1 数据表(HTML) 29 Page - Texas Instruments |
|
29 / 49 page ![]() Real-Time Clock Alarm GPIO AFE8220-Q1 www.ti.com....................................................................................................................................................... SBAS455A – JANUARY 2009 – REVISED JULY 2009 Invalid combinations of rtc_day and rtc_month (trying to set February 30, for example) cause unpredictable behavior and should be avoided. The February 28/29 rollover variation based on leap year is automatically corrected for. The RTC defaults to operate in 12-hour plus AM/PM mode. To operate in 24-hour mode (where the AM/PM bits are disabled) set rtc_mode to 1. Care must be taken when switching between AM/PM mode and 24-hour mode to avoid setting the time to a invalid value. See Figure 18 and Figure 19 for the proper procedures. The real-time clock alarm function can be used to generate an interrupt (or a wakeup interrupt) at a pre-programmed time. If the appropriate bit in an interrupt enable register is set, an interrupt will be generated when the values in the RTC time registers become equal to the values in the RTC alarm registers. The register settings are shown in Table 15. Table 15. RTC Alarm Control Register Settings PARAMETER ADDRESS BITS rtc_seconds_alarm[6:0] 67 6:0 rtc_minutes_alarm[6:0] 68 6:0 rtc_hours_alarm[5:0] 69 5:0 rtc_ampm_alarm 69 7 rtc_day_alarm[5:0] 70 5:0 rtc_month_arlarm[4:0] 71 4:0 rtc_year_alarm[7:0] 72 7:0 Eight general-purpose I/O pins are provided, labeled GPIO0 through GPIO7. The direction of the eight GPIO pins can be independently set through control variable gpio_oe(7:0). A pin is an input if the corresponding bit of gpio_oe is 0; a pin is an output if the corresponding bit of gpio_oe is 1. The control variable gpio(7:0) serves different functions, depending on whether it is read from or written to. A read operation from gpio returns the logic state of the eight GPIO pins regardless of their direction. A write to gpio sets the output state of the GPIO pins if they are configured as outputs; there is no effect if the pin is configured as an input. Note that the write value of gpio is stored in a register, so that if a GPIO pin is changed from an input to an output its logic state is set by the stored value of gpio. Table 18 shows the gpio control variable settings. The GPIO inputs can be optionally debounced if an RTC oscillator is running. Debouncing is controlled by gpio_delay, which is divided into eight 2-bit fields, each controlling a particular GPIO input according to Table 16. Table 16. gpio_delay [15:14] [13:12] [11:10] [9:8] [7:6] [5:4] [3:2] [1:0] GPIO7 GPIO6 GPIO5 GPIO4 GPIO3 GPIO2 GPIO1 GPIO0 Copyright © 2009, Texas Instruments Incorporated Submit Documentation Feedback 29 Product Folder Link(s): AFE8220-Q1 |
|
链接网址 |
| 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 |