A method, device, electronic device and storage medium for detecting the number of optical discs
Through the detection distance relationship configuration circuit between the transmitting device and the receiving device, the signal strength is used to determine the number of optical discs, which solves the problem of detection of optical discs with large errors in the robot method, and achieves higher detection accuracy.
Patent Information
- Application Number
- CN202210292964.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-23
- Publication Date
- 2025-07-25
- Estimated Expiration
- 2042-03-23
AI Technical Summary
The existing method of detecting the number of optical discs mainly through robotic methods, with large errors and difficulty in accurately detecting the number of optical discs.
By determining device parameters according to the detection distance relationship between the transmitting device and the receiving device, configuring the transmitting and receiving circuits to transmit and receive signals, judging the optical disk number interval using the signal intensity, including setting a plurality of transmitting and receiving devices in the diametric direction of the optical disk bucket, the transmitting device transmits signals, and the receiving device receives or does not receive signals to determine the optical disk height, and then determining the optical disk number interval.
Improve the accuracy of the number of discs detection to ensure the reliability and accuracy of the detection results.
Smart Images

Figure CN114638331B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of detection technologies, and in particular, to a method, apparatus, electronic device, and storage medium for detecting the number of optical discs. Background Art
[0002] A desktop optical disc library is a miniaturized and movable storage device. The desktop optical disc library is mainly designed for placing on a desktop, and has the characteristics of small size and light weight, and is suitable for long-term archiving and backup of small databases.
[0003] When using a desktop optical disc library, it is necessary to know the number of optical discs in the optical disc library, so as to put in optical discs in time when the optical discs are insufficient.
[0004] The existing method for determining the number of optical discs mainly determines the number of optical discs through a mechanical arm method, but the error is large, and it is difficult to accurately detect the number of optical discs. Summary of the Invention
[0005] The present invention provides a method, apparatus, electronic device, and storage medium for detecting the number of optical discs, so as to improve the accuracy of detecting the number of optical discs.
[0006] According to one aspect of the present invention, a method for detecting the number of optical discs is provided. The method for detecting the number of optical discs includes:
[0007] Determine device parameters in the transmitting device and device parameters in the receiving device according to the detection distance relationship formula between the transmitting device and the receiving device;
[0008] Determine a transmitting circuit according to the device parameters of the transmitting device, and determine a receiving circuit according to the device parameters of the receiving device; wherein, the transmitting circuit includes a plurality of the transmitting devices, and the receiving circuit includes a plurality of the receiving devices; wherein, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when receiving the first signal, and emit a third signal when not receiving the first signal;
[0009] Determine the number range of optical discs in the optical disc barrel according to the second signal or the third signal.
[0010] Optionally, the receiving device includes an infrared receiving tube and a first resistor. The first end of the first resistor is connected to a power signal, the second end of the first resistor is electrically connected to the cathode of the infrared receiving tube, and the anode of the infrared receiving tube is grounded; the transmitting device includes a second resistor and an infrared transmitting tube; the first end of the second resistor is connected to a power signal, the second end of the second resistor is electrically connected to the anode of the infrared transmitting tube, and the cathode of the infrared transmitting tube is grounded;
[0011] The detection distance relationship formula is where D is the detection distance, λp1 is the peak value of the signal emitted by the transmitting device, λ p2 is the peak value of the signal received by the receiving device, R pT is the resistance value of the first resistor, R IR is the resistance value of the second resistor.
[0012] Optionally, determining the device parameters in the transmitting device and the receiving device according to the detection distance relationship between the transmitting device and the receiving device includes:
[0013] Determining the resistance value of the first resistor and the resistance value of the second resistor according to the detection distance relationship between the transmitting device and the receiving device.
[0014] Optionally, determining the resistance value of the first resistor and the resistance value of the second resistor according to the detection distance relationship between the transmitting device and the receiving device includes:
[0015] Determining the preset detection distance between the receiving device and the transmitting device, and determining the preset intensity of the first signal;
[0016] Determining the resistance value of the first resistor and the resistance value of the second resistor according to the preset detection distance, the preset intensity, and the detection distance relationship.
[0017] Optionally, after determining the optical disc quantity range in the optical disc cartridge according to the second signal or the third signal, further includes:
[0018] Sending an alarm control signal according to the optical disc quantity range.
[0019] Optionally, after determining the optical disc quantity range in the optical disc cartridge according to the second signal or the third signal, further includes:
[0020] Sending the optical disc quantity range to a display device so that the display device displays the optical disc quantity range.
[0021] According to another aspect of the present invention, there is provided an optical disc quantity detection device, and the optical disc quantity detection device includes:
[0022] A device parameter determination module, configured to determine the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relationship between the transmitting device and the receiving device;
[0023] A circuit determination module, configured to determine a transmitting circuit according to device parameters of the transmitting device, and determine a receiving circuit according to device parameters of the receiving device; wherein, the transmitting circuit includes a plurality of the transmitting devices, and the receiving circuit includes a plurality of the receiving devices; wherein, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when the first signal is received, and emit a third signal when the first signal is not received.
[0024] An optical disc quantity determination module, configured to determine an optical disc quantity range in an optical disc barrel according to the second signal or the third signal.
[0025] Optionally, the optical disc quantity detection device further includes:
[0026] An alarm control module, configured to issue an alarm control signal according to the optical disc quantity range.
[0027] According to another aspect of the present invention, there is provided an electronic device, which includes:
[0028] At least one processor; and
[0029] A memory communicatively connected to the at least one processor; wherein,
[0030] The memory stores a computer program executable by the at least one processor, and when the computer program is executed by the at least one processor, the at least one processor is enabled to execute the optical disc quantity detection method according to any implementation manner of the present invention.
[0031] According to another aspect of the present invention, there is provided a computer-readable storage medium storing computer instructions for causing a processor to implement the optical disc quantity detection method according to any implementation manner of the present invention when executed.
[0032] In the technical solution of the embodiment of the present invention, by determining the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relation formula between the transmitting device and the receiving device, it can be ensured that the device parameters in the transmitting device and the device parameters in the receiving device meet the detection requirements of the optical disc cartridge, so that the detection distance between the transmitting device and the receiving device and the signal strength of the first signal transmitted can meet the requirements of the optical disc cartridge, and the number range of optical discs can be accurately detected, improving the accuracy of optical disc number detection. The corresponding devices of the transmitting circuit and the receiving circuit are in the diameter direction of the optical disc cartridge. The transmitting circuit includes multiple transmitting devices, and the receiving circuit includes multiple receiving devices. The transmitting devices and the receiving devices are correspondingly arranged in the diameter direction of the optical disc cartridge. The transmitting devices can transmit the first signal in a direct radiation manner, and the receiving devices correspondingly arranged with the transmitting devices can receive the first signal transmitted by the transmitting devices. When the height of the optical discs in the optical disc cartridge exceeds the heights of the transmitting devices and the receiving devices, the optical discs block the receiving devices from receiving the first signal, causing the receiving devices to not receive the first signal, and the receiving devices will emit a third signal; when the height of the optical discs in the optical disc cartridge is less than the heights of the transmitting devices and the receiving devices, the optical discs cannot block the receiving devices from receiving the first signal, enabling the receiving devices to receive the first signal, and the receiving devices will emit a second signal. The second signal is, for example, a low-level signal. When the control device receives the second signal, it can know that the height of the optical discs does not exceed the heights of the transmitting devices and the receiving devices, and can know the number range of the optical discs; the third signal is, for example, a high-level signal. When the control device receives the third signal, it can know that the height of the optical discs exceeds the heights of the transmitting devices and the receiving devices, and can know the number range of the optical discs. The technical solution of the embodiment of the present invention solves the problem that the number of optical discs is determined by the manipulator method, but the error is large and it is difficult to accurately detect the number of optical discs, and achieves the effect of improving the accuracy of optical disc number detection.
[0033] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present invention, nor is it used to limit the scope of the present invention. Other features of the present invention will become easily understood through the following description. Brief Description of the Drawings
[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the following drawings are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0035] Figure 1 It is a flowchart of a method for detecting the number of optical discs provided by an embodiment of the present invention;
[0036] Figure 2It is a schematic structural diagram of an optical disc library provided by an embodiment of the present invention;
[0037] Figure 3 It is a schematic circuit diagram of a transmitting circuit and a receiving circuit provided by an embodiment of the present invention;
[0038] Figure 4 It is a flowchart of another optical disc quantity detection method provided by an embodiment of the present invention;
[0039] Figure 5 It is a flowchart of another optical disc quantity detection method provided by an embodiment of the present invention;
[0040] Figure 6 It is a schematic structural diagram of an optical disc quantity detection device provided by an embodiment of the present invention;
[0041] Figure 7 It is a schematic structural diagram of another optical disc quantity detection device provided by an embodiment of the present invention;
[0042] Figure 8 It is a schematic structural diagram of an electronic device for implementing the optical disc quantity detection method of the embodiment of the present invention. Detailed implementation manners
[0043] In order to enable those skilled in the art to better understand the solution of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0044] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above drawings are used to distinguish similar objects, and do not necessarily need to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device that includes a series of steps or units does not necessarily need to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0045] Figure 1 It is a flowchart of an optical disc quantity detection method provided by an embodiment of the present invention. This embodiment is applicable to the situation of detecting the quantity of optical discs in an optical disc library. Refer to Figure 1, the optical disc quantity detection method includes:
[0046] S110. Determine the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relation formula between the transmitting device and the receiving device.
[0047] Specifically, the transmitting device includes, for example, an infrared emitting diode, and the receiving device includes, for example, an infrared receiving diode. The transmitting device can emit a first signal in a direct radiation manner, and the receiving device can receive the first signal. When there is no obstacle between the transmitting device and the receiving device, the receiving device can receive the first signal. When there is an obstacle between the transmitting device and the receiving device, the receiving device cannot receive the first signal. Therefore, it can be determined whether there is an optical disc between the transmitting device and the receiving device according to whether the receiving device receives the first signal. By arranging a plurality of transmitting devices and a plurality of receiving devices on the optical disc barrel, the height of the optical discs in the optical disc barrel can be judged, so as to determine the optical disc quantity range in the optical disc barrel.
[0048] The detection distance ranges of the transmitting device and the receiving device are different in different test occasions and for different test objects. Therefore, the control device determines the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relation formula between the transmitting device and the receiving device, so that the detection distance between the transmitting device and the receiving device and the signal intensity of the first signal emitted satisfy the requirements of the optical disc barrel, so as to accurately detect the optical disc quantity range in the optical disc barrel.
[0049] S120. Determine the transmitting circuit according to the device parameters of the transmitting device, and determine the receiving circuit according to the device parameters of the receiving device; wherein, the transmitting circuit includes a plurality of transmitting devices, and the receiving circuit includes a plurality of receiving devices; wherein, the transmitting device is configured to emit a first signal, and the receiving device is configured to emit a second signal when the first signal is received, and emit a third signal when the first signal is not received.
[0050] Specifically, Figure 2 is a schematic structural diagram of an optical disc library provided by an embodiment of the present invention. The optical disc library includes an optical disc barrel 200, a transmitting circuit 110 and a receiving circuit 120. The optical disc barrel 200 can accommodate optical discs. The optical discs can be put into the optical disc barrel 200 from the top and sent out from the bottom of the optical disc barrel 200. The corresponding devices of the transmitting circuit 110 and the receiving circuit 120 are in the diameter direction of the optical disc barrel 200. The transmitting circuit 110 includes a plurality of transmitting devices 101, and the receiving circuit 120 includes a plurality of receiving devices 102. After determining the device parameters of the transmitting device 101 and the device parameters of the receiving device 102, the control device can determine the transmitting circuit 110 and the receiving circuit 120.
[0051] The transmitting device 101 and the receiving device 102 are correspondingly arranged in the diametrical direction of the optical disc barrel 200. The transmitting device 101 can transmit the first signal in a direct radiation manner. The first signal is, for example, an infrared signal. The receiving device 102 correspondingly arranged with the transmitting device 101 can receive the first signal transmitted by the transmitting device 101. When the height of the optical disc in the optical disc barrel 200 exceeds the heights of the transmitting device 101 and the receiving device 102, the optical disc blocks the receiving device 102 from receiving the first signal, causing the receiving device 102 not to receive the first signal, and the receiving device 102 will emit a third signal; when the height of the optical disc in the optical disc barrel 200 is less than the heights of the transmitting device 101 and the receiving device 102, the optical disc cannot block the receiving device 102 from receiving the first signal, enabling the receiving device 102 to receive the first signal, and the receiving device 102 will emit a second signal.
[0052] S130. Determine the number range of the optical discs in the optical disc barrel according to the second signal or the third signal.
[0053] Specifically, referring to Figure 2 , the second signal is, for example, a low-level signal. When the control device receives the second signal, it can know that the height of the optical disc does not exceed the heights of the transmitting device 101 and the receiving device 102, and can know the number range of the optical discs; the third signal is, for example, a high-level signal. When the control device receives the third signal, it can know that the height of the optical disc exceeds the heights of the transmitting device 101 and the receiving device 102, and can know the number range of the optical discs.
[0054] Exemplarily, the optical disc quantity detection device includes, for example, five transmitting devices 101 and five receiving devices 102. From the bottom to the top of the optical disc barrel 200, the first transmitting device 101 to the fifth transmitting device 101 are arranged in sequence. That is, the first transmitting device 101 is the transmitting device 101 closest to the bottom of the optical disc barrel 200. The height of the first transmitting device 101 from the bottom of the optical disc barrel 200 is the first preset height. The first receiving device 102 is correspondingly arranged on the other side of the optical disc barrel 200, and the height of the first receiving device 102 from the bottom of the optical disc barrel 200 is the first preset height. That is, the connection line between the transmitting device 101 and the receiving device 102 is parallel to the bottom of the optical disc barrel 200. When the height of the optical discs in the optical disc barrel 200 is less than the first preset height, the optical discs cannot block the first receiving device 102 from receiving the first signal emitted by the first transmitting device 101. When the first receiving device 102 receives the first signal emitted by the first transmitting device 101, the first receiving device 102 will emit a second signal. The control device will then know that the optical disc height is less than the first preset height, will know the optical disc quantity range, and thus know that the optical disc quantity is small, and will remind the user that the optical disc quantity is insufficient, so that the user can add optical discs in time. The fifth transmitting device 101 is the transmitting device 101 closest to the top of the optical disc barrel 200. The height of the fifth transmitting device 101 from the bottom of the optical disc barrel 200 is the second preset height. The fifth receiving device 102 is correspondingly arranged on the other side of the optical disc barrel 200, and the height of the fifth receiving device 102 from the bottom of the optical disc barrel 200 is the second preset height. When the height of the optical discs in the optical disc barrel 200 is greater than the second preset height, the optical discs block the fifth receiving device 102 from receiving the first signal emitted by the fifth transmitting device 101. The fifth receiving device 102 cannot receive the first signal, and the fifth receiving device 102 will emit a third signal. When the control device receives the third signal from the fifth receiving device 102, it will know that the optical disc height is greater than the second preset height, will know the optical disc quantity range, and thus know that the optical disc quantity is large, and will remind the user that the optical disc quantity is full, so that the user can know in time that the optical disc quantity is full.
[0055] It should be noted that Figure 2 only the case where the transmitting circuit 110 includes five transmitting devices 101 and the receiving circuit 120 includes five receiving devices 102 is shown in
[0056] In the technical solution of this embodiment, by determining the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relationship between the transmitting device and the receiving device, it can be ensured that the device parameters in the transmitting device and the device parameters in the receiving device meet the detection requirements of the optical disc cartridge, so that the detection distance between the transmitting device and the receiving device and the signal strength of the first signal transmitted can meet the requirements of the optical disc cartridge, the number range of optical discs can be accurately detected, and the accuracy of optical disc number detection is improved. The corresponding devices of the transmitting circuit and the receiving circuit are in the diameter direction of the optical disc cartridge. The transmitting circuit includes multiple transmitting devices, and the receiving circuit includes multiple receiving devices. After determining the device parameters of the transmitting device and the device parameters of the receiving device, the control device can determine the transmitting circuit and the receiving circuit. The transmitting device and the receiving device are correspondingly arranged in the diameter direction of the optical disc cartridge. The transmitting device can transmit the first signal in a direct light way, and the receiving device correspondingly arranged with the transmitting device can receive the first signal transmitted by the transmitting device. When the height of the optical discs in the optical disc cartridge exceeds the heights of the transmitting device and the receiving device, the optical discs block the receiving device from receiving the first signal, so that the receiving device cannot receive the first signal, and the receiving device will send out a third signal; when the height of the optical discs in the optical disc cartridge is less than the heights of the transmitting device and the receiving device, the optical discs cannot block the receiving device from receiving the first signal, so that the receiving device can receive the first signal, and the receiving device will send out a second signal. The second signal is, for example, a low-level signal. When the control device receives the second signal, it can know that the height of the optical discs does not exceed the heights of the transmitting device and the receiving device, and can know the number range of the optical discs; the third signal is, for example, a high-level signal. When the control device receives the third signal, it can know that the height of the optical discs exceeds the heights of the transmitting device and the receiving device, and can know the number range of the optical discs. The technical solution of this embodiment solves the problem that the number of optical discs is determined by the manipulator method, but the error is large and it is difficult to accurately detect the number of optical discs, and achieves the effect of improving the accuracy of optical disc number detection.
[0057] On the basis of the above implementation scheme, Figure 3 is a schematic circuit structure diagram of the transmitting circuit and the receiving circuit provided by an embodiment of the present invention. Optionally, referring to Figure 3 , the receiving device 102 includes an infrared receiving tube D1 and a first resistor R1. The first end of the first resistor R1 is connected to the power supply signal V1, the second end of the first resistor R1 is electrically connected to the cathode of the infrared receiving tube D1, and the anode of the infrared receiving tube D1 is grounded; the transmitting device 101 includes a second resistor R2 and an infrared transmitting tube D2; the first end of the second resistor R2 is connected to the power supply signal V1, the second end of the second resistor R2 is electrically connected to the anode of the infrared transmitting tube D2, and the cathode of the infrared transmitting tube D2 is grounded;
[0058] The detection distance relationship is where D is the detection distance, λ p1is the peak value of the signal emitted by the transmitting device 101, λ p2 is the peak value of the signal received by the receiving device 102, R pT is the resistance value of the first resistor R1, R IR is the resistance value of the second resistor R2.
[0059] Specifically, the detection distance D between the transmitting device 101 and the receiving device 102 and the peak value λ of the signal emitted by the transmitting device 101 p1 , the peak value λ of the signal received by the receiving device 102 p2 , the resistance value R of the first resistor R1 pT and the resistance value R of the second resistor R2 IR are related. Therefore, after the infrared transmitting tube D2 and the infrared receiving tube D1 are determined, the peak value λ of the signal emitted by the transmitting device 101 p1 and the peak value λ of the signal received by the receiving device 102 p2 can be determined. Then, the resistance value R of the first resistor R1 and the resistance value R of the second resistor R2 pT can be determined according to the required detection distance and the detection distance relationship formula, IR so as to determine the device parameters in the transmitting device 101 and the device parameters in the receiving device 102.
[0060] It should be noted that, Figure 3 only shows the case where the transmitting circuit 110 includes two transmitting devices 101 and the receiving circuit 120 includes two receiving devices 102, but it is not limited.
[0061] On the basis of the above embodiments, Figure 4 is a flowchart of another optical disc quantity detection method provided by an embodiment of the present invention. Refer to Figure 4 , this optical disc quantity detection method includes:
[0062] S210. Determine the resistance values of the first resistor and the second resistor according to the detection distance relationship formula between the transmitting device and the receiving device.
[0063] Specifically, when the infrared transmitting tube D2 and the infrared receiving tube D1 are determined, the peak value λ of the signal emitted by the transmitting device p1 can be determined. According to the detection distance relationship formula and the required detection distance, the resistance value R of the first resistor R1 pT and the resistance value R of the second resistor R2 IR, the required detection distance is, for example, the diameter of the disc barrel, or can be the diameter of the disc barrel plus a preset value, so as to ensure that when there is no disc obstruction, the receiving device can receive the first signal emitted by the corresponding transmitting device, which can avoid misjudgment caused by the receiving device not receiving the first signal due to insufficient detection distance, thereby improving the accuracy of disc quantity detection and the reliability of disc quantity detection.
[0064] Among them, the preset value can be a specific numerical value or a numerical range. The specific preset value can be determined according to the actual situation and is not limited here.
[0065] S220. Determine the transmitting circuit according to the device parameters of the transmitting device, and determine the receiving circuit according to the device parameters of the receiving device; among them, the transmitting circuit includes multiple transmitting devices, and the receiving circuit includes multiple receiving devices; among them, the transmitting device is configured to transmit the first signal, and the receiving device is configured to emit the second signal when receiving the first signal and emit the third signal when not receiving the first signal.
[0066] S230. Determine the disc quantity range in the disc barrel according to the second signal or the third signal.
[0067] S240. Send an alarm control signal according to the disc quantity range.
[0068] Specifically, for example, the transmitting circuit 110 includes five transmitting devices 101, and the receiving circuit 120 includes five receiving devices 102. From the bottom to the top of the disc barrel 200, the first transmitting device 101 to the fifth transmitting device 101 are arranged in sequence. When the first receiving device 102 receives the first signal emitted by the first receiving device 102, the first receiving device 102 will emit the second signal, and the control device will know that the disc height is less than the first preset height, will know the disc quantity range, and thus know that the disc quantity is small, and will send the first alarm control signal, causing the alarm device to emit the first alarm signal, such as ringing three times, so as to remind the user that the disc quantity is insufficient, enabling the user to add discs in time; when the fifth receiving device 102 emits the third signal and the control device receives the third signal of the fifth receiving device 102, it will know that the disc height is greater than the second preset height, will know the disc quantity range, and thus know that the disc quantity is large, and will send the second alarm control signal, causing the alarm device to emit the second alarm signal, such as ringing five times, so as to remind the user that the disc quantity is full, enabling the user to know in time that the disc quantity is full.
[0069] Based on the above technical solution, Figure 5 is a flowchart of another disc quantity detection method provided by an embodiment of the present invention. Optionally, refer to Figure 5 , this disc quantity detection method includes:
[0070] S310. Determine the preset detection distance between the receiving device and the transmitting device, and determine the preset intensity of the first signal.
[0071] Specifically, the control device first obtains the preset detection distance between the receiving device and the transmitting device. The preset detection distance is, for example, the sum of the diameter of the disc barrel and a preset value, and determines the preset intensity of the first signal. If the intensity of the first signal is too small, the receiving device may sometimes receive the first signal and sometimes not, which is extremely unstable. And since the disc has the ability to reflect light, if the intensity of the first signal is too large, it is likely to cause false triggering. Therefore, determining the preset detection distance and the preset intensity of the first signal can avoid misjudgment caused by the receiving device not receiving the first signal due to insufficient detection distance, thereby improving the accuracy of disc quantity detection.
[0072] Among them, the preset intensity of the first signal can be a specific intensity value or an intensity range. The specific preset intensity can be determined according to the actual situation and is not limited here.
[0073] S320. Determine the resistance value of the first resistor and the resistance value of the second resistor according to the preset detection distance, the preset intensity, and the detection distance relationship formula.
[0074] Specifically, when the infrared emitting diode D2 and the infrared receiving diode D1 are determined, the peak value λ of the signal emitted by the transmitting device p1 can be determined. According to the detection distance relationship formula and the preset detection distance, the initial resistance value of the first resistor R1 and the initial resistance value of the second resistor R2 can be determined. After determining the transmitting circuit and the receiving circuit according to the initial resistance value of the first resistor R1 and the initial resistance value of the second resistor R2, use the transmitting circuit and the receiving circuit to detect the disc quantity range of the disc barrel, and at the same time measure the current intensity of the first signal emitted by the transmitting circuit. If the current intensity meets the preset intensity, then the initial resistance value of the first resistor R1 can be determined as the resistance value R pT of the first resistor R1 and the resistance value R IR of the second resistor R2; if the current intensity does not meet the preset intensity, then adjust the initial resistance value of the first resistor R1 and the initial resistance value of the second resistor R2, and actually measure the current intensity of the first signal until the current intensity of the first signal meets the preset intensity, and then the resistance value R pT of the first resistor R1 and the resistance value R IR of the second resistor R2 can be determined, thereby ensuring that the receiving device stably receives the first signal emitted by the corresponding transmitting device.
[0075] S330. Determine the transmitting circuit according to the device parameters of the transmitting device, and determine the receiving circuit according to the device parameters of the receiving device. Among them, the transmitting circuit includes multiple transmitting devices, and the receiving circuit includes multiple receiving devices. Among them, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when the first signal is received and emit a third signal when the first signal is not received.
[0076] S340. Determine the range of the number of optical discs in the disc barrel according to the second signal or the third signal.
[0077] S350. Send an alarm control signal according to the range of the number of optical discs.
[0078] S360. Send the range of the number of optical discs to the display device so that the display device can display the range of the number of optical discs.
[0079] Specifically, after the control device determines the range of the number of optical discs, it can send the range of the number of optical discs to the display device, so that the display device can display the range of the number of optical discs in real time, facilitating the user to know the range of the number of optical discs in real time.
[0080] Figure 6 FIG. is a schematic structural diagram of an optical disc number detection device provided by an embodiment of the present invention. The optical disc number detection device includes:
[0081] A device parameter determination module 610, configured to determine the device parameters in the transmitting device and the device parameters in the receiving device according to the detection distance relationship between the transmitting device and the receiving device;
[0082] A circuit determination module 620, configured to determine the transmitting circuit according to the device parameters of the transmitting device and determine the receiving circuit according to the device parameters of the receiving device. Among them, the transmitting circuit includes multiple transmitting devices, and the receiving circuit includes multiple receiving devices. Among them, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when the first signal is received and emit a third signal when the first signal is not received;
[0083] An optical disc number determination module 630, configured to determine the range of the number of optical discs in the disc barrel according to the second signal or the third signal.
[0084] The optical disc number detection device provided by the embodiment of the present invention can execute the optical disc number detection method provided by any implementation scheme of the present invention, and has corresponding functional modules and beneficial effects for executing the method. The implementation manner and technical effect of the optical disc number detection device in this implementation scheme are similar to those of the above implementation scheme, and will not be elaborated here.
[0085] Figure 7 FIG. is a schematic structural diagram of another optical disc number detection device provided by an embodiment of the present invention. Optionally, refer to Figure 7 , the optical disc number detection device further includes:
[0086] An alarm control module 640 is configured to issue an alarm control signal according to the optical disc quantity range.
[0087] Figure 8 It is a schematic structural diagram of an electronic device for implementing the optical disc quantity detection method according to an embodiment of the present invention. Figure 8 It shows a schematic structural diagram of an electronic device 10 that can be used to implement an embodiment of the present invention. The electronic device is intended to represent various forms of digital computers, such as, a laptop computer, a desktop computer, a workbench, a personal digital assistant, a server, a blade server, a mainframe computer, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as, a personal digital processor, a cellular phone, a smart phone, a wearable device (such as a helmet, glasses, a watch, etc.) and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or claimed herein.
[0088] As Figure 8 shown, the electronic device 10 includes at least one processor 11, and a memory communicatively connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc. Among them, the memory stores a computer program executable by the at least one processor. The processor 11 can execute various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 into the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. The input / output (I / O) interface 15 is also connected to the bus 14.
[0089] Multiple components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a magnetic disk, an optical disc, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0090] The processor 11 may be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as the optical disc quantity detection method.
[0091] In some embodiments, the optical disc quantity detection method may be implemented as a computer program tangibly embodied in a computer-readable storage medium, such as the storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed onto the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the optical disc quantity detection method described above may be executed. Alternatively, in other embodiments, the processor 11 may be configured to execute the optical disc quantity detection method by any other suitable means (e.g., by means of firmware).
[0092] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuitry, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-chip (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special-purpose or general-purpose programmable processor that receives data and instructions from a storage system, at least one input device, and at least one output device, and transmits the data and instructions to the storage system, the at least one input device, and the at least one output device.
[0093] The computer program for implementing the method of the present invention can be written in any combination of one or more programming languages. These computer programs can be provided to the processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when the computer program is executed by the processor, the functions / operations specified in the flowchart and / or block diagram are implemented. The computer program can be executed entirely on the machine, partially on the machine, as a stand-alone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.
[0094] In the context of the present invention, a computer-readable storage medium can be a tangible medium that can contain or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer-readable storage medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, the computer-readable storage medium can be a machine-readable signal medium. More specific examples of the machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0095] To provide for interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the electronic device. Other kinds of devices can also be used to provide for interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0096] The systems and techniques described herein can be implemented in a computing system that includes backend components (such as, for example, a data server), or a computing system that includes middleware components (such as, for example, an application server), or a computing system that includes frontend components (such as, for example, a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected by any form or medium of digital data communication (such as, for example, a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0097] A computing system may include a client and a server. The client and the server are generally far from each other and usually interact via a communication network. The client-server relationship is created by computer programs running on respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system, solving the defects of difficult management and weak business scalability existing in traditional physical hosts and VPS services.
[0098] It should be understood that various forms of the processes shown above can be used, with steps reordered, added, or deleted. For example, the steps recited in the present invention can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solution of the present invention can be achieved, and no limitation is imposed herein.
[0099] The above specific embodiments do not constitute a limitation on the protection scope of the present invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims
1. A method for detecting the number of optical discs, characterized in that, Including: Determining device parameters in the transmitting device and device parameters in the receiving device according to the detection distance relationship between the transmitting device and the receiving device; Determining a transmitting circuit according to the device parameters of the transmitting device, and determining a receiving circuit according to the device parameters of the receiving device; wherein, the transmitting circuit includes a plurality of the transmitting devices, and the receiving circuit includes a plurality of the receiving devices; wherein, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when the first signal is received, and emit a third signal when the first signal is not received; Determining the number range of optical discs in the disc barrel according to the second signal or the third signal; Wherein, the receiving device includes an infrared receiving tube and a first resistor. The first end of the first resistor is connected to a power signal, the second end of the first resistor is electrically connected to the cathode of the infrared receiving tube, and the anode of the infrared receiving tube is grounded; the transmitting device includes a second resistor and an infrared transmitting tube; the first end of the second resistor is connected to a power signal, the second end of the second resistor is electrically connected to the anode of the infrared transmitting tube, and the cathode of the infrared transmitting tube is grounded; The detection distance relational expression is where D is the detection distance, λ p1 is the peak value of the signal emitted by the transmitting device, λ p2 is the peak value of the signal received by the receiving device, R pT is the resistance value of the first resistor, R IR is the resistance value of the second resistor; Determine the peak wavelength λ of the emitted signal based on the infrared emitting tube and the infrared receiving tube p1 and the peak wavelength λ of the received signal p2 , and determine the resistance values of the first resistor and the second resistor according to the required detection distance and the detection distance relationship formula.
2. The optical disc quantity detection method according to claim 1, wherein Determining the resistance values of the first resistor and the second resistor according to the detection distance relationship between the transmitting device and the receiving device includes: Determining a preset detection distance between the receiving device and the transmitting device, and determining a preset intensity of the first signal; Determining the resistance values of the first resistor and the second resistor according to the preset detection distance, the preset intensity and the detection distance relationship.
3. The optical disc quantity detection method according to claim 1, wherein After determining the number range of optical discs in the disc barrel according to the second signal or the third signal, further including: Sending an alarm control signal according to the number range of optical discs.
4. The optical disc quantity detection method according to claim 1, wherein After determining the number range of optical discs in the disc barrel according to the second signal or the third signal, further including: Sending the number range of optical discs to a display device so that the display device displays the number range of optical discs.
5. An optical disc quantity detection device, characterized in that, Including: A device parameter determination module, configured to determine device parameters in the transmitting device and device parameters in the receiving device according to the detection distance relationship between the transmitting device and the receiving device; A circuit determination module, configured to determine a transmitting circuit according to the device parameters of the transmitting device, and determine a receiving circuit according to the device parameters of the receiving device; wherein, the transmitting circuit includes a plurality of the transmitting devices, and the receiving circuit includes a plurality of the receiving devices; wherein, the transmitting device is configured to transmit a first signal, and the receiving device is configured to emit a second signal when the first signal is received, and emit a third signal when the first signal is not received; A disc number determination module, configured to determine the number range of optical discs in the disc barrel according to the second signal or the third signal; Wherein, the receiving device includes an infrared receiving tube and a first resistor. The first end of the first resistor is connected to a power signal, the second end of the first resistor is electrically connected to the cathode of the infrared receiving tube, and the anode of the infrared receiving tube is grounded; the transmitting device includes a second resistor and an infrared transmitting tube; the first end of the second resistor is connected to a power signal, the second end of the second resistor is electrically connected to the anode of the infrared transmitting tube, and the cathode of the infrared transmitting tube is grounded; The detection distance relationship formula is where D is the detection distance, λ p1 is the peak value of the signal emitted by the transmitting device, λ p2 is the peak value of the signal received by the receiving device, R pT is the resistance value of the first resistor, R IR is the resistance value of the second resistor; Determine the peak wavelength λ of the emitted signal based on the infrared emitting tube and the infrared receiving tube p1 and the peak wavelength λ of the received signal p2 , and determine the resistance values of the first resistor and the second resistor according to the required detection distance and the detection distance relationship formula 6. The optical disc quantity detection device according to claim 5, wherein Further included is: An alarm control module, configured to issue an alarm control signal according to the optical disc quantity range.
7. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program executable by the at least one processor, and when the computer program is executed by the at least one processor, the at least one processor is enabled to execute the optical disc quantity detection method according to any one of claims 1-4.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions, and when the computer instructions are executed by a processor, the optical disc quantity detection method according to any one of claims 1-4 is implemented.
Citation Information
Patent Citations
Optical disc number detection device and optical disc juke-box
CN217113320U
Wafer detection device and wafer positioning device
JP1994069323A
Food and beverage accommodation device and method for measuring and providing food and beverage consumption information
WO2016021906A1