                                                               +--------------+
                                                               | IO90385-003E |
                                                               +--------------+























                           SAMPLE I/O REGISTER FILES
                      FOR F2MC-16LX FAMILY MB90385/455 SERIES

                                 USERS MANUAL

                                FUJITSU LIMITED

                                 VERSION 3.0

Preface

  The sample I/O register files for MB90385/455 series declares and defines
  variables, thereby enabling the I/O registers
  of the F2MC-16LX family MB90385/455 series to be handled as C variables.
  This manual describes the configuration of the I/O register files,
  variable declaration and definition.




Items to note before using I/O register files

  - The I/O register files are intended for specific series of
    F2MC-16L/16LX/16/16H/16F family.
    Before applying these programs to any other series of MB90385/455 series,
    therefore, be sure to modify the I/O register files.

  - When a program for I/O register operation is coded, the I/O register
    access sequence and timing must be considered. Please refer to the
    related hardware manuals.

  - The I/O register files are provided as valuable aids in developing the
    application programs for MB90385/455 series. In practice, however,
    some of these programs may need be modified depending on the
    target system. Before using any of them, therefore, be sure to verify
    the actual operation of the program.

  - Fujitsu may assume no liability for errors in the I/O register files and
    no responsibility for correcting errors immediately even if they are found.

Reference manuals

  I/O register files forMB90385/455 series (Version 3.0) are made based
  on the following manuals.

    - MB90385 series HARDWARE MANUAL(CM44-10118-1E.pdf)
    - MB90455 series HARDWARE MANUAL(CM44-10124-1E.pdf)

Contents

CHAPTER 1  CONFIGURATION OF I/O REGISTER FILES

CHAPTER 2  USAGE OF I/O REGISTER FILES

CHAPTER 3  DECLARATION OF I/O REGISTER DECLARATION FILES

CHAPTER 4  VARIABLE AND MEMBER NAMES USED IN I/O REGISTER DECLARATION FILES
           FOR MB90385/455 SERIES

CHAPTER 1  CONFIGURATION OF I/O REGISTER FILES

 ${FETOOL}             (Directory set in environment variable FETOOL)
  +-lib
    +-907
      +-include
        +-sample
          +-mb90385
            +-_ffmc16.h (I/O register declaration file)
            |
            +-_mb90385.h (I/O register declaration file for MB90385/455 series)
            +-_r90385.h (I/O register structure declaration file
            |                                           for MB90385/455 series)
            |
            +-*.c        (I/O register definition file for each I/O register)

  - I/O register declaration file

    This file declares all the associated I/O register variables (variables
    corresponding to I/O registers).
    Please include this file when coding a program that handles associated
    I/O registers.

  - I/O register declaration file for MB90385/455 series

    This file declares all the structure types corresponding to I/O registers
    for MB90385/455 series.

  - I/O register structure declaration file for MB90385/455 series

    This file declares all the structure types corresponding to I/O registers
    for MB90385/455 series.

  - I/O register definition file for each I/O register

    This file defines each the associated I/O register variable and specifies
    arrangement address.

CHAPTER 2  USAGE OF I/O REGISTER FILES

  (1) Please compile the all I/O register definition files with the CPU option
      of using MB number, and make the relocatable load module by linker.

        example:  > fcc907s  -cpu mb90*** -c *.c
                  > flnk907s -cpu mb90*** -r -o io90***.rel *.obj

  (2) When you describe the application program which refers to the I/O
      registers, please include the I/O register declaration file.

        example:  #include "_ffmc16.h"

                  void func(){
                         .....
                    IO_TCCS.bit.MODE = 1;
                         .....
                  }

  (3) Please compile the application program file with the CPU option of
      using MB number.

        example:  > fcc907s -cpu mb90*** -c sample.c

        Note: When the MB number of the specified CPU option cannot be used
              for the I/O register file, the following messages are output.

                #error "The I/O register file of the specified CPU option
                        does not exist"

  (4) Please link the relocatable load module and the application program
      object file.

        example:  > flnk907s -cpu mb90*** -o sample.abs io90***.rel sample.obj

