CN114006653A - Equipment compatible with different types of optical modules, control method thereof and storage medium - Google Patents

Equipment compatible with different types of optical modules, control method thereof and storage medium Download PDF

Info

Publication number
CN114006653A
CN114006653A CN202111270614.8A CN202111270614A CN114006653A CN 114006653 A CN114006653 A CN 114006653A CN 202111270614 A CN202111270614 A CN 202111270614A CN 114006653 A CN114006653 A CN 114006653A
Authority
CN
China
Prior art keywords
optical module
circuit
optical
type
control
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.)
Granted
Application number
CN202111270614.8A
Other languages
Chinese (zh)
Other versions
CN114006653B (en
Inventor
张标
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ruijie Networks Co Ltd
Original Assignee
Ruijie Networks 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 Ruijie Networks Co Ltd filed Critical Ruijie Networks Co Ltd
Priority to CN202111270614.8A priority Critical patent/CN114006653B/en
Publication of CN114006653A publication Critical patent/CN114006653A/en
Application granted granted Critical
Publication of CN114006653B publication Critical patent/CN114006653B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B10/00Transmission systems employing electromagnetic waves other than radio-waves, e.g. infrared, visible or ultraviolet light, or employing corpuscular radiation, e.g. quantum communication
    • H04B10/03Arrangements for fault recovery
    • H04B10/032Arrangements for fault recovery using working and protection systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B10/00Transmission systems employing electromagnetic waves other than radio-waves, e.g. infrared, visible or ultraviolet light, or employing corpuscular radiation, e.g. quantum communication
    • H04B10/03Arrangements for fault recovery
    • H04B10/038Arrangements for fault recovery using bypasses

Landscapes

  • Physics & Mathematics (AREA)
  • Electromagnetism (AREA)
  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Optical Communication System (AREA)

Abstract

The invention discloses a device compatible with different types of optical modules, a control method and a storage medium thereof, which are used for solving the problem that a switch can not be compatible with an SFP/SFP + optical module and a CSFP/SCFP + optical module at the same time, and the device comprises: the on-site detection circuit is connected between an on-site detection end of the control circuit and a designated pin of the optical port and is used for detecting whether the optical module is connected into the optical port; i of control circuit and optical port2The pin corresponding to the C bus is connected and used for determining that the optical module is connected into the optical port according to the detection result of the in-place detection current and then passing through the I2The bus reads the optical module information from the optical module, determines the type of the optical module according to whether the optical module information is read or not, and outputs a control signal of a working state corresponding to the type of the optical module; and the adaptation circuit is connected between the optical port and the second exchange circuit and is used for adapting the second exchange circuit to a state corresponding to the type of the optical module according to the control signal.

Description

Equipment compatible with different types of optical modules, control method thereof and storage medium
Technical Field
The present invention relates to the field of optical communications, and in particular, to an apparatus compatible with different types of optical modules, a control method thereof, and a storage medium.
Background
In the field of optical communication, in order to ensure the universality of optical modules produced by different manufacturers, standard specifications for different types of optical modules are established.
In these standard specifications, the structure size, signal definition, register definition, etc. of the optical module are generally defined to ensure the universality of the optical modules produced by different manufacturers. For example, the Compact Small Form-Factor plug-able Multi-Source agent (CSFP MSA)2.0 specification specifies a CSFP + gigabit optical module that integrates two gigabit optical ports, the external dimensions of which are consistent with the SFP + gigabit optical module specified by the Small Form-Factor (SFF) -8432 specification. Therefore, both the CSFP + module and the SFP + module can be inserted into the corresponding interfaces of the Small Form-factor plug (SFP) + optical module from the structural point of view. However, since the pin definition of CSFP + is different from that of SFP +, the interface supporting the CSFP + module cannot directly use the SFP + module from an electrical point of view.
If the switch connected with the optical module supports the interface corresponding to the SFP/SFP + optical module, the number of optical ports that can be supported by the switch is small, and if the switch supports the interface corresponding to the CSFP/SCFP + optical module, the cost for using the CSFP/CSFP + is high. If the switch can be compatible with the two optical modules simultaneously, the application of the switch can be more flexible.
In view of this, how to make the switch compatible with the SFP/SFP + optical module and the CSFP/SCFP + optical module at the same time becomes a technical problem to be solved urgently.
Disclosure of Invention
The invention provides equipment compatible with different types of optical modules, a control method and a storage medium thereof, which are used for solving the technical problem that a switch in the prior art cannot be compatible with an SFP/SFP + optical module and a CSFP/SCFP + optical module at the same time.
In a first aspect, to solve the above technical problems, an apparatus compatible with different types of optical modules provided in an embodiment of the present invention includes a control circuit, a first switch circuit, a second switch circuit, and an optical port, where the first switch circuit and the second switch circuit are connected between the control circuit and the optical port, the first switch circuit and the second switch circuit are used to obtain optical signals of respective corresponding transmission channels from the optical port and convert the optical signals into digital signals, and the control circuit is used to configure and manage the first switch circuit and the second switch circuit, and a technical scheme of the apparatus is as follows:
the in-place detection circuit is connected between the in-place detection end of the control circuit and the appointed pin of the optical port and is used for detecting whether an optical module is connected into the optical port; the designated pin is a pin corresponding to the grounding end of the second exchange circuit;
the control circuit and the internal integrated circuit I of the optical port2The pin corresponding to the C bus is connected and is also used for determining that an optical module is connected to the optical port according to the detection result of the on-site detection circuit and then passes through the I2The bus C reads optical module information from the optical module, determines the type of the optical module according to whether the optical module information is read or not, and outputs a control signal corresponding to the type of the optical module;
and the adaptation circuit is connected between the optical port and the second exchange circuit and is used for adapting the second exchange circuit to a state corresponding to the type of the optical module according to the control signal.
In one possible implementation, the presence detection circuit includes:
the first resistor is connected between the in-place detection end and the appointed pin and used for reducing the voltage of the in-place detection end when the optical module is connected into the optical port;
and the second resistor is connected between the on-site detection end and the constant voltage source and used for limiting the current of the on-site detection end.
In one possible embodiment, the adaptation circuit includes:
the controlled end is connected with the control end of the control circuit and is used for receiving the control signal from the control circuit;
the switching circuit is connected between the optical port and the constant voltage source, a control end of the switching circuit is electrically connected with a control end of the control circuit through the controlled end, the switching circuit is used for determining the type of the optical module according to the control signal, and if the type of the optical module is determined to be a single-channel optical module, a pull-up signal corresponding to the constant voltage source is output to pull up the voltage of a speed selection end of the optical module, so that the second switching circuit is switched to a non-working state; if the type of the optical module is determined to be a dual-channel optical module, outputting a high-resistance signal to switch the second switching circuit to a working state;
and the protection circuit is connected between the second exchange circuit and the optical port and used for preventing the second exchange circuit from being damaged when the type of the optical module is the single-channel optical module.
In one possible embodiment, the switching circuit includes:
one end of each of the two pull-up resistors is connected with the constant voltage source;
the input ends of the two tri-state gates are respectively connected with the other ends of the two pull-up resistors, the output ends of the two tri-state gates are respectively connected with two pins of the optical port, the control ends of the two tri-state gates are used as the control ends of the switching circuit and are electrically connected with the output pins of the tri-state gate corresponding to the control circuit, and the two tri-state gates are used for controlling the respective output ends to output the pull-up signals or the high-impedance signals according to the control signals; the default output of the tri-state gate is the high-impedance signal, and the two pins are respectively connected with the receiving and signaling pins with positive electrical property in the corresponding second switching circuit.
In one possible embodiment, the protection circuit includes:
the capacitor is connected between the second switching circuit and each pair of transceiving pins corresponding to the optical port and used for preventing the second switching circuit from being damaged when the optical module is of the type of the single-channel optical module;
the third resistor is connected between a second sending enabling pin of the control circuit and a pin corresponding to the optical port and used for preventing a chip connected with the second sending enabling pin in the control circuit from being damaged;
the fourth resistor is connected between a second receiving loss indication pin of the control circuit and the corresponding pin of the optical port and used for preventing a chip connected with the second receiving loss pin in the control circuit from being damaged;
and the fifth resistor is connected between the constant voltage source and the third resistor and the second receiving missing pin and used for providing a pull-up signal for the second receiving missing pin.
In a second aspect, an embodiment of the present invention provides a method for controlling an apparatus, where the method is applied to the apparatus according to the first aspect, and the method includes:
detecting whether an optical module is accessed through an in-place detection circuit;
if the fact that an optical module is accessed is detected, determining the type of the optical module according to whether a control circuit reads optical module information of the optical module;
and controlling an adaptation circuit to adapt a second exchange circuit to a state corresponding to the type of the optical module according to the type of the optical module.
One possible implementation manner, determining the type of the optical module according to whether the control circuit reads the optical module information of the optical module, includes:
if the control circuit reads the optical module information, determining that the type of the optical module is a dual-channel optical module;
and if the control circuit does not read the information of the optical module, determining that the type of the optical module is a single-channel optical module.
A possible implementation manner, according to the type of the optical module, controlling the adaptation circuit to adapt the second switch circuit to a state corresponding to the type of the optical module, includes:
if the type of the optical module is the dual-channel optical module, controlling the adaptation circuit to switch the second exchange circuit to a working state, so that the equipment works in a dual-channel mode;
and if the type of the optical module is the single-channel optical module, controlling the adaptation circuit to switch the second exchange circuit to a non-working state, so that the equipment works in a single-channel mode.
In a third aspect, an embodiment of the present invention further provides an apparatus, including:
at least one processor, and
a memory coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor, and the at least one processor performs the method according to the second aspect by executing the instructions stored by the memory.
In a fourth aspect, an embodiment of the present invention further provides a readable storage medium, including:
a memory for storing a plurality of data to be transmitted,
the memory is for storing instructions that, when executed by the processor, cause an apparatus comprising the readable storage medium to perform the method of the second aspect as described above.
Through the technical solutions in one or more of the above embodiments of the present invention, the embodiments of the present invention have at least the following technical effects:
in the embodiment provided by the invention, the in-place detection end of the control circuit is connected with the appointed pin of the optical port, so that the control circuit can detect whether the optical module is accessed through the appointed pin, and further, after the optical module is detected to be accessed, the control circuit can detect whether the optical module is accessed through the I2The bus C reads optical module information from the accessed optical module, determines the type of the accessed optical module according to whether the optical module information is read or not, outputs a control signal of a working state corresponding to the type of the optical module, and controls the adaptation circuit to adapt the second exchange circuit to a state corresponding to the type of the accessed optical module, so that the accessed optical module can normally communicate with the equipment, the purpose that the equipment is compatible with a single-channel optical module and a double-channel optical module is achieved, the application of the equipment is more flexible, when more transmission channels need to be used, the double-channel optical module can be accessed, the number of optical ports is doubled without increasing the cost of the optical ports, when the number of the required transmission channels is less, the single-channel optical module with a lower price can be accessed, and the use cost is reduced.
Drawings
FIG. 1 is a pin diagram of 2ch CSFP option 2;
FIG. 2 is a pin diagram of SFP/SFP +;
fig. 3 is a schematic structural diagram of a device compatible with different types of optical modules according to an embodiment of the present invention;
FIG. 4 is a circuit diagram of an on-bit detection circuit according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an adaptation circuit according to an embodiment of the present invention;
FIG. 6 is a circuit diagram of a switching circuit according to an embodiment of the present invention;
fig. 7 is a circuit diagram of a protection circuit according to an embodiment of the present invention;
fig. 8 is a circuit diagram of a device compatible with different types of optical modules according to an embodiment of the present invention;
fig. 9 is a flowchart of a method for controlling a device compatible with different types of optical modules according to an embodiment of the present invention.
Detailed Description
The embodiment of the invention provides equipment compatible with different types of optical modules, a control method and a storage medium thereof, which are used for solving the technical problem that a switch in the prior art cannot be compatible with an SFP/SFP + optical module and a CSFP/SCFP + optical module at the same time.
In order to better understand the technical solutions of the present invention, the following detailed descriptions of the technical solutions of the present invention are provided with the accompanying drawings and the specific embodiments, and it should be understood that the specific features in the embodiments and the examples of the present invention are the detailed descriptions of the technical solutions of the present invention, and are not limitations of the technical solutions of the present invention, and the technical features in the embodiments and the examples of the present invention may be combined with each other without conflict.
Referring to fig. 1 and fig. 2, fig. 1 is a schematic diagram of a pin of the 2ch CSFP option2, and fig. 2 is a schematic diagram of a pin of SFP/SFP +. The pin meanings of 2ch CSFP option2 and SFP/SFP + are shown in Table 1.
TABLE 1
Figure BDA0003328616370000061
Figure BDA0003328616370000071
It can be seen from fig. 1 and fig. 2 and table 1 that the pin definitions of CSFP/CSFP + and SFP/SFP + are different, which makes SFP/SFP + not able to access the CSFP + optical port.
The pins of the standard CSFP + optical port are the same as those in fig. 1, and the pins of the standard SFP + optical port are the same as those in fig. 2.
In practical application, the CSFP + optical port can provide more data channels than the SFP + optical port, but the cost of the SFP/SFP + optical module is lower than that of the CSFP/CSFP + optical module, and if the optical port in the device is compatible with the SFP/SFP + optical module and the CSFP/CSFP + optical module at the same time, the accessed optical module can be more flexible while the device has a larger number of optical ports.
In order to solve the above technical problem, the present application provides the following solutions.
Referring to fig. 3, an embodiment of the present invention provides a schematic structural diagram of a device compatible with different types of optical modules, where the device includes:
the optical switch comprises a control circuit S1, a first switch circuit S2, a second switch circuit S3 and an optical port S4, wherein the first switch circuit S2 and the second switch circuit S3 are connected between the control circuit S1 and the optical port S4, the first switch circuit S2 and the second switch circuit S3 are used for acquiring optical signals of respective corresponding transmission channels from the optical port S4 and converting the optical signals into digital signals, and the control circuit S1 is used for configuring and managing the first switch circuit and the second switch circuit;
an on-site detection circuit S5 connected between the on-site detection end of the control circuit S1 and the designated pin of the optical port S4 for detecting whether an optical module is connected to the optical port S4; wherein, the designated pin is a pin corresponding to the ground terminal of the second switch circuit S3;
control Circuit S1 and Inter-Integrated Circuit (I) of optical port S42C) The corresponding pins of the bus are connected, and the bus is also used for determining that an optical module is connected into the optical port S4 according to the detection result of the in-place detection circuit S5 and then passing through I2C, the bus reads the information of the optical module from the optical module, determines the type of the optical module according to whether the information of the optical module is read or not, and outputs the information and the type of the optical moduleA corresponding control signal;
and an adaptation circuit S6 connected between the optical port S4 and the second switch circuit S3, for adapting the second switch circuit S3 to a state corresponding to the type of the optical module according to the control signal.
The connection method between the first switch circuit S2 and the optical port S4 and the control circuit S1 can be continued by using a switch circuit and an optical port common to the dual-channel optical module and the single-channel optical module, such as a single-channel optical module (SFP + optical module) and a dual-channel optical module (CSFP + optical module), the common switch circuit of which is a standard switch circuit of a first channel in the CSFP + optical module, the standard switch circuit of the first channel in the CSFP + optical module is used as a first switch circuit in the present application, the standard switch circuit of a second channel in the CSFP + optical module is used as a second switch circuit in the present application, the standard CSFP + optical port in the CSFP + optical module is used as the optical port S4 in the present invention, the standard control circuit in the CSFP + optical module is used as a control circuit in the present application, and the connection method between the standard CSFP + optical port in the CSFP + optical module and the standard control circuit is continued, therefore, the description thereof is omitted.
In order to make the device compatible with a single-channel optical module (such as an SFP/SFP + optical module) and a dual-channel optical module (such as a CSFP/CSFP + optical module), a circuit corresponding to a standard dual-channel optical module (such as a CSFP + optical module) is improved:
first, the on-site detection circuit S5 is connected between a designated pin (e.g., the ground pin 11 of the CSFP + optical module) in the optical port S4 (e.g., the CSFP + optical port) of the standard dual-channel optical module and an on-site detection terminal in the control circuit S1, so as to assist the controller S1 in detecting whether an optical module is accessed.
Secondly, a control circuit S1 in the dual-channel optical module is improved, so that the control circuit S1 determines whether an optical module is accessed through a signal read from an in-place detection end, and after the optical module is determined to be accessed, the control circuit passes through I2C, the bus reads optical module information from the accessed optical module, if the optical module information is read, the type of the accessed optical module is determined to be a dual-channel optical module, if the optical module information is not read, the type of the accessed optical module is determined to be a single-channel optical module, andand outputting a corresponding control signal.
An adapting circuit S6 is additionally arranged between a standard switch circuit (corresponding to the second switch circuit S3 in the present invention) of a second channel corresponding to an optical port S4 (e.g., CSFP + optical port) of a standard dual-channel optical module and an optical port S4 (e.g., standard CSFP + optical port), so that the second switch circuit S3 is adapted to a state corresponding to the type of an accessed optical module according to a control signal output by the control circuit, so that the optical module and the device perform data transmission, thereby achieving the purpose that the device is compatible with both a single-channel optical module and a dual-channel optical module.
In the embodiment of the invention, the in-place detection end of the control circuit S1 is connected to the designated pin of the optical port S4, so that the control circuit S1 can detect whether the optical module is connected through the designated pin, and after detecting that the optical module is connected, the optical module is connected through the I2The bus C reads optical module information from the accessed optical module, determines the type of the accessed optical module according to whether the optical module information is read or not, outputs a control signal corresponding to the type of the optical module, and controls the adaptation circuit S6 to adapt the second switching circuit S3 to a state corresponding to the type of the accessed optical module, so that the accessed optical module can normally communicate with the equipment, the purpose that the equipment is compatible with a single-channel optical module and a dual-channel optical module is achieved, the application of the equipment is more flexible, when more transmission channels are needed to be used, the dual-channel optical module can be accessed, the number of optical ports is doubled, the cost of the optical ports is not increased, when the needed transmission channels are few, the single-channel optical module with a lower price can be accessed, and the use cost is reduced.
Fig. 4 is a circuit diagram of an on-bit detection circuit according to an embodiment of the invention.
The presence detection circuit S5 includes:
the first resistor S51 is connected between the on-position detection end and the designated pin and used for pulling down the voltage of the on-position detection end when the optical module is connected into the optical port S4;
the second resistor S52 is connected between the on-bit detection terminal and the constant voltage source VCC, and is used for limiting the current at the on-bit detection terminal.
When no optical module is connected to the optical port 4, since the designated pin is in a floating state, the voltage of the constant voltage source VCC is transmitted to the on-position detection terminal through the second resistor S52, the voltage of the on-position detection terminal of the control circuit S1 is a high voltage (i.e., a high level detected by the control circuit S1), and when an optical module is connected to the optical port 4, since the designated pin in the optical module is a ground terminal, at this time, the first resistor S51 is connected in series with the second resistor S52, the voltage of the on-position detection terminal is pulled low, so that the control circuit S1 detects that the voltage of the on-position detection terminal is a low level, and further the control circuit S1 can determine whether the optical module is connected according to the detected levels of the on-position detection terminal. No matter whether the optical port S4 has an optical module connected, the second resistor S52 can limit the current flowing into the on-site detection end so as to protect the on-site detection end from damaging the control circuit S1 due to the excessive flowing current.
Fig. 5 is a schematic structural diagram of an adaptation circuit according to an embodiment of the present invention.
An adaptation circuit S6, comprising:
a controlled terminal S61 connected to the control terminal S1c of the control circuit S1 for receiving a control signal from the control circuit S1;
the switching circuit S62 is connected between the optical port S4 and the constant voltage source VCC, a control end of the switching circuit S62 is electrically connected with a control end of the control circuit through the controlled end S61, the switching circuit S62 is configured to determine the type of the optical module according to the control signal, and if the type of the optical module is determined to be a single-channel optical module, output a pull-up signal corresponding to the constant voltage source VCC to pull up a voltage at a rate selection end of the optical module, so that the second switching circuit S3 is switched to a working state; if the type of the optical module is determined to be a dual-channel optical module, outputting a high-resistance signal to switch the optical second switching circuit S3 to be in a non-working state; the voltage value of the constant voltage source VCC may be 3.3V, or may be set to another voltage value according to actual needs.
And a protection circuit 53 connected between the second switch circuit S3 and the optical port S4, for preventing the second switch circuit S3 from being damaged when the type of the optical module is a dual-channel optical module.
In the embodiment provided by the invention, by providing the switching circuit S62 connected between the optical port S4 and the constant voltage source VCC in the adapting circuit S6, the adapting circuit S6 can control the state of the second switching circuit S3 by using the switching circuit S62 according to the type of the connected photovoltaic module, so that the second switching circuit S3 is adapted to the working state or the non-working state corresponding to the type of the photovoltaic module; and the protection circuit 53 is arranged in the adaptation circuit S6, so that the second switching circuit S3 can be prevented from being damaged when the type of the optical module is a single-channel optical module.
Referring to fig. 6, a circuit diagram of a switching circuit according to an embodiment of the present invention is shown, in which the switching circuit S62 includes:
one end of each of the two pull-up resistors S621 is connected to a constant voltage source VCC;
two tristate gates S622, input terminals S622i of the two tristate gates S622 are respectively connected with the other ends of the two pull-up resistors S621, output terminals S622o of the two tristate gates S622 are respectively connected with two pins in the optical port S4, control terminals S622c of the two tristate gates S622 are electrically connected with output pins of the tristate gate corresponding to the control circuit S1 as control terminals of the switching circuit 62, and the two tristate gates S622 are used for controlling the respective output terminals S622o to output pull-up signals or high-impedance signals according to the control signals; the output of the tri-state gate S622 is a high impedance signal, and the two pins are respectively connected to the signal receiving and transmitting pins electrically positive in the corresponding second switch circuit S3.
The electrical property in the second switch circuit S3 is positive signal receiving and transmitting pins, that is, the signal in the standard switch circuit of the second channel is positive signal receiving and transmitting pins, and two corresponding pins in the optical port S4 are RD2+ pin and TD2+ pin in the standard optical port (for example, CSFP optical port) of the standard dual-channel optical module. The tri-state gate S622 may be, for example, 74LVC1G125, but may also be a tri-state gate of another type, which is not illustrated here.
Referring to fig. 7, which is a circuit diagram of a protection circuit according to an embodiment of the present invention, the protection circuit S63 includes:
the capacitor S631 is connected between the second switch circuit S3 and each pair of transceiving pins corresponding to the optical port S4, and is configured to prevent the second switch circuit S3 from being damaged when the single-channel optical module is accessed; the second switch circuit S3 comprises a pair of second receiving pins (RD2+, RD2-) and a pair of second transmitting pins (TD2+, TD 2-). By arranging the capacitor S631 between each pair of transceiving pins corresponding to the second switch circuit S3 and the optical port S4, the second switch circuit S3 can be prevented from being damaged when the dual-channel optical module is connected to the optical port S4, so that the second switch circuit S3 can be normally used no matter whether the single-channel optical module is connected to the optical port S4 or the dual-channel optical module is connected to the optical port S4, and the second switch circuit S3 is prevented from being damaged.
A third resistor S632 connected between the second transmit enable pin S11 of the control circuit S1 and the pin corresponding to the optical port 4, for preventing the chip connected to the second transmit enable pin S11 in the control circuit from being damaged;
a fourth resistor S633 connected between the second reception loss indication pin S12 of the control circuit S1 and the corresponding pin of the optical port S4, for preventing the chip connected to the second reception loss pin S32 in the control circuit from being damaged;
the fifth resistor S634 is connected between the constant voltage source VCC and the third resistor S632 and the second receiving loss pin S12, and is used for providing a pull-up signal for the second receiving loss pin S12.
The value of the capacitor S631 may be 0.1uF, the values of the first resistor S632 and the second resistor S633 may be 100 Ω, and the value of the third resistor S634 may be 4.7k Ω.
In the embodiment of the present invention, the control circuit S1 includes a Complex Programmable Logic Device (CPLD), a Central Processing Unit (CPU), the CPLD stores some configurations initialized by some CPUs to ensure that the CPUs are normally started after being powered on, and the CPUs are used for configuring devices, controlling data interaction, and the like.
Fig. 8 is a circuit diagram of a device compatible with different types of optical modules according to an embodiment of the present invention.
In fig. 8, the pin numbers, the numbers and the meanings of the optical ports S4 are the same as those in table 1, and the related circuits of the first switch circuit S2 are also shown, and since the first switch circuit S2 is not modified, the first switch circuit S2 is used for the dual-channel optical module in the prior artThe circuit design of the first channel switching circuit is not described in detail. Meanwhile, fig. 7 also shows a CPU, CPLD included in the control circuit S1, which pass through I2The C interface and the accessed optical module carry out I2C communication, when CPLD detects that there is optical module to access optical port S4, it will generate an interrupt signal to be provided to CPU through lead INT, to make CPU pass I2The C interface reads the optical module information from the optical module to determine the type of the optical module, and controls the adapting circuit S6 to adapt the second switching circuit S3 to the working state of the optical module according to the determined type of the optical module.
It should be noted that TD1+ and TD 1-in the first switch circuit S2 are respectively a positive terminal and a negative terminal of the first path of transmission signal, RD1+ and RD 1-are respectively a positive terminal and a negative terminal of the first path of reception signal, and a resistor R1 connected between RD1+ and RD 1-may be determined according to actual needs to be set; TD2+ and TD 2-in the second switching circuit S3 are respectively a positive terminal and a negative terminal of the second path of sending signals, RD2+ and RD 2-are respectively a positive terminal and a negative terminal of the second path of receiving signals, and a resistor R2 connected between RD2+ and RD 2-can determine whether the setting is required according to actual needs.
Based on the same inventive concept, an embodiment of the present invention provides a method for controlling a device, which is applied to the device compatible with different types of optical modules, and the specific structure and the control implementation of the device may refer to the description of the embodiment of the device, and repeated descriptions are omitted, please refer to fig. 9, where the method includes:
step 901: detecting whether an optical module is accessed through an in-place detection circuit;
step 902: if the fact that an optical module is accessed is detected, determining the type of the optical module according to whether a control circuit reads optical module information of the optical module;
step 903: and controlling an adaptation circuit to adapt a second exchange circuit to a state corresponding to the type of the optical module according to the type of the optical module.
One possible implementation manner, determining the type of the optical module according to whether the control circuit reads the optical module information of the optical module, includes:
if the control circuit reads the optical module information, determining that the type of the optical module is a dual-channel optical module;
and if the control circuit does not read the information of the optical module, determining that the type of the optical module is a single-channel optical module.
A possible implementation manner, according to the type of the optical module, controlling the adaptation circuit to adapt the second switch circuit to a state corresponding to the type of the optical module, includes:
if the type of the optical module is the dual-channel optical module, controlling the adaptation circuit to switch the second exchange circuit to a working state, so that the equipment works in a dual-channel mode;
and if the type of the optical module is the single-channel optical module, controlling the adaptation circuit to switch the second exchange circuit to a non-working state, so that the equipment works in a single-channel mode.
Based on the same inventive concept, an embodiment of the present invention provides an apparatus, including: at least one processor, and
a memory coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor, and the at least one processor executes the control method as described above by executing the instructions stored by the memory.
Based on the same inventive concept, an embodiment of the present invention further provides a readable storage medium, including:
a memory for storing a plurality of data to be transmitted,
the memory is used to store instructions that, when executed by the processor, cause an apparatus comprising the readable storage medium to perform the control method as described above.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (10)

