CN109101454B - Communication method and system of user-defined usbcam debugging interface and electronic equipment - Google Patents
Communication method and system of user-defined usbcam debugging interface and electronic equipment Download PDFInfo
- Publication number
- CN109101454B CN109101454B CN201810720184.7A CN201810720184A CN109101454B CN 109101454 B CN109101454 B CN 109101454B CN 201810720184 A CN201810720184 A CN 201810720184A CN 109101454 B CN109101454 B CN 109101454B
- Authority
- CN
- China
- Prior art keywords
- slave
- data length
- master
- data
- address
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 27
- 230000003993 interaction Effects 0.000 claims abstract description 30
- 238000004590 computer program Methods 0.000 claims abstract description 7
- 230000006870 function Effects 0.000 claims description 30
- 230000002452 interceptive effect Effects 0.000 description 9
- 230000000694 effects Effects 0.000 description 3
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 238000010586 diagram Methods 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F13/00—Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
- G06F13/38—Information transfer, e.g. on bus
- G06F13/42—Bus transfer protocol, e.g. handshake; Synchronisation
- G06F13/4282—Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N5/00—Details of television systems
- H04N5/76—Television signal recording
- H04N5/765—Interface circuits between an apparatus for recording and another apparatus
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
- Information Transfer Systems (AREA)
Abstract
The invention is suitable for the communication field, and provides a communication method, a system and electronic equipment of a user-defined usbcam debugging interface, wherein the method comprises the steps that a host inquires a first data length of a slave, and the slave replies the first data length of the host; the master machine sends an address to the slave machine, and the slave machine receives the address; the master inquires the slave by a second data length, and the slave replies to the master by the second data length; the master machine sends data to the slave machine, and the slave machine receives the data. The system comprises a first data length interaction module, an address interaction module, a second data length interaction module and a data interaction module. The apparatus includes a memory, a processor, and a computer program stored on the memory and executed on the processor. The invention improves the flexibility of the user by increasing the adjustable range.
Description
Technical Field
The invention belongs to the field of communication, and particularly relates to a communication method and system of a user-defined usbcam debugging interface and electronic equipment.
Background
UVC, USB Video Class, is an interactive protocol specifically established for Video equipment using USB interface, and is currently one of USB org standards. The protocol is widely applied to video equipment, including webcams, digital cameras, analog image converters, television sticks and other equipment, and the network camera is the first UVC-supporting equipment and is also the most numerous UVC equipment. The UVC protocol provides a control interface for the camera through which a user can control the exposure mode, zoom mode, etc. of the camera and also adjust image quality, such as brightness, chrominance, saturation, sharpness, etc., but the adjustable parameters are limited only to the ranges provided in the protocol, which is disabled if the protocol does not support or meet the user's requirements.
Disclosure of Invention
The embodiment of the invention aims to provide a communication method, a communication system and electronic equipment of a user-defined usbcam debugging interface, and aims to solve the problem of limitation of the regulation range of the current UVC protocol and improve the flexibility of use of a user by increasing the adjustable range.
The embodiment of the invention is realized in such a way that the communication method of the self-defined usbcam debugging interface comprises the following steps:
the method comprises the steps that a master inquires a slave in a first data length, and the slave replies to the master in the first data length;
the master machine sends an address to the slave machine, and the slave machine receives the address;
the master inquires the slave by a second data length, and the slave replies to the master by the second data length;
the master machine sends data to the slave machine, and the slave machine receives the data.
Preferably, before the master queries the slaves for the first data length, the method further comprises: the host computer obtains a first instruction, wherein the first instruction is a parameter adjusting instruction.
Preferably, the master sends an address to the slave, and the receiving of the address by the slave specifically includes: and the host sends a storage address according to the first data length, and the slave receives the storage address.
As a further preferred embodiment, the master sends data to the slave, and the receiving of the data by the slave specifically includes: and the host sends storage data according to the second data length, and the slave receives the storage data and stores the storage data to the storage address.
Preferably, before the master queries the slaves for the first data length, the method further comprises: and the host computer acquires a second instruction, wherein the second instruction is a user-defined function instruction.
Preferably, the master sends an address to the slave, and the receiving of the address by the slave specifically includes: and the master machine sends a function pointer according to the first data length, and the slave machine receives the function pointer.
Preferably, the master sends data to the slave, and the receiving of the data by the slave specifically includes: and the host sends a function calling instruction according to the second data length, and the slave receives the function calling instruction and realizes a corresponding function.
Preferably, the querying, by the master, the second data length of the slave specifically includes: and the master inquires the slave according to the first data length for a second data length.
The communication system of the user-defined usbcam debugging interface comprises a first data length interaction module, an address interaction module, a second data length interaction module and a data interaction module;
the first data length interaction module is used for inquiring a first data length of a slave by a host, and the slave replies the first data length of the host;
the address interaction module is used for the host to send an address to the slave, and the slave receives the address;
the second data length interaction module is used for inquiring a second data length of the slave by the master, and the slave replies the second data length of the master;
the data interaction module is used for the master machine to send data to the slave machine, and the slave machine receives the data.
Another embodiment of the present invention is implemented by an electronic device, which includes a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor implements the steps of the communication method of the customized usb cam debugging interface when executing the computer program.
According to the communication method, the communication system and the electronic equipment of the user-defined usbcam debugging interface, provided by the invention, a user can adjust interface parameters provided in an original protocol through the debugging interface for improving the debugging quality and effect of an image, and can also set a user-defined function through the debugging interface, so that the function of the usbcam debugging interface is increased, and the applicability of the usbcam debugging interface is increased.
Drawings
Fig. 1 is a flowchart of sending parameter data to a slave by a master according to an embodiment of the present invention;
fig. 2 is a flowchart of a master device implementing a custom function through a slave device according to an embodiment of the present invention.
Fig. 3 is a structural diagram of a communication system of a customized usb cam debugging interface according to an embodiment of the present invention.
1-a first data length interaction module; 2-address interaction module; 3-a second data length interaction module; and 4, a data interaction module.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention. In addition, the technical features involved in the embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.
Because the adjustable parameters of the control interface of the camera provided by the current UVC protocol are limited within the range provided by the protocol, the use requirement of a user can not be met sometimes, and thus the control interface of the camera provided by the USV protocol can be directly invalidated. Therefore, the invention provides a communication method, a system and electronic equipment of a user-defined usbcam debugging interface, which can greatly increase the adjustment range of parameters, thereby improving the flexibility of use of users.
In the specific embodiment of the invention, the invention provides a communication method, a system and an electronic device of a user-defined usbcam debugging interface, a user can adjust interface parameters provided in an original protocol through the interface to improve the debugging quality and effect of an image, and the user can set a user-defined function through the interface, such as online camera initialization, patch modification and the like.
In an embodiment of the present invention, the usbcam debug interface inherits an extension module xu (extension unit) in the UVC protocol. The UVC protocol provides the extension module primarily for user-customized functionality, but when user functionality is represented by an extension unit, the host still needs to access the user-specific extensions through a delivery mechanism. The UVC protocol provides that, although the master cannot decide which functions are used to the extension module, the master will still report the status of the user segment, query the client by sending control commands and return client parameters, in a specific embodiment of the invention, the slave is a client.
In a specific embodiment of the invention, a communication method of a customized usbcam debugging interface is provided, which comprises the steps of storing parameter data sent by a host computer into a slave computer and realizing the customized function by the host computer through the slave computer. The method specifically comprises the following steps:
the method comprises the steps that a master inquires a slave in a first data length, and the slave replies to the master in the first data length;
the master machine sends an address to the slave machine, and the slave machine receives the address;
the master inquires the slave by a second data length, and the slave replies to the master by the second data length;
the master machine sends data to the slave machine, and the slave machine receives the data.
As shown in fig. 1, the storing the parameter data sent by the master to the slave includes:
a1, the host computer obtains a first instruction, wherein the first instruction is a parameter adjusting instruction;
a2, inquiring a first data length of a slave by the master according to the first instruction, and replying the first data length of the master by the slave;
a3, the host sends a storage address according to the first data length, and the slave receives the storage address;
a4, the master inquires the slave by a second data length, and the slave replies to the master by the second data length;
a5, the master sends storage data according to the second data length, and the slave receives the storage data and stores the storage data to the storage address.
As shown in fig. 2, the master implementing the custom function through the slave includes:
b1, the host computer obtains a second instruction, wherein the second instruction is a user-defined function instruction;
b2, inquiring a first data length of a slave by the master, and replying the first data length of the master by the slave;
b3, the master sends a function pointer according to the first data length, and the slave receives the function pointer;
b4, the master inquires the slave by a second data length, and the slave replies to the master by the second data length;
and B5, the host sends a function calling instruction according to the second data length, and the slave receives the function calling instruction and realizes the corresponding function.
Wherein the master queries the slave for a second data length according to the first data length.
In another embodiment of the present invention, as shown in fig. 3, a communication system of a customized usb cam debugging interface is provided, which includes a first data length interaction module 1, an address interaction module 2, a second data length interaction module 3, and a data interaction module 4; the output end of the first data length interactive module 1 is connected with the input end of the address interactive module 2, the output end of the address interactive module 2 is connected with the input end of the second data length interactive module 3, and the output end of the second data length interactive module 3 is connected with the input end of the data interactive module 4.
The first data length interactive module 1 is used for inquiring a first data length of a slave by a host, and the slave replies the first data length of the host.
The address interaction module 2 is configured to send an address to the slave by the master, and the slave receives the address.
The second data length interactive module 3 is configured to query, by the master, the slave for the second data length, and reply, by the slave, the second data length by the master.
The data interaction module 4 is used for the master to send data to the slave, and the slave receives the data.
The communication system of the customized usbcam debugging interface can complete all functions of the communication method of the customized usbcam debugging interface.
In another embodiment of the present invention, an electronic device is provided, which includes a memory, a processor, and a computer program stored in the memory and running on the processor, and the processor implements the steps of the communication method of the customized usbcam debugging interface when executing the computer program
The invention enables the user to adjust the interface parameters provided in the original protocol through the debugging interface for improving the debugging quality and effect of the image, and also enables the user to set the self-defined function through the debugging interface, thereby increasing the function of the usbcam debugging interface and increasing the applicability of the usbcam debugging interface.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and is not to be construed as limiting the invention, and any modifications, equivalents and improvements made within the spirit and principle of the present invention are intended to be included within the scope of the present invention.
Claims (8)
1. A communication method of a self-defined usbcam debugging interface is characterized by comprising the following steps:
the method comprises the steps that a master inquires a slave in a first data length, and the slave replies to the master in the first data length;
the master machine sends an address to the slave machine, and the slave machine receives the address;
the master inquires the slave by a second data length, and the slave replies to the master by the second data length;
the master machine sends data to the slave machine, and the slave machine receives the data;
the master sends an address to the slave, and the slave receiving the address specifically includes:
the master machine sends a function pointer according to the first data length, and the slave machine receives the function pointer;
wherein the master queries the slave for a second data length according to the first data length.
2. The communication method of the customized usbcam debug interface of claim 1, further comprising, before the master queries the slaves for a first data length: the host computer obtains a first instruction, wherein the first instruction is a parameter adjusting instruction.
3. The communication method of the customized usbcam debug interface according to claim 1, wherein the host sends an address to the slave, and the slave receives the address specifically: and the host sends a storage address according to the first data length, and the slave receives the storage address.
4. The communication method of the customized usbcam debugging interface according to claim 3, wherein the master sends data to the slave, and the slave receives the data specifically: and the host sends storage data according to the second data length, and the slave receives the storage data and stores the storage data to the storage address.
5. The communication method of the customized usbcam debug interface of claim 1, further comprising, before the master queries the slaves for a first data length: and the host computer acquires a second instruction, wherein the second instruction is a user-defined function instruction.
6. The communication method of the customized usbcam debugging interface according to claim 1, wherein the master sends data to the slave, and the slave receives the data specifically: and the host sends a function calling instruction according to the second data length, and the slave receives the function calling instruction and realizes a corresponding function.
7. A communication system of a self-defined usbcam debugging interface is characterized by comprising a first data length interaction module (1), an address interaction module (2), a second data length interaction module (3) and a data interaction module (4);
the first data length interaction module (1) is used for inquiring a first data length of a slave by a host, and the slave replies the first data length of the host;
the address interaction module (2) is configured to send an address to the slave by the master, the slave receives the address, the master sends the address to the slave, and the receiving of the address by the slave specifically includes: the master machine sends a function pointer according to the first data length, and the slave machine receives the function pointer;
the second data length interaction module (3) is used for inquiring a second data length of the slave by the master, and the slave replies the second data length of the master, wherein the master inquires the second data length of the slave according to the first data length;
the data interaction module (4) is used for the master machine to send data to the slave machine, and the slave machine receives the data.
8. An electronic device comprising a memory, a processor and a computer program stored on the memory and running on the processor, wherein the processor implements the steps of the method of any of claims 1-6 when executing the computer program.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810720184.7A CN109101454B (en) | 2018-07-03 | 2018-07-03 | Communication method and system of user-defined usbcam debugging interface and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810720184.7A CN109101454B (en) | 2018-07-03 | 2018-07-03 | Communication method and system of user-defined usbcam debugging interface and electronic equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109101454A CN109101454A (en) | 2018-12-28 |
CN109101454B true CN109101454B (en) | 2020-09-29 |
Family
ID=64845548
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810720184.7A Active CN109101454B (en) | 2018-07-03 | 2018-07-03 | Communication method and system of user-defined usbcam debugging interface and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109101454B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110929576B (en) * | 2019-10-23 | 2022-11-11 | 珠海研果科技有限公司 | Face recognition method and device based on UVC protocol |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN204633931U (en) * | 2015-04-20 | 2015-09-09 | 江苏理工学院 | Android mobile phone wireless controller for mobile terminal |
CN106027901A (en) * | 2016-06-24 | 2016-10-12 | 北京奇虎科技有限公司 | Intelligent acquisition method and device for vehicular photographing equipment, and car digital video recorder |
CN107038993A (en) * | 2017-05-23 | 2017-08-11 | 西安诺瓦电子科技有限公司 | parameter adjusting method and device, display system |
CN107295250A (en) * | 2017-06-09 | 2017-10-24 | 福州汇思博信息技术有限公司 | Camera adjustment method and its system |
CN107493437A (en) * | 2017-09-21 | 2017-12-19 | 北京图森未来科技有限公司 | A kind of camera parameter control method and relevant device |
CN107566718A (en) * | 2017-08-17 | 2018-01-09 | 深圳市瑞科慧联科技有限公司 | A kind of dual-purpose CCTV camera and implementation method |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
TWI381737B (en) * | 2009-01-20 | 2013-01-01 | Quanta Comp Inc | Digital video/audio capture device and method thereof |
-
2018
- 2018-07-03 CN CN201810720184.7A patent/CN109101454B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN204633931U (en) * | 2015-04-20 | 2015-09-09 | 江苏理工学院 | Android mobile phone wireless controller for mobile terminal |
CN106027901A (en) * | 2016-06-24 | 2016-10-12 | 北京奇虎科技有限公司 | Intelligent acquisition method and device for vehicular photographing equipment, and car digital video recorder |
CN107038993A (en) * | 2017-05-23 | 2017-08-11 | 西安诺瓦电子科技有限公司 | parameter adjusting method and device, display system |
CN107295250A (en) * | 2017-06-09 | 2017-10-24 | 福州汇思博信息技术有限公司 | Camera adjustment method and its system |
CN107566718A (en) * | 2017-08-17 | 2018-01-09 | 深圳市瑞科慧联科技有限公司 | A kind of dual-purpose CCTV camera and implementation method |
CN107493437A (en) * | 2017-09-21 | 2017-12-19 | 北京图森未来科技有限公司 | A kind of camera parameter control method and relevant device |
Non-Patent Citations (1)
Title |
---|
基于UVC协议的USB3.0图像采集系统设计;殷开亮;《中国优秀硕士学位论文全文数据库》;20141015;I140-412 * |
Also Published As
Publication number | Publication date |
---|---|
CN109101454A (en) | 2018-12-28 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11363105B2 (en) | Determining a target service based on a service discovery request | |
US11888958B2 (en) | Content delivery network CDN edge node scheduling method and device | |
WO2021093501A1 (en) | Task processing method and network device | |
CN111240620A (en) | Intelligent terminal screen projection processing method and device, computer equipment and medium | |
US11146660B2 (en) | Information packet download method for preventing high concurrency, electronic device and storage medium | |
CN109101454B (en) | Communication method and system of user-defined usbcam debugging interface and electronic equipment | |
JP7257554B2 (en) | Model file distribution method, platform, system, terminal and readable storage medium | |
CN113038180A (en) | Intelligent mirror image screen projection method, device, equipment and storage medium | |
CN111259441B (en) | Device control method, device, storage medium and electronic device | |
EP3226513A1 (en) | Network-based file transfer method and system | |
CN114727023A (en) | Method and system for adjusting camera parameters | |
CN109033393A (en) | Paster processing method, device, storage medium and electronic equipment | |
WO2017000803A1 (en) | Method for implementing application and service controller | |
CN206149319U (en) | Internet video shared device | |
US10136072B2 (en) | Image pickup apparatus, image pickup system, method for controlling image pickup apparatus, method for controlling image pickup system, and program | |
CN112866506B (en) | Time domain noise reduction method and device for video image and storage medium | |
US10248010B2 (en) | Method for adjusting relative position between devices and adjustment apparatus | |
JP2023514142A (en) | Method and network node for QoS notification | |
WO2023142664A1 (en) | Image display method, terminal device, server, electronic device, storage medium, and program product | |
CN116723264B (en) | Method, apparatus and storage medium for determining target location information | |
CN114944986B (en) | Service isolation method, device and micro-service system | |
CN110704340B (en) | Data transmission device, system and method | |
US20150286633A1 (en) | Generation, at least in part, of at least one service request, and/or response to such request | |
CN114584738A (en) | Camera sharing method and device, terminal equipment and storage medium | |
EP3632065B1 (en) | Method of providing information to an audio/video receiver device and corresponding apparatus |
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 | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220505 Address after: Rooms 1306-1309, 13 / F, 19 science Avenue West, Hong Kong Science Park, Shatin, New Territories, China Patentee after: BUILDWIN INTERNATIONAL (ZHUHAI) LTD. Address before: 1302, yuemeite building, 1 Gaoxin South 7th Road, Yuehai street, Nanshan District, Shenzhen, Guangdong 518000 Patentee before: Jianrong semiconductor (Shenzhen) Co.,Ltd. Patentee before: BUILDWIN INTERNATIONAL (ZHUHAI) Ltd. |
|
TR01 | Transfer of patent right |