CHAPTER 3  DECLARATION OF I/O REGISTER DECLARATION FILES

  Each I/O register declaration file declares the variables and the bit field
  members corresponding to I/O register names and bit names as follows:

    - The I/O register variables that can be accessed in bits, bytes or words
      are declared in union type (except some declared in structure type).

    - The I/O register variables that must be accessed in 1, 2 or 4 bytes
      are declared in integer type.

    - Basically, each variable name is declared in the form of the
      corresponding I/O  register name plus 'IO_'.
      (However, for access convenience, two or more I/O registers may be
       declared by one variable name.)

    - A bit field member name is declared by the corresponding bit name.
      (some bits are declared in one member name for access convenience)


  [Example]  Declaration for I/O register PDR0

    - I/O register structure

          7       6       5       4       3       2       1       0    bit No.
      +-------+-------+-------+-------+-------+-------+-------+-------+
      |   P07 |   P06 |   P05 |   P04 |   P03 |   P02 |   P01 |   P00 | PDR0
      +-------+-------+-------+-------+-------+-------+-------+-------+

    - Contents of declaration

        union io_pdr0 {
                unsigned char    byte;
                struct {
                        unsigned char    P00:1;
                        unsigned char    P01:1;
                        unsigned char    P02:1;
                        unsigned char    P03:1;
                        unsigned char    P04:1;
                        unsigned char    P05:1;
                        unsigned char    P06:1;
                        unsigned char    P07:1;
                } bit;
        };

        extern __io union io_pdr0  IO_PDR0;

CHAPTER 4  VARIABLE AND MEMBER NAMES USED IN I/O REGISTER DECLARATION FILES
           FOR MB90385/455 SERIES

<<I/O port>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  Pn7  |  Pn6  |  Pn5  |  Pn4  |  Pn3  |  Pn2  |  Pn1  |  Pn0  | PDRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  Dn7  |  Dn6  |  Dn5  |  Dn4  |  Dn3  |  Dn2  |  Dn1  |  Dn0  | DDRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  ADE7 |  ADE6 |  ADE5 |  ADE4 |  ADE3 |  ADE2 |  ADE1 |  ADE0 | ADER
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      PDRn              IO_PDRn.byte          IO_PDRn.bit.Pnx(x:0 - 7)
      (n=1 - 5)

      DDRn              IO_DDRn.byte          IO_DDRn.bit.Dnx(x:0 - 7)
      (n=1 - 5)

      ADER              IO_ADER.byte          IO_ADER.bit.ADEx(x:0 - 7)
    --------------------------------------------------------------------------

<<UART>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  MD1  |  MD0  |  CS2  |  CS1  |  CS0  |  RST  |  SCKE |  SOE  | SMRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  PEN  |    P  |  SBL  |   CL  |   AD  |  REC  |  RXE  |  TXE  | SCRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   D7  |   D6  |   D5  |   D4  |   D3  |   D2  |   D1  |   D0  | SIDRn/
    +-------+-------+-------+-------+-------+-------+-------+-------+ SODRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   PE  |  ORE  |  FRE  |  RDRF |  TDRE |  BDS  |  RIE  |  TIE  | SSRn
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   MD  |   -   |   -   |   -   |reserve|  DIV2 |  DIV1 |  DIV0 | CDCRn
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      SMRn              IO_SMRn.byte          IO_SMRn.bit.SOE
      (n:1)                                   IO_SMRn.bit.SCKE
                                              IO_SMRn.bit.RST
                                              IO_SMRn.bit.CS     [CS0 - CS2]
                                              IO_SMRn.bit.MD     [MD0 - MD1]

      SCRn              IO_SCRn.byte          IO_SCRn.bit.TXE
      (n:1)                                   IO_SCRn.bit.RXE
                                              IO_SCRn.bit.REC
                                              IO_SCRn.bit.AD
                                              IO_SCRn.bit.CL
                                              IO_SCRn.bit.SBL
                                              IO_SCRn.bit.P
                                              IO_SCRn.bit.PEN

      SIDRn/SODRn       IO_SIDRn.byte         IO_SIDRn.bit.D     [D0 - D6]
      (n:1)

      SSRn              IO_SSRn.byte          IO_SSRn.bit.TIE
      (n:1)                                   IO_SSRn.bit.RIE
                                              IO_SSRn.bit.BDS
                                              IO_SSRn.bit.TDRE
                                              IO_SSRn.bit.RDRF
                                              IO_SSRn.bit.FRE
                                              IO_SSRn.bit.ORE
                                              IO_SSRn.bit.PE

      CDCRn             IO_CDCRn.byte         IO_CDCRn.bit.DIV   [DIV0 - DIV2]
      (n:1)                                   IO_CDCRn.bit.MD
    --------------------------------------------------------------------------
      Note: When using a simple assignment statement to write data to CDCRn
            (member IO_CDCRn.byte), be sure to write 0 to reserved bit.

