The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/dev/i2c/pcf8583reg.h

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 /*      $NetBSD: pcf8583reg.h,v 1.1 2003/09/30 00:35:31 thorpej Exp $   */
    2 
    3 /*
    4  * Ben Harris, 2000
    5  *
    6  * This file is in the public domain
    7  */
    8 
    9 /*
   10  * Philips PCF8583 RTC registers
   11  */
   12 
   13 /* We only have clock mode registers here */
   14 
   15 #ifndef _PCF8583REG_H
   16 #define _PCF8583REG_H
   17 
   18 /*
   19  * PCF8583 RTC I2C address:
   20  *
   21  *      101 0000
   22  */
   23 #define PCF8583_ADDRMASK        0x7f
   24 #define PCF8583_ADDR            0x50
   25 
   26 #define PCF8583_REG_CSR         0x00
   27 #define PCF8583_REG_CENTI       0x01
   28 #define PCF8583_REG_SEC         0x02
   29 #define PCF8583_REG_MIN         0x03
   30 #define PCF8583_REG_HOUR        0x04
   31 #define PCF8583_REG_YEARDATE    0x05
   32 #define PCF8583_REG_WKDYMON     0x06
   33 #define PCF8583_REG_TIMER       0x07
   34 #define PCF8583_REG_ALMCTL      0x08
   35 #define PCF8583_REG_ALMCENTI    0x09
   36 #define PCF8583_REG_ALMSEC      0x0a
   37 #define PCF8583_REG_ALMMIN      0x0b
   38 #define PCF8583_REG_ALMHOUR     0x0c
   39 #define PCF8583_REG_ALMDAY      0x0d
   40 #define PCF8583_REG_ALMMON      0x0e
   41 #define PCF8583_REG_ALMTIMER    0x0f
   42 
   43 #define PCF8583_NVRAM_START     0x10
   44 #define PCF8583_NVRAM_SIZE      240
   45 
   46 #define PCF8583_CSR_TIMER       0x01
   47 #define PCF8583_CSR_SECTICK     0x01
   48 #define PCF8583_CSR_ALARM       0x02
   49 #define PCF8583_CSR_MINTICK     0x02
   50 #define PCF8583_CSR_ALARMENABLE 0x04
   51 #define PCF8583_CSR_MASK        0x08
   52 #define PCF8583_CSR_FN_MASK     0x30
   53 #define PCF8583_CSR_FN_32768HZ  0x00
   54 #define PCF8583_CSR_FN_50HZ     0x10
   55 #define PCF8583_CSR_FN_EVENT    0x20
   56 #define PCF8583_CSR_FN_TEST     0x30
   57 #define PCF8583_CSR_HOLD        0x40
   58 #define PCF8583_CSR_STOP        0x80
   59 
   60 #define PCF8583_HOUR_MASK       0x3f
   61 #define PCF8583_HOUR_PM         0x40
   62 #define PCF8583_HOUR_12H        0x80
   63 
   64 #define PCF8583_DATE_MASK       0x3f
   65 #define PCF8583_YEAR_MASK       0xc0
   66 #define PCF8583_YEAR_SHIFT      6
   67 
   68 #define PCF8583_MON_MASK        0x1f
   69 #define PCF8583_WKDY_MASK       0xe0
   70 #define PCF8583_WKDY_SHIFT      5
   71 
   72 #define PCF8583_ALMCTL_TIMER_MASK       0x07
   73 #define PCF8583_ALMCTL_TIMER_OFF        0x00
   74 #define PCF8583_ALMCTL_TIMER_CENTI      0x01
   75 #define PCF8583_ALMCTL_TIMER_SEC        0x02
   76 #define PCF8583_ALMCTL_TIMER_MIN        0x03
   77 #define PCF8583_ALMCTL_TIMER_HOUR       0x04
   78 #define PCF8583_ALMCTL_TIMER_DAY        0x05
   79 #define PCF8583_ALMCTL_TIMER_TEST       0x07
   80 #define PCF8583_ALMCTL_TIMERINT         0x08
   81 #define PCF8583_ALMCTL_CLKALM_MASK      0x30
   82 #define PCF8583_ALMCTL_CLKALM_NONE      0x00
   83 #define PCF8583_ALMCTL_CLKALM_DAILY     0x10
   84 #define PCF8583_ALMCTL_CLKALM_WKDY      0x20
   85 #define PCF8583_ALMCTL_CLKALM_DATED     0x30
   86 #define PCF8583_ALMCTL_TIMERALM         0x40
   87 #define PCF8583_ALMCTL_ALMINT           0x80
   88 
   89 #endif  /* _PCF8583REG_H */

Cache object: 1136b60b1cdcdf196e00ffd49f67aebb


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.