touch key lcd display card reference design...lcd displays “-----” lcd shifts to the right and...
Post on 04-Oct-2020
2 Views
Preview:
TRANSCRIPT
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 1 / 11 September 25, 2020
Touch Key LCD Display Card Reference Design
D/N: WAS-19C1EN
Introduction
Smart cards integrated with a password display function are called display cards. The display card
is turned on by entering a PIN code. This PIN code is then used along with the entered transaction
information to calculate an SHA dynamic password (TOTP) which is then displayed on an LCD
screen. This improves the security of e-banking login and reduces the possibility of transaction loss
due to phishing websites. The display card has an integrated paper battery with a capacity of
15mAH which can provide a guaranteed battery life of 3~5 years.
Figure 1
Application Areas
e-Banking, touch key LCD display cards, ultra-low power touch key + LCD products.
Solution Features
1. Ultra-low standby current: the product 1-key wake-up standby current is 130nA@3V.
The BS67F2563 includes a low frequency 32768Hz crystal oscillator circuit. Its extremely
low oscillation current allows a 1-key standby current of 130nA@3V(Typ.) for the product. It
can be used for accurate time counting combined with an internal Time Base counter.
2. High level of functional integration: only a few external components are required.
The BS67F2563 includes up to 20 internal capacitive touch keys with the touch sensitivity
adjustable by firmware to fit into different materials or media. The integrated C-type LCD
driver reduces power consumption when the LCD display is being used.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 2 / 11 September 25, 2020
3. High contrast LCD display: internal reference voltage.
The BS67F2563 includes an internal reference voltage boost function, which can be used with
the LVD to detect the battery voltage to avoid LCD grayscale display under low battery
voltage conditions.
Functional Description
The Holtek touch key LCD display card solution is mainly composed of the BS67F2563 master
MCU, a 32768Hz crystal oscillator with CL≤7pF as specified, an LCD power supply circuit and a
6-digit segment LCD panel and also reserved SIM card contact points. When the touch keys are not
touched, the display card will enter the On/Off 1-key standby state, where the current reduces to
about 130nA@3V. When the On/Off main key is touched, the LCD will display “------”,
in which condition Key 0~9, Key C and Key OK can be touched with the results being displayed
on the LCD. Touching the On/Off key again will turn off the LCD forcing it to enter the 1-key
standby state and awaiting a further wake-up. The function of the Key C is to delete the last key
code entered and shift left. The function of the Key OK is for confirmation with its current program
configuration displaying “------”. This solution only is used to provide touch key
sensitivity tuning and as a PCB design reference. A picture of the physical product is shown in
Figure 2.
Figure 2
Operating Principles
For the Holtek touch key LCD display card solution, the BS67F2563 includes an ultra-low power
LXT oscillation circuit to provide calendar timing, 13 touch keys for PIN code and a challenge code
input. It also includes a 4×12 C-type LCD panel to display the operations. The standby current for
its 1-key standby wake-up and RTC timing can be less than 130nA@3V(Typ.). This solution
provides 13 touch key inputs, reducing the cost of traditional tactile switches and the labour cost of
bounding keys. The touch key sensitivity and scan times can be adjusted using firmware and the
solution can support up to 8 digit password display solutions. The main circuit is introduced below.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 3 / 11 September 25, 2020
Hardware Description
Figure 3
The BS67F2563’s internal LXT oscillator needs to be matched with a 32768Hz crystal oscillator
with a specified CL≤7pF to achieve the optimum oscillation current. If the crystal oscillator CL is
larger, the oscillation current will increase. The oscillation frequency accuracy depends on the
crystal oscillator CL, external capacitance C3/C4 and the PCB parasitic capacitance. It is important
to pay special attention to the trace distances and sizes when laying out the PCB.
Figure 4
The provided LXT oscillator negative impedance reference requires at least 3 times the ESR
specification of the 32768Hz crystal oscillator as a safe value, to avoid oscillation problems during
mass production. These problems could be no oscillation or ceasing oscillation. This requires
special attention to be paid when choosing a particular 32768Hz crystal oscillator. The 32768Hz
crystal oscillator ESR of this solution is 65kΩ and the measured negative impedance of the
BS67F2563 is up to 500kΩ.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 4 / 11 September 25, 2020
The LXT oscillation frequency is mainly related to the 32768Hz crystal oscillator CL specification.
For example, the external C3/C4 series equivalent capacitance value plus the PCB parasitic
capacitance equal to the crystal oscillator CL can provide an accurate 32768Hz oscillation frequency.
Developers can adjust the oscillation frequency to find a suitable C3/C4 capacitance value. It is
important to pay attention to the oscillation effect of C3/C4. Choosing C3/C4 values larger than CL
will result in a slower oscillation frequency, and vice versa. Figure 5 below shows the frequency
errors for different voltages and external C3/C4 capacitors.
Note: The influence of temperature on the frequency offset of the 32768Hz crystal oscillator is not
considered here.
It should be noted that oscilloscope probes should not be used to directly touch the XT1/XT2 pin
to view the oscillation frequency during measurement. Users can view the oscillation frequency
through I/O pin output.
Figure 5
The BS67F2563 includes an integrated C-type LCD driver, which supports different LCD power
supply modes set by the LCD control register depending on the voltage of the LCD liquid crystal.
If a 3V LCD screen is chosen, users can set the LVD (Low Voltage Detection) voltage to 2.7V and
turn on the internal voltage dividing mode. When the voltage is lower than 2.7V, the internal
reference voltage (1.04V) will be turned on to provide boosting to offer a stable contrast display.
Note that the VMAX pin should be connected to the MCU’s highest voltage level. The LCD circuit
is shown in Figure 6.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 5 / 11 September 25, 2020
Figure 6
The BS67F2563 integrated capacitive touch key circuit uses PCB pads as the touch sense capacitive
inputs. Here an internal oscillation change is used to determine whether a touch action has occurred.
This solution allows a 1-key standby wake-up key to be specified, the scan times to be configured,
all keys to be scanned in the Auto Scan mode and also to tune the touch sensitivity.
Within the example program, the TKS_GLOBE_VARIES.INC is used to configure the touch keys,
the standby wake-up key and the touch sensitivity tuning.
Layout and Hardware Considerations
The external size of the display card is 85.60×53.98×0.8mm (ISO7816 standard) and the card
product has used a cold press process. Therefore, the length and width reserved for the PCB display
card should be reduced by 2mm. As the paper battery and LCD panel are components with a certain
height, the PCB should be hollowed out to reserve this height space. Also the allowed height for
related components should not exceed 0.3mm. The thickness of the PCB board including gold
immersion should not exceed 0.15mm.
Due to the limited size of the display card PCB, it is necessary to locate a suitable touch key pad.
This solution illustrates the case for placing 13 touch keys. It is recommended that the touch key
trace diameter is 6mil wide and the spacing is 5mil during layout. It is recommended during design
that only one key is scanned for each touch key module to avoid mutual key interference. Since the
thickness of the display card PCB board is 0.15mm, the front and back side grounding of the PCB
is important in order to avoid mutual key interference or interference from the back touches. Users
should refer to the PCB mesh ground design for this solution.
Developers should test the crystal oscillation frequency when designing the circuit. Select
appropriate C3 and C4 capacitors to match the oscillation frequency and take care to avoid any high
frequency circuits being placed nearby which could affect the oscillation characteristics. The
32768Hz crystal oscillator circuit should be as close as possible to the XT1 and XT2 pins and the
traces between the C3/C4 capacitors and the MCU VSS pin should be shortened.
Figure 7 and Figure 8 are the front and back PCB layout diagrams of the BS67F2563 touch key
LCD display card.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 6 / 11 September 25, 2020
Figure 7
Figure 8
PCB BOM List
Table 1
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 7 / 11 September 25, 2020
Software Description
Start
MCU initialization
Turn off LCD and enter standby mode
Touch key scan
On/Off key touched ?
LCD displays “------”
Time Base On8s overflow?
Key C touched ? Key OK touched ? Key 0~9 touched ?
LCD last digit is deleted then shift to the left LCD displays “------”
LCD shifts to the right and displays the current
digit
Y
N
Y
Y Y Y
N
N N
Touch library initialization
USER_PROGARM
Figure 9
Initialization
After initial power on, the program will first initialize user application related data, including the
system clock, WDT, LVD, KEYOSC and touch key scan configuration. Special attention should be
paid to the I/O configuration to avoid any floating I/Os which will cause the static current to increase.
Main Program
The main program will first scan the touch keys to detect whether the On/Off key is touched or not. If
touched then the LCD will be turned on and will display “------”. When any Key 0~9 is
touched, the LCD will display the first digit from the leftmost side. When the second key is touched,
the LCD display will shift to the right and display the current digit and so on. If Key C is touched, the
leftmost digit will be deleted and shifted left. If Key OK is touched, display “------”.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 8 / 11 September 25, 2020
After each touch key operation is finished, a time base counter is turned on to initiate an 8 second time
period. If there is no operation within 8 seconds, the LCD will be turned off and it will enter the ultra-
low power standby mode. In addition to the above operations, if it is already in the On state, touching
the On/Off key again will turn off the LCD forcing it to enter the ultra-low power standby mode.
Touch Software Package Description
To implement the touch key function, the Holtek touch software package should be used. This
software package is a complete HT-IDE3000 project, which has integrated a basic program structure
(MAIN_PROGRAM.asm) and reserves a user initialization program (USER_PROGRAM_INITIAL)
and a user main program (USER_PROGRAM). The software package will call the user initialization
program once during the power on initialization process and repeatedly call the user main program
during normal operation. For further use and modification of the software package, contact Holtek’s
and Bestsolution’s technical staff.
File Structure and Description
The software package contains two types of files:
1. ASM/.C application programs.
2. Files required for .INC/.H & .INI include. “.INI” is an underlying parameter file which is
recommended not to be modified.
The software package contains four parts, main program (MAIN_PROGRAM.asm), touch program
(BS67F2563_CTOUCH.INI), LCD driver (wizcard.c) and user program (USER_PROGRAM.c), as
shown in Figure 10.
MAIN_PROGRAM.asm MAIN_PROGRAM.inc TKS_GLOBE_VARIES.inc
BS67F2563_CTOUCH.INI
wizcard.c
USER_PROGRAM.c
include include
Figure 10
As the touch program adopts a library method, the corresponding program library
BS67F2563_CTOUCH_V600.OBJ needs to be loaded to implement the touch function. The
parameter settings of the related functions are setup in TKS_GLOBE_VARIES.inc.
BS67F2563_CTOUCH_V600.OBJ TKS_GLOBE_VARIES.incinclude
Figure 11
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 9 / 11 September 25, 2020
The library provides touch key related parameter settings whose details are as follows:
Parameter Name Function Value Range Recommended Value
SystemClock System frequency selection
0=4MHz 1=8MHz 2=12MHz
0
DebounceTimes Debounce times 0~15 2
AutoCalibrationPeriod Auto calibration period setting 0~15 4~8
HighSensitive High sensitivity setting 0=Off; 1=On 0 MaximumKeyHoldTime Maximum key hold time 0~15 1 (4 seconds) FastResponse Fast response setting 0=Off; 1=On 0
AutoFrequencyHopping Auto frequency hopping setting 0=Off; 1=On 1
OneKeyActive 1 key or all keys active 0=All keys active 1=One key active
1
PowerSave Low power setting 0=Off; 1=Low power 1 NoiseProtect Noise protection setting 0=Off; 1=On 1
MovingCalibration Dynamic calibration setting 0=Static; 1=Dynamic 1
MainFrequency KEYOSC frequency setting
0=1MHz 1=3MHz 2=7MHz 3=11MHz
1
HaltTouchScanRate Touch key scan rate setting
0=64ms 1=128ms 2=256ms 3=512ms
2
KeyNThreshold Trigger threshold 10~64 The smaller the value, the more sensitive.
Refer to the Operating Description chapter.
IO_TOUCH_ATTR Touch key selection 0=Off; 1=On Select according to actual application requirements.
WAKEUP_ATTR Wake-up key selection 0=Off; 1=On Select according to actual application requirements.
Table 2
Considerations for Use
1. The touch parameters listed in Table 2 can be adjusted in TKS_GLOBE_VARIES.INC.
2. The main parameters that affect the battery life of the product include SystemClock, PowerSave,
MainFrequency and HaltTouchScanRate, etc. Users should properly configure these parameters
according to their requirements.
3. Since the software package adopts a time-shared multi-work scheme, the touch response will be
delayed if the user program is executed for too long a time. It is recommended that the execution
time of the USER_PROGRAM does not exceed 10ms.
Used Resources
The used RAM and ROM sources are as follows. ROM Total Size : 16384 [4000h] Total Used : 2606 [0A2Eh] Total Remain : 13778 [35D2h] Total Percentage : 15% RAM Total Size : 2304 [0900h] Total Used : 247 [00F7h]
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 10 / 11 September 25, 2020
Operating Description
This solution provides functions for touch key sensitivity configuration, malfunction test,
measurement for 1-key wake-up standby current and scan current.
Touch Key Sensitivity Configuration and Malfunction Test The trigger threshold of each touch key can be configured in the program to adjust the touch
sensitivity.
1. If the thickness of the PCB board is 0.4mm, the recommended trigger threshold (KeynThreshold)
is “32”.
2. If the thickness of the PCB board is 0.15mm, the recommended trigger threshold (KeynThreshold)
is “16”.
In display card applications, due to factors such as the PCB board, a too high trigger threshold
configuration could cause poor sensitivity while a too low configuration will make the product too
sensitive and therefore easy to malfunction. Developers need to pay special attention to these areas
during debugging.
The PCB front and back sides adopt mesh grounding for isolation to avoid accidental touch or
interference. Users can use a key or other metal to test malfunctions.
Test Data
Current Measurement
In this solution, the system frequency is set to 4MHz and the touch key oscillator frequency is set to
3MHz. It has also distinguished between the 1-key standby wake-up current and the all touch key
scanned current. As the standby current of the ultra-low power series of MCU is extremely small, it is
recommended to use the KEYSIGHT 34461A 61/2 ammeter when conducting measurements to avoid
measurement errors. Refer to Table 3.
Test Item Test Condition VDD Specification Measured Value
ISTB In the standby mode, scan the touch key every 256ms 3V Typ. = 200nA
Max. = 250nA 127nA
IDD Under normal operation 3V N/A 695µA
Table 3
Note: The values are measured using the KEYSIGHT 34461A 61/2 ammeter.
Conclusion
This text has used the BS67F2563 MCU to introduce the Holtek touch key LCD display card
solution. The BS67F2563 provides an excellent ultra-low 1-key standby current of 127nA@3V,
allowing for a battery life as long as 3~5 years. The integrated touch keys and C-type LCD driver
circuits in the BS67F2563 further reduce the cost of the solution, making it very suitable for battery
applications such as display cards.
Touch Key LCD Display Card Reference Design
WAS-19C1EN V1.00 11 / 11 September 25, 2020
Reference Material
Reference file: BS67F2563 Datasheet.
For more information, refer to the Holtek official website: www.holtek.com.
Versions and Modification Information
Date Author Issue 2020.06.03 黃啓德 V1.00
Disclaimer
All information, trademarks, logos, graphics, videos, audio clips, links and other items appearing
on this website ('Information') are for reference only and is subject to change at any time without
prior notice and at the discretion of Holtek Semiconductor Inc. and its related companies
(hereinafter 'Holtek', 'the company', 'us', 'we' or 'our'). Whilst Holtek endeavors to ensure the
accuracy of the Information on this website, no express or implied warranty is given by Holtek to
the accuracy of the Information. Holtek will bear no responsibility for any incorrectness or leakage.
Holtek shall not be liable for any damages (including but not limited to computer virus, system
problems or data loss) whatsoever arising in using or in connection with the use of this website by
any party. There may be links in this area, which allow you to visit the websites of other companies.
These websites are not controlled by Holtek. Holtek will bear no responsibility and no guarantee to
whatsoever Information displayed at such sites. Hyperlinks to other websites are at your own risk.
Limitation of Liability
In any case, the Company has no need to take responsibility for any loss or damage caused when
anyone visits the website directly or indirectly and uses the contents, information or service on the
website.
Governing Law
This disclaimer is subjected to the laws of the Republic of China and under the jurisdiction of the
Court of the Republic of China.
Update of Disclaimer
Holtek reserves the right to update the Disclaimer at any time with or without prior notice, all
changes are effective immediately upon posting to the website.
top related