<<DTP/external interrupts>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  EN7  |  EN6  |  EN5  |  EN4  |  EN3  |  EN2  |  EN1  |  EN0  | ENIR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  ER7  |  ER6  |  ER5  |  ER4  |  ER3  |  ER2  |  ER1  |  ER0  | EIRR
    +-------+-------+-------+-------+-------+-------+-------+-------+

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | ELVR
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |   LA7 |   LA6 |   LA5 |   LA4 |   LA3 |   LA2 |   LA1 |   LA0
      LB7     LB6     LB5     LB4     LB3     LB2     LB1     LB0

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      ENIR              IO_ENIR.byte          IO_ENIR.bit.ENx(x:0 - 7)

      EIRR              IO_EIRR.byte          IO_EIRR.bit.ERx(x:0 - 7)

      ELVR              IO_ELVR.word          IO_ELVR.bit.LALBx(x:0 - 7)
                                                                  [LAx,LBx]
    --------------------------------------------------------------------------

<<A/D converter>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  MD1  |  MD0  |  ANS2 |  ANS1 |  ANS0 |  ANE2 |  ANE1 |  ANE0 | ADCSL
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  BUSY |  INT  |  INTE |  PAUS |  STS1 |  STS0 |  STRT |reserve| ADCSH
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   D7  |   D6  |   D5  |   D4  |   D4  |   D2  |   D1  |   D0  | ADCRL
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  S10  |  ST1  |  ST0  |  CT1  |  CT0  |   -   |   D9  |   D8  | ADCRH
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      ADCSL             IO_ADCSL.byte         IO_ADCSL.bit.ANE    [ANE0 - ANE2]
                                              IO_ADCSL.bit.ANS    [ANS0 - ANS2]
                                              IO_ADCSL.bit.MD     [MD0 - MD1]

      ADCSH             IO_ADCSH.byte         IO_ADCSH.bit.STRT
                                              IO_ADCSH.bit.STS    [STS0 - STS1]
                                              IO_ADCSH.bit.PAUS
                                              IO_ADCSH.bit.INTE
                                              IO_ADCSH.bit.INT
                                              IO_ADCSH.bit.BUSY

      ADCRL,ADCRH       IO_ADCRLH.DATA8     [ADCRL       D0-D7]
                        IO_ADCRLH.DATA10    [ADCRL,ADCRH D0-D9]
                        IO_ADCRLH.byte.ADCRH
    --------------------------------------------------------------------------
      Note 1: Data write to ADCSL is enabled by assigning a variable or
              constant to member IO_ADCSL.byte with a simple assignment
              expression. (Always write 0 to reserved bit.)
      Note 2: Data write to ADCRH is enabled by assigning a variable or
              constant to member IO_ADCRLH.byte.ADCRH with a simple
              assignment expression.

<<8/16-bit PPG>>

  - I/O register structure

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    |   | - |   |   |   |   |   |rsv|   | - |   |   |   | - | - |rsv| PPGCn
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |       |  PIE1 |   MD1 |       |       |  PIE0 |
     PEN1    PE1     PUF1     MD0    PEN0    PE0     PUF0

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  PCS2 |  PCS1 |  PCS0 |  PCM2 |  PCM1 |  PCM0 |   -   |   -   | PPGn
    +-------+-------+-------+-------+-------+-------+-------+-------+

      31          24  23          16  15           8  7            0  bit No.
    +-------------------------------+-------------------------------+
    |              PRLH             |              PRLL             |
    +---------------+---------------+---------------+---------------+ PRLxy
    |     PRLHy     |     PRLLy     |     PRLHx     |     PRLLx     |
    +---------------+---------------+---------------+---------------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      PPGCn             IO_PPGCn.word         IO_PPGCn.bit.PUF0
      (n=01,23)                               IO_PPGCn.bit.PIE0
                                              IO_PPGCn.bit.PE0
                                              IO_PPGCn.bit.PEN0
                                              IO_PPGCn.bit.MD     [MD0 - MD1]
                                              IO_PPGCn.bit.PUF1
                                              IO_PPGCn.bit.PIE1
                                              IO_PPGCn.bit.PE1
                                              IO_PPGCn.bit.PEN1

      PPGn              IO_PPGn.byte          IO_PPGn.bit.PCM     [PCM0 - PCM2]
      (n=01,23)                               IO_PPGn.bit.PCS     [PCS0 - PCS2]

      PRLxy             IO_PRLxy.lword        none
      (xy=01,23)        IO_PRLxy.word.PRLx
                        IO_PRLxy.word.PRLy
                        IO_PRLxy.byte.PRLLx
                        IO_PRLxy.byte.PRLHx
                        IO_PRLxy.byte.PRLLy
                        IO_PRLxy.byte.PRLHy
    --------------------------------------------------------------------------
      Note: When using a simple assignment statement to write data to PPGCn
            (member IO_PPGCn.word), be sure to write 1 to reserved bit.

