CN115834970A - Light sensing module control method and device, display equipment and storage medium - Google Patents

Light sensing module control method and device, display equipment and storage medium Download PDF

Info

Publication number
CN115834970A
CN115834970A CN202211370598.4A CN202211370598A CN115834970A CN 115834970 A CN115834970 A CN 115834970A CN 202211370598 A CN202211370598 A CN 202211370598A CN 115834970 A CN115834970 A CN 115834970A
Authority
CN
China
Prior art keywords
light sensing
sensing module
signal line
module
bus
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
Application number
CN202211370598.4A
Other languages
Chinese (zh)
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.)
Shenzhen Skyworth RGB Electronics Co Ltd
Original Assignee
Shenzhen Skyworth RGB Electronics 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 Shenzhen Skyworth RGB Electronics Co Ltd filed Critical Shenzhen Skyworth RGB Electronics Co Ltd
Priority to CN202211370598.4A priority Critical patent/CN115834970A/en
Publication of CN115834970A publication Critical patent/CN115834970A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Photometry And Measurement Of Optical Pulse Characteristics (AREA)

Abstract

The invention belongs to the technical field of display equipment and discloses a light sensing module control method and device, display equipment and a storage medium. The method comprises the following steps: when the starting of the equipment is detected, matching the light sensing modules to obtain the equipment number information of the light sensing modules; configuring each light sensing module according to the equipment number information so as to start and work each light sensing module and detect whether each light sensing module in the equipment is abnormal or not; when the detection result indicates that the light sensing module is abnormal, configuring the bus and each signal line of the light sensing module as an appointed transmission mode; and finishing reading operation on each light sensing module in a designated transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module. By the mode, the applicability of the light sensing module on the display device is improved. And when the light sensing module is abnormal, the bus and each signal line are automatically configured and normal starting is completed, so that the starting is prevented from being influenced by the abnormality of a single light sensing module.

Description

