6 - 24
emPC-CXR
(
Hardware Manual
)
•
FPGA expansion subsystem
©
Janz Tec AG
Rev. V1.2
6.1
Control Registers
Address Offset
access
Description
BAR4 + 0x00
RO
INT_STAT
BAR4 + 0x04
RO
INT_MASK
BAR4 + 0x08
WO
INT_DISABLE
BAR4 + 0x0C
WO
INT_ENABLE
BAR4 + 0x10
WO
RESET_ASSERT
BAR4 + 0x14
WO
RESET_DEASSERT
BAR4 + 0x18
RO
RESET_STATUS
BAR4 + 0x1c
RW
I2C_CONTROL
BAR4 + 0x20
RO
FEATURE1
BAR4 + 0x24
RO
FEATURE2
BAR4 + 0x30
RW
TESTREG
BAR4 + 0x3C
RO
REVISON
Table 12: Control registers
6.1.1
Feature detection
FEATURE1
BAR4 +
0x20 (32bit, ro)
31..10
9
8
7..2
1
0
reserved
COM1
COM0
Reserved
CAN1
CAN0
CAN[1..0]
High if corresponding CAN is available
COM[1..0]
High if corresponding COM is available
Reserved
Reserved positions are zero
REVISION
BAR4 +
0x3c (32bit, ro)
31..24
23..16
15..8
7..0
ID
Reserved
Release
Build
ID
Refers to the specific hardware design (0x02 is emPC-CXR)
Reserved
Is 0x00
Release
Specifies the current Version of the design
Build
Running Build Number
6.1.2
Interrupt programming
The FPGA generate an interrupt that is logically or’ed amoung all internal interrupt sources.
To determine which source has generated an interrupt the Interrupt handler must read the interrupt
status register:
INT_STAT
BAR4 +
0x0 (32bit, ro)
31..10
9
8
7..2
1
0
reserved
COM1
COM0
Reserved
CAN1
CAN0
CAN[1..0]
Interrupt status info. Each defined bit in this register reflects the status of
the INT# pin of the corresponding CAN. A zero will be read when an
interrupt is pending.