<<16-bit I/O timer>>

  - I/O register structure

      15                                                           0  bit No.
    +---------------------------------------------------------------+
    |                                                               | TCDT
    +---------------------------------------------------------------+

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  IVF  |  IVFE |  STOP |reserve|  CLR  |  CLK2 |  CLK1 |  CLK0 | TCCS
    +-------+-------+-------+-------+-------+-------+-------+-------+

      15                                                           0  bit No.
    +---------------------------------------------------------------+
    |                                                               | IPCPn
    +---------------------------------------------------------------+

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  ICP1 |  ICP0 |  ICE1 |  ICE0 |  EG11 |  EG10 |  EG01 |  EG00 | ICSxy
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      TCDT              IO_TCDT               none

      TCCS              IO_TCCS.byte          IO_TCCS.bit.CLK    [CLK0 - CLK2]
                                              IO_TCCS.bit.CLR
                                              IO_TCCS.bit.STOP
                                              IO_TCCS.bit.IVFE
                                              IO_TCCS.bit.IVF

      IPCPn             IO_IPCPn              none
      (n:0 - 3)

      ICSxy             IO_ICSxy.byte         IO_ICSxy.bit.EG0    [EG00 - EG01]
      (x:01,23)                               IO_ICSxy.bit.EG1    [EG10 - EG11]
                                              IO_ICSxy.bit.ICE0
                                              IO_ICSxy.bit.ICE1
                                              IO_ICSxy.bit.ICP0
                                              IO_ICSxy.bit.ICP1
    --------------------------------------------------------------------------
      Note: When using a simple assignment statement to write data to TCCS
            (member IO_TCCS.byte), be sure to write 0 to reserved bit.

<<16-bit reload timer>>

  - I/O register structure

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    | - | - | - | - |   |   |   |   |   |   |   |   |   |   |   |   | TMCSRn
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
                      |  CSL0 |  MOD1 |  OUTE |  RELD |   UF  |   TRG
                     CSL1    MOD2    MOD0    OUTL    INTE    CNTE

      15                                                           0  bit No.
    +---------------------------------------------------------------+
    |                                                               | TMRn/
    +---------------------------------------------------------------+TMRLRn

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      TMCSRn            IO_TMCSRn.word        IO_TMCSRn.bit.TRG
      (n=0 - 1)                               IO_TMCSRn.bit.CNTE
                                              IO_TMCSRn.bit.UF
                                              IO_TMCSRn.bit.INTE
                                              IO_TMCSRn.bit.RELD
                                              IO_TMCSRn.bit.OUTL
                                              IO_TMCSRn.bit.OUTE
                                              IO_TMCSRn.bit.MOD   [MOD0 - MOD2]
                                              IO_TMCSRn.bit.CSL   [CSL0 - CSL1]

      TMRn/TMRLRn       IO_TMR[n]
      (n=0 - 1)
    --------------------------------------------------------------------------

<<ROM mirror function selection module>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   -   |   -   |   -   |   -   |   -   |   -   |   -   |   MI  | ROMM
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      ROMM              IO_ROMM               none
    --------------------------------------------------------------------------