Light sensing module control method and device, display equipment and storage medium
Technical Field
The invention relates to the technical field of display equipment, in particular to a light sensing module control method and device, display equipment and a storage medium.
Background
A television has one common function: the backlight function is automatically adjusted. The function needs to use a light sensing equipment module, the intensity of the ambient light is obtained through the light sensing equipment module, and then the backlight brightness is correspondingly adjusted according to the configured mapping relation between the light intensity and the backlight brightness. The common light sensing equipment module adopts a bus (I2C) interface to communicate with a host. The host can send an instruction to the light sensing module through the I2C, and can also read the light sensing value detected by the current light sensing equipment module through the I2C. Different light sensitivity values correspond to different light intensities. The television set determines the light intensity of the current environment through the read light sensation value. And then calling the backlight brightness value of the display set by the platform according to the preset mapping relation between the light sensitivity value and the backlight brightness, and finally realizing the function of automatically adjusting the backlight.
Due to the uncertainty of the light sensation module supply, for example, if a television of a certain model is only provided with one model of light sensation, a provider suddenly cannot supply the light sensation module normally. Because no substitute exists, the software is required to be adapted again only by introducing light senses of other models, and mass production can be introduced only after subjective evaluation is free of problems. Because only one type of light sensing module is configured, no substitute is troublesome, so that the time for mass production and marketing of products is influenced, and the problem of solving the light sensing module through after-sale treatment is also influenced. And normally, the damage of the light-sensing module can pull the I2C bus to be dead, thereby causing the problem of slow startup.
The above is only for the purpose of assisting understanding of the technical solution of the present invention, and does not represent an admission that the above is the prior art.
Disclosure of Invention
The invention mainly aims to provide a light sensing module control method, a light sensing module control device, a display device and a storage medium, and aims to solve the technical problems that a light sensing module of a display device in the prior art is low in applicability and the starting is affected due to the damage of a single light sensing module.
In order to achieve the above object, the present invention provides a method for controlling a light sensing module, the method comprising the steps of:
when the equipment is detected to be started, matching the light sensing modules to obtain the equipment number information of the light sensing modules;
configuring each light sensing module according to the equipment number information so as to start and work each light sensing module, and detecting whether each light sensing module in the equipment is abnormal or not;
when the detection result indicates that the light sensing module is abnormal, configuring a bus and each signal line of the light sensing module as an appointed transmission mode;
and finishing the reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module.
Optionally, the detecting that the device is started matches each light sensing module to obtain the device number information of each light sensing module includes:
when the equipment is detected to be started, information of the supporting light sensor is obtained;
generating a device address configuration strategy according to the information of the light sensing supporting device;
and matching the light sensing modules according to the device address configuration strategy to obtain the equipment number information of each light sensing module.
Optionally, the matching the light sensing modules according to the device address configuration policy to obtain the device number information of each light sensing module includes:
determining a device address configuration sequence according to the device address configuration strategy;
obtaining module device information of each light sensing module;
determining an equipment number comparison table of each light sensing module according to the module device information;
and matching the light sensing modules according to the device address configuration sequence and the equipment number comparison table to obtain the equipment number information of each light sensing module.
Optionally, the detecting whether there is an abnormality in a light sensing module in the apparatus includes:
acquiring bus information;
configuring a data signal line into a general input mode according to the bus information, transmitting a working signal through the data signal line in the general input mode, and detecting the signal level of the working signal on the data signal line;
and determining whether the light sensing module is abnormal or not according to the detected signal level of the data signal line.
Optionally, when the detection result indicates that the light sensing module is abnormal, configuring the bus and each signal line of the light sensing module as a designated transmission mode according to the detection result, including:
when the detection result indicates that the light sensing module is abnormal, configuring a clock signal line of the light sensing module into a general output mode, and transmitting a target clock signal through the clock signal line in the general output mode;
when the continuous clock number of the target clock signal is within a cycle threshold range and the continuous clock number changes to be at a low level, detecting the level of a data signal line of the light sensing module to obtain a first level detection result;
and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the first level detection result.
Optionally, after configuring the clock signal line of the light sensing module in a general input mode and outputting a target clock signal when the detection result indicates that the light sensing module is abnormal, the method further includes:
when the continuous clock quantity of the target clock signal is not in the range of the cycle threshold value, detecting the level of the data signal line to obtain a second level detection result;
and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the second level detection result.
Optionally, the configuring the bus and each signal line of the photo sensing module into a designated transmission mode according to the first level detection result includes:
when the first level detection result is that the data signal line is at a high level, configuring the data signal line into a general output mode;
and under the general output mode, the signal states of the data signal line and the clock signal line are adjusted according to a level adjustment strategy, so that the bus and each signal line of the light sensing module are configured into a designated transmission mode.
In addition, in order to achieve the above object, the present invention further provides a light sensing module control device, including:
the information matching module is used for matching the light sensing modules when the equipment is detected to be started to obtain the equipment number information of the light sensing modules;
the configuration starting module is used for configuring each light sensing module according to the equipment number information so as to start and work each light sensing module and detect whether each light sensing module in the equipment is abnormal or not;
the abnormity processing module is used for configuring the bus and each signal line of the light sensing module as an appointed transmission mode when the detection result indicates that the light sensing module is abnormal;
and the bus recovery module is used for completing reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module.
Further, to achieve the above object, the present invention also proposes a display apparatus comprising: the control method comprises a memory, a processor and a light sensing module control program stored on the memory and capable of running on the processor, wherein the light sensing module control program is configured to realize the steps of the light sensing module control method.
In addition, to achieve the above object, the present invention further provides a storage medium, wherein the storage medium stores a light sensing module control program, and the light sensing module control program, when executed by a processor, implements the steps of the light sensing module control method as described above.
When the equipment is detected to be started, the light sensing modules are matched to obtain the equipment number information of the light sensing modules; configuring each light sensing module according to the equipment number information so as to start and work each light sensing module, and detecting whether each light sensing module in the equipment is abnormal or not; when the detection result indicates that the light sensing module is abnormal, configuring a bus and each signal line of the light sensing module as an appointed transmission mode; and finishing reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module. By the mode, the light sensation modules of different types can be carried on the display equipment and are self-adaptively matched when the display equipment is started, and the applicability of the light sensation modules on the display equipment is improved. And when the light sensing module is abnormal, the bus and each signal wire can be automatically configured and normal starting can be completed, the phenomenon that starting is influenced by the abnormality of a single light sensing module is prevented, and when the abnormality of the light sensing module occurs, the communication state of the bus is timely found and recovered from a deadlock state.
Drawings
Fig. 1 is a schematic structural diagram of a display device in a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart illustrating a method for controlling a light sensing module according to a first embodiment of the present invention;
FIG. 3 is a flowchart illustrating a second embodiment of a method for controlling a light sensing module according to the present invention;
FIG. 4 is a complete flow chart of the anomaly detection of the light sensing module according to the embodiment of the control method of the light sensing module of the present invention;
FIG. 5 is a block diagram of a first embodiment of a light sensing module control device according to the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a display device in a hardware operating environment according to an embodiment of the present invention.
As shown in fig. 1, the display apparatus may include: a processor 1001, such as a Central Processing Unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein a communication bus 1002 is used to enable connective communication between these components. The user interface 1003 may include a Display (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a Wireless interface (e.g., a Wireless-F number identity (Wi-Fi) interface). The Memory 1005 may be a Random Access Memory (RAM) Memory, or a Non-Volatile Memory (NVM), such as a disk Memory. The memory 1005 may alternatively be a storage device separate from the processor 1001.
Those skilled in the art will appreciate that the configuration shown in fig. 1 does not constitute a limitation of the display device and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, the memory 1005, which is a storage medium, may include therein an operating system, a network communication module, a user interface module, and a light sensing module control program.
In the display device shown in fig. 1, the network interface 1004 is mainly used for data communication with a network server; the user interface 1003 is mainly used for data interaction with a user; the processor 1001 and the memory 1005 of the display device of the present invention may be provided in the display device, and the display device calls the photo module control program stored in the memory 1005 through the processor 1001 and executes the photo module control method provided by the embodiment of the present invention.
An embodiment of the invention provides a method for controlling a light sensing module, and referring to fig. 2, fig. 2 is a schematic flow chart of a first embodiment of the method for controlling the light sensing module.
In this embodiment, the method for controlling the light sensing module includes the following steps:
step S10: and when the equipment is detected to be started, matching the light sensing modules to obtain the equipment number information of the light sensing modules.
It should be noted that the execution subject of this embodiment is a processor or other information processing apparatus on a display device, and may be any display device, including but not limited to: the present invention is not limited to this, and the present invention may be implemented in a main chip, a processor, an onboard computer, etc. of a television, a display, a projector, etc., or other devices capable of implementing the functions.
It should be understood that, currently, light sensing modules of the same model are basically configured on a display device, but since only one light sensing module of the same model is configured, no substitute is needed, which is troublesome, and thus, not only the time for mass production and marketing of products is affected, but also the problem of solving the light sensing modules through after-sale processing is affected. And normally, the damaged light sensing module can pull the I2C bus to be dead, so that the damaged light sensing module causes the problem of slow startup. The scheme of the embodiment can automatically detect whether the light sensing module is abnormal or not when the equipment is started, and can configure the bus and each signal line of the light sensing module to a specified transmission mode when the light sensing module is abnormal. And completing reading operation on the equipment light sensing module in the appointed transmission mode, and recovering the equipment light sensing module from a deadlock state to be normal, so that the bus is prevented from being dead due to abnormal damage of the light sensing module. By the mode, the light sensation modules of different types can be carried on the display equipment and are self-adaptively matched when the display equipment is started, and the applicability of the light sensation modules on the display equipment is improved. And when the light sensing module is abnormal, the bus and each signal line can be automatically configured and normal starting can be completed, so that the starting is prevented from being influenced by the abnormality of the single light sensing module.
In a specific implementation, when it is detected that the device is started, it is first detected whether the light sensing module configured inside the device is abnormal, and the device may be any display device, which is not limited in this embodiment. The detection of the device boot is that the device is powered on and the main processor begins to operate.
It should be noted that the light sensing module in this embodiment may be any type of light sensing module of any brand, and may be different types of light sensing modules.
It should be understood that, when the device startup is detected, the process of matching each light-sensing module is started first, that is, the device number information corresponding to the device information of each light-sensing module is determined.
Further, in order to obtain the device number information of each photo sensing module, the step S30 includes: when the starting of the equipment is detected, the information of the supporting light sensing device is obtained; generating a device address configuration strategy according to the information of the light sensing supporting device; and matching the light sensing modules according to the device address configuration strategy to obtain the equipment number information of each light sensing module.
In a specific implementation, the information of the supported light-sensing devices refers to the device information of the light-sensing module devices supported by the current display device, which includes the device address, the function register address, the register address length, the data length, and the like of each supported light-sensing module.
It should be noted that, in the device address configuration policy generated according to the information of the light-sensing-supporting device, the device address configuration policy refers to an address configuration policy required for matching between each light-sensing module installed on the device and the light-sensing module supported by the device, where matching of the light-sensing modules is implemented by configuring different addresses for verification.
It should be understood that, matching each photo sensing module according to the device address configuration policy to obtain the device number information of each photo sensing module means: and executing a device address configuration strategy on each light sensing module, and verifying signals through I2C, thereby determining the equipment number information corresponding to each light sensing module.
By the method, the matching of the information of the supporting light sensing devices of all the light sensing modules supported by the display equipment is realized, so that the equipment number information of each light sensing module is obtained.
Further, in order to determine how to perform matching, matching each light sensing module according to the device address configuration policy to obtain the device number information of each light sensing module, including: determining a device address configuration sequence according to the device address configuration strategy; obtaining module device information of each light sensing module; determining an equipment number comparison table of each light sensing module according to the module device information; and matching the light sensing modules according to the device address configuration sequence and the equipment number comparison table to obtain the equipment number information of each light sensing module.
In a specific implementation, determining a device address configuration sequence according to the device address configuration policy refers to: the optical sensing device module is connected to the I2C channel of the host through hardware, and generally has multiple I2C channels. The device address configuration sequence is set as: firstly, configuring the address of a light sensing device in the equipment as the address of the light sensing module 1, writing data through I2C, reading back the ID of the light sensing module equipment through I2C after writing successfully, and if the read ID of the light sensing module equipment is the same as that of the light sensing module 1, considering that the light sensing module 1 is successfully matched and identified, and then the light sensing module 1 cannot be matched with other light sensing modules; if the light sensing module 1 is not successfully identified, the light sensing module 2 is continuously identified, if the light sensing module 2 is successfully identified, other light sensing modules cannot be matched, otherwise, the light sensing module 3 is continuously identified, and the like is repeated until the matching is successful.
It should be noted that obtaining module device information of each light-sensing module refers to: and obtaining module device information of each light sensing module, wherein the module device information comprises an equipment device address, a function register address, a register address length, a data length and the like. The module device information may be obtained by querying the datashort of the optical sensing device module. The device address of the light sensing module comprises a read address and a write address.
It should be understood that determining the device number look-up table of each photo-sensing module according to the module device information means: and establishing and determining a corresponding comparison relation table of the equipment of each light sensing module and the equipment ID number according to the module device information.
In specific implementation, matching each light sensing module according to the device address configuration sequence and the equipment number comparison table to obtain the equipment number information of each light sensing module refers to: and matching the light sensing modules according to the device address configuration sequence and the equipment comparison table, so as to determine the equipment number information of each light sensing module.
Through the mode, accurate matching and determination of the equipment number information of each light sensing module are achieved, and therefore the light sensing modules can be started normally and controlled to work normally subsequently.
Step S20: and configuring each light sensing module according to the equipment number information so as to start and work each light sensing module and detect whether each light sensing module in the equipment is abnormal or not.
It should be noted that, after the device number information is determined, the device address corresponding to the device number information of each light sensing module is correctly configured, so that each light sensing module can be driven to normally operate from the bus.
Further, in order to detect whether there is an abnormality in the photo sensing module, step S10 includes: acquiring bus information; configuring a data signal line into a general input mode according to the bus information, transmitting a working signal through the data signal line in the general input mode, and detecting the signal level of the working signal on the data signal line; and determining whether the light sensing module is abnormal or not according to the detected signal level of the data signal line.
It should be understood that, for the problem that all the light sensing modules supported by the television damage the I2C bus and are dead, which results in slow start-up, the hardware amount is an I2C waveform, and the I2C bus has SDA and SCL signals, and when the light sensing modules supported by the television are damaged, the SDA signal of the I2C bus is pulled low, which results in slow start-up. I2C is a multi-master multi-slave serial synchronous communication bus consisting of two signal lines (clock signal line SCL + data signal line SDA). The specification requires that the devices accessing I2C, both the SCL clock and SDA data lines must be bi-directional open-drain, pulled to a logic high level by a pull-up resistor on the bus. Such a configuration may implement the line and (&) function. Because of this characteristic, as long as any one device on the bus pulls either SDA or SCL low, the other devices cannot pull them high, all seen as low. If there are devices that do not release the bus, then the communication on the entire bus is suspended, called an I2C bus pull-down.
In a specific implementation, the bus information refers to configuration information of each signal line on a bus to which the light sensing modules are connected.
It should be noted that configuring the data signal line to be in a general input mode according to the bus information, transmitting an operating signal through the data signal line in the general input mode, and detecting a signal level of the operating signal on the data signal line means: the SDA of the I2C for the communication between the television main chip (or other equipment or device as an execution main body) and the light sensing module is firstly configured to be in a GPIO port input mode, then a working signal is transmitted on the data signal line SDA at the moment, and then the signal level on the data signal line is detected in real time.
It should be understood that when the signal level of the data signal line is low level or is pulled low compared to the level of the signal in normal operation, it is determined that there is an abnormality in the light sensing module, otherwise, the light sensing module is in normal operation.
By the method, whether the bus is abnormal or not due to the abnormity of the light sensing module can be intuitively judged according to the signal level on the data signal line.
Step S30: and when the detection result shows that the light sensing module is abnormal, configuring the bus and each signal line of the light sensing module as a specified transmission mode.
In the specific implementation, after the light sensing module is determined to have abnormality according to the detection result, the data transmission states and modes of the bus of the light sensing module and each signal line are adjusted and tested, and finally the data transmission states and modes are adjusted to be the designated transmission modes. The signal lines include two lines, namely a data signal line SDA and a clock signal line SCL.
It should be noted that the transmission mode is designated as an I2C mode in which the SDA and SCL are configured, and the light sensing module can be adaptively matched.
Step S40: and finishing reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module.
It should be understood that, after the bus and each signal line are configured into the designated transmission mode, the read operation is performed on each light sensing module in the designated transmission mode, that is, the bus performs a read operation on each light sensing module once, so as to recover the communication state of the bus, and recover from a deadlock state, so as to prevent the bus from being locked due to an abnormality of a single or individual light sensing module, and further, the normal start of the device is affected.
In the embodiment, when the device is detected to be started, the light sensing modules are matched to obtain the device number information of each light sensing module; and configuring each light sensing module according to the equipment number information so as to start and work each light sensing module. Detecting whether a light sensing module in the equipment is abnormal or not; when the detection result indicates that the light sensing module is abnormal, configuring a bus and each signal line of the light sensing module as an appointed transmission mode; and completing reading operation on the equipment light sensing module in the appointed transmission mode, and recovering the equipment light sensing module from a deadlock state to be normal, so that the bus is prevented from being dead due to abnormal damage of the light sensing module. By the mode, the light sensation modules of different types can be carried on the display equipment and are self-adaptively matched when the display equipment is started, and the applicability of the light sensation modules on the display equipment is improved. And when the light sensing module is abnormal, the bus and each signal wire can be automatically configured and normal starting can be completed, the phenomenon that starting is influenced by the abnormality of a single light sensing module is prevented, and when the abnormality of the light sensing module occurs, the communication state of the bus is timely found and recovered from a deadlock state.
Referring to fig. 3, fig. 3 is a flowchart illustrating a second embodiment of a method for controlling a light sensing module according to the present invention.
Based on the first embodiment, the method for controlling the light sensing module in this embodiment includes, in the step S20:
step S301: and when the detection result shows that the light sensing module is abnormal, configuring a clock signal line of the light sensing module into a general output mode, and transmitting a target clock signal through the clock signal line in the general output mode.
When it is determined that there is an abnormality in the optical sensing module, the I2C clock signal line connected to the optical sensing module is first configured in a GPIO (general purpose input/output) port output mode, and then the target clock signal is transmitted in the general output mode. Specifically, the target clock signal is a CLK clock signal whose analog output is continuous.
Further, after step S301, in order to configure the bus and the signal lines when the number of consecutive clocks is not within the cycle threshold, the method further includes: when the continuous clock quantity of the target clock signal is not in the range of the cycle threshold value, detecting the level of the data signal line to obtain a second level detection result; and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the second level detection result.
It should be understood that when the number of consecutive clocks of the target clock signal is equal to or greater than 9, that is, not within the cycle threshold range, the level of the data signal line is detected again.
In one embodiment, when the second level detection result is a low level, the SDA and SCL are directly configured as an I2C mode for adaptive matching of the light sensing module.
By the method, the bus and the signal lines can be configured to normally start and execute work of each light sensing module when the continuous clock number of the target clock signal is not in the range of the cycle threshold.
Step S302: and when the continuous clock number of the target clock signal is within a cycle threshold range and the continuous clock number changes to be at a low level, detecting the level of a data signal line of the light sensing module to obtain a first level detection result.
It should be understood that the cycle threshold range refers to a range within 1 or more and less than 9 times of CLK. When the number of consecutive clocks of the target clock signal is within a cycle threshold and the number of consecutive clocks is changed to be at a low level, the method comprises the following steps: the first level detection result is obtained if the level at which each CLK is continuously detected while outputting less than 9 consecutive CLKs changes to the low level, that is, the level on the data signal line at the time after each CLK.
Step S303: and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the first level detection result.
In a specific implementation, configuring the bus and each signal line of the photo sensing module as a designated transmission mode according to the first level detection result means: when the first level detection result is a high level, the signal states of the data signal line and the clock signal line are reconfigured, and then the bus line and the respective signal lines are configured to designate a transmission mode.
Further, in order to accurately configure the states of the bus and the signal lines, step S303 includes: when the first level detection result is that the data signal line is at a high level, configuring the data signal line into a general output mode; and under the general output mode, the signal states of the data signal line and the clock signal line are adjusted according to a level adjustment strategy, so that the bus and each signal line of the light sensing module are configured into a designated transmission mode.
It should be noted that fig. 4 is a complete flow chart of the present embodiment, wherein when the first level detection result is that the data signal line is at a high level, the data signal line is configured to the GPIO port output mode, then the SDA is set to a low level, the SCL is set to a high level, the SDA is set to a high level, and finally the SDA and SCL of the main chip are configured to the I2C mode to perform adaptive matching on the corresponding light sensing modules, so that the bus and each signal line are configured to the designated transmission mode.
By the mode, when the first evaluation detection result is that the data signal lines are at a high level, the data signal lines and the clock signal lines are sequentially adjusted through the level adjustment strategy, so that the locked state of the bus is released, and the equipment normally operates.
In this embodiment, when the detection result indicates that the light sensing module is abnormal, the clock signal line of the light sensing module is configured to be in a general output mode, and the target clock signal is transmitted through the clock signal line in the general output mode; when the continuous clock number of the target clock signal is within a cycle threshold range and the continuous clock number changes to be at a low level, detecting the level of a data signal line of the light sensing module to obtain a first level detection result; and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the first level detection result. Through the method, the I2C slave equipment light sensing module can finish reading operation by adjusting the configuration and testing of the data signal line and the clock signal line when the light sensing module is abnormal, and the normal state is recovered from a deadlock state, so that the I2C bus cannot be dead even if the light sensing module is damaged, the problem that starting is slow due to damage of the light sensing module is avoided, and the user experience is improved.
In addition, an embodiment of the present invention further provides a storage medium, where the storage medium stores a light sensing module control program, and the light sensing module control program, when executed by a processor, implements the steps of the light sensing module control method as described above.
Since the storage medium adopts all technical solutions of all the embodiments described above, at least all the beneficial effects brought by the technical solutions of the embodiments described above are achieved, and are not described in detail herein.
Referring to fig. 5, fig. 5 is a block diagram of a first embodiment of the light sensing module control device of the present invention.
As shown in fig. 5, the light sensing module control device according to the embodiment of the present invention includes:
and the information matching module 10 is used for matching the light sensing modules when detecting that the equipment is started to obtain the equipment number information of the light sensing modules.
And the configuration starting module 20 is used for configuring each light sensing module according to the equipment number information so as to start and work each light sensing module, and detecting whether each light sensing module in the equipment is abnormal or not.
And the exception handling module 30 is configured to configure the bus and each signal line of the light sensing module as a designated transmission mode when the detection result indicates that the light sensing module is abnormal.
And the bus recovery module 40 is configured to complete a read operation on each light sensing module in the designated transmission mode, so as to release a deadlock state of a bus corresponding to each light sensing module.
In the embodiment, when the device is detected to be started, the light sensing modules are matched to obtain the device number information of each light sensing module; and configuring each light sensing module according to the equipment number information so as to start and work each light sensing module. Detecting whether a light sensing module in the equipment is abnormal or not; when the detection result indicates that the light sensing module is abnormal, configuring a bus and each signal line of the light sensing module as an appointed transmission mode; and completing reading operation on the equipment light sensing module in the appointed transmission mode, and recovering the equipment light sensing module from a deadlock state to be normal, so that the bus is prevented from being dead due to abnormal damage of the light sensing module. By the mode, the light sensing modules of different models can be carried on the display equipment and are self-adaptively matched when the display equipment is started, and the applicability of the light sensing modules on the display equipment is improved. And when the light sensing modules are abnormal, the bus and each signal line can be automatically configured and normal starting can be completed, the phenomenon that the starting is influenced by the abnormality of a single light sensing module is prevented, and the communication state of the bus is timely found and recovered from a deadlock state when the abnormality of the light sensing modules occurs.
In an embodiment, the information matching module 10 is further configured to, when detecting that the apparatus is started, obtain information of the supporting optical sensing device; generating a device address configuration strategy according to the information of the light sensing supporting device; and matching the light sensing modules according to the device address configuration strategy to obtain the equipment number information of each light sensing module.
In an embodiment, the information matching module 10 is further configured to determine a device address configuration sequence according to the device address configuration policy; obtaining module device information of each light sensing module; determining an equipment number comparison table of each light sensing module according to the module device information; and matching the light sensing modules according to the device address configuration sequence and the equipment number comparison table to obtain the equipment number information of each light sensing module.
In an embodiment, the configuration starting module 20 is further configured to obtain bus information; configuring a data signal line into a general input mode according to the bus information, transmitting a working signal through the data signal line in the general input mode, and detecting the signal level of the working signal on the data signal line; and determining whether the light sensing module is abnormal or not according to the detected signal level of the data signal line.
In an embodiment, the exception handling module 30 is further configured to configure a clock signal line of the photo sensing module to a general output mode when the detection result indicates that the photo sensing module is abnormal, and transmit a target clock signal through the clock signal line in the general output mode; when the continuous clock number of the target clock signal is within a cycle threshold range and the continuous clock number changes to be at a low level, detecting the level of a data signal line of the light sensing module to obtain a first level detection result; and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the first level detection result.
In an embodiment, the exception handling module 30 is further configured to detect a level of the data signal line when the number of consecutive clocks of the target clock signal is not within a cycle threshold range, so as to obtain a second level detection result; and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the second level detection result.
In an embodiment, the exception handling module 30 is further configured to configure the data signal line in a general output mode when the first level detection result indicates that the data signal line is at a high level; and under the general output mode, the signal states of the data signal line and the clock signal line are adjusted according to a level adjustment strategy, so that the bus and each signal line of the light sensing module are configured into a designated transmission mode.
It should be understood that the above is only an example, and the technical solution of the present invention is not limited in any way, and in a specific application, a person skilled in the art may set the technical solution as needed, and the present invention is not limited thereto.
It should be noted that the above-described work flows are only exemplary, and do not limit the scope of the present invention, and in practical applications, a person skilled in the art may select some or all of them to achieve the purpose of the solution of the embodiment according to actual needs, and the present invention is not limited herein.
In addition, the technical details that are not described in detail in this embodiment can be referred to the method for controlling the light sensing module provided in any embodiment of the present invention, and are not described herein again.
Further, it is to be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrases "comprising one of 8230; \8230;" 8230; "does not exclude the presence of additional like elements in a process, method, article, or system that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention or portions thereof that contribute to the prior art may be embodied in the form of a software product, where the computer software product is stored in a storage medium (e.g. Read Only Memory (ROM)/RAM, magnetic disk, optical disk), and includes several instructions for enabling a terminal device (e.g. a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. A control method of a light sensing module is characterized in that the starting method of the light sensing module comprises the following steps:
when the starting of the equipment is detected, matching the light sensing modules to obtain the equipment number information of the light sensing modules;
configuring each light sensing module according to the equipment number information so as to start and work each light sensing module, and detecting whether each light sensing module in the equipment is abnormal or not;
when the detection result indicates that the light sensing module is abnormal, configuring the bus and each signal line of the light sensing module as an appointed transmission mode;
and finishing reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module.
2. The method as claimed in claim 1, wherein the detecting of the device start-up matches the photo modules to obtain the device number information of each photo module includes:
when the starting of the equipment is detected, the information of the supporting light sensing device is obtained;
generating a device address configuration strategy according to the information of the light sensing supporting device;
and matching the light sensing modules according to the device address configuration strategy to obtain the equipment number information of each light sensing module.
3. The method as claimed in claim 2, wherein the matching the photo modules according to the device address configuration policy to obtain the device number information of each photo module comprises:
determining a device address configuration sequence according to the device address configuration strategy;
obtaining module device information of each light sensing module;
determining an equipment number comparison table of each light sensing module according to the module device information;
and matching the light sensing modules according to the device address configuration sequence and the equipment number comparison table to obtain the equipment number information of the light sensing modules.
4. The method as claimed in claim 1, wherein said detecting whether there is an anomaly in a light-sensing module within said device comprises:
acquiring bus information;
configuring a data signal line into a general input mode according to the bus information, transmitting a working signal through the data signal line in the general input mode, and detecting the signal level of the working signal on the data signal line;
and determining whether the light sensing module is abnormal or not according to the detected signal level of the data signal line.
5. The method as claimed in claim 1, wherein when the detection result indicates that the photo sensor module is abnormal, configuring the bus and the signal lines of the photo sensor module as a designated transmission mode according to the detection result comprises:
when the detection result indicates that the light sensing module is abnormal, configuring a clock signal line of the light sensing module into a general output mode, and transmitting a target clock signal through the clock signal line in the general output mode;
when the continuous clock number of the target clock signal is within a cycle threshold range and the continuous clock number changes to be at a low level, detecting the level of a data signal line of the light sensing module to obtain a first level detection result;
and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the first level detection result.
6. The method as claimed in claim 5, wherein after configuring the clock signal line of the photo sensing module in the general input mode and outputting the target clock signal when the detection result is that the photo sensing module is abnormal, further comprising:
when the continuous clock quantity of the target clock signal is not in the range of the cycle threshold value, detecting the level of the data signal line to obtain a second level detection result;
and configuring the bus and each signal line of the light sensing module into a designated transmission mode according to the second level detection result.
7. The method as claimed in claim 5, wherein the configuring the bus lines and the signal lines of the photo-sensing modules to designate a transmission mode according to the first level detection result comprises:
when the first level detection result is that the data signal line is at a high level, configuring the data signal line into a general output mode;
and under the general output mode, the signal states of the data signal line and the clock signal line are adjusted according to a level adjustment strategy, so that the bus and each signal line of the light sensing module are configured into a designated transmission mode.
8. A light sensing module control device, comprising:
the information matching module is used for matching the light sensing modules when the equipment is detected to be started to obtain the equipment number information of the light sensing modules;
the configuration starting module is used for configuring each light sensing module according to the equipment number information so as to start and work each light sensing module and detect whether each light sensing module in the equipment is abnormal or not;
the abnormity processing module is used for configuring the bus and each signal line of the light sensing module as an appointed transmission mode when the detection result indicates that the light sensing module is abnormal;
and the bus recovery module is used for completing reading operation on each light sensing module in the appointed transmission mode so as to remove the deadlock state of the bus corresponding to each light sensing module.
9. A display device, characterized in that the display device comprises: a memory, a processor, and a light-sensing module control program stored on the memory and executable on the processor, the light-sensing module control program being configured to implement the light-sensing module control method as claimed in any one of claims 1 to 7.
10. A storage medium, wherein a photo module control program is stored on the storage medium, and when executed by a processor, the method for controlling a photo module as claimed in any one of claims 1 to 7 is implemented.
CN202211370598.4A 2022-11-03 2022-11-03 Light sensing module control method and device, display equipment and storage medium Pending CN115834970A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211370598.4A CN115834970A (en) 2022-11-03 2022-11-03 Light sensing module control method and device, display equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211370598.4A CN115834970A (en) 2022-11-03 2022-11-03 Light sensing module control method and device, display equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115834970A true CN115834970A (en) 2023-03-21

Family

ID=85526449

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211370598.4A Pending CN115834970A (en) 2022-11-03 2022-11-03 Light sensing module control method and device, display equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115834970A (en)

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001266196A (en) * 2000-03-17 2001-09-28 Toshiba Corp Multiple device system and its device switching method and fare reception system and its device switching method
CN103019871A (en) * 2012-12-31 2013-04-03 四川迪佳通电子有限公司 Anti-deadlock system of I2C bus and anti-deadlock method
CN203689513U (en) * 2013-12-31 2014-07-02 大连捷成实业发展有限公司 Device for avoiding abnormality of multi-master I2C communication of AVR single-chip microcomputers
CN106649180A (en) * 2016-09-09 2017-05-10 锐捷网络股份有限公司 Method and device for relieving I2C bus deadlock
CN107562668A (en) * 2017-08-31 2018-01-09 广东欧珀移动通信有限公司 Bus deadlock recovery system and method
US20190020586A1 (en) * 2017-07-14 2019-01-17 Qualcomm Incorporated Selective insertion of a deadlock recovery buffer in a bus interconnect for deadlock recovery
CN109388605A (en) * 2017-08-10 2019-02-26 深圳市中兴微电子技术有限公司 A kind of method and apparatus releasing I2C bus deadlock
US20190272252A1 (en) * 2018-01-09 2019-09-05 Shenzhen GOODIX Technology Co., Ltd. Method of processing deadlock of i2c bus, electronic device and communication system
CN111061587A (en) * 2019-12-12 2020-04-24 浪潮商用机器有限公司 Communication control method, device, equipment and storage medium of I2C bus
CN112422178A (en) * 2020-10-20 2021-02-26 浪潮思科网络科技有限公司 Optical module monitoring method, electronic device and storage medium
CN114968683A (en) * 2022-05-13 2022-08-30 上海艾为电子技术股份有限公司 Bus relation detection device, slave device, system and chip

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001266196A (en) * 2000-03-17 2001-09-28 Toshiba Corp Multiple device system and its device switching method and fare reception system and its device switching method
CN103019871A (en) * 2012-12-31 2013-04-03 四川迪佳通电子有限公司 Anti-deadlock system of I2C bus and anti-deadlock method
CN203689513U (en) * 2013-12-31 2014-07-02 大连捷成实业发展有限公司 Device for avoiding abnormality of multi-master I2C communication of AVR single-chip microcomputers
CN106649180A (en) * 2016-09-09 2017-05-10 锐捷网络股份有限公司 Method and device for relieving I2C bus deadlock
US20190020586A1 (en) * 2017-07-14 2019-01-17 Qualcomm Incorporated Selective insertion of a deadlock recovery buffer in a bus interconnect for deadlock recovery
CN109388605A (en) * 2017-08-10 2019-02-26 深圳市中兴微电子技术有限公司 A kind of method and apparatus releasing I2C bus deadlock
CN107562668A (en) * 2017-08-31 2018-01-09 广东欧珀移动通信有限公司 Bus deadlock recovery system and method
US20190272252A1 (en) * 2018-01-09 2019-09-05 Shenzhen GOODIX Technology Co., Ltd. Method of processing deadlock of i2c bus, electronic device and communication system
CN111061587A (en) * 2019-12-12 2020-04-24 浪潮商用机器有限公司 Communication control method, device, equipment and storage medium of I2C bus
CN112422178A (en) * 2020-10-20 2021-02-26 浪潮思科网络科技有限公司 Optical module monitoring method, electronic device and storage medium
CN114968683A (en) * 2022-05-13 2022-08-30 上海艾为电子技术股份有限公司 Bus relation detection device, slave device, system and chip

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
陈世淼等: ""给予SmartFushion的I2C多主多从通信设计"", 电子设计工程, 5 July 2021 (2021-07-05) *

Similar Documents

Publication Publication Date Title
CN105786421B (en) Server display method and device
US20110179211A1 (en) Bios architecture
JPH08511887A (en) Device and method for automatic recognition and configuration of peripheral devices
US6434697B1 (en) Apparatus for savings system configuration information to shorten computer system initialization time
CN109976816B (en) Computer system configuration method and server
CN113704104B (en) Program debugging method, device, system, electronic device and storage medium
CN112765082B (en) Multi-host arbitration method, device and readable storage medium
CN105120259A (en) Detection method and apparatus for digital television
CN111124508A (en) Method and device for adjusting PXE (PCI extensions for instrumentation) starting sequence of network card
CN113077834A (en) Storage device testing method and device, television and storage medium
US9886055B2 (en) Memory initializing method and electronic device supporting the same
US20080235428A1 (en) Method and system for dynamic switching between multiplexed interfaces
CN114660436A (en) Chip testing equipment and chip testing method
US20140317391A1 (en) Method for changing a system program and processing device utilizing the same
CN113272785B (en) Method for mounting file system, terminal equipment and storage medium
CN117407065A (en) Network card pre-start control method, device, equipment, system and storage medium
CN115834970A (en) Light sensing module control method and device, display equipment and storage medium
CN112203131B (en) Prompting method and device based on display equipment and storage medium
CN111221554B (en) DSP circuit structure, DSP online program upgrading method and device
US11983134B2 (en) Method for recognizing another electronic device by using plurality of interfaces, and electronic device therefor
CN108279949B (en) Starting method and system applied to television and television
CN112214486B (en) Data storage method, system and device
CN108513169A (en) A kind of chip downloads method, chip and the LCD TV of startup program
US11977897B2 (en) Mounting position of NVMe or SATA on a backplane using bay slot ID
US11989566B2 (en) Method for controlling electronic device

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