- •Preface
- •About this document
- •Intended audience
- •Organization
- •Typographical conventions
- •Further reading
- •ARM publications
- •Feedback
- •Feedback on this document
- •Feedback on the ARM PrimeCell Generic Infrared Interface (PL140)
- •Introduction
- •1.1 About the ARM PrimeCell Generic Infrared Interface (PL140)
- •1.1.1 Features of the PrimeCell GIR
- •1.1.2 Programmable parameters
- •1.2 Block diagram
- •1.3 AMBA compatibility
- •Functional Overview
- •2.1 ARM PrimeCell Generic Infrared Interface (PL140) overview
- •2.2 PrimeCell GIR functional description
- •2.2.1 AMBA APB interface
- •2.2.2 Register block
- •2.2.3 Receive and transmit clock divider
- •2.2.4 Transmit FIFO
- •2.2.5 Receive FIFO
- •2.2.6 Transmit logic
- •2.2.7 Receive logic
- •2.2.8 Interrupt generation logic
- •2.2.9 Synchronizing registers and logic
- •2.2.10 Test registers and logic
- •2.3 Infrared methodology
- •2.4 PrimeCell GIR operation
- •2.4.1 Interface reset
- •2.4.2 Clock signals
- •2.4.3 Receive processing
- •2.4.4 Receive demodulation
- •2.4.5 Receive FIFO information
- •2.4.6 Transmit processing
- •2.4.7 Transmit modulation
- •2.4.8 Clock dividers
- •Programmer’s Model
- •3.1 About the programmer’s model
- •3.2 Summary of PrimeCell GIR registers
- •3.3 Register descriptions
- •3.3.1 GIRFCR: [15] (+ 0x00)
- •3.3.5 GIRSTAT: [8] (+0x10)
- •3.3.7 GIRIIR/GIRICR: [3/0] (+0x18)
- •Programmer’s Model for Test
- •4.1 PrimeCell GIR test harness overview
- •4.2 Scan testing
- •4.3 Test registers
- •4.3.4 GIRTISR: [1] (+0x88)
- •4.3.5 GIRTOCR: [5] (+0x8c)
- •4.3.6 GIRTTXCDC [16] (+0x90)
- •4.3.7 GIRTRXCDC [16] (+0x94)
- •4.3.8 GIRTTXC [20] (+0x98)
- •4.3.9 GIRTRXPTC [20] (+0x9c)
- •4.3.10 GIRTDC [7] (+0xa0)
- •A.1 AMBA APB signals
- •A.2 On-chip signals
- •A.3 Signals to pads
Programmer’s Model
3.3Register descriptions
The following registers are described in this section:
•GIRFCR: [15] (+ 0x00)
•GIRTXGENCR: [16] (+ 0x04) on page 3-6
•GIRRXGENCR: [16] (+ 0x08) on page 3-7
•GIRTXDUTYCR: [4] (+ 0x0c) on page 3-8
•GIRSTAT: [8] (+0x10) on page 3-8
•GIRDATAR: [18/17] (+ 0x14c) on page 3-9
•GIRIIR/GIRICR: [3/0] (+0x18) on page 3-10.
For each of the following register descriptions, the format of the title is:
Register name: [bit width] (Offset from Base)
3.3.1GIRFCR: [15] (+ 0x00)
GIRFCR is the function control register which acts as the main source of control for the infrared interface. Separate enables are provided for transmit and receive paths. In addition, the FIFOs can be separately enabled. Table 3-2 shows the bit assignments for the GIRFCR.
|
|
|
|
Table 3-2 GIRFCR register read/write bits |
|
|
|
|
|
Bits |
Name |
Type |
Function |
|
|
|
|
|
|
31:15 |
|
Read/write |
Reserved, do not modify, read as 0. |
|
|
|
|
|
|
14 |
RORIntEnable |
Read/write |
Receive overrun interrupt enable bit. |
|
|
|
|
1 |
= Interrupt is enabled whenever receive |
|
|
|
overrun bit is set. |
|
|
|
|
0 |
= Interrupt is disabled. |
|
|
|
|
|
13 |
RxIntEnable |
Read/write |
Receive interrupt enable bit. |
|
|
|
|
1 |
= Interrupt is enabled. |
|
|
|
0 |
= Interrupt is disabled. |
|
|
|
|
|
12 |
TxIntEnable |
Read/write |
Transmit interrupt enable bit. |
|
|
|
|
1 |
= Interrupt is enabled. |
|
|
|
0 |
= Interrupt is disabled. |
|
|
|
|
|
3-4 |
© Copyright ARM Limited 1999. All rights reserved. |
ARM DDI 0149B |
Programmer’s Model
Table 3-2 GIRFCR register read/write bits (continued)
Bits |
Name |
Type |
Function |
|
|
|
|
|
|
11 |
TxIntCtrl |
Read/write |
Transmit interrupt control bit. |
|
|
|
|
1 |
= When transmit function is enabled, |
|
|
|
GIRTXINTR is raised when transmitter is not |
|
|
|
|
busy, that is when transmission has completed |
|
|
|
|
and TxIntEnable = 1. |
|
|
|
|
0 |
= GIRTXINTR raised when transmit FIFO is |
|
|
|
half full or less, independent of whether the |
|
|
|
|
transmit function is enabled or disabled, but |
|
|
|
|
TxIntEnable must be 1. |
|
|
|
|
|
|
10 |
RxIntCtrl |
Read/write |
Receive interrupt control bit. |
|
|
|
|
1 |
= When receive function is enabled, |
|
|
|
GIRRXINT is raised when the receive FIFO is |
|
|
|
|
not empty and RxIntEnable = 1. |
|
|
|
|
0 |
= When receive function is enabled, |
|
|
|
GIRRXINT is raised when receive FIFO is half |
|
|
|
|
full or greater and RxIntEnable = 1. |
|
|
|
|
|
|
9 |
TxEnable |
Read/write |
Enable transmit function. |
|
|
|
|
1 |
= Enable transmission. |
|
|
|
0 |
= Disable transmission. |
|
|
|
|
|
8 |
RxEnable |
Read/write |
Enable receive function. |
|
|
|
|
1 |
= Enable receiver. |
|
|
|
0 |
= Disable receiver. |
|
|
|
|
|
7 |
TxFifoEn |
Read/write |
Enable transmit FIFO. |
|
|
|
|
1 |
= Transmit FIFO enabled to accept data. |
|
|
|
0 |
= Transmit FIFO disabled and flushed. |
|
|
|
|
|
6 |
RxFifoEn |
Read/write |
Enable receive FIFO. |
|
|
|
|
1 |
= Receive FIFO enabled to accept data. |
|
|
|
0 |
= Receive FIFO disabled and flushed. |
|
|
|
|
|
5 |
ModEn |
Read/write |
Enable modulation. |
|
|
|
|
1 |
= Output level is modulated with a carrier |
|
|
|
signal as described below. |
|
|
|
|
0 |
= Output level is set by bit 16 of the transmit |
|
|
|
FIFO. |
|
|
|
|
|
|
ARM DDI 0149B |
© Copyright ARM Limited 1999. All rights reserved. |
3-5 |
Programmer’s Model
Table 3-2 GIRFCR register read/write bits (continued)
Bits |
Name |
Type |
Function |
|
|
|
|
|
|
4 |
DemodEn |
Read/write |
Enable demodulation. |
|
|
|
|
1 = Demodulation enabled. |
|
|
|
|
0 = Demodulation disabled. |
|
|
|
|
|
|
3:2 |
EdgeCtrl[1:0] |
Read/write |
Edge detector control bits for pulse timer in |
|
|
|
|
receive direction: |
|
|
|
|
00 |
= Edge detection disabled. |
|
|
|
01 |
= Enable falling edges to restart timer. |
|
|
|
10 |
= Enable rising edges to restart timer. |
|
|
|
11 = Either edge restarts timer (used in |
|
|
|
|
demodulation mode). |
|
|
|
|
|
|
1:0 |
Winctrl[1:0] |
Read/write |
Limit control bits for window comparator: |
|
|
|
|
00 |
= Limits set to +3 and -3. |
|
|
|
01 |
= Limits set to +3 and -4. |
|
|
|
10 |
= Limits set to +4 and -3. |
|
|
|
11 = Limits set to +4 and -4. |
|
|
|
|
|
|
3.3.2GIRTXGENCR: [16] (+ 0x04)
GIRTXGENCR is the transmit clock generator control register which holds the value of the divisor to be applied to the internal programmable divider for transmit functions.
When the transmit function is disabled, the value written to this register is applied directly to the internal programmable transmit clock divider. When the transmit function is enabled, changes to this register value only take effect when the associated internal counter reaches zero.
Table 3-3 on page 3-7 shows the bit assignments for the GIRTXGENCR.
3-6 |
© Copyright ARM Limited 1999. All rights reserved. |
ARM DDI 0149B |
Programmer’s Model
|
|
|
Table 3-3 GIRTXGENCR register read/write bits |
|
|
|
|
Bits |
Name |
Type |
Function |
|
|
|
|
31:16 |
- |
Read/write |
Reserved, do not modify, read as 0. |
|
|
|
|
15:0 |
clkdiv |
Read/write |
Divisor value for the programmable divider/clock |
|
|
|
generator. |
|
|
|
Value of 0 is reserved. |
|
|
|
Divisor value = (clkdiv + 1). |
|
|
|
If the value of clkdiv is 1, the divisor value is 2. |
|
|
|
If the value of clkdiv is 2, the divisor value is 3, |
|
|
|
and so on, up to a maximum divisor value of |
|
|
|
65536. |
|
|
|
|
3.3.3GIRRXGENCR: [16] (+ 0x08)
GIRRXGENCR is the receive clock generator control register which holds the value of the divisor to be applied to the internal programmable divider for receive functions.
When the receive function is disabled, the value written to this register is applied directly to the internal programmable receive clock divider. When the receive function is enabled, changes to this register value only take effect when the associated internal counter reaches zero. Table 3-4 shows the bit assignments for the GIRRXGENCR.
|
|
|
Table 3-4 GIRRXGENCR register read/write bits |
|
|
|
|
Bits |
Name |
Type |
Function |
|
|
|
|
31:16 |
- |
Read/write |
Reserved, do not modify, read as 0. |
|
|
|
|
15:0 |
clkdiv |
Read/write |
Divisor value for the programmable divider/clock |
|
|
|
generator. |
|
|
|
Value of 0 is reserved. |
|
|
|
Divisor value = (clkdiv + 1). |
|
|
|
If the value of clkdiv is 1, the divisor value is 2. |
If the value of clkdiv is 2, the divisor value is 3, and so on, up to a maximum divisor value of 65536.
ARM DDI 0149B |
© Copyright ARM Limited 1999. All rights reserved. |
3-7 |