<<CAN controller>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | BVAL7 | BVAL6 | BVAL5 | BVAL4 | BVAL3 | BVAL2 | BVAL1 | BVAL0 | BVALR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | TREQ7 | TREQ6 | TREQ5 | TREQ4 | TREQ3 | TREQ2 | TREQ1 | TREQ0 | TREQR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | TCAN7 | TCAN6 | TCAN5 | TCAN4 | TCAN3 | TCAN2 | TCAN1 | TCAN0 | TCANR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  TC7  |  TC6  |  TC5  |  TC4  |  TC3  |  TC2  |  TC1  |  TC0  | TCR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  RC7  |  RC6  |  RC5  |  RC4  |  RC3  |  RC2  |  RC1  |  RC0  | RCR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | RRTR7 | RRTR6 | RRTR5 | RRTR4 | RRTR3 | RRTR2 | RRTR1 | RRTR0 | RRTRR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | ROVR7 | ROVR6 | ROVR5 | ROVR4 | ROVR3 | ROVR2 | ROVR1 | ROVR0 | ROVRR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  RIE7 |  RIE6 |  RIE5 |  RIE4 |  RIE3 |  RIE2 |  RIE1 |  RIE0 | RIER
    +-------+-------+-------+-------+-------+-------+-------+-------+

    +---------------------------------------------------------------+
    |                  General-purpose RAM (32byte)                 | RAM
    +---------------------------------------------------------------+

      31  30  29  28  27  26  25  24  23  22  21  20  19  18  17  16
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+-
    |   |   |   |   |   | - | - | - |   |   |   |   |   |   |   |   |
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+-
      |  ID3  |  ID1  |               |  ID11 |  ID9  |  ID7  |  ID5
     ID4     ID2     ID0             ID12    ID10    ID8     ID6
        15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
     -+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | IDRy
     -+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
        |  ID19 |  ID17 |  ID15 |  ID13 |  ID27 |  ID25 |  ID23 |  ID21
       ID20    ID18    ID16    ID14    ID28    ID26    ID24    ID22

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    | - | - | - | - | - | - | - | - | - | - | - | - |   |   |   |   | DLCRy
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
                                                      |  DLC2 |  DLC0
                                                     DLC3    DLC1

      63                                                           0  bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | BYTE7 | BYTE6 | BYTE5 | BYTE4 | BYTE3 | BYTE2 | BYTE1 | BYTE0 | DTRy
    +-------+-------+-------+-------+-------+-------+-------+-------+

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    |   |   | - | - | - |   |   |   |   | - | - | - | - |   | - |   | CSR
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |   RS              NT  |  NS0  |                  NIE     HALT
      TS                     NS1     TOE

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  NTE  |  TCE  |  RCE  |   -   |   -   |  MBP2 |  MBP1 |  MBP0 | LEIR
    +-------+-------+-------+-------+-------+-------+-------+-------+

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | RTEC
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |  TEC6 |  TEC4 |  TEC2 |  TEC0 |  REC6 |  REC4 |  REC2 |  REC0
     TEC7    TEC5    TEC3    TEC1    REC7    REC5    REC3    REC1
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
    | - |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | BTR
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
        TS2.2 | TS2.0 | TS1.2 | TS1.0 |  RSJ0 |  PSC4 |  PSC2 |  PSC0
            TS2.1   TS1.3   TS1.1    RSJ1    PSC5    PSC3    PSC1

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  IDE7 |  IDE6 |  IDE5 |  IDE4 |  IDE3 |  IDE2 |  IDE1 |  IDE0 | IDER
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | TRTR7 | TRTR6 | TRTR5 | TRTR4 | TRTR3 | TRTR2 | TRTR1 | TRTR0 | TRTRR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    | RFWT7 | RFWT6 | RFWT5 | RFWT4 | RFWT3 | RFWT2 | RFWT1 | RFWT0 | RFWTR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  TIE7 |  TIE6 |  TIE5 |  TIE4 |  TIE3 |  TIE2 |  TIE1 |  TIE0 | TIER
    +-------+-------+-------+-------+-------+-------+-------+-------+

      15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  AMS7 |  AMS6 |  AMS5 |  AMS4 |  AMS3 |  AMS2 |  AMS1 |  AMS0 | AMSR
    +-------+-------+-------+-------+-------+-------+-------+-------+

      31  30  29  28  27  26  25  24  23  22  21  20  19  18  17  16
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+-
    |   |   |   |   |   | - | - | - |   |   |   |   |   |   |   |   |
    +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+-
      |  AM3  |  AM1  |               |  AM11 |  AM9  |  AM7  |  AM5
     AM4     AM2     AM0             AM12    AM10    AM8     AM6
        15  14  13  12  11  10  9   8   7   6   5   4   3   2   1   0   bit No.
     -+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
      |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   |   | AMR0,
     -+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+
        |  AM19 |  AM17 |  AM15 |  AM13 |  AM27 |  AM25 |  AM23 |  AM21
       AM20    AM18    AM16    AM14    AM28    AM26    AM24    AM22

  - Usable variable and member name

    --------------------------------------------------------------------------
     Register name At access in 1/2/4bytes   At access in bits
    --------------------------------------------------------------------------
     BVALR         IO_BVALR.byte             IO_BVALR.bit.BVALx(x:0-7)
     TREQR         IO_TREQR.byte             IO_TREQR.bit.TREQx(x:0-7)
     TCANR         IO_TCANR.byte             IO_TCANR.bit.TCANx(x:0-7)
     TCR           IO_TCR.byte               IO_TCR.bit.TCx(x:0-7)
     RCR           IO_RCR.byte               IO_RCR.bit.RCx(x:0-7)
     RRTRR         IO_RRTRR.byte             IO_RRTRR.bit.RRTRx(x:0-7)
     ROVRR         IO_ROVRR.byte             IO_ROVRR.bit.ROVRx(x:0-7)
     RIER          IO_RIER.byte              IO_RIER.bit.RIEx(x:0-7)

     RAM           IO_CANID.RAM[x]           none
                   (x:0 - 15)

     IDRy          IO_CANID.IDR[y].lword     IO_CANID.IDR[y].bit.IDx(x:0-28)
     DLCRy         IO_CANID.DLCR[y].word     IO_CANID.DLCR[y].DLC  [DLC0-3]
     (y:0 - 7)

     DTRy          IO_CANID.DTR[y].BYTE0_3   none
     (y:0 - 7)     IO_CANID.DTR[y].BYTE4_7   none

     CSR           IO_CANCT.CSR.word         IO_CANCT.CSR.bit.HALT
                                             IO_CANCT.CSR.bit.NIE
                                             IO_CANCT.CSR.bit.TOE
                                             IO_CANCT.CSR.bit.NS   [NS0 - NS1]
                                             IO_CANCT.CSR.bit.NT
                                             IO_CANCT.CSR.bit.RS
                                             IO_CANCT.CSR.bit.TS

     LEIR          IO_CANCT.LEIR.byte        IO_CANCT.LEIR.bit.MBP [MBP0-MBP2]
                                             IO_CANCT.LEIR.bit.RCE
                                             IO_CANCT.LEIR.bit.TCE
                                             IO_CANCT.LEIR.bit.NTE

     RTEC          IO_CANCT.RTEC.REC         none
                   IO_CANCT.RTEC.TEC

     BTR           IO_CANCT.BTR.word         IO_CANCT.BTR.bit.PSC  [PSC0-PSC5]
                                             IO_CANCT.BTR.bit.RSJ  [RSJ0-RSJ1]
                                             IO_CANCT.BTR.bit.TS1  [TS1.0 - 3]
                                             IO_CANCT.BTR.bit.TS2  [TS2.0 - 2]

     IDER          IO_CANCT.IDER.byte        IO_CANCT.IDER.bit.IDEx(x:0-7)
     TRTRR         IO_CANCT.TRTRR.byte       IO_CANCT.TRTRR.bit.TRTRx(x:0-7)
     RFWTR         IO_CANCT.RFWTR.byte       IO_CANCT.RFWTR.bit.RFWTx(x:0-7)
     TIER          IO_CANCT.TIER.byte        IO_CANCT.TIER.bit.TIEx(x:0-7)
     AMSR          IO_CANCT.AMSR.word        IO_CANCT.AMSR.bit.AMSx(x:0-7)
     AMR0          IO_CANCT.AMR0.lword       IO_CANCT.AMR0.bit.AMx(x:0-28)
     AMR1          IO_CANCT.AMR1.lword       IO_CANCT.AMR1.bit.AMx(x:0-28)
    --------------------------------------------------------------------------
      Note 1: Data write to CSR is enabled by assigning a variable or
              constant to member IO_CANCT.CSR.word with a simple assignment
              expression.
      Note 2: The usage of bit access members of CSR are limited to the
              reading description.
      Note 3: Data write to IDRy is enabled by assigning a variable or
              constant to member IO_CANID.IDR[y].lword with a simple
              assignment expression.
      Note 4: The usage of bit access members of IDRy are limited to the
              reading description.
      Note 5: Data write to DLCRy is enabled by assigning a variable or
              constant to member IO_CANID.DLCR[y].word with a simple
              assignment expression.
      Note 6: The usage of bit access members of DLCRy are limited to the
              reading description.
      Note 7: Data write to DTRy is enabled by assigning a variable or
              constant to member IO_CANID.DTR[y].BYTE0_3 and
              IO_CANID.DTR[y].BYTE4_7 with a simple assignment expression.

