Home

Dot-Matrix LCD Units (with built

image

Contents

1. HIGH ORDER 4 BIT LOW 0000 10010 0011 0100 0101 0110 0111 1010 1011 1100 1101 111101111 ORDER 4 BIT CG pan er OE e nuns coo xxxx0000 EUN PU orc 1 0 CU Y xoxo O t2 MESE xxxotot 09 251 15515 O tip RECTO E mo am xxxx01 1 1 8 A 111 1 1 T t Hec 01 1911412111 11521232 Ee ub 010 9 ed um 202 ibi 91413 x op EIS 01 m I EL E Lo m eR EE m NOTES 1 The CG RAM generates character patterns in accordance with the user s program 2 Shaded areas indicate 5 x 10 dot character patterns 8 Display Unit User s Manual SHARP Table 5 Character Codes Dot Matrix LCD Units High Order Low 4 bit 10000 0010 0011 0100 0101 0110 0111 1010 1011 1100 1101 1110 1111 Order 4 bit xxxx0000 RAM 0 Q P p 8 sla 1 xxxx0001 0 7 1 A fa 715 BENE 0010 19 1 12 EIE 0011 4 3 8 5 Jv gt eg xxxx0100 5 4 D T d t x a S 0101 6 5 E Uje u a 2 o 0110 0 8
2. it A HEX HEX Digit Digit Example DD RAM address 4E acou A 2 4 The address of the display data RAM corre sponds to the display position on the LCD panel as follows Display Unit User s Manual Dot Matrix LCD Units a Address type a For dual line display Display Position Digit 1 2 3 4 5 6 7 8 9 39 40 ine fixes nosso DD RAM Address HEX When a display shift takes place the addresses shift is as follows Left 01 024 034 044 05 06 07 08 09 E 274 00 Shift 141 142 43 446 45 464 47 484494 67 404 Right 27 00 01 02 08 04 05 06 107 25 26 Shift 67 40 141 4 42 43 44 45 46 147 656 66 The addresses for the second line are not con tinuous to the addresses for the first line A 40 char acter RAM area is assigned to each of the two line as follows line 1 00H 27H line 2 40H 67H For an LCD unit with a display capacity of less than 40 characters per line characters equal in number to the display capacity as counted from display position 1 are displayed b Address type 6 For single line display with logically dual line addressing Digit Display Position 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 DD RAM Address HEX When a display shift takes place the addresses shift as follows iA The right hand eight characters for the purposes of
3. LCD UNIT 2 0 NOTE Ground S type 5 V Depends on particular LCD unit model refer to device specifications LCD27 34 Figure 11 Contrast Adjustment Circuit Sample Instruction Procedures 1 8 Bit Data Transfer with a Single Line 16 Char acter Display Using Internal Reset Table 13 shows a sample operating procedure for an LCD unit in this mode Initially the function of the LCD unit must be selected by executing the function set instruction Up to 80 characters may be stored in the display data RAM and may be displayed by using the display shift operation The contents of the display data RAM are not affected by the display shift operation and the display cursor home instruction enables the res toration of the initial display position 24 SHARP 4 Bit Microprocessor The LCD unit can be connected to the I O port of a 4 bit microprocessor If the I O port is not limited 8 bit data may be transferred between the devices Otherwise 4 bit split data may be transferred in two operations after selecting the 4 bit data length function For the timing wave form see Figure 9 Figure 10 shows a sample connection to an SM 200 microprocessor It should be noted that the busy flag check requires a two step operation 8 Bit Data Transfer with a Dual Line 16 Charac ter Display Using Internal Reset Table 15 shows a sample operating procedure for an LCD unit in this mode The
4. DR or CG RAM DR Display Unit User s Manual SHARP Busy Flag BF When the busy flag is set at logical 1 the LCD unit is executing an internal operation and no in struction will be accepted The state of the busy flag is output on data line DB7 in response to the register selection signals RS 0 R W 1 as shown in Table 3 The next instruction may be entered after the busy flag is reset to logical 0 Address Counter AC The address counter generates the address for the display data RAM and character generator RAM When the address set instruction is written into the instruction register the address information is sentto the address counter The same instruciton also determines which of the two RAM s is to be selected After data has been written to or read from the display data RAM or character generator RAM the address counter is automatically incremented or decremented by one The contents of the address counter are output on data lines DBo DBe in response to the register selection signals RS 0 R W 1 as shown in Table 3 Display Data RAM DD RAM This 80 x 8 bit RAM stores up to 80 8 bit character codes as display data The unused area of the RAM may be used by the microprocessor as a general purpose RAM area The display data RAM address set in the address counter is expressed in hexadecimal HEX num bers as follows High order bits Lower order its
5. Single line display F 20 5 7 dot matrix character font 12 SHARP Display ON OFF Control D 0 Display OFF C 0 Cursor OFF B 0 Blink function OFF Entry Mode Set D 1 Increment Mode S 20 Display shift OFF CAUTION If the power conditions stated in Table 11 Power condi tions applicable when internal reset circuit is used are not satisfied then internal reset circuit will not operate properly and the LCD unit will not be initalized In this case the initialization procedure must be executed by the external microprocessor Display Unit User s Manual SHARP Dot Matrix LCD Units Initialization by Instructions If the power conditions for the normal operation of the internal reset circuit are not satisfied see Table 11 then LCD unit must be initialized by executing a series of instructions The procedure for this initialization process is as follows Wait 15 ms or more after reaches 4 5 V RS R W DB DB DB DB DB 00 0 0 1 1 Wait 4 1 ms or more RS R W DB DBg DB DB 00 00 1 14 s Busy flag can t be checked before execution of this instruction Function Set 8 Bit Interface Busy flag can t be checked before execution of this instruction Function Set 8 Bit Interface Wait 100 us or more RS R W DB DBg DB DB DB DB 00 00 1 1 Busy flag can t be checked before execution of this
6. 6 0111 8 7 G Wi sg w RB 1000 0 8 H X h x 2 J 4 X xxxx1001 2 9 I Y i y 5 J E y xxxx1010 3 J Z j 7 3 S v j xxxx1011 10 c vc 1100 9 lt e 41917191 1101 6 m gt P xxxx1110 7 gt N A n 3 OIF 1111 8 210 gt 9 a Display Unit User s Manual Dot Matrix LCD Units Table 6 Relationship Among Character Code DD RAM CG RAM Address and Character Pattern CG RAM SHARP NOTES 1 Character code bits 0 2 correspond to CG RAM address bits 3 5 Each of the 8 unique bit strings designates one of the 8 Character Code DD RAM Data 76543210 CG RAM Address 543210 Character Pattern CG RAM Data 76543210 High order Low order High order Low order High order Low order bit bit bit bit bit bit a ER i T 000 00 1 1 00 0 1 010 110 0 0 1 0000 000 0 00 0 1 1 ERE 100 4 0 1 0 0 101 11 0 0 1 0 110 moo 22 200000 000 1 0 0 0 1 0 0 1 iaia 0000 001 0011011 0 01110 0 100 0 1 0 0 110 00 1 0 0 111 x 4189 00 0 i000 EP character patterns cursor status ON OFF Accordingly if the cursor is to be used CG RAM data for the 8th row shou
7. TX Ph 512 349 7262 Fax 512 349 7002 DFW Airport TX Ph 972 456 8560 Fax 972 456 0360 Houston TX Ph 281 955 9909 Fax 281 955 9910 East Burlington MA Ph 781 270 7979 Fax 781 229 9117 Annandale NJ Ph 908 713 0505 Fax 908 713 0312 Research Triangle Park NC Ph 919 941 0065 Fax 919 941 0066 Ph 310 563 2355 Fax 310 563 2514 Future Electronics Canada Ph 514 694 7710 Fax 514 695 3707 Marshall Industries El Monte CA Ph 800 522 0084 Fax 818 307 6173 www marshall com Reptron Tampa FL Ph 800 659 1361 Fax 813 854 4695 Sterling Electronics Corp Houston TX Ph 800 745 5500 Fax 713 629 3939 SHARP Ref SMT99007
8. 20H The address counter is reset to zero If the display has been shifted the original position is restored By execution of this instruction the dis play goes off and the cursor and character blink functions if activated are moved to the upper left most display position Display Cursor Home RS RWDB cove o Jo lo o 15161511 NOTE Don t Care The address counter is reset to zero If the dis play has been shifted the original position is re stored The content of the DD RAM is not affected The cursor and character blink functions if acti vated are moved to the upper leftmost display position Entry Mode Set RS RW DB DB o o o o I D The address counter is incremented I D 1 decremented I D 0 by one following the reading or writing of each display data RAM character code The cursor and character blink functions move one display position to the right I D 1 or left I D 0 The same operation takes place when data is written to or read from the character generator RAM S When S 1 the entire display is shifted one position to the left I D 1 or right I D 0 following the writing of a display data RAM character code The cursor and character blink functions do not move relative to the display position When S 0 the display is not shifted The display is not shifted when writing data to the character generator R
9. In no event will Sharp be liable or in any way responsible for any incidental or consequential economic or property damage The above warranty is also extended to Customers of Sharp authorized distributors with the following exception reports of failures of Products during the warranty period and return of Products that were purchased from an authorized distributor must be made through the distributor In case Sharp is unable to repair or replace such Products refunds will be issued to the distributor in the amount of distributor cost SHARP reserves the right to make changes in specifications at any time and without notice SHARP does not assume any responsibility for the use of any circuitry described no circuit patent licenses are implied 1999 SHARP Microelectronics of the Americas Printed in the USA SHARP Contents PREFACE FEATURES OVERVIEW HARDWARE 2 RUP RUE eee Interface Signals Functional Blocks Microprocessor Interface Reset Function INSTRUCTIONS General Information Description of Instruction ELECTRICAL CHARACTERISTICS Absolute Maximum Ratings Electrical Characteristics Timing Characteristics Power Conditions for Internal Reset LCD UNIT USAGE INSTRUCTIONS Interface with External Microprocessor Contrast Control Volta
10. LCD27 37 Table 16 NO OPERATION RESTRICTION 1 Execution of the display clear or display cursor home The display cursor home instruction should be executed after the defective instruction instruction when the display has been shifted from its but after a time interval not equal to any multiple of 400 fosc KHz seconds original position Since fosc 250 kHz the following timing intervals should be avoided 1 6 seconds 3 2 seconds 4 8 seconds etc 2 Execution ofthe In the case of address type a when DD Before executing the display cursor home instruction the data in the four address display cursor RAM address locations 43 47 4B and locations in question should be saved elsewhere by the microprocessor After home instruction 4F use execution of the display cursor home instruction the data may be restored to the DD In the case of address types b and c RAM when DD RAM address locations 23 27 63 and 67 are in use Display Unit User s Manual 29 SHARP Microelectronics of the Americas Corporation Regional Sales Offices Distributors North American Headquarters Bell Milgray El Segundo CA Camas WA Ph 360 834 2500 Fax 360 834 8903 West Huntington Beach CA Ph 714 903 4600 Fax 714 903 0295 San Jose CA Ph 408 436 4900 Fax 408 436 0924 Central Romeoville IL Ph 630 226 2400 Fax 630 759 8572 Auburn Hills Ph 248 377 9220 Fax 248 377 9222 Austin
11. cursor is automatically moved from the first line to the second line after column 40 of the first line has been written Inthe example Table 15 where only 16 characters are displayed on each line the display data RAM address must be reset after the 16th character has been written When a display shift is executed both lines are shifted simultaneously When the diplay shift operation is repeated characters on one line are not moved to the other line but rather are looped back onto the same line NOTE To use the internal reset function the power conditions must be satisfied Otherwise the LCD unit must be initialized by the execution of a series of instructions as shown in the Initialization by Instructions section Display Unit User s Manual SHARP Dot Matrix LCD Units Table 13 8 Bit Data Transfer with a Single Line 16 Character Display Using Internal Reset NO INSTRUCTION DISPLAY OPERATION 1 Power ON The LCD unit is initialized No display intemal reset circuit is triggered 2 Function Set DS R W DB DBo 00001100 Set for 8 bit data transfer and address type a 3 Display ON OFF 00000001110 Turn on the display and cursor After initialization the DD RAM is filled with the space code 4 Entry Mode Set 0000000110 Set the LCD unit to increment the address counter and shift the cursor to the right after each data transaction The display does not shift 5 CGRAM DD RAM
12. instruction Function Set 8 Bit Interface a Busy flag can be checked after the following instructions are completed If the busy flag is not going to be checked then a wait time longer than the total execution time of these instructions is required See Table 7 RS R W DB DBs DB DB 0 0 N F Function Set E Interface Caution At this point Single Dual Line the display format 0 0 1 Display Off Display Display Font an t be changed 0 0 0 Display Clear 0 0 Entry Mode Set End of Initialization LCD21 10 Figure 3 8 Bit Interface Display Unit User s Manual 13 Dot Matrix LCD Units SHARP 4 Bit Interface Wait 15 ms or more after Vpp reaches 4 5 V RS R W DB DBg DBs DB 0 4 de 0 1 4 Wait 4 1 ms or more RS R W DB DBg DBs DB 0000 1 1 Wait 100 us or more RS R W DB DBg DBs DB 0 00 0 1 1 Busy flag can t be checked before execution of this instruction Function Set 8 Bit Interface Busy flag can t be checked before execution of this instruction Function Set 8 Bit Interface Busy flag can t be checked before execution of this instruction Function Set 8 Bit Interface a Busy flag can be checked after the following instructions are completed If the busy flag is not going to be checked then a wait time longer than the total execution time of these instructions is required See Table 7 RS R W DB DBg DBs DB
13. or fosc 250 kHz Display Clear 0 0 0 0 0 0 0 0 0 1 Clear enter display area restore display from 1 64 ms shift and load address counter with DD RAM address 0 Display Cursor 0 0 0 0 0 0 0 0 1 Restore display from shift and load address 1 64 ms Home counter with DD RAM address 0 Entry Mode 0 0 0 0 0 0 0 1 10 S Specify cursor advance direction and display 40 us Set shift mode This operation takes place after each data transfer Display ON OFF 0 0 0 0 0 0 1 C B Specify activation of display D cursor C 40 us and blinking of character at cursor position B Display Cursor 0 0 0 0 0 1 S C R L z Shift display or move cursor 40 us Shift Function Set 0 0 0 0 1 DL N 0 Set interface data length DL and number of 40 us display lines N CG RAM 0 0 0 1 Acc Load the address counter with a CG RAM 40 us Address Set address Subsequent data is CG RAM data DD RAM 0 0 1 App Load the address counter with a DD RAM 40 us Address Set address Subsequent data is DD RAM data Busy 0 1 BF AC Read busy flag BF and contents of address 0 us Flag Address counter AC Counter Read CG RAMIDD 1 0 Write data Write data to CG RAM or DD RAM 40 us RAM Data Write CG 1 1 Read data Read data from CG RAM or DD RAM 40 us RAM Data Read I D 1 Increment I D 0 Decrement DD RAM Display Data RAM 5 1 Display Shift On CG RAM Character Generator RAM S C 1 Shift Display S C 0 Move Cursor Acc Character Generator RA
14. 0 l Function Set 4 Bit Interface This instruction signals the LCD unit to begin accepting and T sending data in dual 4 bit transfers for all subsequent transfers for all subsequent transactions This is the only 4 bit instruction recognized by the LCD unit ll Function Set 4 Bit Interface Caution At this point Single Dual Line the display format Ill Display Off Display Display Font can t be changed IV Display Clear V Entry Mode Set 0 0 0 0 0 0 0 0 0 oo o End of Initialization LCD21 11 Figure 4 4 Bit Interface 14 Display Unit User s Manual SHARP INSTRUCTIONS General Information When the LCD unit is controlled by an external microprocessor the only registers which can be directly accessed by the microprocessor are the instruction register IR and data register DR Con trol information is buffered to allow the LCD unit to interface with various microprocessors and periph eral control devices with different operating speeds The internal operation of the LCD unit is determined by the signals sent from the external microproces sor These signals include the register select RS signal the read write R W signal and the data bus DBo DB7 signals Table 7 lists the instructions available to the LCD unit with their execution times The instructions fall into the following four categories 1 Instructions for setting LCD unit functions suc
15. AM 15 Dot Matrix LCD Units Display ON OFF RSRWDB DB c e D When D 1 the display is turned When 0 the display is turned off with the display data retained in the display data RAM C When C 1 the cursor is displayed in the position specified by the address counter When 0 the cursor is not displayed The cursor is made up of five dots displayed across the 8th display row below the 5 x 7 dot matrix character block For 5 x 10 dot matrix character blocks 5 dots are displayed across the 11th row B When 1 the character at the cursor position blinks on and off When this function is acti vated at fcp or fosc 250 kHz alternating between all dots black and the display charac ter the character is alternately displayed for 409 6 ms and blanked for 409 6 ms The cursor may be used simultaneously with the character blink function Blink frequency varies in propor tion to the reciprocal of fcp or fosc 409 6 x 250 270 379 2 ms fcp 270 kHz Ss M Cursor Character Font Character Font 5x 7 dot 5 x 10 dot A Cursor Function B Character Blink Function LCD27 16 Display Cursor Shift RS RW DB DBo jo o o Jo 1 NOTE Don t Care 16 SHARP The display and or cursor are shifted to
16. AM Data Write 100101 100101 HARP CD U Write U into the DD RAM Right and left halves of display shift left one character 15 Entry Mode Set 000000 000110 HARP CDU Set the LCD unit to increment the address counter and shift the cursor to the right after each data transaction The display does not shift 16 DDRAM Address Set 001000 001000 HARP CDU Set DD RAM address to the 9th position on the left half of the display address 08H 17 CG RAM Data Write 100100 101100 HARP LCDU Write L into the DD RAM 18 DD RAM Address Set 001100 000101 HARP LCD U_ Set DD RAM address to the 6th position on the right half of the display address 45H 19 Entry Mode Set 000000 000111 HARP LCD U_ Set the display to shift after each data writer 20 21 CG RAM DD RAM Data Write 100101 100100 P LCD UNIT Write T into the DD RAM 22 23 Display Cursor Home 000000 00001 SHARP LCD UNIT Restore the display and cursor to their initial positions 26 Display Unit User s Manual SHARP Dot Matrix LCD Units Table 15 8 Bit Data Transfer with Dual Line 16 Character Display Using Internal Reset NO INSTRUCTION DISPLAY OPERATION Power ON Internal reset circuit is triggered The LCD unit is initialized No display 0000000010 M16251 16CHAR 2 Fuction
17. D unit for extended periods under direct sunlight Mechanical shock and pressure on the glass LCD panel should be avoided Care must be taken to insure that no torsional or compressive forces are applied to the LCD unit when it is mounted If leakage of the liquid crystal material should occur all contact with the material par ticularly accidental ingestion must be avoided If the body or clothing become contaminated by the liquid crystal material wash thoroughly with water and soap The reflector and polarizers attached to the LCD unit are made of soft materials Care must be taken not to scratch these materials To clean the display use a soft dry cloth Do not use organic solvents or water If dirt can not be removed by this method a small amount of petroleum benzine may be used The LCD unit uses CMOS LSI s Precautions must be taken to protect the unit from electro static charges Do not apply the power supply voltages to the LCD unit while the input signal terminals are open Also it is better if the input signal and LCD unit power supply voltages are switched on and off simultaneously The LCD unit should be stored in its original packing case at a temperature of 0 to 35 C and at a relative humidity of 60 or less The LCD unit should be stored in a dark place not ex posed to direct sunlight or fluorescent lamps The following precautions should be taken when mounting the LCD unit The LCD unit may be m
18. DISPLAY UNIT USER S MANUAL Dot Matrix LCD Units with built in controllers SHARP LIFE SUPPORT POLICY SHARP components should not be used in medical devices with life support functions or in safety equipment or similiar applications where component failure would result in loss of life or physical harm without the written approval of an officer of the SHARP Corporation LIMITED WARRANTY SHARP warrants to its Customer that the Products will be free from defects in material and workmanship under normal use and service for a period of one year from the date of invoice Customer s exclusive remedy for breach of this warranty is that SHARP will either i repair or replace at its option any Product which fails during the warranty period because of such defect if Customer promptly reported the failure to SHARP in writing or ii if SHARP is unable to repair or replace refund the purchase price of the Product upon its return to SHARP This warranty does not apply to any Product which has been subjected to misuse abnormal service or handling or which has been altered or modified in design or construction or which has been serviced or repaired by anyone other than Sharp The warranties set forth herein are in lieu of and exclusive of all other warranties express or implied ALL EXPRESS AND IMPLIED WARRANTIES INCLUDING THE WARRANTIES OF MERCHANTABILITY FITNESS FOR USE AND FITNESS FOR A PARTICULAR PURPOSE ARE SPECIFICALLY EXCLUDED
19. Data Write 1001010011 Write S into the DD RAM The cursor shifts to the right 6 CGRAM DD RAM Data Write 1001001001 n I Write H into the DD RAM 8 CGRAM DD RAM Data Write 1000100000 SHARP LCD UNIT Write space into the DD RAM 9 Entry Mode Set 0000000111 SHARP LCD UNIT Set display to shift after each data write 10 CG RAM DD RAM Data Write 1001001100 HARP LCD UNIT L_ Write L into the DD RAM 12 CG RAM DD RAM Data Write 1000110001 LCD UNIT LM171_ Write 1 into the DD RAM 13 Display Cursor Shift 00000100 LCD UNIT LM171 Shift the cursor to the left 14 Display Cursor Shift 00000100 LCD UNIT LM171 Shift the cursor to the left 15 CG RAM DD RAM Data Write 1000110110 LCD UNIT 161 Write 6 into the DD RAM 16 Display Cursor Shift 00000111 LCD UNIT L161 Shift the display and cursor to the right 17 Display Cursor Shift 00000101 LCD UNIT LM161 Shift the cursor to the right 18 CGRAM DD RAM Data Write 1000110101 LCD UNIT L1615_ Write 5 into the DD RAM 19 20 Display Cursor Home 0000000010 AE MUAL SHARP LCD UNIT L Restore the display and cursor to their initial positions Display Unit User s Manual 25 Dot Matrix LCD Units SHARP Table 14 4 Bit Data Transfer with Single Line 16 Character Display Using Internal Re
20. LCD27 26 20 Figure 7 Display Unit User s Manual SHARP Dot Matrix LCD Units LCD UNIT USAGE INSTRUCTIONS Interface with External Microprocessor 1 8 bit Microprocessor mmus _____ wemwommoN seven f XXX X Bus NNNNNNNB sv XXX 08 Write Instruction Check Busy Flag Check Busy Flag Check Busy Flag Write Instruction LCD27 27 Figure 8 8 Bit Interface Timing Example a Interface to 8 Bit Microprocessor via Peripheral Interface Adaptor PIA The following exempli fies the connection of the LCD unit to an 8 bit microprocessor chip through a PIA or 1 0 port The interface is TTL compatible PBo PB7 of the interface device are connected to DBo DB7 of the LCD unit and PAo PA are connected to E R W and RS respectively When the PIA is used care must be taken to insure the proper relationship between the E signal and other signals when reading and writ ing data RS R W MC6800 MC6821 LCD UNIT R Ww P E PBo PB DB DB LCD27 28 Display Unit User s Manual 21 Dot Matrix LCD Units SHARP b Direct Connection to 8 Bit Microprocessor VMA Q2 Ais MC6800 LCD UNIT R W DB DB LCD27 29 c Interface with MC6805 Microprocessor Ag A7 DB DB MC6805 LCD UNIT Co E C4 RS C2 LCD27 30 d Interface with Z 80 Microprocessor LCD27 31 22 Dis
21. M Address R L 1 Shift Right R L 0 Shift Left App Display Data RAM Address 1 8 Bit DL 0 4 Bit AC Address Counter N 1 Dual Line N 0 Single Line BF 1 Internal Operation BF 0 Ready for Instruction NOTES 1 Symbol signifies a don t care bit 2 Correct input value for N is predetermined for each model see Table 12 18 Display Unit User s Manual SHARP ELECTRICAL CHARACTERISTICS Absolue Maximum Ratings See the device specifications for each LCD unit model Electrical Characteristics See the device specificiations for each LCD unit model Some of the currently available specifica tions do not describe the test conditions for the high level and low level output voltages These conditions are as follows Timing Characteristics Dot Matrix LCD Units Table 8 PARAMETER SYMBOL TESTCONDITIONS MIN MAX UNIT Output H lo4 0 205mA 24 V Voltage vo lo 12mA 04 V RS R W DBg DB y LCD27 24 Figure 5 Write Operation Timing Diagram For data sent from the external microprocessor to the LCD unit Table 9 Write Operation Timing Characteristics 5 0 5 Vss 0 0 50 PARAMETER SYMBOL UNIT MIN MAX Enable Cycle Time 1000 ns Enable Pulse Width High L
22. Set DD R W DB DBo Set for 8 bit data transfer and address type b 00001110 3 Display ON OFF Turn on the display and cursor After initialization the DD RAM is filled 0000001110 with the space code 4 Entry Mode Set Set the LCD unit to increment the address counter and shift the cursor 0000000110 to the right after each data transaction The display does not shift 5 CG RAM DD RAM Data Write S Write S into the DD RAM The cursor shifts to the right 1001010011 6 7 CG RAM DD RAM Data Write SHARP LCD UNIT Write space into the DD RAM 1000100000 8 DDRAM Address Set SHARP LCD UNIT Set DD RAM address to the first position of the second line 0011000000 9 CG RAMDD RAM Data Write Write L into the DD RAM 1001001100 L 10 11 CG RAM DD RAM Data Write SHARP LCD UNIT Write A into the DD RAM 1001000001 LM16251 16CHA 12 Entry Mode Set SHARP LCD UNIT Set the display to shift after each data write 0000000111 LM16251 16CHA 13 RAMIDD RAM Data Write SHARP LCD UNIT Write R into the DD RAM Both lines shift to the left 1001011001 M16251 16CHAR 14 15 Display Cursor Home SHARP LCD UNIT Restrore the display and cursor to their initial positions Display Unit User s Manual 27 Dot Matrix LCD Units HANDLING INSTRUCTIONS 1 28 Operate the LCD unit within the allowable ranges of temperature and power supply volt age Avoid operating the LCD unit in high hu midity Avoid operating the LC
23. addressing and shifting may be considered to constitute a second display line For the address type of each model see Table 12 Dot Matrix LCD Units Character Generator ROM CG ROM This ROM generates a 5 x 7 dot matrix character pattern for each of 160 different 8 bit character codes The correspondence between character codes and character patterns is shown in Tables 4 and 5 Inquiries are invited for units with custom character patterns Character Generator RAM CG RAM This RAM stores eight arbitrary 5 x 7 dot matrix character patterns as programmed by the user For displaying a character pattern stored in the CG RAM a character code corresponding to the left most column in Tables 4 and 5 is written into the display data RAM For the relationship among the CG RAM address the display data and the displayed pattern see Table 6 As shown in Table 6 the unused portion of the CG RAM may be used as a general purpose RAM area Timing Generator The timing generator produces timing signals used for the internal operation of the display data RAM character generator ROM and character gen erator RAM Timing in controlled so that read out of the RAM for display and access to the RAM by the external microprocessor do not interfere Display flicker when data is written to the display data RAM is eliminated Cursor Blink Controller This circuit can be used to generate a cursor or blink a character in the display positio
24. ay Unit User s Manual SHARP CG RAM Address Set RS RW DB DB cove o o TA Ta TA JA T The address counter is loaded with a character generator RAM address expressed as a 6 digit binary number Following the execution of this in struction subsequent data transactions will be be tween the external microprocessor and the character generator RAM DD RAM Address Set RS RIW DB 108 ala The address counter is loaded with a display data RAM address expressed as a 7 digit binary num ber Following the execution of this instruction sub sequent data transactions will be between the external microprocessor and the display data RAM For N 0 single line display the binary number App may have a value ranging from 00H to 4FH For N 1 dual line display the binary number App may have a value ranging from 00H to 27H for the first line or 40H to 67H for the second line Busy Flag Address Counter Read RS RWDB cove o T Tr The busy flag BF is read out and indicates whether or not the LCD unit is still executing the previous instruction BF 1 indicates the busy state internal operation and the next instruction will not be accepted until BF 0 This instruction also reads out the contents of the address counter expressed as a 7 digit binary number The address counter is used for accessing both the character generator RAM and th
25. e display data RAM On read out the address counter will contain either a character gen erator RAM address or a display data RAM address as determined by the most recently executed ad dress set instruction Display Unit User s Manual Dot Matrix LCD Units CG RAM DD RAM Data Write RS RWDB DB CODE 1 0 D D 8 bit data word is written into either the char acter generator RAM or display data RAM as de termined by the most recently executed address set instruciton The data is written into the RAM location specified by the address counter After the data is written into the RAM the address counter is either incremented or decremented by one as determined by the current entry mode Adisplay shift may also take place after the data is written CG RAM DD Data Read RS RW DB DBy CODE 1 1 8 bit data word is read from either the charac ter generator RAM or display data RAM as deter mined by a previously executed address set instruction The data is read from the RAM location specified by the address counter This instruction must be immediately preceded by the CG RAM address set instruction the DD RAM address set instruction the cursor shift instruction or a previous CG RAM DD RAM data read instruc tion Any other preceding instruction will cause in valid data to be read The address set instructions cause
26. erface Data lines DB4 DB are used for data transfers Data transactions with the external microprocessor take place in two 4 bit data transfer operations Dot Matrix LCD Units The high order 4 bits corresponding to DB4 DB7 in an 8 bit transfer are transferred first followed by the low order 4 bits corresponding to DBo in an 8 bit transfer The busy flag is to be checked on completion of the second 4 bit data transfer Busy flag and address counter are output in two opera tions 8 bit Microprocessor Interface Each 8 bit piece of data is transferred in a single opera tion using the entire data bus DBo DB7 RS R W Write to Instruction Register IR d Cm ASA KA ARA Xon CS AUS A KKK AEX CS ARX ANA Co CR Ge CS O Read Busy Read Data Flag BF and Register DR Address Counter AC LCD27 9 Figure 2 4 Bit Data Transfer Display Unit User s Manual 11 Dot Matrix LCD Units Reset Function Initialization by Internal Reset Circuit The LCD unit has an internal reset circuit for implementing an automatic reset operation at power on During the initalization operation the busy flag is set The busy state lasts for 10 msec after reaches 4 5 V The following instructions are executed in initializing the LCD unit 1 Clear Display 2 Function Set DL 1 8 bit data length for interface N 0
27. evel PWEH 450 ns Enable Rise Fall Time ter ter 25 ns Setup Time RS R W E tas 140 ns Address Hold Time 10 ns Data Setup Time tpsw 195 ns Data Hold Time tH 10 ns Display Unit User s Manual 19 Dot Matrix LCD Units SHARP RS VHT RW VALID DATA toycE LCD27 25 Table 10 Read Operation Timing Characteristics 5 0 5 Vss 0 V Ta 0 50 C Figure 6 Read Operation Timing Diagram For data sent from the LCD unit to the external microprocessor PARAMETER SYMBOL UNIT MIN MAX Enable Cycle Time teyc0E 1000 ns Enable Pulse Width High Level PWeH 450 ns Enable Rise Fall Time ter ter 25 ns Setup Time RS R W E tas 140 ns Address Hold Time taH 10 E ns Data Delay Time 320 ns Data Hold Time 20 ns Table 11 Power Conditions for Internal Reset VALUE PARAMETER SYMBOL UNIT MIN MAX Voltage Build Up Time troc 0 1 10 ms Power Off Period torr 1 ms If the above conditions are not satisfied the inter nal reset circuit will not operate normally In sucha case the LCD unit must be initialized by executing a series of instructions see the Execution by In structions section 0 1 ms toc lt 10 ms NOTE topp indicates Power off Period torr 211105
28. evels LCD Driver This circuit receives display data timing signals and bias voltage and produces the common and segment display signals LCD Panel This is a dot matix liquid crystal display panel arranged in either 1 row of 16 characters 2 rows of 16 characters 2 rows of 20 characters or 2 rows of 40 characters Display Unit User s Manual SHARP Dot Matrix LCD Units EE 4 EL T back amp Inverter 5V light See note 2 Display Data Se gment Eer Signals Electrode Scanning Signals 1 i light Drive Vip Viss L Common Electrode Drive Circuit Timing Generator Character Generator Display Data ROM RAM CG ROM Address DD RAM 7 200 bits Counter 80 x 8 bits AC Character Generator ROM Instruction CG ROM Decoder 512 bits 8 Data Register Busy DR Flag BF Instruction Register R 8 Buffer 4 4 RS RW E DB DB DBs NOTES 1 LM16152 incorporates a temperature compensation circuit within the bias voltage generator See table 12 2 For the inverters of EL backlights please contact your representative Parallel to Serial Converter Bias Voltage Generator See Note 1 Vss LCD27 6 Figure 1 Functional Block Diagram Display Unit User s Manual Dot Matrix LCD Units SHARP Table 4 Character Codes
29. ge Sample Instruction Procedures HANDLING INSTRUCTIONS OPERATING RESTRICTIONS Display Unit User s Manual Dot Matrix LCD Units Dot Matrix LCD Units PREFACE The Sharp dot matrix LCD units with built in con trollers operate under the control of a 4 bit or 8 bit microcomputer to display alphanumeric characters SHARP The LCD unit provides the user with a dot matrix display panel featuring simple interface circuitry symbols etc Table 1 Dot Matrix LCD Unit with Built In Controllers NUMBER OF DISPLAY MODEENG CHARACTERS FORMAT LM161XXX 16x1 5x7 dots LM162XXX 16x2 5x7 dots LM202XXX 20x2 5x7 dots LM40X2XX 40x2 5x7 dots Display Unit User s Manual SHARP FEATURES e Interface with either 4 bit or 8 bit microprocessor e Display data RAM e 80 x 8 bits 80 characters e Character generator ROM e 160 different 5 x 7 dot matrix character patterns e Character generator RAM e 8 different user programmed 5 x 7 dot matrix patterns e Display data RAM and character generator RAM may be accessed by the microprocessor e Numerous instructions e Clear Display Cursor Home Display ON OFF Cursor ON OFF Blink Character Cursor Shift Display Shift e Built in reset circuit is triggered at power ON e Built in oscillator Display Unit User s Manual Dot Matrix LCD Units OVERVIEW The LCD unit receives character codes 8 bits per cha
30. h as display format and data length 2 Instructions for addressing the internal RAM s 3 Instructions for transferring data to or from the internal RAM s 4 Other instructions In normal operation instructions from category 3 are used most frequently The internal RAM address may be incremented or decremented auto matically after each data transaction to reduce the programming requirements of the microprocessor The display may also be shifted automatically after each display data write see Sample Instruction Procedures section for examples These features facilitate the construction of efficient systems During the internal execution of an instruction no instruction other than the busy flag address counter read instruction will be accepted During internal operation the busy flag is set to 1 It is necessary for the microprocessor to check that the busy flag is reset to 0 before sending the next instruction NOTE Either the microprocessor must check that the busy flag is not set to 1 before sending each instruction or the interval waited before sending each instruction must be made sufficiently longer than the execution time of the previous instruction For the execution time of each instruction see Table 7 Display Unit User s Manual Dot Matrix LCD Units Description of Instruction Display Clear RS RWDB coo oo S8 ST TS TS The display data RAM is filled with the space code
31. hedisdl Jena h tion is now being replaced with a modified version SEM e uh ee pus HD44780RAXX The above mentioned restrictions id 5 ER ee do not apply to products using the version of SANEA NS origina position ongina the LSI The RA version devices have an R display position may not be restored printed in the upper right corner as shown 2 When the display cursor home instruction is executed the data in the following display data R RAM locations may be lost HD44780A A Address type a B Address type b and c Address HEX 00 01 02 03 04 05 06 07 41 42 43 44 45 46 47 48 49 4A 4B 4C 4D 4E 4 011 2 77 2 Total 80 Characters The contents of addresses 43 47 4B and 4F may be destroyed Address HEX 00 01 02 03 04 05 06 07 1A 1B 1C 1D 1E 1F 20 21 22 23 24 25 26 27 Address HEX 40 41 42 43 44 45 46 47 BA 5B 5C 5D 5E 60 61 62 63 64 65 66 67 Total 40 Characters x 2 Lines The contents of address locations 23 27 63 and 67 may be lost during the execution of the NOTE Although address type C is for a single line display its display cursor home instruction address structure is logically the same as for address type b
32. ld be set to 0 CG RAM data bits 0 4 correspond to the column position of CG RAM address bits 0 2 designate the row position of each character pattern The 8th row is the cursor position CG RAM data in the 8th row is OR ed with the display cursor Any 1 bits in the 8th row will result in a displayed dot regardless of the 5 CG RAM data 1 produces a dark dot and data 0 produces a light dot in the corresponding position on the display panel 6 Signifies a don t care bit each character pattern bit 4 corresponding to the left most column of the character pattern CG RAM data bits 5 7 are not used for displaying character patterns but may be used as a general purpose RAM area Sample Character Pattern 1 Cursor Position Sample Character Pattern 2 4 As shown in tables 4 and 5 character patterns in the CG RAM are accessed by character codes with bits 4 7 equal to 0 For example the character pattern R shown in the first sample character pattern of the table is selected by the character code 00 HEX or 08 HEX since bit 3 of the character code is a don t care bit i e can take either value 00 or 17 LCD27 8 10 Display Unit User s Manual SHARP Microprocessor Interface The LCD unit performs either dual 4 bit or single 8 bit data transers allowing the user to interface with either a 4 bit or 8 bit microprocessor 4 Bit Microprocessor Int
33. n indicated by the DD RAM address which is set in the address counter AC The following example shows the cursor position when the address counter contains 08 HEX SHARP AC AC jojo 1 o Display Position Digit 1 2 3 4 5 6 7 8 9 1011 Sie Tos oroe oo on DD RAM Address HEX Cursor Position Display Position Digt 123456 7 8 9 1011 Dual Line Line 1 00101 0203 04 05 06 07 08 09 0A Display Line 2 40 41 42 43 44 45 46 47 48 49 4A DD RAM Address HEX Cursor Position NOTE The address counter has the dual function of containing either a DD RAM address or a CG RAM address The cursor blink controller does not distinguish between these two functions and thus when activated it always considers the address counter to contain DD RAM address To avoid spurious cursor blink effects the cursor blink function should be turned off while the microprocessor writes to or reads from the CG RAM Parallel to Serial Converter This circuit converts parallel data read from the CG ROM or CG RAM to serial data for use by the display driver Bias Voltage Generator This circuit provides the bias voltage level re quired for driving the liquid crystal display Some models incorporate a temperature compensation circuit which generates a temperature dependent bias voltage in order to provide constant display contrast at all ambient temperature l
34. ounted on either the inside or outside of a cabinet as shown in Figure 12 To determine the optimum mounting angle refer to the viewing angle range in the device specification for each model SHARP b An acrylic sheet or the like may be used to protect the LCD panel A spacing of 0 5 mm to 1 0 mm should be used between the protective plate and the LCD panel See Figure 13 To prevent stress on the LCD panel the unit should be mounted with a nominal height accu racy of 0 1 mm Ananti glare anti reflection sheet may be used in place of the protective acrylic sheet The mounting considerations will be the same LCD UNIT gt C B Outside Mount LCD UNIT aN aN XA x Inside Mount UL LCD27 35 Figure 12 Mounting Diagrams Transparent 0 5 1 0 mm Protective Spacing Sheet A ee d 277223 LCD UNIT N Mounting WW m WW Frame LCD27 36 Figure 13 Sample Design Display Unit User s Manual SHARP Dot Matrix LCD Units OPERATING RESTRICTIONS The LSI HD44780AXX used in the LCD units is To counteract these defects The following re reported to have the following defects strictions should be followed Table 16 HD44780AXX Defective Functions In the production facility the LSI device in ques 1 Whend
35. play Unit User s Manual SHARP Dot Matrix LCD Units 2 4 Bit Data Transfer with a Single Line 16 Char Since the data lines DBo are not con acter Display Using Internal Reset Table 14 nected this data is not accepted and must be shows a sample operating procedure for an LCD written again i e the function set instruction unit in this mode After power has been turned must be written twice Subsequent data trans on the 8 bit data transfer mode is in effect and fers are completed in two 4 bit transfer opera the first write operation is assumed to be an 8 bit tions see Table 14 data transfer RS INTERNAL OPERATION READY FOR DATA XX X e N XN 9 Write Instruction Check Busy Flag Check Busy Flag Write Instruction NOTE IR IR Instruction bits 7 and 3 AC3 Address counter bit LCD27 32 Figure 9 4 Bit Interface Timing Example E LCD UNIT DB DB LCD27 33 Figure 10 Connection to SM200 Display Unit User s Manual 23 Dot Matrix LCD Units Contrast Control Voltage The LCD unit has three power terminals Vpp Vss and Vo Acontrast control voltage is supplied to the terminal Vo The panel is driven by the voltage difference between Vpp and Vo Vpp Vo Figure 11 shows an example of the contrast control voltage supply circuit in which VR is adjusted to obtain the best display quality
36. racter from a microprocessor or microcomputer latches the codes to its display data RAM 80 byte DD RAM for storing 80 characters transforms each character code into a 5 x 7 dot matrix character pattern and displays the characters on its LCD screen The LCD unit incorporates a character generator ROM which produces 160 different 5 x 7 dot matrix character patterns The unit also provides a char acter generator RAM 64 bytes through which the user may define up to eight additional 5 x 7 dot ma trix character patterns as required by the applica tion To display a character positional data is sent via the data bus from the microprocessor to the LCD unit where it is written into the instruction register A character code is then sent and written into the data register The LCD unit displays the correspond ing character pattern in the specified position The LCD unit can either increment or decrement the display position automatically after each character entry so that only successive characters codes need to be entered to display a continuous character string The display cursor shift instruction allows the entry of characters in either the left to right or right to left direction Since the display data RAM DD RAM and the character generator RAM CG RAM many be accessed by the microprocessor unused portions of each RAM may be used as general purpose data areas The LCD unit may be operated with either dual 4 bit or single 8 bi
37. set NO INSTRUCTION 1 Power ON internal reset circuit is triggered DISPLAY OPERATION The LCD unit is initialized No display 2 Function Set RS R W DB DB4 000010 Set for 4 bit data transfer This instruction is transferred in a single operation since up to this point the LCD unit is in the 8 bit mode 3 Function Set 000010 0000 Set for 4 bit data transfer and address type C Data is transferred in two operations 4 Display ON OFF 000000 001110 Tum on the display and cursor After initialization the DD RAM is filled with the space code 5 Entry Mode Set 000000 001110 Set the LCD unitto increment the address counter and shift the cursor to the right after each data transaction The display does not shift 6 CGRAM DD RAM Data Write 100101 10001 Write S into the DD RAM The cursor shifts to the right CG RAM DD RAM Data Write 1000101 100000 SHARP_ Write P into the DD RAM 9 DD RAM Address Set 001100 000000 SHARP Set DD RAM address to the first position on the right half of the display character position 9 10 CG RAMDD RAM Data Write 100100 101100 SHARP 1 Write L into the DD RAM 12 CG RAMDD RAM Data Write 100010 100000 SHARP LCD Write space into the DD RAM 13 Entry Mode Set 000000 000111 SHARP LCD Set the display to shift after each data write 14 CG RAMWDD R
38. t data transers to accommodate interfaces with both 4 bit and 8 bit microprocessors The low power feature of the LCD unit will be further appreciated when combined with a CMOS microprocessor Dot Matrix LCD Units HARDWARE Interface Signals SHARP Table 2 Interface Signals EXTERNAL SIGNALNAME INPUT OUTPUT FUNCTION RS Input MPU Register select signal 0 Instruction register when writing Busy flag and address counter when reading 1 Data register when writing and reading R W Input MPU Read write select signal 0 Writing 1 Reading E Input MPU Operation data read write enable signal DB4 DB7 Input Output MPU High order lines of data bus with three state bidirctional function for use in data transactions with the MPU DB may also be used to check the busy flag DBo DB3 Input Output MPU Low order lines of data bus with three state bidirectional function for use in data transactions with the MPU These lines are not used when interfacing with a 4 bit microprocessor Vss Power Supply Vpp 5 V Vss GND Vo Power Supply Contrast adjustment voltage Functional Blocks Registers The LCD unit has two 8 bit registers an instruc tion register IR and a data register DR The instruction register stores instruction codes such as clear display or shift cursor and also stores address information for the display data RAM and character genera
39. the address counter to be loaded with a valid data read address The cursor shift command allows selected DD RAM data to be read without the necessity of reset ting the DD RAM address Following the cursor shift instruction the CG RAM DD RAM data read instruc tion will read data from the DD RAM After the execution of each data read instruction the address counter is either incremented or decre mented by one as determined by the current entry mode It is not necessary to reset the RAM address before the execution of subsequent data read in structions if the same RAM is to be read The display is not shifted by the data read instruction NOTE After the execution of the CG RAM DD RAM data write instruction the address counter is incremented or decre mented automatically However the contents of the RAM location specified by the address counter cannot be read by a subsequent CG RAM DD RAM data read instruction The correct procedure for reading data from the CG RAM or DD RAM is to execute an address set or cursor shift instruction Once a data read instruction has been exe cuted successive data read instructions may be exe cuted with no requirement for intervening instructions 17 Dot Matrix LCD Units SHARP Table 7 Instruction Set CODE INSTRUCTION FUNCTION RS RW DB DB DBs DB3 DE DB fcr
40. the right or left For two line displays the cursor moves from the 40th position of the top line to the first position of the second line From the 40th position of the second line the cursor does not move back to the home position but rather to the first position of the second line SIC RIL 0 0 Shiftthe cursor to the left AC lt AC 1 0 1 Shiftthe cursor to the right AC lt AC 1 1 0 Shift the entire display with the cursor to the left 1 1 Shift the entire display with the cursor to the right NOTE When the display is shifted the address counter is not affected Function Set AS RWDB DB 01 1 NOTE Don t DL Selects the interface data length When DL 1 8 bit data transfers are used When DL 0 4 bit data transfers are used NOTE When using a 4 bit data length two transfer operations are needed to transfer a complete data word to or from the external micoprocessor N Selects display format single or dual line See Table 12 for the correct input value for each model CAUTION The function set instruction must be executed at the beginning of the microprocessor program before all other instructions except the busy flag address counter read instruction The function set instruction cannot be exe cuted again except to change the interface data length Once set the display format cannot be changed Displ
41. tor RAM The IR can be accessed by the microprocessor only for writing The data register is used for temporarily storing data during data transactions with the microproces sor When writing data to the LCD unit the data is initially stored in the data register and is then auto matically written into either the display data RAM or character generator RAM as determined by the current operation The data register is also used as a temporary storage area when reading data from the display data RAM or character generator RAM When address information is written into the instruc tion register the corresponding data from the display data RAM or character generator RAM is moved to the data register Data transfer is completed when the microprocessor reads the contents of the data register by the next instruction After the transfer is completed data from the next address position of the appropriate RAM is moved to the data register in preparation for subsequent reading operations by the microprocessor One of the two registers is selected by the register select RS signal Table 3 Register Selection RS OPERATION 0 0 Write to instruction register and execute internal operation clear display etc 0 1 Read busy flag DB7 and address counter DBo 6 1 0 Write to data register and execute internal operation DR DD RAM or DR gt CG RAM 1 1 Read data register and execute internal operation DD RAM

Download Pdf Manuals

image

Related Search

Related Contents

"取扱説明書"  Professional Series PS77401 User's Manual  LEICA S-ADAPTER H  フラッシュマンFM6TGN 取扱説明書  Instruction Manual  RCA RCT6077W22 Tablet Accessory User Manual  Samsung RS552NRUA1J Наръчник за потребителя  the Kosmos Super Nova User Manual.  User`s Guide - B&H Photo Video  User Manual  

Copyright © All rights reserved.
Failed to retrieve file