1. An apparatus compatible with different types of optical modules, the apparatus comprising a control circuit, a first switch circuit, a second switch circuit, and an optical port, the first switch circuit and the second switch circuit being connected between the control circuit and the optical port, the first switch circuit and the second switch circuit being configured to obtain optical signals of respective corresponding transmission channels from the optical port and convert the optical signals into digital signals, and the control circuit being configured and managed for the first switch circuit and the second switch circuit, the apparatus further comprising:
the in-place detection circuit is connected between the in-place detection end of the control circuit and the appointed pin of the optical port and is used for detecting whether an optical module is connected into the optical port; the designated pin is a pin corresponding to the grounding end of the second exchange circuit;
the control circuit and the internal integrated circuit I of the optical port2The pin corresponding to the C bus is connected and is also used for determining that an optical module is connected to the optical port according to the detection result of the on-site detection circuit and then passes through the I2The bus C reads optical module information from the optical module, determines the type of the optical module according to whether the optical module information is read or not, and outputs a control signal corresponding to the type of the optical module;
and the adaptation circuit is connected between the optical port and the second exchange circuit and is used for adapting the second exchange circuit to a state corresponding to the type of the optical module according to the control signal.
2. The apparatus of claim 1, wherein the presence detection circuit comprises:
the first resistor is connected between the in-place detection end and the appointed pin and used for reducing the voltage of the in-place detection end when the optical module is connected into the optical port;
and the second resistor is connected between the on-site detection end and the constant voltage source and used for limiting the current of the on-site detection end.
3. The device of claim 1, wherein the adaptation circuit comprises:
the controlled end is connected with the control end of the control circuit and is used for receiving the control signal from the control circuit;
the switching circuit is connected between the optical port and the constant voltage source, a control end of the switching circuit is electrically connected with a control end of the control circuit through the controlled end, the switching circuit is used for determining the type of the optical module according to the control signal, and if the type of the optical module is determined to be a single-channel optical module, a pull-up signal corresponding to the constant voltage source is output to pull up the voltage of a speed selection end of the optical module, so that the second switching circuit is switched to a non-working state; if the type of the optical module is determined to be a dual-channel optical module, outputting a high-resistance signal to switch the second switching circuit to a working state;
and the protection circuit is connected between the second exchange circuit and the optical port and used for preventing the second exchange circuit from being damaged when the type of the optical module is the single-channel optical module.
4. The device of claim 3, wherein the switching circuit comprises:
one end of each of the two pull-up resistors is connected with the constant voltage source;
the input ends of the two tri-state gates are respectively connected with the other ends of the two pull-up resistors, the output ends of the two tri-state gates are respectively connected with two pins of the optical port, the control ends of the two tri-state gates are used as the control ends of the switching circuit and are electrically connected with the output pins of the tri-state gate corresponding to the control circuit, and the two tri-state gates are used for controlling the respective output ends to output the pull-up signals or the high-impedance signals according to the control signals; the default output of the tri-state gate is the high-impedance signal, and the two pins are respectively connected with the receiving and signaling pins with positive electrical property in the corresponding second switching circuit.
5. The device of claim 3, wherein the protection circuit comprises:
the capacitor is connected between the second switching circuit and each pair of transceiving pins corresponding to the optical port and used for preventing the second switching circuit from being damaged when the optical module is of the type of the single-channel optical module;
the third resistor is connected between a second sending enabling pin of the control circuit and a pin corresponding to the optical port and used for preventing a chip connected with the second sending enabling pin in the control circuit from being damaged;
the fourth resistor is connected between a second receiving loss indication pin of the control circuit and the corresponding pin of the optical port and used for preventing a chip connected with the second receiving loss pin in the control circuit from being damaged;
and the fifth resistor is connected between the constant voltage source and the third resistor and the second receiving missing pin and used for providing a pull-up signal for the second receiving missing pin.
6. A control method of an apparatus applied to the apparatus according to any one of claims 1 to 5, characterized by comprising:
detecting whether an optical module is accessed through an in-place detection circuit;
if the fact that an optical module is accessed is detected, determining the type of the optical module according to whether a control circuit reads optical module information of the optical module;
and controlling an adaptation circuit to adapt a second exchange circuit to a state corresponding to the type of the optical module according to the type of the optical module.
7. The method of claim 6, wherein determining the type of the optical module according to whether the control circuit reads the optical module information of the optical module comprises:
if the control circuit reads the optical module information, determining that the type of the optical module is a dual-channel optical module;
and if the control circuit does not read the information of the optical module, determining that the type of the optical module is a single-channel optical module.
8. The control method of claim 7, wherein controlling the adaptation circuit to switch the second switching circuit to a state corresponding to the type of the optical module according to the type of the optical module comprises:
if the type of the optical module is the dual-channel optical module, controlling the adaptation circuit to switch the second exchange circuit to a working state, so that the equipment works in a dual-channel mode;
and if the type of the optical module is the single-channel optical module, the adaptation circuit is utilized to switch the second exchange circuit to a non-working state, so that the equipment works in a single-channel mode.
9. An apparatus, comprising:
at least one processor, and
a memory coupled to the at least one processor;
wherein the memory stores instructions executable by the at least one processor, the at least one processor performing the method of any one of claims 6-8 by executing the instructions stored by the memory.
10. A readable storage medium, comprising a memory,
the memory is to store instructions that, when executed by the processor, cause an apparatus comprising the readable storage medium to perform the method of any one of claims 6-8.
CN202111270614.8A 2021-10-29 2021-10-29 Equipment compatible with different types of optical modules, control method thereof and storage medium Active CN114006653B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111270614.8A CN114006653B (en) 2021-10-29 2021-10-29 Equipment compatible with different types of optical modules, control method thereof and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111270614.8A CN114006653B (en) 2021-10-29 2021-10-29 Equipment compatible with different types of optical modules, control method thereof and storage medium