<<Address match detection function>>

  - I/O register structure

      23                16  15                 8  7                0  bit No.
    +---------------------+---------------------+-------------------+
    |       HIGH          |        MID          |       LOW         | PADRn
    +---------------------+---------------------+-------------------+

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |reserve|reserve|reserve|reserve|  AD1E |reserve|  AD0E |reserve| PACSR
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      PADRn             IO_PADR[n].LOW        none
      (n:0 - 1)         IO_PADR[n].MID        none
                        IO_PADR[n].HIGH

      PACSR             IO_PACSR.byte         IO_PACSR.bit.AD0E
                                              IO_PACSR.bit.AD1E
    --------------------------------------------------------------------------
      Note: When using a simple assignment statement to write data to PACSR
            (member IO_PACSR.byte), be sure to write 0 to reserved bit.

<<Delay interrupt generation module>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   -   |   -   |   -   |   -   |   -   |   -   |   -   |   R0  | DIRR
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      DIRR              IO_DIRR.byte          IO_DIRR.bit.R0
    --------------------------------------------------------------------------
      Note:  When DIRR is accessed, bits should be operated considering
             future expansion.

<<Low power consumption mode>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  STP  |  SLP  |  SPL  |  RST  |  TMD  |  CG1  |  CG0  |reserve| LPMCR
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  SCM  |  MCM  |  WS1  |  WS0  |  SCS  |  MCS  |  CS1  |  CS0  | CKSCR
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      LPMCR             IO_LPMCR.byte         IO_LPMCR.bit.CG     [CG0 - CG1]
                                              IO_LPMCR.bit.TMD
                                              IO_LPMCR.bit.RST
                                              IO_LPMCR.bit.SPL
                                              IO_LPMCR.bit.SLP
                                              IO_LPMCR.bit.STP
                                              IO_LPMCR.bitc.SLPSTP

      CKSCR             IO_CKSCR.byte         IO_CKSCR.bit.CS     [CS0 - CS1]
                                              IO_CKSCR.bit.MCS
                                              IO_CKSCR.bit.SCS
                                              IO_CKSCR.bit.WS     [WS0 - WS1]
                                              IO_CKSCR.bit.MCM
                                              IO_CKSCR.bit.SCM
    --------------------------------------------------------------------------
      Note: Always write 0 to reserved bit of LPMCR.

