CN106654770A - Universal serial bus (USB) extension cord - Google Patents

Universal serial bus (USB) extension cord Download PDF

Info

Publication number
CN106654770A
CN106654770A CN201611263951.3A CN201611263951A CN106654770A CN 106654770 A CN106654770 A CN 106654770A CN 201611263951 A CN201611263951 A CN 201611263951A CN 106654770 A CN106654770 A CN 106654770A
Authority
CN
China
Prior art keywords
usb
signal
class standard
data
interface chip
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
CN201611263951.3A
Other languages
Chinese (zh)
Other versions
CN106654770B (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.)
Shenzhen Lontium Semiconductor Science And Technology Co Ltd
Original Assignee
Shenzhen Lontium Semiconductor Science And Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Lontium Semiconductor Science And Technology Co Ltd filed Critical Shenzhen Lontium Semiconductor Science And Technology Co Ltd
Priority to CN201611263951.3A priority Critical patent/CN106654770B/en
Publication of CN106654770A publication Critical patent/CN106654770A/en
Application granted granted Critical
Publication of CN106654770B publication Critical patent/CN106654770B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H01ELECTRIC ELEMENTS
    • H01RELECTRICALLY-CONDUCTIVE CONNECTIONS; STRUCTURAL ASSOCIATIONS OF A PLURALITY OF MUTUALLY-INSULATED ELECTRICAL CONNECTING ELEMENTS; COUPLING DEVICES; CURRENT COLLECTORS
    • H01R31/00Coupling parts supported only by co-operation with counterpart
    • H01R31/06Intermediate parts for linking two coupling parts, e.g. adapter
    • H01R31/065Intermediate parts for linking two coupling parts, e.g. adapter with built-in electric apparatus
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • HELECTRICITY
    • H01ELECTRIC ELEMENTS
    • H01RELECTRICALLY-CONDUCTIVE CONNECTIONS; STRUCTURAL ASSOCIATIONS OF A PLURALITY OF MUTUALLY-INSULATED ELECTRICAL CONNECTING ELEMENTS; COUPLING DEVICES; CURRENT COLLECTORS
    • H01R13/00Details of coupling devices of the kinds covered by groups H01R12/70 or H01R24/00 - H01R33/00
    • H01R13/66Structural association with built-in electrical component
    • H01R13/665Structural association with built-in electrical component with built-in electronic circuit
    • H01R13/6691Structural association with built-in electrical component with built-in electronic circuit with built-in signalling means
    • HELECTRICITY
    • H01ELECTRIC ELEMENTS
    • H01RELECTRICALLY-CONDUCTIVE CONNECTIONS; STRUCTURAL ASSOCIATIONS OF A PLURALITY OF MUTUALLY-INSULATED ELECTRICAL CONNECTING ELEMENTS; COUPLING DEVICES; CURRENT COLLECTORS
    • H01R2201/00Connectors or connections adapted for particular applications
    • H01R2201/06Connectors or connections adapted for particular applications for computer periphery

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Systems (AREA)

Abstract

An embodiment of the invention provides a universal serial bus (USB) extension cord. According to the USB extension cord, in processes of transmitting a standard USB signal and a class standard USB signal, a second USB transmitting module and a second USB receiving module in each USB interface chip and a USB wire connected with two USB interface chips are multiplexed, so that hardware cost is lowered, and connecting lines of two USB interface chips are not required to be occupied independently; and in addition, the second USB transmitting module can convert a non-stand USB signal into the class standard USB signal, and the class standard USB signal can be transmitted through the USB wire. Each module in every USB interface chip in the USB extension cord is relatively high in performance, and the signal transmission rate is relatively high, so that the signal transmission distance and signal transmission rate of the USB extension cord are improved consequently.

Description