Publications (2)

Publication Number Publication Date
CN114006653A true CN114006653A (en) 2022-02-01
CN114006653B CN114006653B (en) 2023-03-21

Family

ID=79925051

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111270614.8A Active CN114006653B (en) 2021-10-29 2021-10-29 Equipment compatible with different types of optical modules, control method thereof and storage medium

Country Status (1)

Country Link
CN (1) CN114006653B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114979494A (en) * 2022-06-28 2022-08-30 重庆紫光华山智安科技有限公司 Communication mode control method, device, camera and readable storage medium
CN115460161A (en) * 2022-08-05 2022-12-09 深圳市飞速创新技术股份有限公司 Optical module code changing method, device, equipment and storage medium
CN116233661A (en) * 2023-05-04 2023-06-06 新华三技术有限公司 Network equipment and optical module access control method

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010115329A1 (en) * 2009-04-08 2010-10-14 中兴通讯股份有限公司 Photoelectric interface automatic switching method and device
CN102590689A (en) * 2011-01-14 2012-07-18 中兴通讯股份有限公司 Device for detecting in-place of small form-factor pluggable (SFP) optical modules
US20160056885A1 (en) * 2014-08-19 2016-02-25 Ubiquoss Inc. Optical network terminal with functions of detecting and recovering from failures, blocking supplied power, and storing information, and method of detecting continuous optical output using the same
CN110880952A (en) * 2019-10-23 2020-03-13 浪潮思科网络科技有限公司 Switch interface rate self-adaptive tuning system, method, equipment and medium
CN111541956A (en) * 2020-04-20 2020-08-14 深圳市三旺通信股份有限公司 Optical port self-adaption method, device, switch and computer readable storage medium
CN111541629A (en) * 2020-04-21 2020-08-14 深圳市三旺通信股份有限公司 Mode self-adaption method, device, equipment and computer readable storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010115329A1 (en) * 2009-04-08 2010-10-14 中兴通讯股份有限公司 Photoelectric interface automatic switching method and device
CN102590689A (en) * 2011-01-14 2012-07-18 中兴通讯股份有限公司 Device for detecting in-place of small form-factor pluggable (SFP) optical modules
US20160056885A1 (en) * 2014-08-19 2016-02-25 Ubiquoss Inc. Optical network terminal with functions of detecting and recovering from failures, blocking supplied power, and storing information, and method of detecting continuous optical output using the same
CN110880952A (en) * 2019-10-23 2020-03-13 浪潮思科网络科技有限公司 Switch interface rate self-adaptive tuning system, method, equipment and medium
CN111541956A (en) * 2020-04-20 2020-08-14 深圳市三旺通信股份有限公司 Optical port self-adaption method, device, switch and computer readable storage medium
CN111541629A (en) * 2020-04-21 2020-08-14 深圳市三旺通信股份有限公司 Mode self-adaption method, device, equipment and computer readable storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
高敏: "多速率自适应技术在Ir协议中的应用研究", 《光通信技术》 *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114979494A (en) * 2022-06-28 2022-08-30 重庆紫光华山智安科技有限公司 Communication mode control method, device, camera and readable storage medium
CN115460161A (en) * 2022-08-05 2022-12-09 深圳市飞速创新技术股份有限公司 Optical module code changing method, device, equipment and storage medium
CN115460161B (en) * 2022-08-05 2024-01-05 深圳市飞速创新技术股份有限公司 Optical module code changing method, device, equipment and storage medium
CN116233661A (en) * 2023-05-04 2023-06-06 新华三技术有限公司 Network equipment and optical module access control method
CN116233661B (en) * 2023-05-04 2023-08-18 新华三技术有限公司 Network equipment and optical module access control method

