CN109272954A - A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter - Google Patents
A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter Download PDFInfo
- Publication number
- CN109272954A CN109272954A CN201811293277.2A CN201811293277A CN109272954A CN 109272954 A CN109272954 A CN 109272954A CN 201811293277 A CN201811293277 A CN 201811293277A CN 109272954 A CN109272954 A CN 109272954A
- Authority
- CN
- China
- Prior art keywords
- liquid crystal
- lcd
- caching
- character
- code type
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G09—EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
- G09G—ARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
- G09G3/00—Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes
- G09G3/20—Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes for presentation of an assembly of a number of characters, e.g. a page, by composing the assembly by combination of individual elements arranged in a matrix no fixed position being assigned to or needed to be assigned to the individual characters or partial characters
- G09G3/34—Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes for presentation of an assembly of a number of characters, e.g. a page, by composing the assembly by combination of individual elements arranged in a matrix no fixed position being assigned to or needed to be assigned to the individual characters or partial characters by control of light from an independent source
- G09G3/36—Control arrangements or circuits, of interest only in connection with visual indicators other than cathode-ray tubes for presentation of an assembly of a number of characters, e.g. a page, by composing the assembly by combination of individual elements arranged in a matrix no fixed position being assigned to or needed to be assigned to the individual characters or partial characters by control of light from an independent source using liquid crystals
Landscapes
- Engineering & Computer Science (AREA)
- Chemical & Material Sciences (AREA)
- Crystallography & Structural Chemistry (AREA)
- Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Control Of Indicators Other Than Cathode Ray Tubes (AREA)
- Controls And Circuits For Display Device (AREA)
Abstract
A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter, S1 establish LCD liquid crystal display caching table according to liquid crystal display content;S2 establishes character library, to each ascii character, is encoded according to display;When S3 character is shown, the coding in character library is inquired, by data indirect assignment corresponding in character library to corresponding byte is cached, obtains filled LCD liquid crystal display cache table;Filled LCD liquid crystal display cache table is carried out caching mapping by S4, is obtained and the consistent cache contents of the practical LCD liquid crystal hardware truth table of the liquid crystal;Caching after mapping is pushed to liquid crystal by S5, is shown.What method of the invention can cache LCD segment code type liquid crystal, which do not advise, deposits content and resequences, form regular caching table, two tables are mapped by code, regular LCD caching table need to only be paid close attention in application layer development process by realizing, reduce development difficulty.
Description
Technical field
The present invention relates to intelligent electric meter field, it is related to not advising for LCD segment code type liquid crystal caching and deposits content and resequence
The method of processing, the caching mapping method of more specifically a kind of LCD segment code type liquid crystal applied to intelligent electric meter.
Background technique
LCD segment code type liquid crystal have it is cheap, drive it is at low cost, it is easy to operate, format freely etc. several big features, answer extensively
For all kinds of automation instrument equipment.
In LCD drive chip, SEG and COM are two groups of signals in LCD driving.COM can be described as " common end ", mention
For stable power supply, and SEG refers to " section ", that is, " scanning end ", by the combination of COM and SEG, light different LCD or
LED display segment, to form text or figure.In the operation of LCD drive chip, user only need to display register into
Row duplication, LCD drive chip can both light liquid crystal.
But due to LCD realize content diversity, cause the segment encode table of most of LCD be it is irregular, user can only
Exploitation liquid crystal drive is gone by looking for the modes such as segment encode arrangement rule, but a large amount of investment energy is needed to go to analyze, and institute
The code of formation has very strong specific aim, cannot transplant substantially, can be readability excessively poor.
Summary of the invention
It is irregular the purpose of the present invention is sorting for segment code type liquid crystal segment encode, it is analyzed when leading to develop liquid crystal, is processed
Journey is complicated, be formed by code substantially not portable the problem of, propose a kind of LCD segment code type liquid crystal applied to intelligent electric meter
Cache mapping method.
The technical scheme is that
A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter, method includes the following steps:
S1, according to liquid crystal display content, establish LCD liquid crystal display caching table;Wherein, ordinate indicates single byte's
Eight bit, each bit correspond to the corresponding pen section of single LCD segment encode, and abscissa indicates the number of byte, for corresponding to LCD segment encode
Number;
S2, character library is established, for each ascii character, is encoded according to its display;
When S3, character display, the coding in character library is inquired, data indirect assignment corresponding in character library is corresponding to caching
Byte obtains the filled LCD liquid crystal display cache table of data;
S4, the filled LCD liquid crystal display cache table of data is subjected to caching mapping, obtained and the practical LCD liquid of the liquid crystal
The brilliant consistent cache contents of hardware truth table;
S5, the caching after mapping is pushed into liquid crystal, is shown.
Further, in step S1, in abscissa, a part of byte corresponds to the number of segment encode, and another part byte is then
Remaining corresponding character displayed separately;The character includes symbol and mark.
Further, in the step S1, LCD liquid crystal display is cached in table, the arrangement mode of segment encode buffer zone
It is consistent with character library sortord;Wherein segment encode uses eight segment encodes.
Further, when code migrating, caching mapping relations described in amendment step S4 can be carried out according to original mode
Show data-pushing.
Beneficial effects of the present invention:
The present invention is applied to the LCD segment code type field of liquid crystal display of intelligent electric meter, to not advising for LCD segment code type liquid crystal caching
It deposits content and carries out rearrangement processing, re-form regular caching table, then two tables are mapped by code,
Regular LCD caching table need to only be paid close attention in application layer development process by realizing, reduce development difficulty.
Other features and advantages of the present invention will then part of the detailed description can be specified.
Detailed description of the invention
Exemplary embodiment of the invention is described in more detail in conjunction with the accompanying drawings, it is of the invention above-mentioned and its
Its purpose, feature and advantage will be apparent, wherein in exemplary embodiment of the invention, identical reference label
Typically represent same parts.
Fig. 1 is LCD liquid crystal display schematic diagram;
Fig. 2 is the end LCD liquid crystal COM line graph;
Fig. 3 is the end LCD liquid crystal SEG line graph;
Fig. 4 is the LCD liquid crystal segment encode hardware arrangement truth table of the prior art;
Fig. 5 is LCD liquid crystal display caching table of the invention;
Fig. 6 is that eight segment encode letters show comparative diagram.
Specific embodiment
The preferred embodiment that the present invention will be described in more detail below with reference to accompanying drawings.Although showing the present invention in attached drawing
Preferred embodiment, however, it is to be appreciated that may be realized in various forms the present invention without the embodiment party that should be illustrated here
Formula is limited.
A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter, method includes the following steps:
S1, according to liquid crystal display content, establish LCD liquid crystal display caching table;Wherein, ordinate indicates single byte's
Eight bit, each bit correspond to the corresponding pen section of single LCD segment encode, and abscissa indicates the number of byte, for corresponding to LCD segment encode
Number;
As shown in figure 5, abscissa 0-13byte indicates 14 for the liquid crystal in legend in LCD liquid crystal display cache table
A segment encode, 14-17byte then correspond to remaining symbol displayed separately and mark;S2, character library is established, as shown in fig. 6, for every
A ascii character is encoded according to its display, for coding mode following table;
When S3, character display, the coding in character library is inquired, data indirect assignment corresponding in character library is corresponding to caching
Byte obtains the filled LCD liquid crystal display cache table of data;(since the sortord of segment encode byte and character library are arranged in caching
Sequence is consistent, so, it, can be by the data indirect assignment responded in character library to caching phase when each segment encode position needs to show character
The byte answered, number, letter etc.)
S4, the filled LCD liquid crystal display cache table of data is subjected to caching mapping, obtained and the practical LCD liquid of the liquid crystal
The brilliant consistent cache contents of hardware truth table, as shown in Figure 4;
S5, the caching after mapping is pushed into liquid crystal, is shown.
When code migrating, caching mapping relations described in amendment step S5 can carry out display data according to original mode
Push.
When specific implementation:
In LCD liquid crystal, the symbol of each display is to carry out driving by SEG and COM to light.Therefore, in liquid crystal
In driving chip, we it is only necessary to know that SEG and COM correspondence table, LCD can be shown according to various demands.But
It is that, due to the various limitations (as shown in Figures 2 and 3) of the wiring of inside liquid crystal, the correspondence table of SGE and COM can not be made
(calling LCD truth table in the following text) arrangement is regular, can only be laid out according to actual circuit and generate more chaotic table, as shown in Figure 4.And it presses
According to shown in Fig. 1, each numerical portion is labeled with A~G, and number 1 is all similarly to be laid out to digital 14, thus can be with
A display caching is established, so that each of which byte is represented a digital display, then remaining display content of LCD truth table is filled out
It is charged into display caching.LCD liquid crystal cache table as shown in Figure 5 available at this time.
At this point, mapping relations are established according to LCD liquid crystal truth table and LCD liquid crystal cache table, by the number in liquid crystal cache table
According to mapping in truth table:
For example,
The caching 9D of truth table Pin1, the position in liquid crystal cache table are the 9th byte bit3;
The caching 9E of truth table Pin1, the position in liquid crystal cache table are the 9th byte bit4;
The caching 9F of truth table Pin1, the position in liquid crystal cache table are the 9th byte bit5;
The caching 9A of truth table Pin1, the position in liquid crystal cache table are the 9th byte bit0;
In this regard, the condition that can be used in C language judges that sentence is handled.
Assuming that:
LCD true value table register is array Reg [], array length 33;
LCD caching is array LCD_buf [], array length 18;
So:
It is otherwise 0 if the bit3 that the bit3 of LCD_buf [9] is 1, Reg [1] is 1:
Reg [1] |=(LCD_buf [9] &0x04)? 0x08:0)
It is otherwise 0 if the bit2 that the bit4 of LCD_buf [9] is 1, Reg [1] is 1:
Reg [1] |=(LCD_buf [9] &0x10)? 0x04:0)
It is otherwise 0 if the bit1 that the bit5 of LCD_buf [9] is 1, Reg [1] is 1:
Reg [1] |=(LCD_buf9] &0x20)? 0x02:0)
It is otherwise 0 if the bit0 that the bit0 of LCD_buf [9] is 1, Reg [1] is 1:
Reg [1] |=(LCD_buf [9] &0x01)? 0x01:0)
The mapping code arrived i.e. are as follows:
Reg [1]=((LCD_buf [9] &0x04)? 0x08:0)
| (LCD_buf [9] &0x10)? 0x04:0)
| (9] &0x20 of LCD_buf)? 0x02:0)
| (LCD_buf [9] &0x01)? 0x01:0))
And so on, available all mapping codes.
Before finally display data-pushing, by all data in LCD_buf, Reg array is converted to, is retransmited to core
In piece, so that it may obtain needing content to be shown.And the data form that upper layer data processing uses then is the LCD_ after arranging
buf。
Simultaneously, since 1-14 numeric structure of LCD display caching is consistent, letter can be established according to Fig. 6
Corresponding table, according to the corresponding table of obtained letter, can the 1-14 byte directly to LCD_buf carry out assignment, it is corresponding to show
Letter.So far, in code, the alphabetical available fixation of push mode of display.
It is handled by the method, code migrating need to only modify segment encode demapping section and remaining symbol is shown.
Various embodiments of the present invention are described above, above description is exemplary, and non-exclusive, and
It is not limited to disclosed each embodiment.Without departing from the scope and spirit of illustrated each embodiment, for this skill
Many modifications and changes are obvious for the those of ordinary skill in art field.
Claims (6)
1. a kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter, which is characterized in that this method include with
Lower step:
S1, according to liquid crystal display content, establish LCD liquid crystal display caching table;Wherein, ordinate indicates eight of single byte
Bit, each bit correspond to the corresponding pen section of single LCD segment encode, and abscissa indicates the number of byte, for corresponding to of LCD segment encode
Number;
S2, character library is established, for each ascii character, is encoded according to its display;
When S3, character display, the coding in character library is inquired, data indirect assignment corresponding in character library is corresponding to caching
Byte obtains the filled LCD liquid crystal display cache table of data;
S4, the filled LCD liquid crystal display cache table of data is subjected to caching mapping, obtained hard with the practical LCD liquid crystal of the liquid crystal
The consistent cache contents of part truth table;
S5, the caching after mapping is pushed into liquid crystal, is shown.
2. the caching mapping method of the LCD segment code type liquid crystal according to claim 1 applied to intelligent electric meter, it is characterized in that
In the step S1, in abscissa, a part of byte corresponds to the number of segment encode, and another part byte then corresponds to remaining individually
The character of display.
3. the caching mapping method of the LCD segment code type liquid crystal according to claim 2 applied to intelligent electric meter, it is characterized in that
The character includes symbol and mark.
4. the caching mapping method of the LCD segment code type liquid crystal according to claim 1 applied to intelligent electric meter, it is characterized in that
In the step S1, LCD liquid crystal display is cached in table, the arrangement mode and character library sortord one of segment encode buffer zone
It causes.
5. the caching mapping method of the LCD segment code type liquid crystal according to claim 4 applied to intelligent electric meter, it is characterized in that
Segment encode uses eight segment encodes.
6. the caching mapping method of the LCD segment code type liquid crystal according to claim 1 applied to intelligent electric meter, it is characterized in that
When code migrating, caching mapping relations described in amendment step S4 can carry out display data-pushing according to original mode.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811293277.2A CN109272954A (en) | 2018-11-01 | 2018-11-01 | A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811293277.2A CN109272954A (en) | 2018-11-01 | 2018-11-01 | A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109272954A true CN109272954A (en) | 2019-01-25 |
Family
ID=65191559
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811293277.2A Pending CN109272954A (en) | 2018-11-01 | 2018-11-01 | A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109272954A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112199225A (en) * | 2020-09-30 | 2021-01-08 | 河北恒源水务科技有限公司 | Segment code type liquid crystal screen conversion processing method based on bit domain concept |
CN112419951A (en) * | 2020-10-22 | 2021-02-26 | 浙江晨泰科技股份有限公司 | Segment code liquid crystal driving method |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101344767A (en) * | 2008-04-18 | 2009-01-14 | 上海海事大学 | Non-encoded keyboard and display interface of watercraft embedded micro-controller |
CN103325360A (en) * | 2013-06-28 | 2013-09-25 | 惠州市德赛西威汽车电子有限公司 | Field type LCD display method |
CN104786844A (en) * | 2014-11-03 | 2015-07-22 | 襄阳群龙汽车部件股份有限公司 | Automobile electronic combination instrument |
CN106504716A (en) * | 2016-12-16 | 2017-03-15 | 四川长虹电器股份有限公司 | Device using Micro Controller Unit (MCU) driving liquid crystal display screen |
CN108182906A (en) * | 2018-01-11 | 2018-06-19 | 青岛海信日立空调系统有限公司 | A kind of control method and device of segment encode display screen on home appliance |
-
2018
- 2018-11-01 CN CN201811293277.2A patent/CN109272954A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101344767A (en) * | 2008-04-18 | 2009-01-14 | 上海海事大学 | Non-encoded keyboard and display interface of watercraft embedded micro-controller |
CN103325360A (en) * | 2013-06-28 | 2013-09-25 | 惠州市德赛西威汽车电子有限公司 | Field type LCD display method |
CN104786844A (en) * | 2014-11-03 | 2015-07-22 | 襄阳群龙汽车部件股份有限公司 | Automobile electronic combination instrument |
CN106504716A (en) * | 2016-12-16 | 2017-03-15 | 四川长虹电器股份有限公司 | Device using Micro Controller Unit (MCU) driving liquid crystal display screen |
CN108182906A (en) * | 2018-01-11 | 2018-06-19 | 青岛海信日立空调系统有限公司 | A kind of control method and device of segment encode display screen on home appliance |
Non-Patent Citations (1)
Title |
---|
EEFOCUS: "用STC系列MCU的IO口直接驱动段码LCD", 《HTTP://NEWS.EEWORLD.COM.CNMCUARTICLE_2016090929280.HTML》 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112199225A (en) * | 2020-09-30 | 2021-01-08 | 河北恒源水务科技有限公司 | Segment code type liquid crystal screen conversion processing method based on bit domain concept |
CN112199225B (en) * | 2020-09-30 | 2022-09-30 | 河北恒源水务科技有限公司 | Segment code type liquid crystal screen conversion processing method based on bit field concept |
CN112419951A (en) * | 2020-10-22 | 2021-02-26 | 浙江晨泰科技股份有限公司 | Segment code liquid crystal driving method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2006133407A3 (en) | Data compression using a stream selector with edit-in-place capability for compressed data | |
CN109272954A (en) | A kind of caching mapping method of the LCD segment code type liquid crystal applied to intelligent electric meter | |
CN101796573B (en) | Display apparatus, character sequence display method, and multiple character sequence sorting method | |
CN101621575B (en) | Embedded vector font color changing method | |
CN101488125B (en) | Tibetan language encoding method and terminal | |
CN1209697C (en) | Single and double stroke Chinese character digital inputting method and keyboard thereof | |
CN1369833A (en) | Lexial system and method for conversion between unsimplified and simplified Chinese characters | |
CN107451105B (en) | Bright braille conversion system based on novel Chinese character holographic coding rule | |
CN111209726A (en) | Intelligent report generation system | |
CN101923399A (en) | Encoding method of computer Chinese character encoded texts capable of being used as input codes and internal codes | |
CN1204799A (en) | Coding method of Chinese character unit stroke numbers | |
CN1845042A (en) | Chinese character input method using numerical keys and keyboard therefor | |
CN2566368Y (en) | Information computer for agricultural information network | |
CN111683079B (en) | Industrial control data secure transmission method based on data encryption | |
CN2207584Y (en) | Watt-hour meter Chinese character indicator | |
CN1744014A (en) | Digital two-stroke and Chinese character input method and key board | |
CN2250563Y (en) | Intelligent colour multiple point electronic recorder | |
CN1333325C (en) | Pictographic character direct-viewing coding input method | |
CN117610102A (en) | SCADA system dynamic interval map generation method based on data label | |
CN100370397C (en) | Chinese character digital two stroke input method and keyboard | |
CN112419951A (en) | Segment code liquid crystal driving method | |
CN201122297Y (en) | Display memory system for number of people in house | |
CN108628578A (en) | The multivalue autoexcitation for quantifying logic quantifies register | |
CN2807331Y (en) | Digital notebook with recognition function | |
CN117370342A (en) | Binary system-based method and binary system-based system for label storage and query |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190125 |
|
RJ01 | Rejection of invention patent application after publication |