General-purpose serial bus USB extended line
Technical field
The invention relates to universal serial bus technology field, is more particularly to general-purpose serial bus USB extended line.
Background technology
At present USB (Universal Serial Bus, USB) Host (main frame) and USB Device (set It is standby) communication when need add USB extended lines.As shown in figure 1, passing through USB extended lines and USB for USB Host in prior art The circuit diagram of Device connections.USB extended lines include chip 11 and chip 12, and chip 11 includes:First circuit 111 and Two circuits 112, wherein the first circuit 111 includes:USB sending module (the USB of first USB receiver modules (USB RX) the 1, the TX) the 1, the 2nd USB receiver modules (USB RX) 2 and the 2nd USB sending modules (USB TX) 2;Second circuit 112 includes: SRAM1 (Static Random Access Memory, static RAM), TX (transmit, transmission) and RX (receive is received);Chip 12 includes:The circuit 122 of tertiary circuit 121 and the 4th, wherein, tertiary circuit 121 includes:The The USB receiver modules (USB RX) 2 of one USB receiver modules (USB RX) the 1, the first USB sending modules (USB TX) the 1, the 2nd and 2nd USB sending modules (USB TX) 2;4th circuit 122 includes:SRAM2, TX and RX;USB Host pass through USB wire It is connected with chip 101, the first circuit 111 is connected by USB wire with tertiary circuit 121;Second circuit passes through wire and the 4th Circuit is connected;Chip 102 is connected by USB wire with USB Device.Chip 101 and chip 102 include I2C buses;Can With by I2C buses carry out read operation or write operation to the SRAM in respective chip.I2C buses include:SCL and SDA, wherein, SCL is I2The clock cable of C buses;SDA is I2The data signal line of C buses.
The process that USB Host 10 and USB Device 13 carry out standard usb signal transmission is as follows:USB Host pass through The 2nd USB in the 2nd USB sending modules 2, chip 12 in a USB receiver modules 1, chip 11 in chip 101 is received A USB sending modules 1 in module 2, chip 12, send to USB Device;USB Device are by chip 12 first In the 2nd USB receiver modules 2, chip 11 in USB receiver modules 1, chip 12 in the 2nd USB sending modules 2, chip 11 One USB sending modules 1, send to USB Host.
If desired non-standard usb signal is transmitted, then needs the I of chip 112C buses will need data Cun Chudao for sending In SRAM1;TX in chip 11 can obtain the data, and the RX sent into chip 12 from SRAM1;RX in chip 12 By in the data storage for receiving to SRAM2;In the same manner, the I in chip 122C buses can will need data Cun Chudao for sending In SRAM2;TX in chip 12 can obtain the data, and the RX sent into chip 11 from SRAM2;RX in chip 11 By in the data storage for receiving to SRAM1.
USB RX, USB TX, USB wire are that signal transmission distance is longer (can be grown for the transmission of standard usb signal Up to more than 50m), and signaling rate is very fast, but TX, RX, wire are its transmission for the transmission of non-standard usb signal Distance is shorter, and transmission speed is slower, can thus limit the overall signal transmission distance of USB extended lines and signal transmission speed Degree so that the signal transmission distance of USB extended lines is shorter relatively low with signaling rate.
The content of the invention
In view of this, the invention provides a kind of general-purpose serial bus USB extended line, to overcome prior art in USB prolong The signal transmission distance of long line is shorter and the relatively low problem of signaling rate.
For achieving the above object, the present invention provides following technical scheme:
A kind of general-purpose serial bus USB extended line, including:Two USB interface chips being connected by USB wire;Its In, each USB interface chip includes:
Memory, for data storage;
First USB receiver modules;
First USB sending modules;
The 2nd USB sending modules being connected with a USB receiver modules and the memory respectively, for from institute State and the first data to be sent are obtained in memory, according to the first data genaration class standard usb signal;And by class standard Usb signal is sent to another USB interface chip;
The 2nd USB receiver modules being connected with a USB sending modules and the memory respectively, for from another The second data are obtained in the class standard usb signal that one USB interface chip sends, and is stored into the memory.
Wherein, the 2nd USB sending modules are obtaining the first data to be sent from the memory, according to described During the first data genaration class standard usb signal, specifically for:
Determine command type, the command type is used to indicate the type of corresponding class standard usb signal to confirm character type Type or non-acknowledgement character types;
Determine the bit number that first data take up room;
Obtain the initial address in first data storage to another USB interface chip, and with the bit number phase The side-play amount answered;
According to the command type, the initial address, the side-play amount, first data and pre-set it is same Step sequence, the signal ended for pre-setting mark generate the corresponding class standard usb signal of first data.
Wherein, the 2nd USB sending modules are obtaining the first data to be sent from the memory, according to described During the first data genaration class standard usb signal, it is additionally operable to:
Calculate the command type, the initial address, the side-play amount, the check code of first data;
It is described according to the command type, the initial address, the side-play amount, first data and to pre-set Synchronizing sequence, the signal ended mark that pre-sets generates the corresponding class standard usb signal of first data and is specially:
According to the command type, the initial address, the side-play amount, first data, the check code and The synchronizing sequence for pre-setting, the signal ended mark for pre-setting generate the corresponding class standard usb signal of first data.
Wherein, the class standard usb signal that another USB interface chip sends carries command type, initial address, side-play amount And second data, the 2nd USB receiver modules obtain in the class standard usb signal sent from another USB interface chip During the second data, specifically for:
Command type is obtained in the class standard usb signal sent from another USB interface chip;
When it is determined that the class standard usb signal that another USB interface chip sends is non-acknowledgement character types, from another USB Second data, and the corresponding starting point of second data are extracted in the class standard usb signal that interface chip sends Location and side-play amount.
Wherein, the 2nd USB receiver modules are when by second data storage to the memory, specifically for:
According to the corresponding initial address of second data and side-play amount, by second data storage to the memory In.
Wherein, the class standard usb signal that another USB interface chip sends is carried for corresponding command type, accordingly Initial address, corresponding side-play amount and second data check code, the 2nd USB receiver modules are additionally operable to:
Check code is obtained in the class standard usb signal sent from another USB interface chip;
When it is determined that the corresponding check code of class standard usb signal that sends of another USB interface chip is correct, perform from another The step of the second data being obtained in the class standard usb signal that USB interface chip sends.
Wherein, each USB interface chip also includes:
Timer, for when the 2nd USB sending modules send class standard usb signal, starting timing;
The 2nd USB receiver modules, are additionally operable to:When the time of the timer record predetermined threshold value is more than or equal to, Not receiving another the corresponding with the class standard usb signal that the 2nd USB sending modules send of USB interface chip transmission should Signal is answered, then sends corresponding class standard usb signal to another USB interface chip again by the 2nd USB sending modules, The answer signal is class standard usb signal.
Wherein, the answer signal carry command type and with corresponding check code, the 2nd USB receives mould Block, is additionally operable to:
Receive the answer signal;
When the command type of the answer signal is to confirm character types, corresponding verification is extracted from the answer signal Code;
When the check code mistake of the answer signal, again by the 2nd USB sending modules to another USB interface Chip sends corresponding class standard usb signal;
When the check code of the answer signal is correct, determine that the 2nd USB sending modules successfully connect to another USB Mouth chip sends corresponding class standard usb signal.
Wherein, usb signal includes class standard usb signal and standard usb signal;Usb signal carries pre-set same Step sequence, synchronizing sequence is used to indicate that the 2nd USB receiver modules are also from as standard usb signal or class standard usb signal For:
Receive the usb signal that another USB interface chip sends;
When it is class standard usb signal that synchronizing sequence determines the usb signal according to the usb signal, perform from another The step for the second data being obtained in the class standard usb signal that one USB interface chip sends, and are stored into the memory;
When it is standard usb signal that synchronizing sequence determines the usb signal according to the usb signal, by USB letters Number sent to usb host or USB device by a USB sending modules.
Wherein, each USB interface chip includes I2C buses;
I2C buses, for detecting currently whether need to transmit class standard usb signal;Need to transmit class standard when detecting During usb signal, the connection of corresponding USB interface chip and usb host or USB device is disconnected;And mark when needs transmission is detected During quasi- usb signal, the connection of corresponding USB interface chip and usb host or USB device is set up.
Wherein, the 2nd USB sending modules are when class standard usb signal is sent to another USB interface chip, specifically For:
After to entering line position filling in class standard usb signal, non-return-to-zero reversal phase coding is carried out, the class standard after being encoded Usb signal;
Class standard usb signal after coding is sent to another USB interface chip.
Understand via above-mentioned technical scheme, compared with prior art, embodiments provide a kind of general serial Bus USB extended line, in the USB extended lines during transmission standard usb signal and class standard usb signal, is multiplexed each USB The USB wire of the 2nd USB sending modules, the 2nd USB receiver modules and two USB interface chips of connection in interface chip; The cost of hardware is reduced compared with prior art, and without the need for the independent connecting line for taking two USB interface chips, such as existing skill Non-standard usb signal needs independent occupancy wire lines in art.And the 2nd USB sending modules non-standard usb signal can be changed Into class standard usb signal, class standard usb signal can be transmitted by USB wire.Due to each USB interface in USB extended lines A USB receiver modules, a USB sending modules, the 2nd USB sending modules and the 2nd USB receiver modules in chip Performance is all higher, and signal transmission rate is very fast, therefore the signal transmission distance and signal transmission rate of USB extended lines can be with It is identical with the signal transmission distance and signal transmission rate of the USB extended lines of only transmission standard usb signal.So as to improve USB The signal transmission distance and signal transmission rate of extended line.
Description of the drawings
In order to be illustrated more clearly that the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing The accompanying drawing to be used needed for having technology description is briefly described, it should be apparent that, drawings in the following description are only this Inventive embodiment, for those of ordinary skill in the art, on the premise of not paying creative work, can be with basis The accompanying drawing of offer obtains other accompanying drawings.
The circuit diagram that USB Host are connected by USB extended lines with USB Device in Fig. 1 prior arts;
A kind of circuit diagram of general-purpose serial bus USB extended line that Fig. 2 is provided for the embodiment of the present application;
Fig. 3 is obtaining to be sent for the 2nd USB sending modules that the embodiment of the present application is provided from respective memory One data, according to the schematic flow sheet of the concrete methods of realizing of the first data genaration class standard usb signal;
A kind of data structure schematic diagram of class standard usb signal that Fig. 4 is provided for the embodiment of the present application;
The data interaction signaling diagram of two USB interface chips in the USB extended lines that Fig. 5 is provided for the embodiment of the present application;
A kind of data structure schematic diagram of answer signal that Fig. 6 is provided for the embodiment of the present application;
The signaling diagram of data interaction between two USB interface chips that Fig. 7 is provided for the embodiment of the present application.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than the embodiment of whole.It is based on Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of creative work is not made Embodiment, belongs to the scope of protection of the invention.
As shown in Fig. 2 a kind of circuit diagram of the general-purpose serial bus USB extended line provided for the embodiment of the present application.
The USB interface chip 201 and USB interface chip 202 being connected by USB wire is shown in Fig. 2.
Optional USB interface chip can be usb hub or USB repeaters.
USB interface chip 201 includes:Memory 2011, a USB receiver modules 2012, a USB sending modules 2013rd, the 2nd USB sending modules 2014 and the 2nd USB receiver modules 2015.
USB interface chip 202 includes:Memory 2021, a USB receiver modules 2022, a USB sending modules 2023rd, the 2nd USB sending modules 2024 and the 2nd USB receiver modules 2025.
First USB receiver modules 2012, the 2nd USB receiver modules 2015, a USB receiver modules 2022, the 2nd USB connect It can be USB RX to receive module 2025;First USB sending modules 2013, the 2nd USB sending modules 2014, a USB send mould Block 2023, the 2nd USB sending modules 2024 can be USB TX.
An above-mentioned USB sending modules 2013, the 2nd USB sending modules 2014, a USB sending modules 2023, second USB sending modules 2024 can be USB TX;USB TX refer to standard USB TX, including low speed TX, full speed TX and high speed TX;An above-mentioned USB receiver modules 2012, the 2nd USB receiver modules 2015, a USB receiver modules 2022nd, the 2nd USB receiver modules 2025 can be USB RX;USB RX refer to standard USB RX, including low speed RX, Full speed RX and high speed RX.
Memory 2011 can be SRAM.
The annexation of each module is as shown in Fig. 2 no longer go to live in the household of one's in-laws on getting married here in USB interface chip 201 and USB interface chip 202 State.
Memory in each USB interface chip is used for data storage.
The 2nd USB sending modules in each USB interface chip, for the storage from affiliated same USB interface chip The first data to be sent are obtained in device, according to the first data genaration class standard usb signal;And send out class standard usb signal Deliver to another USB interface chip.
The 2nd USB receiver modules in each USB interface chip, for the class standard sent from another USB interface chip During the second data, and the memory stored into affiliated same USB interface chip are obtained in usb signal.
In a kind of general-purpose serial bus USB extended line provided in an embodiment of the present invention, in transmission standard in the USB extended lines During usb signal and class standard usb signal, the 2nd USB sending modules and second being multiplexed in each USB interface chip USB receiver modules;The cost of hardware is reduced compared with prior art.And the 2nd USB sending modules non-standard USB can be believed Number class standard usb signal is converted into, class standard usb signal can be transmitted by USB wire.Due to each in USB extended lines A USB receiver modules, a USB sending modules, the 2nd USB sending modules and the 2nd USB in USB interface chip is received The performance of module is all higher, and signal transmission rate is very fast, therefore the signal transmission distance and signal transmission speed of USB extended lines Rate can be identical with the signal transmission distance of the USB extended lines of only transmission standard usb signal and signal transmission rate.So as to improve The signal transmission distance and signal transmission rate of USB extended lines.
The generating process of class standard usb signal is described in detail below.As shown in figure 3, carrying for the embodiment of the present application For the 2nd USB sending modules obtaining the first data to be sent from respective memory, according to the first data genaration category The schematic flow sheet of the concrete methods of realizing of quasi- usb signal, the method includes:
Step S301:Determine command type, the type that the command type is used to indicate corresponding class standard usb signal is true Recognize character types or non-acknowledgement character types.
Confirm that character types can include:ACK (Acknowledgement) type, in data communication, receiving terminal is issued A kind of transmission class control character of transmitting terminal.The data that expression is sent have confirmed that acceptance is errorless.
The number for needing to store into respective memory is not carried in the class standard usb signal of ordinary circumstance confirmation character types According to, and non-acknowledgement character types refer to and the data stored into respective memory in need are carried in class standard usb signal.
Step S302:Determine the bit number that first data take up room.
Step S303:Obtain the initial address in first data storage to another USB interface chip, and with it is described The corresponding side-play amount of bit number.
Step S304:According to the command type, the initial address, the side-play amount, first data and pre- The synchronizing sequence for first arranging, the signal ended mark for pre-setting generate the corresponding class standard usb signal of first data.
It is understood that can also calculate the command type, the initial address, the side-play amount, described first The check code of data.Corresponding step S304 specifically for:According to the command type, the initial address, the side-play amount, First data, the check code and the synchronizing sequence for pre-setting, the signal ended for pre-setting mark generate described The corresponding class standard usb signal of first data.
Optionally, check code can be CRC (Cyclic Redundancy Check, CRC) check code.
As shown in figure 4, a kind of data structure schematic diagram of the class standard usb signal provided for the embodiment of the present application.
Wherein, SYNC (synchronization) is the synchronizing sequence for pre-setting.Command Type are order class Type;ADDR is initial address;Offset is side-play amount, i.e., start to offset how many address bits from initial address;Byte0 is extremely Byten is the data to be sent obtained from memory;EOP is the end of identification of class standard usb signal.Class standard USB believes Number EOP can be identical with the EOP in standard usb signal.N is the positive integer more than or equal to 1.
Optionally, the SYNC in class standard usb signal can be 64bit, wherein there is 31 pairs of 01 sequences, last 2bit is 00.And the SYNC of standard usb signal is 32bit, wherein there is 15 pairs of 01 sequences, last 2bit is 00.
The Command Type bit wides illustrated in Fig. 4 are 4bit, can also be other bit wides in actual applications, can be with The bit wide of Command Type is extended according to demand.
The bit wide of the ADDR illustrated in Fig. 4 is 8bit for the bit wide of 8bit, Offset, in actual applications, can basis Demand extends its bit wide.
ADDR and Offset jointly defines the shared bit number of data to be transmitted, the bit shared by different pieces of information Number is different, therefore, it can extend the bit wide of Offset according to practical application.
2nd USB sending modules obtain data to be sent in the memory from affiliated same USB interface chip, and will Data are filled in Byte0 to Byten.
Calculate Command Type, ADDR, Offset, the check code of Byte0 to Byten, the CRC check of such as 16bit Code.CRC16 is calculated in the calculating of CRC and standard usb signal in class standard usb signal, formula is as follows:G (X)=X16+X15 +X2+1。
EOP in class standard usb signal can be identical with the EOP in standard usb signal, and for example, 01111111.In Fig. 4 The bit wide of the EOP for illustrating is 8bit, in actual applications, or other bit wides.
The embodiment of the present application provides the bit wide of each several part shown in Fig. 4, but is not limited to this.
Fig. 5 is referred to, the data interaction letter of two USB interface chips in the USB extended lines provided for the embodiment of the present application Order figure.Send data instance to USB interface chip 202 with USB interface chip 201 below to illustrate.USB interface chip 202 The process of data is sent to USB interface chip 201 and USB interface chip 201 sends the process of data to USB interface chip 202 It is identical.
Step S501:The 2nd USB sending modules 2014 in USB interface chip 201 obtain pending from memory 2011 The first data sent, and according to the first data genaration class standard usb signal, send to USB interface chip 202.
The data stored in memory 2011 include the first data to be sent, and the data can be memory 2011 I2C buses are by the first data storage to the memory 2011.
2nd USB sending modules 2014 can be refering to shown in Fig. 3 according to the process of the first data genaration class standard usb signal Method, will not be described here.
Step S502:When the 2nd USB sending modules 2014 send class standard usb signal, in USB interface chip 201 Timer 2 016 starts timing.
Step S502 is optional step, therefore is outlined with dotted line frame in Figure 5.Optionally, each USB interface chip includes Timer.
It is understood that USB interface chip 202 receives the class standard USB letters of the transmission of the 2nd USB sending modules 2014 After number, can represent and oneself received the class standard usb signal to feed back answer signal to USB interface chip 201.USB connects If mouthful chip 201 does not receive corresponding answer signal within some time, then illustrate that class standard usb signal sends failure.
Step S503:The 2nd USB receiver modules 2025 of USB interface chip 202 receive class standard usb signal, from category Command type, initial address, side-play amount, the first data and check code are extracted in quasi- usb signal.
Specifically, the 2nd USB receiver modules 2025 can determine category according to the command type in class standard usb signal The type of quasi- usb signal;When class standard usb signal is non-acknowledgement character types, execution step is carried from class standard usb signal Take out command type, initial address, side-play amount, the first data and check code.
Step S504:Check code is calculated according to command type, initial address, side-play amount, the first data;When the school for calculating Test code with class standard usb signal carry check code it is identical when, determine that class standard usb signal is correct.
Preferably, class standard usb signal carries check code, now including step S504;When class standard usb signal is not carried During check code, not including step S504.Therefore it is indicated by the dashed box in Figure 5.
Step S505:2nd USB receiver modules 2025 are according to initial address and side-play amount by the first data storage to storage In device 2021, and answer signal is fed back to USB interface chip 201 by the 2nd USB sending modules 2023.
As shown in fig. 6, a kind of data structure schematic diagram of the answer signal provided for the embodiment of the present application.
Answer signal is also a kind of class standard usb signal, does not simply carry the number of Byte0 to Byten as shown in Figure 4 According to.The bit wide of answer signal each several part is shown in Fig. 6, the embodiment of the present application is provided but not limited to this.For the solution of each several part Releasing can refer to the explanation of appropriate section in Fig. 4, will not be described here.
Preferably, answer signal carries the check code for Command Type.Can not certainly carry.School herein It can be CRC check code to test code.Calculating process is consistent with CRC check Calculative Process as shown in Figure 4.Here is no longer gone to live in the household of one's in-laws on getting married State.
Step S506:The 2nd USB receiver modules 2015 of USB interface chip 201 receive answer signal;Extract answer signal In command type;When answer signal is to confirm character types, corresponding class standard usb signal transmission flow terminates.
Preferably, answer signal carries check code, and now step S505 includes:
Step S5061:2nd USB receiver modules 2015 calculate check code according to the command type of answer signal;When The check code that two USB receiver modules 2015 are calculated is identical with the check code carried in answer signal, it is determined that answer signal is just Really, the class standard usb signal transmission flow terminates.
Step S5062:When the check code carried in the check code that the 2nd USB receiver modules 2015 are calculated with answer signal Differ, or timer record time be more than or equal to predetermined threshold value when, the 2nd USB receiver modules 2015 do not receive yet USB Interface chip 202 send corresponding class standard usb signal answer signal, then return to step S501 send class standard again Usb signal.
Because step S5051 and step S5052 are optional step, therefore it is indicated by the dashed box in Figure 5.
Answer signal correctly illustrates successfully have sent accordingly to USB interface chip 202 for USB interface chip 201 Class standard usb signal, the class standard usb signal transmission process terminates.
The USB extended lines that the embodiment of the present application is provided both can be with transmission standard usb signal, it is also possible to transmit class standard USB Signal, by standard usb signal and class standard usb signal usb signal is referred to as, as shown in fig. 7, provide for the embodiment of the present application The signaling diagram of data interaction between two USB interface chips.Sent to USB interface chip 202 with USB interface chip 201 below Data instance illustrate.The process of the data that USB interface chip 202 sends to USB interface chip 201 and USB interface core The process of the data that piece 201 sends to USB interface chip 202 is identical.
Step S701:The 2nd USB receiver modules 2025 in USB interface chip 202 receive USB interface chip 201 and send Usb signal, judge the type of usb signal according to the synchronizing sequence of usb signal;When usb signal is class USB standard signal, Execution step S503;When usb signal is standard usb signal, execution step S702.
Optionally, above-mentioned " judging the type of usb signal according to the synchronizing sequence of usb signal " is specifically, according to usb signal The bit wide of middle synchronizing sequence judges the type of usb signal.As shown in figure 4, the bit wide of the synchronizing sequence of class standard usb signal is 64bit, and the bit wide of the synchronizing sequence of standard usb signal is 32bit.
Step S702:2nd USB receiver modules 2025 send standard usb signal to a USB sending modules 2023;The One USB sending modules 2023 send standard usb signal to USB Device.
USB interface chip 202 is connected with USB Device in Fig. 2, therefore a USB sending modules 2023 are by standard USB Signal is sent to USB Device;If USB interface chip 202 is connected with USB Host, a USB sending modules 2023 will mark Quasi- usb signal is sent to USB Host.
The USB extended lines that the embodiment of the present application is provided both can transmit class standard USB again with transmission standard usb signal Signal, in order to not affect the transmission of this two classes signal, optionally, each USB interface chip includes I2C buses;I2C buses, are used for Whether detection currently needs to transmit class standard usb signal;When detect need to transmit class standard usb signal when, disconnect corresponding USB The connection of interface chip and usb host or USB device;And when detect need transmission standard usb signal when, set up corresponding The connection of USB interface chip and usb host or USB device.
To sum up, when class standard usb signal is transmitted using USB extended lines, USB Host can not communicate with USB Device. I2C buses disconnect the connection of corresponding USB interface chip and usb host or USB device, refer to I2C buses do not drive corresponding USB to connect Mouth chip and the USB wire between usb host or USB device;Now, usb host or USB device are just given tacit consent to oneself and are not connected with USB interface chip, now usb host or USB device would not be communicated with USB interface chip, so usb host or USB Communication between equipment and USB interface chip is just separated.As shown in Fig. 2 the I of USB interface chip 2012C buses disconnect USB The connection of interface chip 201 and USB Host;The I of USB interface chip 2022C buses disconnect USB interface chip 202 and USB The connection of Device.Now, the USB wire between USB interface chip 201 and USB interface chip 202 are in idle condition, can To transmit class USB standard signal.
I2C buses set up the connection of corresponding USB interface chip and usb host or USB device, refer to I2C bus drivers are corresponding USB wire between USB interface chip and usb host or USB device.
In the embodiment of the present application, in USB Host and USB Device proper communications, when having other request signals of forwarding, Need for other signals to change into class standard usb signal, when USB extended lines are idle, multiplexing USB signalling channel (i.e. the 2nd USB Sending module 2014, the 2nd USB receiver modules 2015, the 2nd USB receiver modules 2025, the 2nd USB sending modules 2024 and USB wire between connection USB interface chip 201 and USB interface chip 202), interruption U SB Host and USB Device lead to Letter, preferential forwarding class standard usb signal, now needs the standard usb signal that USB Host or USB Device sends to lose Lose.After terminating Deng the transmission of class standard usb signal, release usb signal passage communicates to USB Host with USB Device, now When standard usb signal that USB Host and USB Device lose is less, can also recover USB Host and USB Device it Between communication, if lose standard usb signal it is more, need to re-establish the USB between USB Host and USB Device Signalling channel.
For security of the class standard usb signal in transmitting procedure, class standard usb signal can also be encoded. The 2nd USB sending modules in each USB interface chip have when class standard usb signal is sent to another USB interface chip Body is used for:After to entering line position filling in class standard usb signal, non-return-to-zero reversal phase coding is carried out, the class standard USB after being encoded Signal;Class standard usb signal after coding is sent to another USB interface chip.
Synchronizing sequence SYNC wherein in class standard usb signal is without the need for coding.Position filling (Bitstuff) refers to continuously 0 is inserted after 6bit 1, other holdings are constant.NRZI (non-return-to-zero reversal phase coding, No Return Zero-Inverse) is referred to Source code is 0, level upset, and source code is 1, and level keeps constant.
Accordingly, the 2nd USB receiver modules in each USB interface chip are additionally operable to:Receive class standard usb signal Afterwards, class standard usb signal is decoded.
First the data after the SYNC in class standard usb data are carried out into NRZI decodings, then removed the 0 of insertion.
The function phase of the module with same names is same in each USB interface chip in the embodiment of the present application;Such as USB interface The function phase of the 2nd USB sending modules 2024 in the 2nd USB sending modules 2014 and USB interface chip 202 in chip 201 Together;The 2nd USB receiver modules 2015 and the 2nd USB receiver modules 2025 in USB interface chip 202 in USB interface chip 201 Function phase it is same;A USB sending modules 2013 in USB interface chip 201 send with a USB in USB interface chip 202 The function phase of module 2023 is same;The in USB receiver modules 2012 in USB interface chip 201 and USB interface chip 202 The function phase of one USB receiver modules 2022 is same.The data interaction between two USB interface chips is being enumerated in the embodiment of the present application It is, using USB interface chip 201 as data sending terminal, to be as data receiver using USB interface chip 202 during embodiment Example is illustrated, and when USB interface chip 202 is used as data sending terminal, USB interface chip 201 is used as during data receiver Process is similar to, will, exchanged as corresponding module in the data exchange process of data receiver using USB interface chip 202.
Finally, in addition it is also necessary to explanation, herein, such as first and second or the like relational terms be used merely to by One entity or operation make a distinction with another entity or operation, and not necessarily require or imply these entities or operation Between there is any this actual relation or order.And, term " including ", "comprising" or its any other variant meaning Covering including for nonexcludability, so that a series of process, method, article or equipment including key elements not only includes that A little key elements, but also including other key elements being not expressly set out, or also include for this process, method, article or The intrinsic key element of equipment.In the absence of more restrictions, the key element for being limited by sentence "including a ...", does not arrange Except also there is other identical element in including the process of the key element, method, article or equipment.
Each embodiment is described by the way of progressive in this specification, and what each embodiment was stressed is and other The difference of embodiment, between each embodiment identical similar portion mutually referring to.
The foregoing description of the disclosed embodiments, enables professional and technical personnel in the field to realize or uses the application. Various modifications to these embodiments will be apparent for those skilled in the art, as defined herein General Principle can in other embodiments be realized in the case of without departing from spirit herein or scope.Therefore, the application The embodiments shown herein is not intended to be limited to, and is to fit to and principles disclosed herein and features of novelty phase one The most wide scope for causing.

