CN107636632B - Method and system for identifying liquid crystals of different manufacturers - Google Patents

Method and system for identifying liquid crystals of different manufacturers Download PDF

Info

Publication number
CN107636632B
CN107636632B CN201780000414.6A CN201780000414A CN107636632B CN 107636632 B CN107636632 B CN 107636632B CN 201780000414 A CN201780000414 A CN 201780000414A CN 107636632 B CN107636632 B CN 107636632B
Authority
CN
China
Prior art keywords
pin
liquid crystal
reading
value
output pin
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.)
Active
Application number
CN201780000414.6A
Other languages
Chinese (zh)
Other versions
CN107636632A (en
Inventor
吴煌殿
肖锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujian Landi Commercial Equipment Co Ltd
Original Assignee
Fujian Landi Commercial Equipment Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Fujian Landi Commercial Equipment Co Ltd filed Critical Fujian Landi Commercial Equipment Co Ltd
Publication of CN107636632A publication Critical patent/CN107636632A/en
Application granted granted Critical
Publication of CN107636632B publication Critical patent/CN107636632B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Control Of Indicators Other Than Cathode Ray Tubes (AREA)
  • Liquid Crystal Display Device Control (AREA)

Abstract

The invention relates to the field of software, in particular to a method and a system for identifying liquid crystals of different manufacturers. The method for identifying the liquid crystals of different manufacturers comprises the following steps: s1, connecting a data line interface of the liquid crystal with a reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input; s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, obtaining the connection state of the liquid crystal ID pin, and obtaining first liquid crystal information corresponding to the connection state. The data line interface of the liquid crystal is connected with the reading pin by using the data line interface of the liquid crystal, and 11 different liquid crystal manufacturers can be identified by configuring the GPIO port of the data line interface and in a low level output state and configuring the state of the reading pin as pull-down input.

Description

Method and system for identifying liquid crystals of different manufacturers
Technical Field
The invention relates to the field of software, in particular to a method and a system for identifying liquid crystals of different manufacturers.
Background
With the continuous development of science and technology, more and more embedded products are applied to daily life, the embedded products are small in size and convenient to use, and are deeply favored by people, and the liquid crystal display screen is an indispensable part of many embedded products and is the most intuitive impression of people on the terminal product. The working principle of the liquid crystal display screen is that when the terminal system is started, the microprocessor firstly writes working parameters corresponding to a driving chip in the liquid crystal display screen into the driving chip to complete initialization of the driving chip, and thus normal work of the liquid crystal display screen can be guaranteed.
However, as the demand for terminal products increases, the market for liquid crystal display screens is also increasing, and at the same time, the quality thereof is becoming uneven. If a terminal product is very powerful, but only has the display effect of a screen or has poor quality, the use feeling of a user is influenced. At present, liquid crystal display screens produced by different manufacturers all adopt different driving chips, and different driving parameters are inevitably used due to the difference of the driving chips. At the present stage, the liquid crystal display screen of the seen terminal product adopts the corresponding fixed model, if the screen is damaged carelessly, the same manufacturer, the same model of display screen can be used, although some end products have been made to be compatible with two different models of lcd screens, as shown in fig. 1, the type of the liquid crystal display screen is judged by the height of a GPIO (general purpose input/output) pin (the identification pin of the liquid crystal display screen is connected with a power supply or a ground), but the method also has certain limitation, since the update speed of the electronic market is said to be changing day by day, after several years, perhaps the two types of liquid crystal screens stop producing early, therefore, the user has to replace the new end product, which not only affects the user's usage, but also is a waste of resources.
Disclosure of Invention
The technical problem to be solved by the invention is as follows: the method and the system can identify the liquid crystals of a plurality of different manufacturers, and further accurately load the corresponding driver.
In order to solve the technical problems, the invention adopts the technical scheme that:
a method for identifying liquid crystals of different manufacturers comprises the following steps:
s1, connecting a data line interface of the liquid crystal with a reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, obtaining the connection state of the liquid crystal ID pin, and obtaining first liquid crystal information corresponding to the connection state.
The invention adopts another technical scheme that:
a system for identifying liquid crystals of different manufacturers comprises a configuration module and an acquisition module;
the configuration module is used for connecting a data line interface of the liquid crystal with the reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
the acquisition module is used for reading the reading pin to obtain a first numerical value, and if the first numerical value is valid, acquiring the connection state of the liquid crystal ID pin and acquiring first liquid crystal information corresponding to the connection state.
The invention has the beneficial effects that:
the invention provides a method and a system for identifying liquid crystals of different manufacturers, which are characterized in that a data line interface of the liquid crystals is connected with a reading pin by utilizing a data line interface of the liquid crystals, and the data line interface is configured with a GPIO (general purpose input/output) port and is in a low level output state, and the state of the reading pin is configured as a pull-down input, so that the data receiving and transmitting functions of the data lines are closed in the identification process, the interference on data transmission is avoided, in addition, the data line interface can adopt an 8080 data bus with eight output pins, namely 8 data lines can be added on the original identification number, and therefore, the identification method provided by the invention can identify at least 11 different liquid crystal manufacturers.
Drawings
FIG. 1 is a flow chart illustrating the steps of a method for identifying liquid crystals of different manufacturers according to the present invention;
FIG. 2 is a schematic diagram of a system for identifying liquid crystals of different manufacturers according to the present invention;
FIG. 3 is a flowchart illustrating steps of a method for identifying liquid crystals of different manufacturers according to an embodiment of the present invention;
description of reference numerals:
1. a configuration module; 2. and an acquisition module.
Detailed Description
The most key concept of the invention is as follows: and the identification number of liquid crystal manufacturers is expanded by using a data line interface of the liquid crystal.
Referring to fig. 1, the method for identifying liquid crystals of different manufacturers according to the present invention includes the following steps:
s1, connecting a data line interface of the liquid crystal with a reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, obtaining the connection state of the liquid crystal ID pin, and obtaining first liquid crystal information corresponding to the connection state.
From the above description, the beneficial effects of the present invention are: the invention provides a method for identifying liquid crystals of different manufacturers, which is characterized in that a data line interface of the liquid crystals is connected with a reading pin by utilizing a data line interface of the liquid crystals, and the data line interface is configured with a GPIO (general purpose input/output) port and is in a low level output state, and the state of the reading pin is in pull-down input, so that the data receiving and transmitting functions of the data lines are closed in the identification process, the interference on data transmission is avoided, in addition, the data line interface can adopt an 8080 data bus with eight output pins, namely 8 data lines can be added on the original identification number, and therefore, the identification method provided by the invention can identify at least 11 different liquid crystal manufacturers. In the case of an 8080 data bus of sixteen data lines, 19 different liquid crystal manufacturers can be identified by the method.
Further, step S2 is specifically:
s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, the connection state of the ID pin of the liquid crystal is that the ID pin of the liquid crystal is connected with a power supply, and first liquid crystal information corresponding to the connection state of the ID pin of the liquid crystal and the power supply is obtained.
In an embodiment, as shown in fig. 3, a correspondence table between the connection state of the ID pin and the liquid crystal information is created in advance, when the interface of the liquid crystal data line is configured as a GPIO port and is in a low level output state, and the state of the read pin is configured as a pull-down input, if the read pin is read to obtain a first value which is valid, it indicates that the ID pin of the liquid crystal and the power supply are in a connection state, and the correspondence table is queried to obtain the liquid crystal information corresponding to the connection state, which is the liquid crystal manufacturer identification code.
Further, step S2 further includes:
if the first numerical value is invalid, sequentially configuring each output pin of the data line interface to be in a high-level output state, and reading the reading pin to obtain a corresponding numerical value;
and if the numerical value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code.
In an embodiment, if the ID pin of the liquid crystal is not connected to the power supply, the connection mode of each output pin of the data line interface is determined, and if the ID pin of the liquid crystal is connected to one of the output pins, when the output pin configured in the high-level output state is connected to the ID pin of the liquid crystal, the value obtained by reading the read pin is valid, so that it is only necessary to sequentially configure each output pin of the data line interface in the high-level output state, and as long as the value obtained by reading the read pin is valid, it is known which output pin is connected to the ID pin of the liquid crystal, where each output pin has a unique identification code for distinguishing the pins.
Further, if the first value is invalid, sequentially configuring each output pin of the data line interface to be in a high-level output state, and reading the reading pin to obtain a corresponding value; if the value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code, wherein the specific steps are as follows:
if the first value is invalid, configuring a first output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a second value, and if the second value is valid, acquiring an identification code of the first output pin and acquiring liquid crystal information corresponding to the identification code of the first output pin; the data line interface is an 8080 bus and comprises a first output pin, a second output pin, a third output pin, a fourth output pin, a fifth output pin, a sixth output pin, a seventh output pin and an eighth output pin;
if the second value is invalid, configuring a second output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a third value, and if the third value is valid, acquiring an identification code of the second output pin and acquiring liquid crystal information corresponding to the identification code of the second output pin;
if the third value is invalid, configuring a third output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fourth value, and if the fourth value is valid, acquiring an identification code of the third output pin and acquiring liquid crystal information corresponding to the identification code of the third output pin;
if the fourth value is invalid, configuring a fourth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fifth value, and if the fifth value is valid, acquiring an identification code of the fourth output pin and acquiring liquid crystal information corresponding to the identification code of the fourth output pin;
if the fifth value is invalid, configuring a fifth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a sixth value, and if the sixth value is valid, acquiring an identification code of the fifth output pin and acquiring liquid crystal information corresponding to the identification code of the fifth output pin;
if the sixth numerical value is invalid, configuring a sixth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a seventh numerical value, and if the seventh numerical value is valid, obtaining an identification code of the sixth output pin and obtaining liquid crystal information corresponding to the identification code of the sixth output pin;
if the seventh numerical value is invalid, configuring a seventh output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain an eighth numerical value, and if the eighth numerical value is valid, acquiring an identification code of the seventh output pin and acquiring liquid crystal information corresponding to the identification code of the seventh output pin;
and if the eighth numerical value is invalid, configuring an eighth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a ninth numerical value, and if the ninth numerical value is valid, obtaining the identification code of the eighth output pin and obtaining the liquid crystal information corresponding to the identification code of the eighth output pin.
In the embodiment, each output pin of the data line interface is sequentially configured to be in a high-level output state in the above manner, and whether each output pin is connected to the ID pin of the liquid crystal can be determined.
Further, step S2 further includes:
if the second numerical value, the third numerical value, the fourth numerical value, the fifth numerical value, the sixth numerical value, the seventh numerical value, the eighth numerical value and the ninth numerical value are all invalid, configuring the state of the reading pin as pull-up input;
reading the reading pin to obtain a tenth value, if the tenth value is valid, the connection state of the ID pin of the liquid crystal is suspended, and acquiring third liquid crystal information corresponding to the suspension state of the connection state;
and if the tenth value is invalid, the connection state of the ID pin of the liquid crystal is grounded, and fourth liquid crystal information corresponding to the grounding connection state is acquired.
Further, step S1 is preceded by:
judging whether to drive the liquid crystal, if so, entering the step S1;
step S2 is followed by:
and obtaining a corresponding liquid crystal manufacturer identification code according to the obtained liquid crystal information, loading a liquid crystal driving program of the corresponding liquid crystal manufacturer, and operating the liquid crystal driving program to drive the liquid crystal.
In the implementation mode, the identification process provided by the scheme is entered only when the liquid crystal needs to be driven, specifically, whether the liquid crystal is driven can be judged by judging whether an instruction for driving the liquid crystal is received, if the instruction for driving the liquid crystal is received, namely, the liquid crystal needs to be driven, the data line interface can be set as the identification port and is not the data transmission interface, and the purpose of changing the data line interface can occupy a large amount of data transmission time, so that the data line interface is configured only when the liquid crystal needs to be driven.
Further, operating the liquid crystal driving program to drive the liquid crystal specifically includes:
and configuring a liquid crystal data line interface to be in a data receiving and sending state, configuring the state of a reading pin to be in no pull-up input and no pull-down input, and operating the liquid crystal driving program to drive the liquid crystal of the corresponding liquid crystal manufacturer.
In the embodiment, in order not to affect normal data communication, after identification, the liquid crystal data line interface is configured to be in a data receiving and transmitting state, and the reading pin is configured to be in a state without pull-up input or pull-down input, so that the identification process is completed.
Referring to fig. 2, the invention further provides a system for identifying liquid crystals of different manufacturers, which includes a configuration module 1 and an acquisition module 2;
the configuration module 1 is used for connecting a data line interface of the liquid crystal with a reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
the obtaining module 2 is configured to read the reading pin to obtain a first value, and if the first value is valid, obtain a connection state of the liquid crystal ID pin, and obtain first liquid crystal information corresponding to the connection state.
From the above description, the beneficial effects of the present invention are: the invention provides a system for identifying liquid crystals of different manufacturers, which is characterized in that a data line interface of the liquid crystals is connected with a reading pin by utilizing a data line interface of the liquid crystals, and the data line interface is configured with a GPIO (general purpose input/output) port and is in a low level output state, and the state of the reading pin is in pull-down input, so that the data receiving and transmitting functions of the data lines are closed in the identification process, the interference on data transmission is avoided, in addition, the data line interface can adopt an 8080 data bus with eight output pins, namely 8 data lines can be added on the original identification number, and therefore, the identification method provided by the invention can identify at least 11 different liquid crystal manufacturers. In the case of an 8080 data bus of sixteen data lines, 19 different liquid crystal manufacturers can be identified by the method.
Further, the obtaining module is further configured to read the reading pin to obtain a first value, and if the first value is valid, the connection state of the ID pin of the liquid crystal is that the ID pin of the liquid crystal is connected to the power supply, and obtain first liquid crystal information that the connection state is that the ID pin of the liquid crystal is connected to the power supply.
In an embodiment, as shown in fig. 3, a correspondence table between the connection state of the ID pin and the liquid crystal information is created in advance, when the interface of the liquid crystal data line is configured as a GPIO port and is in a low level output state, and the state of the read pin is configured as a pull-down input, if the read pin is read to obtain a first value which is valid, it indicates that the ID pin of the liquid crystal and the power supply are in a connection state, and the correspondence table is queried to obtain the liquid crystal information corresponding to the connection state, which is the liquid crystal manufacturer identification code.
Further, the obtaining module is further configured to, if the first value is invalid, sequentially configure each output pin of the data line interface to be in a high-level output state, and read the read pin to obtain a corresponding value; and if the numerical value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code.
In an embodiment, if the ID pin of the liquid crystal is not connected to the power supply, the connection mode of each output pin of the data line interface is determined, and if the ID pin of the liquid crystal is connected to one of the output pins, when the output pin configured in the high-level output state is connected to the ID pin of the liquid crystal, the value obtained by reading the read pin is valid, so that it is only necessary to sequentially configure each output pin of the data line interface in the high-level output state, and as long as the value obtained by reading the read pin is valid, it is known which output pin is connected to the ID pin of the liquid crystal, where each output pin has a unique identification code for distinguishing the pins.
Further, the obtaining module is further configured to configure a first output pin of the data line interface to be in a high-level output state if the first value is invalid, read the read pin to obtain a second value, and obtain the identification code of the first output pin and obtain the liquid crystal information corresponding to the identification code of the first output pin if the second value is valid; the data line interface is an 8080 bus and comprises a first output pin, a second output pin, a third output pin, a fourth output pin, a fifth output pin, a sixth output pin, a seventh output pin and an eighth output pin;
if the second value is invalid, configuring a second output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a third value, and if the third value is valid, acquiring an identification code of the second output pin and acquiring liquid crystal information corresponding to the identification code of the second output pin;
if the third value is invalid, configuring a third output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fourth value, and if the fourth value is valid, acquiring an identification code of the third output pin and acquiring liquid crystal information corresponding to the identification code of the third output pin;
if the fourth value is invalid, configuring a fourth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fifth value, and if the fifth value is valid, acquiring an identification code of the fourth output pin and acquiring liquid crystal information corresponding to the identification code of the fourth output pin;
if the fifth value is invalid, configuring a fifth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a sixth value, and if the sixth value is valid, acquiring an identification code of the fifth output pin and acquiring liquid crystal information corresponding to the identification code of the fifth output pin;
if the sixth numerical value is invalid, configuring a sixth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a seventh numerical value, and if the seventh numerical value is valid, obtaining an identification code of the sixth output pin and obtaining liquid crystal information corresponding to the identification code of the sixth output pin;
if the seventh numerical value is invalid, configuring a seventh output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain an eighth numerical value, and if the eighth numerical value is valid, acquiring an identification code of the seventh output pin and acquiring liquid crystal information corresponding to the identification code of the seventh output pin;
and if the eighth numerical value is invalid, configuring an eighth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a ninth numerical value, and if the ninth numerical value is valid, obtaining the identification code of the eighth output pin and obtaining the liquid crystal information corresponding to the identification code of the eighth output pin.
In the embodiment, each output pin of the data line interface is sequentially configured to be in a high-level output state in the above manner, and whether each output pin is connected to the ID pin of the liquid crystal can be determined.
Further, the obtaining module is further configured to configure the state of the read pin as a pull-up input if the second numerical value, the third numerical value, the fourth numerical value, the fifth numerical value, the sixth numerical value, the seventh numerical value, the eighth numerical value, and the ninth numerical value are all invalid;
reading the reading pin to obtain a tenth value, if the tenth value is valid, the connection state of the ID pin of the liquid crystal is suspended, and acquiring third liquid crystal information corresponding to the suspension state of the connection state;
and if the tenth value is invalid, the connection state of the ID pin of the liquid crystal is grounded, and fourth liquid crystal information corresponding to the grounding connection state is acquired.
Furthermore, the device also comprises a judging module and a driving module;
the judging module is used for judging whether to drive the liquid crystal, and if so, entering the configuration module;
and the driving module is used for obtaining a corresponding liquid crystal manufacturer identification code according to the obtained liquid crystal information, loading a liquid crystal driving program corresponding to the liquid crystal manufacturer, and operating the liquid crystal driving program to drive the liquid crystal.
In the implementation mode, the identification process provided by the scheme is entered only when the liquid crystal needs to be driven, specifically, whether the liquid crystal is driven can be judged by judging whether an instruction for driving the liquid crystal is received, if the instruction for driving the liquid crystal is received, namely, the liquid crystal needs to be driven, the data line interface can be set as the identification port and is not the data transmission interface, and the purpose of changing the data line interface can occupy a large amount of data transmission time, so that the data line interface is configured only when the liquid crystal needs to be driven.
Further, the driving module is further configured to configure the liquid crystal data line interface to be in a data receiving and sending state, configure the read pin to be in a no-pull-up input state and a no-pull-down input state, and operate the liquid crystal driving program to drive the liquid crystal of the corresponding liquid crystal manufacturer.
In the embodiment, in order not to affect normal data communication, after identification, the liquid crystal data line interface is configured to be in a data receiving and transmitting state, and the reading pin is configured to be in a state without pull-up input or pull-down input, so that the identification process is completed.
Referring to fig. 1-3, a first embodiment of the present invention is:
1. according to the definition of the connection relationship of the ID pins in advance (as shown in Table 1), the liquid crystal manufacturer is informed to manufacture the liquid crystal according to the definition.
Manufacturer of the product ID pin connection mode
Manufacturer 1 ID pin and D0 connection
Manufacturer
2 ID pin and D1 connection
Manufacturer 3 ID pin and D2 connection
Manufacturer 4 ID pin and D3 connection
Manufacturer 5 ID pin and D4 connection
Manufacturer 6 ID feet and D5 connection to
Manufacturer 7 ID pin and D6 connection
Manufacturer 8 ID pin and D7 connection
Manufacturer 9 ID pin and power connection
Manufacturer 10 ID pin and ground connection
Manufacturer 11 ID pin is unsettled
TABLE 1
2. Assembling the liquid crystal on the machine, starting the machine, and operating the method for identifying the liquid crystal of different manufacturers.
3. The method for identifying the liquid crystal of different manufacturers is applied before loading the liquid crystal drive, software firstly identifies the connection mode of an ID pin, the scheme takes 8bit data lines D0-D7 as an example, and the steps are as follows:
step 1: the main control end configures the reading pin LCD _ ID as a pull-down input, connects a data line interface of the liquid crystal with the reading pin, configures the data line interface of the 8080 bus as a common GPIO and outputs at a low level, and then reads the value of the reading pin LCD _ ID.
Step 2: if the value of the LCD _ ID is read to be 1, the current liquid crystal ID pin is connected to a power supply; if the value of the LCD _ ID is read to be not 1, executing the step 3;
it should be noted that: the value of LCD _ ID is 1, which indicates that the value is valid; the value of LCD _ ID is not 1, indicating invalidity.
And step 3: outputting a high level to D0, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D0, and if the value of LCD _ ID is read to be not 1, executing step 4;
and 4, step 4: outputting a high level to D1, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D1, and if the value of LCD _ ID is read to be not 1, executing step 5;
and 5: outputting a high level to D2, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D2, and if the value of LCD _ ID is read to be not 1, executing step 6;
step 6: outputting a high level to D3, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D3, and if the value of LCD _ ID is read to be not 1, executing step 7;
and 7: outputting a high level to D4, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D4, and if the value of LCD _ ID is read to be not 1, executing step 8;
and 8: outputting a high level to D5, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D5, and if the value of LCD _ ID is read to be not 1, executing step 9;
and step 9: outputting a high level to D6, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D6, and if the value of LCD _ ID is read to be not 1, executing step 10;
step 10: outputting a high level to D7, reading the value of LCD _ ID, if the value of LCD _ ID is read to be 1, connecting the current liquid crystal ID pin to D7, and if the value of LCD _ ID is read to be not 1, executing step 11;
step 11: configuring the LCD _ ID to be input pull-up, reading the value of the LCD _ ID, and suspending the current ID pin of the liquid crystal if the value of the LCD _ ID is read to be 1; if the value of LCD _ ID is read to be not 1, the ID pin of the current liquid crystal is connected to the ground.
Step 12: the LCD _ ID is configured as an input and without pull-up and pull-down, the data line DX is configured as an 8080 bus function, and the ID pin identification is completed.
4. Software identifies the current liquid crystal ID pin connection mode, compares the current liquid crystal ID pin connection mode with the predefined ID pin connection mode to know which manufacturer the current liquid crystal is, and then loads the corresponding liquid crystal drive.
In summary, the method and system for identifying liquid crystals of different manufacturers provided by the present invention connect the data line interface of the liquid crystal with the reading pin by using the data line interface of the liquid crystal itself, and close the data receiving and transmitting function of the data line in the identification process by configuring the GPIO port of the data line interface and being in the low level output state and configuring the state of the reading pin as the pull-down input, so as to avoid interference to data transmission, and in addition, the data line interface can adopt 8080 data bus with eight output pins, that is, 8 data lines can be added to the original identification number, so the identification method provided by the present invention can identify at least 11 different liquid crystal manufacturers. In the case of an 8080 data bus of sixteen data lines, 19 different liquid crystal manufacturers can be identified by the method. According to the method and the system for identifying the liquid crystal of different manufacturers, provided by the invention, the expansion can be realized only by connecting the data line interface of the liquid crystal with the reading pin without hardware cost, and the normal use of the data line is ensured.

Claims (10)

1. A method for identifying liquid crystals of different manufacturers is characterized by comprising the following steps:
s1, connecting a data line interface of the liquid crystal with a reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, obtaining the connection state of the liquid crystal ID pin, and obtaining first liquid crystal information corresponding to the connection state;
step S2 specifically includes:
s2, reading the reading pin to obtain a first numerical value, if the first numerical value is valid, the connection state of the ID pin of the liquid crystal is that the ID pin of the liquid crystal is connected with a power supply, and first liquid crystal information corresponding to the connection state of the ID pin of the liquid crystal and the power supply is obtained;
step S2 further includes:
if the first numerical value is invalid, sequentially configuring each output pin of the data line interface to be in a high-level output state, and reading the reading pin to obtain a corresponding numerical value;
and if the numerical value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code.
2. The method for identifying liquid crystals of different manufacturers according to claim 1, wherein if the first value is invalid, each output pin of the data line interface is sequentially configured to be in a high-level output state, and the read pin is read to obtain a corresponding value; if the value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code, wherein the specific steps are as follows:
if the first value is invalid, configuring a first output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a second value, and if the second value is valid, acquiring an identification code of the first output pin and acquiring liquid crystal information corresponding to the identification code of the first output pin; the data line interface is an 8080 bus and comprises a first output pin, a second output pin, a third output pin, a fourth output pin, a fifth output pin, a sixth output pin, a seventh output pin and an eighth output pin;
if the second value is invalid, configuring a second output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a third value, and if the third value is valid, acquiring an identification code of the second output pin and acquiring liquid crystal information corresponding to the identification code of the second output pin;
if the third value is invalid, configuring a third output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fourth value, and if the fourth value is valid, acquiring an identification code of the third output pin and acquiring liquid crystal information corresponding to the identification code of the third output pin;
if the fourth value is invalid, configuring a fourth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fifth value, and if the fifth value is valid, acquiring an identification code of the fourth output pin and acquiring liquid crystal information corresponding to the identification code of the fourth output pin;
if the fifth value is invalid, configuring a fifth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a sixth value, and if the sixth value is valid, acquiring an identification code of the fifth output pin and acquiring liquid crystal information corresponding to the identification code of the fifth output pin;
if the sixth numerical value is invalid, configuring a sixth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a seventh numerical value, and if the seventh numerical value is valid, obtaining an identification code of the sixth output pin and obtaining liquid crystal information corresponding to the identification code of the sixth output pin;
if the seventh numerical value is invalid, configuring a seventh output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain an eighth numerical value, and if the eighth numerical value is valid, acquiring an identification code of the seventh output pin and acquiring liquid crystal information corresponding to the identification code of the seventh output pin;
and if the eighth numerical value is invalid, configuring an eighth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a ninth numerical value, and if the ninth numerical value is valid, obtaining the identification code of the eighth output pin and obtaining the liquid crystal information corresponding to the identification code of the eighth output pin.
3. The method of claim 2, wherein the step S2 further comprises:
if the second numerical value, the third numerical value, the fourth numerical value, the fifth numerical value, the sixth numerical value, the seventh numerical value, the eighth numerical value and the ninth numerical value are all invalid, configuring the state of the reading pin as pull-up input;
reading the reading pin to obtain a tenth value, if the tenth value is valid, the connection state of the ID pin of the liquid crystal is suspended, and acquiring third liquid crystal information corresponding to the suspension state of the connection state;
and if the tenth value is invalid, the connection state of the ID pin of the liquid crystal is grounded, and fourth liquid crystal information corresponding to the grounding connection state is acquired.
4. The method for identifying liquid crystals of different manufacturers according to any one of claims 1 to 3, wherein the step S1 is preceded by the steps of:
judging whether to drive the liquid crystal, if so, entering the step S1;
step S2 is followed by:
and obtaining a corresponding liquid crystal manufacturer identification code according to the obtained liquid crystal information, loading a liquid crystal driving program of the corresponding liquid crystal manufacturer, and operating the liquid crystal driving program to drive the liquid crystal.
5. The method for identifying liquid crystals of different manufacturers according to claim 4, wherein the liquid crystal driver is operated to drive the liquid crystals, specifically:
and configuring a liquid crystal data line interface to be in a data receiving and sending state, configuring the state of a reading pin to be in no pull-up input and no pull-down input, and operating the liquid crystal driving program to drive the liquid crystal of the corresponding liquid crystal manufacturer.
6. A system for identifying liquid crystals of different manufacturers is characterized by comprising a configuration module and an acquisition module;
the configuration module is used for connecting a data line interface of the liquid crystal with the reading pin, configuring the liquid crystal data line interface as a GPIO (general purpose input/output) port and in a low level output state, and configuring the reading pin as a pull-down input;
the acquisition module is used for reading the reading pin to obtain a first numerical value, and if the first numerical value is valid, acquiring the connection state of the liquid crystal ID pin and acquiring first liquid crystal information corresponding to the connection state;
the acquisition module is further configured to read the reading pin to obtain a first numerical value, and if the first numerical value is valid, the connection state of the ID pin of the liquid crystal is that the ID pin of the liquid crystal is connected to the power supply, and first liquid crystal information corresponding to the connection state of the ID pin of the liquid crystal and the power supply is acquired;
the obtaining module is further configured to, if the first value is invalid, sequentially configure each output pin of the data line interface to be in a high-level output state, and read the read pin to obtain a corresponding value; and if the numerical value obtained by reading the reading pins is valid, acquiring the identification code of the corresponding output pin, and acquiring second liquid crystal information corresponding to the identification code.
7. The system for identifying liquid crystals of different manufacturers according to claim 6, wherein the obtaining module is further configured to configure a first output pin of the data line interface to be in a high-level output state if the first value is invalid, read the read pin to obtain a second value, and obtain the identification code of the first output pin and obtain the liquid crystal information corresponding to the identification code of the first output pin if the second value is valid; the data line interface is an 8080 bus and comprises a first output pin, a second output pin, a third output pin, a fourth output pin, a fifth output pin, a sixth output pin, a seventh output pin and an eighth output pin;
if the second value is invalid, configuring a second output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a third value, and if the third value is valid, acquiring an identification code of the second output pin and acquiring liquid crystal information corresponding to the identification code of the second output pin;
if the third value is invalid, configuring a third output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fourth value, and if the fourth value is valid, acquiring an identification code of the third output pin and acquiring liquid crystal information corresponding to the identification code of the third output pin;
if the fourth value is invalid, configuring a fourth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a fifth value, and if the fifth value is valid, acquiring an identification code of the fourth output pin and acquiring liquid crystal information corresponding to the identification code of the fourth output pin;
if the fifth value is invalid, configuring a fifth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a sixth value, and if the sixth value is valid, acquiring an identification code of the fifth output pin and acquiring liquid crystal information corresponding to the identification code of the fifth output pin;
if the sixth numerical value is invalid, configuring a sixth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a seventh numerical value, and if the seventh numerical value is valid, obtaining an identification code of the sixth output pin and obtaining liquid crystal information corresponding to the identification code of the sixth output pin;
if the seventh numerical value is invalid, configuring a seventh output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain an eighth numerical value, and if the eighth numerical value is valid, acquiring an identification code of the seventh output pin and acquiring liquid crystal information corresponding to the identification code of the seventh output pin;
and if the eighth numerical value is invalid, configuring an eighth output pin of the data line interface to be in a high-level output state, reading the reading pin to obtain a ninth numerical value, and if the ninth numerical value is valid, obtaining the identification code of the eighth output pin and obtaining the liquid crystal information corresponding to the identification code of the eighth output pin.
8. The system for identifying liquid crystals of different manufacturers according to claim 7, wherein the obtaining module is further configured to configure the state of the read pin as a pull-up input if the second, third, fourth, fifth, sixth, seventh, eighth, and ninth values are all invalid;
reading the reading pin to obtain a tenth value, if the tenth value is valid, the connection state of the ID pin of the liquid crystal is suspended, and acquiring third liquid crystal information corresponding to the suspension state of the connection state;
and if the tenth value is invalid, the connection state of the ID pin of the liquid crystal is grounded, and fourth liquid crystal information corresponding to the grounding connection state is acquired.
9. The system for identifying the liquid crystal of different manufacturers according to any one of claims 6 to 8, further comprising a judging module and a driving module;
the judging module is used for judging whether to drive the liquid crystal, and if so, entering the configuration module;
and the driving module is used for obtaining a corresponding liquid crystal manufacturer identification code according to the obtained liquid crystal information, loading a liquid crystal driving program corresponding to the liquid crystal manufacturer, and operating the liquid crystal driving program to drive the liquid crystal.
10. The system for identifying liquid crystals of different manufacturers according to claim 9, wherein the driving module is further configured to configure the liquid crystal data line interface to be in a data receiving and sending state, configure the read pin to be in a no pull-up input and no pull-down input state, and operate the liquid crystal driving program to drive the liquid crystals of the corresponding liquid crystal manufacturers.
CN201780000414.6A 2017-05-27 2017-05-27 Method and system for identifying liquid crystals of different manufacturers Active CN107636632B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2017/086352 WO2018218430A1 (en) 2017-05-27 2017-05-27 Method and system for identifying liquid crystal of different manufacturers

Publications (2)

Publication Number Publication Date
CN107636632A CN107636632A (en) 2018-01-26
CN107636632B true CN107636632B (en) 2020-05-05

Family

ID=61108003

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201780000414.6A Active CN107636632B (en) 2017-05-27 2017-05-27 Method and system for identifying liquid crystals of different manufacturers

Country Status (2)

Country Link
CN (1) CN107636632B (en)
WO (1) WO2018218430A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107636632B (en) * 2017-05-27 2020-05-05 福建联迪商用设备有限公司 Method and system for identifying liquid crystals of different manufacturers
CN111144733B (en) * 2019-12-23 2023-07-18 宁波三星医疗电气股份有限公司 Platform identification method, platform identification device, metering automation terminal and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101131731A (en) * 2007-07-25 2008-02-27 中兴通讯股份有限公司 Method for recognizing chip types of mobile phone LCD
CN101695088A (en) * 2009-10-19 2010-04-14 深圳华为通信技术有限公司 Module identification method and terminal
CN102164193A (en) * 2011-01-21 2011-08-24 惠州Tcl移动通信有限公司 Electronic device, manufacturing method thereof and method for identifying and driving display screen
CN104298635A (en) * 2014-09-26 2015-01-21 福建联迪商用设备有限公司 Method and device for recognizing equipment version information through GPIO port line
CN105652973A (en) * 2015-12-28 2016-06-08 深圳宝龙达信息技术股份有限公司 Mainboard structure compatible with notebook computer and multi-source liquid crystal screen

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6694428B2 (en) * 2000-11-29 2004-02-17 Palm One, Inc. System for indentifying a peripheral device by sending an inquiry thereto after receiving an interrupt notification message if the interrupt and communication port meet predetermined conditions
CN107636632B (en) * 2017-05-27 2020-05-05 福建联迪商用设备有限公司 Method and system for identifying liquid crystals of different manufacturers

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101131731A (en) * 2007-07-25 2008-02-27 中兴通讯股份有限公司 Method for recognizing chip types of mobile phone LCD
CN101695088A (en) * 2009-10-19 2010-04-14 深圳华为通信技术有限公司 Module identification method and terminal
CN102164193A (en) * 2011-01-21 2011-08-24 惠州Tcl移动通信有限公司 Electronic device, manufacturing method thereof and method for identifying and driving display screen
CN104298635A (en) * 2014-09-26 2015-01-21 福建联迪商用设备有限公司 Method and device for recognizing equipment version information through GPIO port line
CN105652973A (en) * 2015-12-28 2016-06-08 深圳宝龙达信息技术股份有限公司 Mainboard structure compatible with notebook computer and multi-source liquid crystal screen

Also Published As

Publication number Publication date
WO2018218430A1 (en) 2018-12-06
CN107636632A (en) 2018-01-26

Similar Documents

Publication Publication Date Title
CN106055361B (en) Integrated firmware implementation method and system for multiple different types based on BMC (baseboard management controller)
CN104361871A (en) Display screen debugging method, device and system
EP2546825A1 (en) Method, device and terminal for identifying lcd screen
CN109426625A (en) A kind of control device and implementation method that more drivings are compatible
CN100383737C (en) SCM online loading and updating method and system
JP6359955B2 (en) Serial communication system, communication control device, and electronic device
CN107636632B (en) Method and system for identifying liquid crystals of different manufacturers
CN101702299A (en) System and method for identifying LCD module
CN101370202A (en) Method for automatic recognition of different display devices by mobile phone
CN101208913A (en) Simultaneous control of multiple I/O banks in an I2C slave device
CN103902480A (en) Android phone driving method and system
CN101159814A (en) Embedded equipment camera software dynamic recognizing method
CN107526614B (en) Communication method of FPGA development board
CN103389845A (en) Capacitance touch screen burn test system
CN106933754A (en) A kind of USB drives recognition methods and device
CN113553289A (en) MCU pin function configuration method based on SOC chip and SOC chip
CN101127978A (en) Method for mobile phone to be compatible to different display part
CN110795369B (en) Method and terminal for realizing MDIO slave function based on GPIO pin
CN102445981B (en) Data transmission system and data transmission method
CN109933471A (en) Method, apparatus, computer readable storage medium are surveyed in Android device and its production
CN204066271U (en) A kind of device customized towards POS or scale of tracing to the source
CN216356999U (en) Television and display device
CN216057079U (en) Internet of things terminal and internet of things system
CN101719053A (en) Method for reading IIC storage card by SPI interface
CN206353307U (en) Mobile terminal for debugging peripheral hardware

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
GR01 Patent grant
GR01 Patent grant