------------- Registers -- -------------
UART0_Periph : aliased UART_Peripheral
with Import, Address => UART0_Base;
UART1_Periph : aliased UART_Peripheral
with Import, Address => UART1_Base;
type UART_Peripheral is record
UARTDR : aliased UARTDR_Register;
UARTRSR : aliased UARTRSR_Register;
UARTFR : aliased UARTFR_Register;
UARTILPR : aliased UARTILPR_Register;
UARTIBRD : aliased UARTIBRD_Register;
UARTFBRD : aliased UARTFBRD_Register;
UARTLCR_H : aliased UARTLCR_H_Register;
UARTCR : aliased UARTCR_Register;
UARTIFLS : aliased UARTIFLS_Register;
UARTIMSC : aliased UARTIMSC_Register;
UARTRIS : aliased UARTRIS_Register;
UARTMIS : aliased UARTMIS_Register;
UARTICR : aliased UARTICR_Register;
UARTDMACR : aliased UARTDMACR_Register;
UARTPERIPHID0 : aliased UARTPERIPHID0_Register;
UARTPERIPHID1 : aliased UARTPERIPHID1_Register;
UARTPERIPHID2 : aliased UARTPERIPHID2_Register;
UARTPERIPHID3 : aliased UARTPERIPHID3_Register;
UARTPCELLID0 : aliased UARTPCELLID0_Register;
UARTPCELLID1 : aliased UARTPCELLID1_Register;
UARTPCELLID2 : aliased UARTPCELLID2_Register;
UARTPCELLID3 : aliased UARTPCELLID3_Register;
end record;
Receive Status Register/Error Clear Register, UARTRSR/UARTECR
Flag Register, UARTFR
IrDA Low-Power Counter Register, UARTILPR
Integer Baud Rate Register, UARTIBRD
Fractional Baud Rate Register, UARTFBRD
Line Control Register, UARTLCR_H
Control Register, UARTCR
Interrupt FIFO Level Select Register, UARTIFLS
Interrupt Mask Set/Clear Register, UARTIMSC
Raw Interrupt Status Register, UARTRIS
Masked Interrupt Status Register, UARTMIS
Interrupt Clear Register, UARTICR
DMA Control Register, UARTDMACR
UARTPeriphID0 Register
UARTPeriphID1 Register
UARTPeriphID2 Register
UARTPeriphID3 Register
UARTPCellID0 Register
UARTPCellID1 Register
UARTPCellID2 Register
UARTPCellID3 Register
type UARTCR_OUT_Field
(As_Array : Boolean := False)
is record
case As_Array is
when False =>
Val : HAL.UInt2;
when True =>
Arr : UARTCR_OUT_Field_Array;
end case;
end record;
type UARTCR_OUT_Field_Array is array (1 .. 2) of Boolean
with Component_Size => 1, Size => 2;
type UARTCR_Register is record
UARTEN : Boolean := False;
SIREN : Boolean := False;
SIRLP : Boolean := False;
Reserved_3_6 : HAL.UInt4 := 16#0#;
LBE : Boolean := False;
TXE : Boolean := True;
RXE : Boolean := True;
DTR : Boolean := False;
RTS : Boolean := False;
OUT_k : UARTCR_OUT_Field := (As_Array => False, Val => 16#0#);
RTSEN : Boolean := False;
CTSEN : Boolean := False;
Reserved_16_31 : HAL.UInt16 := 16#0#;
end record;
SIR enable: 0 = IrDA SIR ENDEC is disabled. nSIROUT remains LOW (no light pulse generated), and signal transitions on SIRIN have no effect. 1 = IrDA SIR ENDEC is enabled. Data is transmitted and received on nSIROUT and SIRIN. UARTTXD remains HIGH, in the marking state. Signal transitions on UARTRXD or modem status inputs have no effect. This bit has no effect if the UARTEN bit disables the UART.
SIR low-power IrDA mode. This bit selects the IrDA encoding mode. If this bit is cleared to 0, low-level bits are transmitted as an active high pulse with a width of 3 / 16th of the bit period. If this bit is set to 1, low-level bits are transmitted with a pulse width that is 3 times the period of the IrLPBaud16 input signal, regardless of the selected bit rate. Setting this bit uses less power, but might reduce transmission distances.
unspecified
Loopback enable. If this bit is set to 1 and the SIREN bit is set to 1 and the SIRTEST bit in the Test Control Register, UARTTCR is set to 1, then the nSIROUT path is inverted, and fed through to the SIRIN path. The SIRTEST bit in the test register must be set to 1 to override the normal half-duplex SIR operation. This must be the requirement for accessing the test registers during normal operation, and SIRTEST must be cleared to 0 when loopback testing is finished. This feature reduces the amount of external coupling required during system test. If this bit is set to 1, and the SIRTEST bit is set to 0, the UARTTXD path is fed through to the UARTRXD path. In either SIR mode or UART mode, when this bit is set, the modem outputs are also fed through to the modem inputs. This bit is cleared to 0 on reset, to disable loopback.
Transmit enable. If this bit is set to 1, the transmit section of the UART is enabled. Data transmission occurs for either UART signals, or SIR signals depending on the setting of the SIREN bit. When the UART is disabled in the middle of transmission, it completes the current character before stopping.
Receive enable. If this bit is set to 1, the receive section of the UART is enabled. Data reception occurs for either UART signals or SIR signals depending on the setting of the SIREN bit. When the UART is disabled in the middle of reception, it completes the current character before stopping.
Data transmit ready. This bit is the complement of the UART data transmit ready, nUARTDTR, modem status output. That is, when the bit is programmed to a 1 then nUARTDTR is LOW.
Request to send. This bit is the complement of the UART request to send, nUARTRTS, modem status output. That is, when the bit is programmed to a 1 then nUARTRTS is LOW.
This bit is the complement of the UART Out1 (nUARTOut1) modem status output. That is, when the bit is programmed to a 1 the output is 0. For DTE this can be used as Data Carrier Detect (DCD).
RTS hardware flow control enable. If this bit is set to 1, RTS hardware flow control is enabled. Data is only requested when there is space in the receive FIFO for it to be received.
CTS hardware flow control enable. If this bit is set to 1, CTS hardware flow control is enabled. Data is only transmitted when the nUARTCTS signal is asserted.
unspecified
type UARTDMACR_Register is record
RXDMAE : Boolean := False;
TXDMAE : Boolean := False;
DMAONERR : Boolean := False;
Reserved_3_31 : HAL.UInt29 := 16#0#;
end record;
Transmit DMA enable. If this bit is set to 1, DMA for the transmit FIFO is enabled.
DMA on error. If this bit is set to 1, the DMA receive request outputs, UARTRXDMASREQ or UARTRXDMABREQ, are disabled when the UART error interrupt is asserted.
unspecified
subtype UARTDR_DATA_Field is HAL.UInt8;
type UARTDR_Register is record
DATA : UARTDR_DATA_Field := 16#0#;
FE : Boolean := False;
PE : Boolean := False;
BE : Boolean := False;
OE : Boolean := False;
Reserved_12_31 : HAL.UInt20 := 16#0#;
end record;
Read-only. Framing error. When set to 1, it indicates that the received character did not have a valid stop bit (a valid stop bit is 1). In FIFO mode, this error is associated with the character at the top of the FIFO.
Read-only. Parity error. When set to 1, it indicates that the parity of the received data character does not match the parity that the EPS and SPS bits in the Line Control Register, UARTLCR_H. In FIFO mode, this error is associated with the character at the top of the FIFO.
Read-only. Break error. This bit is set to 1 if a break condition was detected, indicating that the received data input was held LOW for longer than a full-word transmission time (defined as start, data, parity and stop bits). In FIFO mode, this error is associated with the character at the top of the FIFO. When a break occurs, only one 0 character is loaded into the FIFO. The next character is only enabled after the receive data input goes to a 1 (marking state), and the next valid start bit is received.
Read-only. Overrun error. This bit is set to 1 if data is received and the receive FIFO is already full. This is cleared to 0 once there is an empty space in the FIFO and a new character can be written to it.
unspecified
subtype UARTFBRD_BAUD_DIVFRAC_Field is HAL.UInt6;
type UARTFBRD_Register is record
BAUD_DIVFRAC : UARTFBRD_BAUD_DIVFRAC_Field := 16#0#;
Reserved_6_31 : HAL.UInt26 := 16#0#;
end record;
unspecified
type UARTFR_Register is record
CTS : Boolean;
DSR : Boolean;
DCD : Boolean;
BUSY : Boolean;
RXFE : Boolean;
TXFF : Boolean;
RXFF : Boolean;
TXFE : Boolean;
RI : Boolean;
Reserved_9_31 : HAL.UInt23;
end record;
Read-only. Data set ready. This bit is the complement of the UART data set ready, nUARTDSR, modem status input. That is, the bit is 1 when nUARTDSR is LOW.
Read-only. Data carrier detect. This bit is the complement of the UART data carrier detect, nUARTDCD, modem status input. That is, the bit is 1 when nUARTDCD is LOW.
Read-only. UART busy. If this bit is set to 1, the UART is busy transmitting data. This bit remains set until the complete byte, including all the stop bits, has been sent from the shift register. This bit is set as soon as the transmit FIFO becomes non-empty, regardless of whether the UART is enabled or not.
Read-only. Receive FIFO empty. The meaning of this bit depends on the state of the FEN bit in the UARTLCR_H Register. If the FIFO is disabled, this bit is set when the receive holding register is empty. If the FIFO is enabled, the RXFE bit is set when the receive FIFO is empty.
Read-only. Transmit FIFO full. The meaning of this bit depends on the state of the FEN bit in the UARTLCR_H Register. If the FIFO is disabled, this bit is set when the transmit holding register is full. If the FIFO is enabled, the TXFF bit is set when the transmit FIFO is full.
Read-only. Receive FIFO full. The meaning of this bit depends on the state of the FEN bit in the UARTLCR_H Register. If the FIFO is disabled, this bit is set when the receive holding register is full. If the FIFO is enabled, the RXFF bit is set when the receive FIFO is full.
Read-only. Transmit FIFO empty. The meaning of this bit depends on the state of the FEN bit in the Line Control Register, UARTLCR_H. If the FIFO is disabled, this bit is set when the transmit holding register is empty. If the FIFO is enabled, the TXFE bit is set when the transmit FIFO is empty. This bit does not indicate if there is data in the transmit shift register.
Read-only. Ring indicator. This bit is the complement of the UART ring indicator, nUARTRI, modem status input. That is, the bit is 1 when nUARTRI is LOW.
unspecified
subtype UARTIBRD_BAUD_DIVINT_Field is HAL.UInt16;
type UARTIBRD_Register is record
BAUD_DIVINT : UARTIBRD_BAUD_DIVINT_Field := 16#0#;
Reserved_16_31 : HAL.UInt16 := 16#0#;
end record;
unspecified
type UARTICR_Register is record
RIMIC : Boolean := False;
CTSMIC : Boolean := False;
DCDMIC : Boolean := False;
DSRMIC : Boolean := False;
RXIC : Boolean := False;
TXIC : Boolean := False;
RTIC : Boolean := False;
FEIC : Boolean := False;
PEIC : Boolean := False;
BEIC : Boolean := False;
OEIC : Boolean := False;
Reserved_11_31 : HAL.UInt21 := 16#0#;
end record;
Write data bit of one shall clear (set to zero) the corresponding bit in the field. nUARTCTS modem interrupt clear. Clears the UARTCTSINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. nUARTDCD modem interrupt clear. Clears the UARTDCDINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. nUARTDSR modem interrupt clear. Clears the UARTDSRINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Receive interrupt clear. Clears the UARTRXINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Transmit interrupt clear. Clears the UARTTXINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Receive timeout interrupt clear. Clears the UARTRTINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Framing error interrupt clear. Clears the UARTFEINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Parity error interrupt clear. Clears the UARTPEINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Break error interrupt clear. Clears the UARTBEINTR interrupt.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Overrun error interrupt clear. Clears the UARTOEINTR interrupt.
unspecified
type UARTIFLS_Register is record
TXIFLSEL : UARTIFLS_TXIFLSEL_Field := 16#2#;
RXIFLSEL : UARTIFLS_RXIFLSEL_Field := 16#2#;
Reserved_6_31 : HAL.UInt26 := 16#0#;
end record;
Receive interrupt FIFO level select. The trigger points for the receive interrupt are as follows: b000 = Receive FIFO becomes >= 1 / 8 full b001 = Receive FIFO becomes >= 1 / 4 full b010 = Receive FIFO becomes >= 1 / 2 full b011 = Receive FIFO becomes >= 3 / 4 full b100 = Receive FIFO becomes >= 7 / 8 full b101-b111 = reserved.
unspecified
subtype UARTIFLS_RXIFLSEL_Field is HAL.UInt3;
subtype UARTIFLS_TXIFLSEL_Field is HAL.UInt3;
subtype UARTILPR_ILPDVSR_Field is HAL.UInt8;
type UARTILPR_Register is record
ILPDVSR : UARTILPR_ILPDVSR_Field := 16#0#;
Reserved_8_31 : HAL.UInt24 := 16#0#;
end record;
unspecified
type UARTIMSC_Register is record
RIMIM : Boolean := False;
CTSMIM : Boolean := False;
DCDMIM : Boolean := False;
DSRMIM : Boolean := False;
RXIM : Boolean := False;
TXIM : Boolean := False;
RTIM : Boolean := False;
FEIM : Boolean := False;
PEIM : Boolean := False;
BEIM : Boolean := False;
OEIM : Boolean := False;
Reserved_11_31 : HAL.UInt21 := 16#0#;
end record;
nUARTCTS modem interrupt mask. A read returns the current mask for the UARTCTSINTR interrupt. On a write of 1, the mask of the UARTCTSINTR interrupt is set. A write of 0 clears the mask.
nUARTDCD modem interrupt mask. A read returns the current mask for the UARTDCDINTR interrupt. On a write of 1, the mask of the UARTDCDINTR interrupt is set. A write of 0 clears the mask.
nUARTDSR modem interrupt mask. A read returns the current mask for the UARTDSRINTR interrupt. On a write of 1, the mask of the UARTDSRINTR interrupt is set. A write of 0 clears the mask.
Receive interrupt mask. A read returns the current mask for the UARTRXINTR interrupt. On a write of 1, the mask of the UARTRXINTR interrupt is set. A write of 0 clears the mask.
Transmit interrupt mask. A read returns the current mask for the UARTTXINTR interrupt. On a write of 1, the mask of the UARTTXINTR interrupt is set. A write of 0 clears the mask.
Receive timeout interrupt mask. A read returns the current mask for the UARTRTINTR interrupt. On a write of 1, the mask of the UARTRTINTR interrupt is set. A write of 0 clears the mask.
Framing error interrupt mask. A read returns the current mask for the UARTFEINTR interrupt. On a write of 1, the mask of the UARTFEINTR interrupt is set. A write of 0 clears the mask.
Parity error interrupt mask. A read returns the current mask for the UARTPEINTR interrupt. On a write of 1, the mask of the UARTPEINTR interrupt is set. A write of 0 clears the mask.
Break error interrupt mask. A read returns the current mask for the UARTBEINTR interrupt. On a write of 1, the mask of the UARTBEINTR interrupt is set. A write of 0 clears the mask.
Overrun error interrupt mask. A read returns the current mask for the UARTOEINTR interrupt. On a write of 1, the mask of the UARTOEINTR interrupt is set. A write of 0 clears the mask.
unspecified
type UARTLCR_H_Register is record
BRK : Boolean := False;
PEN : Boolean := False;
EPS : Boolean := False;
STP2 : Boolean := False;
FEN : Boolean := False;
WLEN : UARTLCR_H_WLEN_Field := 16#0#;
SPS : Boolean := False;
Reserved_8_31 : HAL.UInt24 := 16#0#;
end record;
Parity enable: 0 = parity is disabled and no parity bit added to the data frame 1 = parity checking and generation is enabled.
Even parity select. Controls the type of parity the UART uses during transmission and reception: 0 = odd parity. The UART generates or checks for an odd number of 1s in the data and parity bits. 1 = even parity. The UART generates or checks for an even number of 1s in the data and parity bits. This bit has no effect when the PEN bit disables parity checking and generation.
Two stop bits select. If this bit is set to 1, two stop bits are transmitted at the end of the frame. The receive logic does not check for two stop bits being received.
Enable FIFOs: 0 = FIFOs are disabled (character mode) that is, the FIFOs become 1-byte-deep holding registers 1 = transmit and receive FIFO buffers are enabled (FIFO mode).
Word length. These bits indicate the number of data bits transmitted or received in a frame as follows: b11 = 8 bits b10 = 7 bits b01 = 6 bits b00 = 5 bits.
Stick parity select. 0 = stick parity is disabled 1 = either: * if the EPS bit is 0 then the parity bit is transmitted and checked as a 1 * if the EPS bit is 1 then the parity bit is transmitted and checked as a 0. This bit has no effect when the PEN bit disables parity checking and generation.
unspecified
subtype UARTLCR_H_WLEN_Field is HAL.UInt2;
type UARTMIS_Register is record
RIMMIS : Boolean;
CTSMMIS : Boolean;
DCDMMIS : Boolean;
DSRMMIS : Boolean;
RXMIS : Boolean;
TXMIS : Boolean;
RTMIS : Boolean;
FEMIS : Boolean;
PEMIS : Boolean;
BEMIS : Boolean;
OEMIS : Boolean;
Reserved_11_31 : HAL.UInt21;
end record;
Read-only. nUARTCTS modem masked interrupt status. Returns the masked interrupt state of the UARTCTSINTR interrupt.
Read-only. nUARTDCD modem masked interrupt status. Returns the masked interrupt state of the UARTDCDINTR interrupt.
Read-only. nUARTDSR modem masked interrupt status. Returns the masked interrupt state of the UARTDSRINTR interrupt.
Read-only. Receive masked interrupt status. Returns the masked interrupt state of the UARTRXINTR interrupt.
Read-only. Transmit masked interrupt status. Returns the masked interrupt state of the UARTTXINTR interrupt.
Read-only. Receive timeout masked interrupt status. Returns the masked interrupt state of the UARTRTINTR interrupt.
Read-only. Framing error masked interrupt status. Returns the masked interrupt state of the UARTFEINTR interrupt.
Read-only. Parity error masked interrupt status. Returns the masked interrupt state of the UARTPEINTR interrupt.
Read-only. Break error masked interrupt status. Returns the masked interrupt state of the UARTBEINTR interrupt.
Read-only. Overrun error masked interrupt status. Returns the masked interrupt state of the UARTOEINTR interrupt.
unspecified
type UARTPCELLID0_Register is record
UARTPCELLID0 : UARTPCELLID0_UARTPCELLID0_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
subtype UARTPCELLID0_UARTPCELLID0_Field is HAL.UInt8;
type UARTPCELLID1_Register is record
UARTPCELLID1 : UARTPCELLID1_UARTPCELLID1_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
subtype UARTPCELLID1_UARTPCELLID1_Field is HAL.UInt8;
type UARTPCELLID2_Register is record
UARTPCELLID2 : UARTPCELLID2_UARTPCELLID2_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
subtype UARTPCELLID2_UARTPCELLID2_Field is HAL.UInt8;
type UARTPCELLID3_Register is record
UARTPCELLID3 : UARTPCELLID3_UARTPCELLID3_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
subtype UARTPCELLID3_UARTPCELLID3_Field is HAL.UInt8;
subtype UARTPERIPHID0_PARTNUMBER0_Field is HAL.UInt8;
type UARTPERIPHID0_Register is record
PARTNUMBER0 : UARTPERIPHID0_PARTNUMBER0_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
subtype UARTPERIPHID1_DESIGNER0_Field is HAL.UInt4;
subtype UARTPERIPHID1_PARTNUMBER1_Field is HAL.UInt4;
type UARTPERIPHID1_Register is record
PARTNUMBER1 : UARTPERIPHID1_PARTNUMBER1_Field;
DESIGNER0 : UARTPERIPHID1_DESIGNER0_Field;
Reserved_8_31 : HAL.UInt24;
end record;
Read-only. These bits read back as 0x1
unspecified
subtype UARTPERIPHID2_DESIGNER1_Field is HAL.UInt4;
type UARTPERIPHID2_Register is record
DESIGNER1 : UARTPERIPHID2_DESIGNER1_Field;
REVISION : UARTPERIPHID2_REVISION_Field;
Reserved_8_31 : HAL.UInt24;
end record;
Read-only. This field depends on the revision of the UART: r1p0 0x0 r1p1 0x1 r1p3 0x2 r1p4 0x2 r1p5 0x3
unspecified
subtype UARTPERIPHID2_REVISION_Field is HAL.UInt4;
subtype UARTPERIPHID3_CONFIGURATION_Field is HAL.UInt8;
type UARTPERIPHID3_Register is record
CONFIGURATION : UARTPERIPHID3_CONFIGURATION_Field;
Reserved_8_31 : HAL.UInt24;
end record;
unspecified
type UARTRIS_Register is record
RIRMIS : Boolean;
CTSRMIS : Boolean;
DCDRMIS : Boolean;
DSRRMIS : Boolean;
RXRIS : Boolean;
TXRIS : Boolean;
RTRIS : Boolean;
FERIS : Boolean;
PERIS : Boolean;
BERIS : Boolean;
OERIS : Boolean;
Reserved_11_31 : HAL.UInt21;
end record;
Read-only. nUARTCTS modem interrupt status. Returns the raw interrupt state of the UARTCTSINTR interrupt.
Read-only. nUARTDCD modem interrupt status. Returns the raw interrupt state of the UARTDCDINTR interrupt.
Read-only. nUARTDSR modem interrupt status. Returns the raw interrupt state of the UARTDSRINTR interrupt.
Read-only. Receive interrupt status. Returns the raw interrupt state of the UARTRXINTR interrupt.
Read-only. Transmit interrupt status. Returns the raw interrupt state of the UARTTXINTR interrupt.
Read-only. Receive timeout interrupt status. Returns the raw interrupt state of the UARTRTINTR interrupt. a
Read-only. Framing error interrupt status. Returns the raw interrupt state of the UARTFEINTR interrupt.
Read-only. Parity error interrupt status. Returns the raw interrupt state of the UARTPEINTR interrupt.
Read-only. Break error interrupt status. Returns the raw interrupt state of the UARTBEINTR interrupt.
Read-only. Overrun error interrupt status. Returns the raw interrupt state of the UARTOEINTR interrupt.
unspecified
type UARTRSR_Register is record
FE : Boolean := False;
PE : Boolean := False;
BE : Boolean := False;
OE : Boolean := False;
Reserved_4_31 : HAL.UInt28 := 16#0#;
end record;
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Parity error. When set to 1, it indicates that the parity of the received data character does not match the parity that the EPS and SPS bits in the Line Control Register, UARTLCR_H. This bit is cleared to 0 by a write to UARTECR. In FIFO mode, this error is associated with the character at the top of the FIFO.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Break error. This bit is set to 1 if a break condition was detected, indicating that the received data input was held LOW for longer than a full-word transmission time (defined as start, data, parity, and stop bits). This bit is cleared to 0 after a write to UARTECR. In FIFO mode, this error is associated with the character at the top of the FIFO. When a break occurs, only one 0 character is loaded into the FIFO. The next character is only enabled after the receive data input goes to a 1 (marking state) and the next valid start bit is received.
Write data bit of one shall clear (set to zero) the corresponding bit in the field. Overrun error. This bit is set to 1 if data is received and the FIFO is already full. This bit is cleared to 0 by a write to UARTECR. The FIFO contents remain valid because no more data is written when the FIFO is full, only the contents of the shift register are overwritten. The CPU must now read the data, to empty the FIFO.
unspecified