Claims (11)

1. a kind of general-purpose serial bus USB extended line, it is characterised in that include:Two USB interfaces being connected by USB wire Chip;Wherein, each USB interface chip includes:
Memory, for data storage;
First USB receiver modules;
First USB sending modules;
The 2nd USB sending modules being connected with a USB receiver modules and the memory respectively, for depositing from described The first data to be sent are obtained in reservoir, according to the first data genaration class standard usb signal;And by class standard USB Signal is sent to another USB interface chip;
The 2nd USB receiver modules being connected with a USB sending modules and the memory respectively, for from another The second data are obtained in the class standard usb signal that USB interface chip sends, and is stored into the memory.
2. general-purpose serial bus USB extended line according to claim 1, it is characterised in that the 2nd USB sending modules exist The first data to be sent are obtained from the memory, it is concrete to use during according to the first data genaration class standard usb signal In:
Determine command type, the command type be used to indicating the type of corresponding class standard usb signal for confirm character types or Non-acknowledgement character types;
Determine the bit number that first data take up room;
The initial address in first data storage to another USB interface chip is obtained, and it is corresponding with the bit number Side-play amount;
According to the command type, the initial address, the side-play amount, first data and the synchronous sequence for pre-setting Row, the signal ended for pre-setting mark generate the corresponding class standard usb signal of first data.
3. general-purpose serial bus USB extended line according to claim 2, it is characterised in that the 2nd USB sending modules exist The first data to be sent are obtained from the memory, during according to the first data genaration class standard usb signal, is also used In:
Calculate the command type, the initial address, the side-play amount, the check code of first data;
It is described according to the command type, the initial address, the side-play amount, first data and pre-set it is same Step sequence, the signal ended for pre-setting mark generate the corresponding class standard usb signal of first data and are specially:
According to the command type, the initial address, the side-play amount, first data, the check code and in advance The synchronizing sequence of setting, the signal ended for pre-setting mark generate the corresponding class standard usb signal of first data.
4. according to the arbitrary general-purpose serial bus USB extended line of claims 1 to 3, it is characterised in that another USB interface core The class standard usb signal that piece sends carries command type, initial address, side-play amount and the second data, and the 2nd USB connects When receipts module obtains the second data in the class standard usb signal sent from another USB interface chip, specifically for:
Command type is obtained in the class standard usb signal sent from another USB interface chip;
When it is determined that the class standard usb signal that another USB interface chip sends is non-acknowledgement character types, from another USB interface Extract second data in the class standard usb signal that chip sends, and the corresponding initial address of second data and Side-play amount.
5. general-purpose serial bus USB extended line according to claim 4, it is characterised in that the 2nd USB receiver modules exist During by second data storage to the memory, specifically for:
According to the corresponding initial address of second data and side-play amount, by second data storage to the memory.
6. general-purpose serial bus USB extended line according to claim 5, it is characterised in that what another USB interface chip sent Class standard usb signal is carried for corresponding command type, corresponding initial address, corresponding side-play amount and described second The check code of data, the 2nd USB receiver modules, is additionally operable to:
Check code is obtained in the class standard usb signal sent from another USB interface chip;
When it is determined that the corresponding check code of class standard usb signal of another USB interface chip transmission is correct, perform from another USB The step of the second data being obtained in the class standard usb signal that interface chip sends.
7. the general-purpose serial bus USB extended line according to claim 1 or 6, it is characterised in that each USB interface chip is also Including:
Timer, for when the 2nd USB sending modules send class standard usb signal, starting timing;
The 2nd USB receiver modules, are additionally operable to:When the time of the timer record predetermined threshold value is more than or equal to, do not connect Receive the response letter corresponding with the class standard usb signal that the 2nd USB sending modules send that another USB interface chip sends Number, then corresponding class standard usb signal is sent to another USB interface chip again by the 2nd USB sending modules, it is described Answer signal is class standard usb signal.
8. general-purpose serial bus USB extended line according to claim 7, it is characterised in that the answer signal carries life Make type and with corresponding check code, the 2nd USB receiver modules, be additionally operable to:
Receive the answer signal;
When the command type of the answer signal is to confirm character types, corresponding check code is extracted from the answer signal;
When the check code mistake of the answer signal, again by the 2nd USB sending modules to another USB interface chip Send corresponding class standard usb signal;
When the check code of the answer signal is correct, determine the 2nd USB sending modules success to another USB interface core Piece sends corresponding class standard usb signal.
9. general-purpose serial bus USB extended line according to claim 1, it is characterised in that usb signal includes class standard USB Signal and standard usb signal;Usb signal carries the synchronizing sequence for pre-setting, and synchronizing sequence is used to indicate from as standard Usb signal or class standard usb signal, the 2nd USB receiver modules are additionally operable to:
Receive the usb signal that another USB interface chip sends;
When it is class standard usb signal that synchronizing sequence determines the usb signal according to the usb signal, perform from another USB The step for the second data being obtained in the class standard usb signal that interface chip sends, and are stored into the memory;
When it is standard usb signal that synchronizing sequence determines the usb signal according to the usb signal, the usb signal is led to Cross a USB sending modules to send to usb host or USB device.
10. general-purpose serial bus USB extended line according to claim 1, it is characterised in that each USB interface chip includes I2C buses;
I2C buses, for detecting currently whether need to transmit class standard usb signal;Need to transmit class standard USB letters when detecting Number when, disconnect the connection of corresponding USB interface chip and usb host or USB device;And need transmission standard USB when detecting During signal, the connection of corresponding USB interface chip and usb host or USB device is set up.
11. general-purpose serial bus USB extended lines according to claim 1, it is characterised in that the 2nd USB sending modules When class standard usb signal is sent to another USB interface chip, specifically for:
After to entering line position filling in class standard usb signal, non-return-to-zero reversal phase coding is carried out, the class standard USB letters after being encoded Number;
Class standard usb signal after coding is sent to another USB interface chip.
CN201611263951.3A 2016-12-30 2016-12-30 General-purpose serial bus USB extended line Active CN106654770B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611263951.3A CN106654770B (en) 2016-12-30 2016-12-30 General-purpose serial bus USB extended line

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611263951.3A CN106654770B (en) 2016-12-30 2016-12-30 General-purpose serial bus USB extended line