Also Published As

Publication number Publication date
CN114006653B (en) 2023-03-21

Similar Documents

Publication Publication Date Title
CN114006653B (en) Equipment compatible with different types of optical modules, control method thereof and storage medium
CN109791528B (en) Configuration dock
US20180060201A1 (en) Usb type-c to legacy usb cable detection
US8553578B2 (en) Automated protocol selection for host adapter card
US20150227485A1 (en) Usb switch with multi-role ports
US11232061B2 (en) CompactFlash express (CFX) adapters
KR20160037850A (en) Cable with circuitry for communicating performance information
WO2011002626A1 (en) Memory system with multi-level status signaling and method for operating the same
CN108736977B (en) Optical module
CN104054064B (en) Flexible port configuration based on interface coupling
CN104809088A (en) Connecting device and control chip and control method thereof
CN204576500U (en) A kind of usb communication circuit of compatible I2C communication and system
CN111666240A (en) Trans-driver for autonomously detecting cable orientation
WO2021227635A1 (en) Usb interface switching apparatus, usb interface switching method, and terminal device
CN102096457B (en) processing device and operating system
WO2016166539A1 (en) Isolator with automatic speed selection for usb communication systems
CN210123977U (en) Relay cable and augmented reality system
CN105260335B (en) Extend the data processing system and method for optical interface
CN107704403B (en) Device and method for optimizing signal transmission of main back plate
CN104393459A (en) Interface circuit, interface switching method and electronic device
KR20140092547A (en) USB OTG auto change device
KR20110015742A (en) Method for power supply using usb interface and portable terminal using the same
CN112131060A (en) Method, system, equipment and medium for detecting cable full link connectivity
CN204480238U (en) A kind of universal serial bus switching device shifter
CN105988962B (en) Overcurrent detecting system and circuit for detecting

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant