Title: Language Detecting Keyboard with LCD Touch Screen Interface
1Language Detecting Keyboard with LCD Touch Screen
Interface
- Joon Sang Ryu
- Si Hyung Lee
- Sung Hwan Kim
2Introduction
- Create a keyboard that displays corresponding
language on LCD screen - Integration of Touch Screen as keyboard.
3Benefits
- No need to memorize the keys of multiple
languages - Easier for new users to adapt to keyboard
- Visually more appealing than existing keyboards
4Features
- Touch Screen Keyboard
- Automatic Language Detection
- English / Korean keyboard configuration display
- Expandable to Any Desired Languages
5Overall System
6System Components
- Hardware
- Microprocessor (PIC16F877A)
- FPGA Board (Altera DE2)
- 17.1 Touch Screen
- 17.1 LCD Monitor
- Bilateral Switch (CD4016CN)
- Software
- Visual C/C
- Quartus II VHDL/Verilog
- Matlab
7Block Diagram
8LangID Detection
- GetUserDefaultLangID( )
- Function from MSDN Library
- Returns LangID
- English gt 1033
- Korean gt 1042
- LangID can be Changed in Control Panel
- Detection is Run by Infinite Loop
- 100 ms (0.1 s) Interval Between Each Loop
9C Code
10(No Transcript)
11Transmitting Via RS232
- Detect LangID from C code
- Connects to MatLab Code through langtemp.txt
- Transmit Data to FPGA
- 00000000 if English
- 1 1 1 1 1 1 1 1 if Korean
12RS232 Communication
- Data Transmission Begins at (1)
- Signal No Longer IDLE
- Transmits 8-Bit Data (2)
- Stop Bit Terminates Communication
- Signal Back to IDLE
13RS232 Port Setting
- Port
- COM1
- RS232 Bits (10 Bits)
- 1 Start Bit
- 8 Data Bits
- 1 Stop Bit
- No Parity Bit
- Baudrate
- 115200 bps
14MatLab Code
15Keyboard Graphic Controller
RS-232 signal graphic controller
17.1 LCD Touch Screen Keyboard Display
16FPGA Board (Altera DE2)
VGA port (board -gt keyboard display)
RS-232 port (computer -gt board)
17RS-232 Graphic Controller
18RS-232 Graphic Controller
50MHz
On-board asynchronous reset
19RS-232 Graphic Controller
50MHz -gt 25MHz
20RS-232 Graphic Controller
RS-232 serial input
21RS-232 Graphic Controller
RS-232 receiver
22RS-232 UART
- Synchronizes FPGA board CLK with asynchronous
serial input - Converts 10-bit serial input to 10-bit parallel
output. - Sends out 8-bit parallel data bits with 1bit
data_ready signal to indicate receiving RS-232
signal is done.
23RS-232 UART
RS-232 serial input
Oversampling
State Machine
Shift Register
8-bit parallel data bits out data_ready
24RS-232 UART
RS-232 serial input
We oversample the incoming data at higher
rates than the known baud rate. This is to
determine when the new data enter with the start
bit. When we detect a new start bit, we sample
at the known baud rate again.
Oversampling
State Machine
Shift Register
8-bit parallel data bits out data_ready
25RS-232 UART
RS-232 serial input
We oversample the incoming data at higher
rates than the known baud rate. This is to
determine when the new data enter with the start
bit. When we detect a new start bit, we sample
at the known baud rate again.
Oversampling
We go over 11 states (Idle, start-bit,
data-bit0,1,2,3,4,5,6,7, and stop bit)
State Machine
Shift Register
8-bit parallel data bits out data_ready
26RS-232 UART
RS-232 serial input
We oversample the incoming data at higher
rates than the known baud rate. This is to
determine when the new data enter with the start
bit. When we detect a new start bit, we sample
at the known baud rate again.
Oversampling
We go over 11 states (Idle, start-bit,
data-bit0,1,2,3,4,5,6,7, and stop bit)
State Machine
Every time when we detect new data bits
through states, we save them into the shift
register.
Shift Register
8-bit parallel data bits out data_ready
27RS-232 Graphic Controller
8-bit data saving register langID decision
maker
28RS-232 Graphic Controller
VGA controller Color Mapper
29Color Mapper
- When decision is 0 (00000000 received for
English from UART_RXD), we map English key
configuration. - When decision is 1 (11111111 received for
Korean from UART_RXD), we map Korean key
configuration.
30Test Results
English Key Configuration Display
Korean Key Configuration Display
31Delay Test
32Improvements
- We can always add more languages.
- We can use thinner, lighter LCD display which can
hold independent power source. - We can replace the FPGA board with smaller
microcontroller chips.
33Touch Screen Circuit
- Simple Voltage Divider at Intersection
- Analog Signal Output at Port
34Touch Screen Controller
35Touch Screen Controller Delay (Total)
Analog Input
1.4 sec Delay
Digital Output
36Bilateral Switch
37Bilateral Switch CD4016CN
38A/D Converter
X
Y
39A/D Converter Delay
Analog Input
200ms Delay
Digital Output
40Coordinate Control
- PortB Digital Y coordinate Input
- PortC Digital X coordinate Input
- RD0, RD1 Controlling Touch screen ends.
- RD3 Data Line
41Coordinate Control Procedure
- Digital output range for Y 59 lt Y lt 160
- Range outside above used for touch detect.
Columns
1 2 3 4 5 6 7
1st Row 159-140
2nd Row 139-120
3rd Row 119-100
4th Row 99-80
5th Row 79-60
42Coordinate Control Button is
Make and Break 0E 0000 1110 F0 1111 0000 0E
0000 1110
001110000010000011111100111000001
43Coordinate Control Button is
H
Make and Break 33 0011 0011 F0 1111 0000 33
0011 0011
011001100110000011111101100110011
44Coordinate Control Button is
BKSP
Make and Break 66 0110 0110 F0 1111 0000 66
0110 0110
001100110110000011111100110011011
45Coordinate Control Delay
Analog Input
900 ms Delay
Digital Output
46Conclusion on Touchpad Controller
- Touch controller is able to send PS/2 signal. If
synchronized with the right clock, can be used as
a normal keyboard. - Delay mostly in control PIC
- Reason too many loops (ex else if)
- Total of 4 loops including the following
- While 1
- If for touch detection
- If/else if for comparing rows
- If/else if for comparing columns
47Future Possible Improvements
- Reducing delay to actually use the product as
everyday keyboard - Optimizing control PIC code
- Replacing PIC with better processor (RAM and ROM)
48Comments and Questions