<<Watchdog timer>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  PONR |   -   |  WRST |  ERST |  SRST |  WTE  |  WT1  |  WT0  | WDTC
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      WDTC              IO_WDTC.byte          IO_WDTC.bit.SRST
                                              IO_WDTC.bit.ERST
                                              IO_WDTC.bit.WRST
                                              IO_WDTC.bit.PONR
    --------------------------------------------------------------------------
      Note 1: WT0,WT1,WTE of WDTC are write-only bits;
              members to be accessed in bits are not declared.
              Data write to WDTC is enabled by assigning a variable or
              constant to member IO_WDTC.byte with a simple assignment
              expression.
      Note 2: The usage of bit access members of WDTC are limited to the
              reading description.

<<Timebase timer>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |reserve|   -   |   -   |  TBIE |  TBOF |  TBR  |  TBC1 |  TBC0 | TBTC
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      TBTC              IO_TBTC.byte          IO_TBTC.bit.TBC     [TBC0 - TBC1]
                                              IO_TBTC.bit.TBR
                                              IO_TBTC.bit.TBOF
                                              IO_TBTC.bit.TBIE
    --------------------------------------------------------------------------
      Note 1: Data write to TBTC is enabled by assigning a variable or
              constant to member IO_TBTC.byte with a simple assignment
              expression. (Always write 1 to reserved bit.)
      Note 2: The usage of bit access members of TBTC are limited to the
              reading description.

<<Clock timer>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  WDCS |  SCE  |  WTIE |  WTOF |  WTR  |  WTC2 |  WTC1 |  WTC0 | WTC
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      WTC               IO_WTC.byte           IO_WTC.bit.WTC      [WTC0 - WTC2]
                                              IO_WTC.bit.WTR
                                              IO_WTC.bit.WTOF
                                              IO_WTC.bit.WTIE
                                              IO_WTC.bit.SCE
                                              IO_WTC.bit.WDCS
    --------------------------------------------------------------------------
      Note: Data write to WTC is enabled by assigning a variable or
              constant to member IO_WTC.byte with a simple assignment
              expression.

<<Flush memory interface>>

  - I/O register structure

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  INTE | RDYINT|   WE  |  RDY  |reserve|  LPM1 |reserve|  LPM0 | FMCS
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      FMCS              IO_FMCS.byte          IO_FMCS.bit.LPM0
                                              IO_FMCS.bit.LPM1
                                              IO_FMCS.bit.RDY
                                              IO_FMCS.bit.WE
                                              IO_FMCS.bit.RDYINT
                                              IO_FMCS.bit.INTE
    --------------------------------------------------------------------------
      Note : When using a simple assignment statement to write data to FMCS
             (member IO_FMCS.byte), be sure to write 0 to reserved bit.