Publications (2)

Publication Number Publication Date
CN106654770A true CN106654770A (en) 2017-05-10
CN106654770B CN106654770B (en) 2018-11-20

Family

ID=58837880

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611263951.3A Active CN106654770B (en) 2016-12-30 2016-12-30 General-purpose serial bus USB extended line

Country Status (1)

Country Link
CN (1) CN106654770B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111741251A (en) * 2019-03-25 2020-10-02 杭州海康威视数字技术股份有限公司 Monitoring system, local host and camera remote preview control method
CN113301130A (en) * 2021-05-11 2021-08-24 深圳市星火数控技术有限公司 Communication method and device of sewing equipment controller, terminal equipment and storage medium
CN114637718A (en) * 2022-05-19 2022-06-17 南京沁恒微电子股份有限公司 USB multiplexing single-wire interface unit, chip and communication system
CN115328837A (en) * 2022-08-22 2022-11-11 北京小鸟科技股份有限公司 Method for supporting USB2.0 ultra-long distance transmission
US11609876B1 (en) 2022-08-31 2023-03-21 Nanjing qinheng Microelectronics Co., Ltd. USB multiplexing single-wire interface unit, chip and communication system

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020144042A1 (en) * 2001-03-30 2002-10-03 Garney John I. Method and apparatus for improving time constraints and extending limited length cables in a multiple-speed bus
CN1707455A (en) * 2004-06-11 2005-12-14 纬创资通股份有限公司 Method for conducting information flow exchange by two electronic device under USB structure and system for applying the same method
EP1589621A4 (en) * 2003-01-29 2007-10-31 Sony Corp Usb connector conversion device
CN101075938A (en) * 2006-05-19 2007-11-21 深圳艾科创新微电子有限公司 System and method for converting between cell-phone telecommunication protocol and USB mass storage protocol
CN202563497U (en) * 2012-05-21 2012-11-28 海南经保科技实业有限公司 Communication interface for Flash-Net animation game
CN204945998U (en) * 2015-09-24 2016-01-06 高华伟 There is the host computer extension fixture of backup twisted-pair feeder

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020144042A1 (en) * 2001-03-30 2002-10-03 Garney John I. Method and apparatus for improving time constraints and extending limited length cables in a multiple-speed bus
EP1589621A4 (en) * 2003-01-29 2007-10-31 Sony Corp Usb connector conversion device
US7744423B2 (en) * 2003-01-29 2010-06-29 Sony Corporation USB connector conversion device
CN1707455A (en) * 2004-06-11 2005-12-14 纬创资通股份有限公司 Method for conducting information flow exchange by two electronic device under USB structure and system for applying the same method
CN101075938A (en) * 2006-05-19 2007-11-21 深圳艾科创新微电子有限公司 System and method for converting between cell-phone telecommunication protocol and USB mass storage protocol
CN202563497U (en) * 2012-05-21 2012-11-28 海南经保科技实业有限公司 Communication interface for Flash-Net animation game
CN204945998U (en) * 2015-09-24 2016-01-06 高华伟 There is the host computer extension fixture of backup twisted-pair feeder

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111741251A (en) * 2019-03-25 2020-10-02 杭州海康威视数字技术股份有限公司 Monitoring system, local host and camera remote preview control method
CN113301130A (en) * 2021-05-11 2021-08-24 深圳市星火数控技术有限公司 Communication method and device of sewing equipment controller, terminal equipment and storage medium
CN114637718A (en) * 2022-05-19 2022-06-17 南京沁恒微电子股份有限公司 USB multiplexing single-wire interface unit, chip and communication system
CN115328837A (en) * 2022-08-22 2022-11-11 北京小鸟科技股份有限公司 Method for supporting USB2.0 ultra-long distance transmission
US11609876B1 (en) 2022-08-31 2023-03-21 Nanjing qinheng Microelectronics Co., Ltd. USB multiplexing single-wire interface unit, chip and communication system

