\n
address_offset : 0x0 Bytes (0x0)
size : 0x20 byte (0x0)
mem_usage : registers
protection : not protected
PS/2 Control Register
address_offset : 0x0 Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
PS2EN : PS/2 Device Enable Bit\nEnable PS/2 device controller.\n
bits : 0 - 0 (1 bit)
access : read-write
Enumeration:
#0 : 0
Disabled
#1 : 1
Enabled
End of enumeration elements list.
TXIEN : Transmit Interrupt Enable Bit\n
bits : 1 - 1 (1 bit)
access : read-write
Enumeration:
#0 : 0
Data transmit complete interrupt Disabled
#1 : 1
Data transmit complete interrupt Enabled
End of enumeration elements list.
RXIEN : Receive Interrupt Enable Bit\n
bits : 2 - 2 (1 bit)
access : read-write
Enumeration:
#0 : 0
Data receive complete interrupt Disabled
#1 : 1
Data receive complete interrupt Enabled
End of enumeration elements list.
TXFDEPTH : Transmit Data FIFO Depth\nThere is 16-byte buffer for data transmit. Software can define the FIFO depth from 1 to 16 bytes depending on the application.\n
bits : 3 - 6 (4 bit)
access : read-write
Enumeration:
0 : 0
1 byte
1 : 1
2 bytes
14 : 14
15 bytes
15 : 15
16 bytes
End of enumeration elements list.
ACK : Acknowledge Enable Bit\n
bits : 7 - 7 (1 bit)
access : read-write
Enumeration:
#0 : 0
Always sends acknowledge to host at 12th clock for host to device communication
#1 : 1
If parity error or stop bit is not received correctly, acknowledge bit will not be sent to host at 12th clock
End of enumeration elements list.
CLRFIFO : Clear TX FIFO\nWrite 1 to this bit to terminate device to host transmission. The TXEMPTY(PS2_STATUS[7]) bit will be set to 1 and pointer BYTEIDEX(PS2_STATUS[11:8]) is reset to 0 regardless there is residue data in buffer or not. The buffer content is not been cleared.\n
bits : 8 - 8 (1 bit)
access : read-write
Enumeration:
#0 : 0
Not active
#1 : 1
Clear FIFO
End of enumeration elements list.
OVERRIDE : Software Override PS/2 CLK/DATA Pin State\n
bits : 9 - 9 (1 bit)
access : read-write
Enumeration:
#0 : 0
CLKSTAT and DATSTAT pins are controlled by internal state machine
#1 : 1
CLKSTAT and DATSTAT pins are controlled by software
End of enumeration elements list.
FPS2CLK : Force CLKSTAT Line\nIt forces CLKSTAT line high or low regardless of the internal state of the device controller if OVERRIDE is set to high.\n
bits : 10 - 10 (1 bit)
access : read-write
Enumeration:
#0 : 0
Force CLKSTAT line low
#1 : 1
Force CLKSTAT line high
End of enumeration elements list.
FPS2DAT : Force DATSTAT Line\nIt forces DATSTAT high or low regardless of the internal state of the device controller if OVERRIDE is set to high.\n
bits : 11 - 11 (1 bit)
access : read-write
Enumeration:
#0 : 0
Force DATSTAT low
#1 : 1
Force DATSTAT high
End of enumeration elements list.
PS/2 Transmit DATA Register 3
address_offset : 0x10 Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
PS/2 Receive DATA Register
address_offset : 0x14 Bytes (0x0)
access : read-only
reset_value : 0x0
reset_Mask : 0x0
DAT : Received Data
For host to device communication, after acknowledge bit is sent, the received data is copied from receive shift register to PS2_RXDAT register. CPU must read this register before next byte reception complete otherwise, the data will be overwritten and RXOV(PS2_STATUS[6]) bit will be set to 1.
bits : 0 - 7 (8 bit)
access : read-only
PS/2 Status Register
address_offset : 0x18 Bytes (0x0)
size : -1 bit
access : read-write
reset_value : 0x0
reset_Mask : 0x0
CLKSTAT : CLK Pin State\nThis bit reflects the status of the CLKSTAT line after synchronizing.
bits : 0 - 0 (1 bit)
access : read-write
DATSTAT : DATA Pin State\nThis bit reflects the status of the DATSTAT line after synchronizing and sampling.
bits : 1 - 1 (1 bit)
access : read-write
FRAMEERR : Frame Error
For host to device communication, if STOP bit (logic 1) is not received it is a frame error. If frame error occurs, DATA line may keep at low state after 12th clock. At this moment, software overrides CLKSTAT to send clock till DATSTAT release to high state. After that, device sends a Resend command to host.
Note: Write 1 to clear this bit.
bits : 2 - 2 (1 bit)
access : read-write
Enumeration:
#0 : 0
No frame error
#1 : 1
Frame error occurred
End of enumeration elements list.
RXPARITY : Received Parity\nThis bit reflects the parity bit for the last received data byte (odd parity).\nNote: This bit is read only.
bits : 3 - 3 (1 bit)
access : read-write
RXBUSY : Receive Busy\nThis bit indicates that the PS/2 device is currently receiving data.\nNote: This bit is read only.
bits : 4 - 4 (1 bit)
access : read-write
Enumeration:
#0 : 0
Idle
#1 : 1
Currently receiving data
End of enumeration elements list.
TXBUSY : Transmit Busy\nThis bit indicates that the PS/2 device is currently sending data.\nNote: This bit is read only.
bits : 5 - 5 (1 bit)
access : read-write
Enumeration:
#0 : 0
Idle
#1 : 1
Currently sending data
End of enumeration elements list.
RXOV : RX Buffer Overwrite\nNote: Write 1 to clear this bit.
bits : 6 - 6 (1 bit)
access : read-write
Enumeration:
#0 : 0
No overwrite
#1 : 1
Data in PS2_RXDAT register is overwritten by new received data
End of enumeration elements list.
TXEMPTY : TX FIFO Empty\nWhen software writes any data to PS2_TXDAT0-3 the TXEMPTY bit is cleared to 0 immediately if PS2EN is enabled. When transmitted data byte number is equal to FIFODEPTH then TXEMPTY bit is set to 1.\nNote: This bit is read only.
bits : 7 - 7 (1 bit)
access : read-write
Enumeration:
#0 : 0
There is data to be transmitted
#1 : 1
FIFO is empty
End of enumeration elements list.
BYTEIDX : Byte Index\n
bits : 8 - 11 (4 bit)
access : read-write
PS/2 Interrupt Status Register
address_offset : 0x1C Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
RXIF : Receive Interrupt\nThis bit is set to 1 when acknowledge bit is sent for Host to device communication. Interrupt occurs if RXIEN(PS2_CTL[2]) bit is set to 1.\nNote: Write 1 to clear this bit to 0.
bits : 0 - 0 (1 bit)
access : read-write
Enumeration:
#0 : 0
No interrupt
#1 : 1
Receive interrupt occurred
End of enumeration elements list.
TXIF : Transmit Interrupt\nThis bit is set to 1 after STOP bit is transmitted. Interrupt occurs if TXIEN(PS2_CTL[1]) bit is set to 1.\nNote: Write 1 to clear this bit to 0.
bits : 1 - 1 (1 bit)
access : read-write
Enumeration:
#0 : 0
No interrupt
#1 : 1
Transmit interrupt occurred
End of enumeration elements list.
PS/2 Transmit DATA Register 0
address_offset : 0x4 Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
DAT : Transmit Data\nWrite data to this register starts device to host communication if bus is in IDLE state. Software must enable PS2EN(PS2_CTL[0]) before writing data to TX buffer.
bits : 0 - 31 (32 bit)
access : read-write
PS/2 Transmit DATA Register 1
address_offset : 0x8 Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
PS/2 Transmit DATA Register 2
address_offset : 0xC Bytes (0x0)
access : read-write
reset_value : 0x0
reset_Mask : 0x0
Is something missing? Is something wrong? can you help correct it ? Please contact us at info@chipselect.org !
This website is sponsored by Embeetle, an IDE designed from scratch for embedded software developers.