<<Interrupt controller>>

  - I/O register structure

    [ICRn]

        7       6       5       4       3       2       1       0     bit No.
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |  ICS3 |  ICS2 |  ICS1 |  ICS0 |  ISE  |  IL2  |  IL1  |  IL0  | write
    +-------+-------+-------+-------+-------+-------+-------+-------+
    +-------+-------+-------+-------+-------+-------+-------+-------+
    |   -   |   -   |   S1  |   S0  |  ISE  |  IL2  |  IL1  |  IL0  | read
    +-------+-------+-------+-------+-------+-------+-------+-------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      ICRn(n:00 - 15)   IO_ICRn.byte          IO_ICRn.bit.IL      [IL0 - IL2]
                                              IO_ICRn.bit.ISE
                                              IO_ICRn.bit.S       [S0 - S1]
    --------------------------------------------------------------------------
      Note 1: Data write to ICRn is enabled by assigning a variable or
              constant to member IO_ICRn.byte with a simple assignment
              expression.
      Note 2: The usage of bit access members of ICRn are limited to the
              reading description.

<<Extended intelligent I/O service descriptor>>

  - I/O register structure

    [ISDn]

      15                           8  7                            0  bit No.
    +-------------------------------+-------------------------------+
    |             BAPM              |             BAPL              | BAPML
    +-------------------------------+-------------------------------+
                                    |             BAPH              | BAPH
                                    +-------------------------------+
                                    |             ISCS              | ISCS
    +-------------------------------+-------------------------------+
    |             IOAH              |             IOAL              | IOA
    +-------------------------------+-------------------------------+
    |             DCTH              |             DCTL              | DCT
    +-------------------------------+-------------------------------+

  - Usable variable and member name

    --------------------------------------------------------------------------
      Register name  At access in 1/2/4bytes  At access in bits
    --------------------------------------------------------------------------
      ISDn(n:0 - 15)    IO_ISD[n].BAPML       none
                        IO_ISD[n].BAPH
                        IO_ISD[n].ISCS
                        IO_ISD[n].IOA
                        IO_ISD[n].DCT
    --------------------------------------------------------------------------
      Note 1: An I/O service function of Extended Intelligent I/O Service
              (EIIOS) has the limitation to uses with the REALOS/907
              (JCTX instruction).
              Please find the hardware manual of each microcontrollers for
              detailed limitation.
      Note 2: When you describe the application program which refers to ISDn,
              please compile all the I/O register definition files with
              "-D USE_ISD" option.

                example:  > fcc907s -c -cpu mb90xxx -D USE_ISD *.c





+-----------------------------------------------------------------------------+
|1. The contents of this document are subject to change without notice.       |
|   Customers are advised to consult with FUJITSU sales representatives       |
|   beforeordering.                                                           |
|2. The information and circuit diagrems in this document presented as        |
|   examples of semiconductor device applications, and are not intended to be |
|   incorporated in devices for actual use. Also FUJITSU is unable to assume  |
|   responsibility for infringement of any patent rights or other rights of   |
|   third parties arising from the use of this information or circuit         |
|   diagrams.                                                                 |
|3. The contents of this document may not be reproduced or copied without the |
|   permission of FUJITSU LIMITED.                                            |
|4. FUJITSU semiconductor devices are intended for use in standard            |
|   applications (computers, office automation and other office equipments,   |
|   industrial, communications, and measurement equipments, personal or       |
|   household devices, etc.).                                                 |
|   CAUTION:                                                                  |
|   Customers considering the use of our products in special applications     |
|   where failure or abnormal operation may directly affect human lives or    |
|   cause physical injury or property damage, or where extremely high levels  |
|   of reliability are demanded (such as aerospace systems, atomic energy     |
|   controls, sea floor repeaters, vehicle operating controls, medical        |
|   devices for life support, etc.) are requested to consult with FUJITSU     |
|   sales representatives before such use. The company will not be            |
|   responsible for damages arising from such use without prior approval.     |
|5. Any semiconductor devices have inherently a certain rate of failure. You  |
|   must protect against injury, damage or loss from such failures by         |
|   incorporating safety design measures into your facility and equipment     |
|   such as redundancy, fire protection, and prevention of over-current       |
|   levels and other abnormal operating conditions.                           |
|6. If any products described in this document represent goods or             |
|   technologies subject to certain restrictions on export under the Foreign  |
|   Exchange and Foreign Trade Control Law of Japan, the prior authorization  |
|   by japanese government should be required for export of those products    |
|   from Japan.                                                               |
+-----------------------------------------------------------------------------+
 (C)2002  FUJITSU LIMITED Printed in Japan