Also Published As

Publication number Publication date
CN106654770B (en) 2018-11-20

Similar Documents

Publication Publication Date Title
CN106654770A (en) Universal serial bus (USB) extension cord
CN100366029C (en) Communication controller, host-side controller, communication equipment, communication system and method
US11258833B2 (en) Transmitting common mode control data over audio return channel
US10216690B2 (en) Single-wire interface bus transceiver system based on I2C-bus, and associated method for communication of single-wire interface bus
CN101953097B (en) Apparatus and method for transmitting and receiving data using visible light communication
US20040260851A1 (en) Data transmission method for microprocessors in a programmable logic controller
CN103051414B (en) A kind of serial communication error correction and system
CN104038316B (en) The highly reliable timeliness asynchronous serial communication method high of space camera
CN105786639A (en) I2C buss data transmission method and system
CN104717762A (en) Pairing method, primary terminal and slave terminal of wireless communication device
CN106528484A (en) Serial communication method
CN106201973B (en) Method and system for single-wire serial communication interface
CN108989014A (en) A kind of single serial half-duplex operation method of width clock tolerance
CN103778772A (en) Framing and interconnection transmitting method in electricity utilization information collecting system
CN100531091C (en) I2C bus realization method for point-to-point communication
CN104135412A (en) Serial bus redundant communication method oriented to multi-point Internet application
CN101841393A (en) PWM (Pulse Width Modulation) input module and MVB (Multifunction Vehicle Bus) equipment based on MVB interface
EP3246823B1 (en) Optical module and transmitting data in optical module
CN107465487B (en) Bus data sending method, system and sub-equipment
US8175170B2 (en) Transmitter, receiver, method for transmitting, method for receiving, fixed length serial burst data transfer system, semiconductor device, and hybrid semiconductor device
CN116647300A (en) SPI-based dynamic length data communication method and data communication system
JPWO2021048990A5 (en) Terminal, communication system and communication method
KR100859499B1 (en) Data transmitting/receiving method and communication system thereof
WO2017000737A1 (en) Transmission checking method, node, system and computer storage medium
JP2013017090A (en) Transmission/reception devices and system for relaying them

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