CN114968015A - Method, device and medium for information interaction and network communication module control - Google Patents

Method, device and medium for information interaction and network communication module control Download PDF

Info

Publication number
CN114968015A
CN114968015A CN202210542598.1A CN202210542598A CN114968015A CN 114968015 A CN114968015 A CN 114968015A CN 202210542598 A CN202210542598 A CN 202210542598A CN 114968015 A CN114968015 A CN 114968015A
Authority
CN
China
Prior art keywords
module
transmitted
information
interaction
network communication
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210542598.1A
Other languages
Chinese (zh)
Inventor
陈宗友
杨春林
周军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Eyes Intelligent Technology Co ltd
Original Assignee
Beijing Eyes Intelligent 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 Beijing Eyes Intelligent Technology Co ltd filed Critical Beijing Eyes Intelligent Technology Co ltd
Priority to CN202210542598.1A priority Critical patent/CN114968015A/en
Publication of CN114968015A publication Critical patent/CN114968015A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/04817Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance using icons
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • H04L67/025Protocols based on web technology, e.g. hypertext transfer protocol [HTTP] for remote control or remote monitoring of applications
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/34Network arrangements or protocols for supporting network services or applications involving the movement of software or configuration parameters 

Abstract

The embodiment of the application provides a method, a device and a medium for information interaction and control of a network communication module, wherein the method comprises the following steps: acquiring instruction information to be transmitted, wherein the instruction information to be transmitted is acquired by a user through browser input; sending the instruction information to be transmitted to an interaction module through a network communication module, wherein the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is used for forwarding interaction information between the client and target equipment, and the interaction information comprises the instruction information to be transmitted; and sending the instruction information to be transmitted to the target equipment through the interaction module so as to enable the target equipment to execute the instruction information to be transmitted. According to the network communication module debugging method and device, the network communication module can be independently arranged, so that the network communication module does not need to be debugged according to different task requirements, and development efficiency is improved.

Description

Method, device and medium for information interaction and network communication module control
Technical Field
The embodiment of the application relates to the field of information transmission, in particular to a method, a device and a medium for information interaction and control of a network communication module.
Background
In order to be able to transfer instructions or information in the browser to the target device, a network communication application for forwarding the information is typically installed at the client. In the related art, a forwarding program (e.g., websocket) for forwarding information and a Software Development Kit (SDK) for providing interface information are generally included in an application program. However, the application program needs to be debugged again for different projects or tasks, which results in a great deal of research and development resources being wasted.
Therefore, how to improve the development efficiency becomes a problem to be solved.
Disclosure of Invention
Embodiments of the present application provide a method, an apparatus, and a medium for information interaction and control of a network communication module, which can independently set the network communication module at least through some embodiments of the present application, so that the network communication module does not need to be debugged according to different task requirements, and further research and development efficiency is improved.
In a first aspect, the present application provides an information interaction method, applied to a client, where the method includes: acquiring instruction information to be transmitted, wherein the instruction information to be transmitted is acquired by a user through browser input; sending the instruction information to be transmitted to an interaction module through a network communication module, wherein the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is used for forwarding interaction information between the client and target equipment, and the interaction information comprises the instruction information to be transmitted; and sending the instruction information to be transmitted to the target equipment through the interaction module so as to enable the target equipment to execute the instruction information to be transmitted.
Therefore, according to the embodiment of the application, the network communication module and the interaction module are respectively and independently arranged in the client, the instruction information to be transmitted can be sent to the interaction module through the network communication module in the information interaction process, so that the network communication module does not need to be debugged according to different task requirements, and the development efficiency is improved.
With reference to the first aspect, in some embodiments of the present application, the network communication module includes a first communication sub-module, where a callback address function is configured in the first communication sub-module, and the callback address function is used to indicate a transfer direction in an information interaction process; the sending the instruction information to be transmitted to an interaction module through a network communication module comprises: when the client sends the instruction information to be transmitted to the target equipment for the first time, the callback address function and the instruction information to be transmitted are sent to the interaction module together through the first communication sub-module; or when the client sends the instruction information to be transmitted to the target device for the Nth time, only sending the instruction information to be transmitted to the interaction module through the first communication sub-module, wherein N is an integer greater than 1.
Therefore, the callback address function is sent to the interaction module, so that the interaction module can call the callback address function when feeding back information, and the transfer direction in the interaction process is determined.
With reference to the first aspect, in some embodiments of the present application, after the sending, by the interaction module, the instruction information to be transmitted to the target device, the method further includes: calling the callback address function through the interaction module; and sending feedback information to the network communication module according to the callback address function, wherein the feedback information is obtained by executing the instruction information to be transmitted by the target equipment.
Therefore, the feedback information is sent to the network communication module by calling the callback address function, and information interaction can be realized only by calling the callback address function in the process of information interaction at each time, so that research and development time can be saved, and research and development efficiency is improved.
With reference to the first aspect, in some embodiments of the present application, the interaction module includes a second communication sub-module, and an interface function is configured in the second communication sub-module; the sending the instruction information to be transmitted to an interaction module through a network communication module comprises: calling an interface function in the second communication sub-module through a network communication module; and sending the instruction information to be transmitted to an interaction module according to the interface function.
Therefore, the embodiment of the application can enable the network communication module to determine the transmission path by setting the interface function in the interaction module, thereby realizing information interaction.
In a second aspect, the present application provides a method of controlling a network communication module, the method comprising: responding to a control instruction of a user, controlling the network communication module according to any embodiment of the first aspect to execute a target operation corresponding to the control instruction; wherein the network communication module is configured to communicate with the interaction module according to any embodiment of the first aspect.
Therefore, the network communication module is controlled through the control instruction, a user can conveniently control the network communication module at any time, and the working efficiency is improved.
With reference to the second aspect, in some embodiments of the present application, the controlling, in response to a control instruction of a user, a network communication module to perform a target operation corresponding to the control instruction includes: and controlling the network communication module to execute corresponding target operation in response to the user selecting any one of the candidate instruction icons.
With reference to the second aspect, in some embodiments of the application, the plurality of candidate instruction icons includes: starting service, stopping service, checking service running state, adding a system daemon task and starting service, deleting the system daemon task and stopping service and installing certificate.
Therefore, according to the method and the device for displaying the candidate instruction icons, the candidate instruction icons are displayed on the display interface of the auxiliary tool, so that the user can quickly find the instruction icon corresponding to the requirement and trigger the instruction icon, and further the working efficiency of the user can be improved.
With reference to the second aspect, in some embodiments of the present application, the control instruction is a view service operation state instruction; the control network communication module is controlled to execute target operation corresponding to the control instruction in response to the control instruction of the user, and the control network communication module comprises: responding to the instruction for checking the service running state, detecting the current running state of the network communication module, and acquiring state information; and displaying the state information.
Therefore, the embodiment of the application can enable a user to clearly determine the running state of the network communication module by displaying the state information, and further can improve the working efficiency.
In a third aspect, the present application provides an information interaction apparatus, which is applied to a client, and includes: the instruction acquisition module is configured to acquire instruction information to be transmitted, wherein the instruction information to be transmitted is acquired by a user through browser input; the first sending module is configured to send the instruction information to be transmitted to an interaction module through a network communication module, wherein the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is used for forwarding interaction information between the client and target equipment, and the interaction information comprises the instruction information to be transmitted; the second sending module is configured to send the instruction information to be transmitted to the target device through the interaction module, so that the target device executes the instruction information to be transmitted.
With reference to the third aspect, in some embodiments of the present application, the network communication module includes a first communication sub-module, where a callback address function is configured in the first communication sub-module, and the callback address function is used for indicating a transfer direction in an information interaction process; the first sending module configured to: when the client sends the instruction information to be transmitted to the target equipment for the first time, the callback address function and the instruction information to be transmitted are sent to the interaction module together through the first communication sub-module; or when the client sends the instruction information to be transmitted to the target device for the nth time, only sending the instruction information to be transmitted to the interaction module through the first communication submodule, wherein N is an integer greater than 1.
With reference to the third aspect, in some embodiments of the present application, the first sending module is configured to: calling the callback address function through the interaction module; and sending feedback information to the network communication module according to the callback address function, wherein the feedback information is obtained by executing the instruction information to be transmitted by the target equipment.
With reference to the third aspect, in some embodiments of the present application, the interaction module includes a second communication sub-module, and the second communication sub-module is configured with an interface function; the first transmitting module configured to: calling an interface function in the second communication sub-module through a network communication module; and sending the instruction information to be transmitted to an interaction module according to the interface function.
In a fourth aspect, the present application provides an apparatus for controlling a network communication module, the apparatus comprising: an instruction response module configured to control the network communication module according to any embodiment of the first aspect to execute a target operation corresponding to a control instruction in response to the control instruction of a user; wherein the network communication module is configured to communicate with the interaction module according to any embodiment of the first aspect.
With reference to the fourth aspect, in some embodiments of the application, the instruction response module is configured to: and controlling the network communication module to execute corresponding target operation in response to the user selecting any one of the candidate instruction icons.
With reference to the fourth aspect, in some embodiments of the application, the plurality of candidate instruction icons includes: starting service, stopping service, checking service running state, adding a system daemon task and starting service, deleting the system daemon task and stopping service and installing certificate.
With reference to the fourth aspect, in some embodiments of the present application, the control instruction is a view service operation state instruction; the instruction response module is configured to: responding to the instruction for checking the service running state, detecting the current running state of the network communication module, and acquiring state information; and displaying the state information.
In a fifth aspect, the present application provides an electronic device, comprising: a processor, a memory, and a bus; the processor is connected to the memory via the bus, and the memory stores computer readable instructions for implementing the method according to any of the embodiments of the first and second aspects when the computer readable instructions are executed by the processor.
In a sixth aspect, the present application provides a computer readable storage medium having stored thereon a computer program which, when executed, implements a method as described in any of the embodiments of the first and second aspects.
Drawings
Fig. 1 is a schematic view of an information interaction scenario shown in an embodiment of the present application;
FIG. 2 is a flowchart illustrating a method for information interaction according to an embodiment of the present disclosure;
fig. 3 is a second flowchart of a method for information interaction according to an embodiment of the present application;
FIG. 4 is a display interface of an auxiliary tool according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram illustrating an apparatus for information interaction according to an embodiment of the present disclosure;
fig. 6 is a schematic diagram illustrating a composition of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, as presented in the figures, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
The embodiment of the application can be applied to a scene in which the client performs information interaction with the terminal acquisition device, for example, the client transmits instruction information to be transmitted, which is input by a user, to the terminal acquisition device (it can be understood that the terminal acquisition device is an example of a target device). In order to solve the problems in the background art, some embodiments of the present application separately set the network communication module and the interaction module in the client, and perform information transmission through the network communication module and the interaction module. For example, in some embodiments of the application, the client first obtains instruction information to be transmitted, then sends the instruction information to be transmitted to the interaction module through the network communication module, and finally sends the instruction information to be transmitted to the terminal acquisition device through the interaction module. Through some embodiments of the application, the network communication module can be independently arranged, so that the network communication module does not need to be debugged according to different task requirements, and the research and development efficiency is improved.
It should be noted that the target device may be any device capable of processing the instruction information to be transmitted. As a specific embodiment of the present application, the target device is a terminal collecting device, and the terminal collecting device may be a fingerprint collector (fingerprint device), a camera, a card reader, an iris device, or the like.
It should be noted that, as a specific embodiment of the present application, the network communication module includes a Protocol that performs full duplex communication on a single Transmission Control Protocol (TCP) connection, which is called websocket. The interaction module includes a Software Development Kit (SDK) for providing interface information. It should be noted that the software development kit SDK may be used for communication with the target device in accordance with any communication interface standard, preferably in accordance with the ISO/IEC 30106 standard (information technology object-oriented biometric application programming interface family standard).
The method steps in the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Fig. 1 provides a schematic view of a scene composition of information interaction in some embodiments of the present application, where the scene includes a user 110, a client 120, and a terminal acquisition device 130. As a specific embodiment of the present application, the user 110 clicks a button (for example, a "fingerprint collection" button) displayed on the browser on the client 120, then the client 120 transmits the instruction information to the terminal acquisition device 130, and the terminal acquisition device 130 generates feedback information according to the received instruction information to be transmitted (for example, generates corresponding feedback information according to "fingerprint collection"), and returns the feedback information to the client 120.
For example, when the terminal acquisition device is a fingerprint acquirer, the user 110 sends a piece of instruction information to be transmitted (for example, 101, which requires to acquire a fingerprint image) to the network communication module on a browser webpage of the client 120, the network communication module forwards the instruction information to be transmitted to the interaction module, the interaction module receives the instruction information to be transmitted, analyzes the meaning of the instruction information to be transmitted 101, and after confirming that the instruction information to be transmitted requires to acquire a fingerprint image, opens the fingerprint acquirer and acquires an effective fingerprint image data. And then returning the fingerprint image data to the network communication module, returning the fingerprint image data to the browser as it is by the network communication module, and displaying the fingerprint image data on the browser webpage.
Different from the embodiment of the present application, in the related art, the application program generally includes a websocket for forwarding information and an SDK for providing interface information. However, the application program needs to be debugged again for different projects or tasks, which results in a great deal of research and development resources being wasted. In the embodiment of the application, the websocket and the SDK are respectively and independently arranged in the client, and the instruction information to be transmitted is sent to the SDK through the websocket, so that the information interaction can be realized without debugging the websocket once for each task like the related technology.
The following describes an information interaction method provided by some embodiments of the present application by taking a client as an example. It can be understood that the technical solution of the method for information interaction in the embodiment of the present application can be applied to any client, for example, a computer.
At least to solve the problem that in the background art, the application program needs to be debugged again for different projects or tasks, which results in wasting a large amount of research and development resources, as shown in fig. 2, the method includes:
s210, obtaining the instruction information to be transmitted.
It should be noted that the instruction information to be transmitted is information transmitted to the target device by the client, and the target device is required to perform corresponding operation according to the acquired instruction information to be transmitted. As a specific embodiment of the present application, the instruction information to be transmitted is obtained by a user through browser input. As another specific embodiment of the present application, the instruction information to be transmitted is automatically generated by the client. The embodiment of the application does not limit the generation mode of the instruction information to be transmitted.
S220, the instruction information to be transmitted is sent to the interaction module through the network communication module.
It should be noted that the network communication module (e.g., websocket) and the interaction module (e.g., SDK) are respectively and independently disposed in the client. The interaction module is used for forwarding interaction information between the client and the target device, that is, the interaction module sends instruction information to be transmitted in the client to the target device, and then the interaction module forwards feedback information of the target device to the client.
As a specific embodiment of the application, the websocket service program is optimized and arranged, so that the windows system and the linux system can use source codes of the same set of websocket service program. Therefore, one set of source codes can be compiled and output on different platforms. When a certain platform environment needs to realize the information interaction function, the corresponding websocket service program can be generated only by copying the set of source codes, compiling and outputting. Therefore, the above embodiments can improve the research and development efficiency for research and development personnel. Furthermore, for users who need to realize the websocket service function, the embodiment of the present application provides an independent websocket service program (i.e., an independent network communication module), and the network communication module can be directly used when the information interaction function needs to be realized.
Based on the above embodiment, an interface for information interaction needs to be configured in the websocket service program provided by the present application, and the interface is used for information interaction with the interaction module. It will be appreciated that before the websocket service program is used, the configuration file needs to be modified so that the websocket service program can explicitly invoke which file in the interactive module.
In one embodiment of the present application, the network communication module includes a first communication submodule, and the first communication submodule is configured with a callback address function. S220 comprises: when the client needs to send the instruction information to be transmitted to the target equipment, the first communication submodule is communicated with the target equipment to send the instruction information to be transmitted.
Specifically, as a specific embodiment of the present application, when the client sends the instruction information to be transmitted to the target device for the first time, the callback address function and the instruction information to be transmitted are sent to the interaction module together through the first communication sub-module.
That is, since the address fed back is not clear in the process of first communicating between the network communication information and the interaction module, in the process of first communicating, the callback address function also needs to be sent to the interaction module by the first communication submodule in the process of sending the instruction information to be transmitted to the interaction module.
For example, the websocket passes the callback address function to the SDK, and the SDK passes the feedback information (i.e., the result or the process information processed by the target device) back to the websocket server through the callback address function, and the websocket server then passes the feedback information back to the browser (e.g., to the page or the web layer).
As another specific embodiment of the present application, when the client sends the instruction information to be transmitted to the target device for a non-first time (for example, nth time), only the instruction information to be transmitted is sent to the interaction module through the first communication sub-module, where N is an integer greater than 1.
That is, in the nth transmission process, since the interactive module already defines the address information by calling back the address function, only the instruction information to be transmitted needs to be sent to the interactive module.
Therefore, the callback address function is sent to the interaction module, so that the interaction module can call the callback address function when feeding back information, and the transfer direction in the interaction process is determined.
In one embodiment of the present application, the interaction module includes a second communication sub-module, and the second communication sub-module is configured with an interface function. S220 comprises: and calling an interface function in the second communication submodule through the network communication module, and sending the instruction information to be transmitted to the interaction module according to the interface function.
That is, in order to implement information interaction, an interface function needs to be configured in the second communication sub-module of the interaction module, so that the network communication module can be connected with the interaction module. Specifically, in the process of sending the instruction information to be transmitted, the network communication module firstly calls an interface function of the interaction module, and then transmits the instruction information to be transmitted to the module to be interacted by taking the interface function as a path.
Therefore, the embodiment of the application can enable the network communication module to determine the transmission path by setting the interface function in the interaction module, thereby realizing information interaction.
It is understood that, as a specific embodiment of the present application, the network communication module and the interaction module may be both disposed in the client. As another specific embodiment of the present application, the network communication module may be disposed in the client, and the interaction module may be disposed in the target device (e.g., the terminal acquisition device).
And S230, sending the instruction information to be transmitted to the target equipment through the interaction module.
That is to say, after receiving the instruction information to be transmitted sent by the network communication module, the interaction module sends the instruction information to be transmitted to the target device.
In an embodiment of the application, after S230, a callback address function is called by the interaction module, and feedback information is sent to the network communication module according to the callback address function, where the feedback information is obtained by executing instruction information to be transmitted by the target device.
That is, the purpose of the network communication module sending the callback address function to the interworking module in S220 is to use when the interworking module forwards the feedback information. Specifically, the callback address function is always stored in the interaction module, when the interaction module needs to forward the feedback information, the callback address function is called, the feedback information is sent to the network communication module according to the address in the callback address function, and then the network communication module sends the feedback information to the browser for display.
As a specific embodiment of the present application, a standard interface function required for external use is used for information interaction, and may be represented by the following code:
void trans_command(string request,
send_msg_callback callback_fun,
void*user_context,
string&response);
the request represents instruction information to be transmitted between the browser and the SDK. callback _ fun represents a callback address function, and it is understood that when the SDK has feedback information (e.g., a new result message or a procedure message), the feedback information can be returned to the websocket server and then to the browser by calling the callback address function. The user _ context represents the context parameter provided by the websocket service program, and it can be understood that sdk only needs to return as it is when executing the callback function. response represents a result response, it being understood that this parameter may return an empty string directly, since a result or procedure message may be returned by a callback function.
Therefore, the feedback information is sent to the network communication module by calling the callback address function, and information interaction can be realized only by calling the callback address function in the process of information interaction at each time, so that research and development time can be saved, and research and development efficiency is improved.
It can be understood that, as a specific embodiment of the present application, if the layer of the websocket service program is omitted, it is equivalent to the browser directly transmitting the instruction information to be transmitted to the SDK.
The above describes an implementation of a method for information interaction in the present application, and the following describes a specific embodiment of the method for information interaction in the present application.
As a specific embodiment of the present application, as shown in fig. 3, the client 120 includes a browser 310, a network communication module 320 (for example, the network communication module is a websocket service program), and an interaction module 330 (for example, the interaction module is an SDK), and it is understood that a target device in the present application may be the terminal acquisition device 130, and may also be any device capable of processing instruction information to be transmitted.
The specific steps of information interaction in this embodiment are as follows:
first, the browser 310 establishes a communication connection with the websocket service program through a web interface (e.g., http socket or https socket) according to a specified port, and sends instruction information to be transmitted to the websocket service program.
Then, after the websocket service program receives the instruction information to be transmitted, which is sent by the browser 310, a standard interface function (e.g., trans _ command) is called to send the instruction information to be transmitted to the dynamic library of the SDK as it is (i.e., without any change). It can be understood that if the system type of the client is windows, the dynamic library is all; if the system type of the client is linux, the system type of the dynamic library is so. Then, the SDK transmits the instruction information to be transmitted to the terminal acquisition device 130.
Then, after receiving the instruction information to be transmitted, the terminal acquisition device 130 parses the instruction information to be transmitted, and then performs corresponding operation according to the requirement of the instruction information to obtain corresponding feedback information (for example, the instruction information to be transmitted is to verify a fingerprint, and the terminal acquisition device 130 captures a fingerprint image according to the instruction information to be transmitted), and transmits the feedback information back to the SDK.
Finally, the SDK returns the feedback information to the websocket service program by calling a callback address function (e.g., callback _ fun) of the websocket service program. After the websocket service program receives the feedback information, the feedback information is transmitted back to the browser 310 through the websocket protocol as it is, and the browser performs subsequent operations after receiving the feedback information.
It should be noted that, if the SDK dynamic library provided by the third party does not directly implement the trans _ command interface function in the SDK, a shell may be packaged above the SDK and implemented by the shell. On one hand, interaction with the websocket can be achieved, on the other hand, the instruction information to be transmitted can be analyzed, and then interface functions in the standard SDK library are called according to different instruction information.
If the instruction information is processed, intermediate process information needs to be returned to the browser, the SDK can actively return the message to the websocket service program through the callback function at any time, and then return the message to the webpage layer.
The universal websocket service program can provide 32-bit and 64-bit service programs under a windows platform, and the linux can provide service programs in environments such as x86-64 and arm-64. And providing service programs of different platforms according to the actual needs of users.
A specific example of information interaction in the embodiment of the present application is described above, and a method for controlling a network communication module in the embodiment of the present application is described below.
In one embodiment of the application, in response to a control instruction of a user, the network communication module is controlled to execute a target operation corresponding to the control instruction. It is understood that the network communication module is used for communicating with the interaction module.
That is, since the network communication module is a program embedded in the client backend, it is inconvenient to control it. Therefore, in order to enable a user to directly control the network communication module, the application provides an auxiliary tool capable of controlling the network communication module.
Specifically, the auxiliary tool is provided with a display interface, a user clicks a display control instruction on the interface, and the client responds to the control instruction of the user and executes an operation corresponding to the control instruction.
It is understood that the accessibility aid may be installed on any client. As a specific embodiment of the present application, the auxiliary tool may be mounted on a mobile phone. As another specific embodiment of the application, the auxiliary tool can be installed on the same computer with the network communication module and the interaction module.
Therefore, the network communication module is controlled through the control instruction, a user can conveniently control the network communication module at any time, and the working efficiency is improved.
In an embodiment of the present application, a plurality of candidate command icons are provided on the display interface of the auxiliary tool, where the plurality of candidate command icons includes: starting service, stopping service, checking service running state, adding a system daemon task and starting service, deleting the system daemon task and stopping service and installing certificate.
Specifically, the start service and the stop service can manually control the network communication module to stop and start.
The operation state of the network communication module at this time can be determined by checking the operation state of the service, for example, the operation state is that the service is not operated, the operation state of the service is normal, the service is not operated, the service is successfully started, and the like.
The system daemon task is added and the service is started mainly to prevent the network communication module from being abnormally stopped and being incapable of being started by itself. When the service program is stopped accidentally, the system daemon task starts the network communication module within 1 minute at most.
The task of deleting the system daemon task and stopping the service is to control the client to stop and delete the task item of the network communication module when the network communication module needs to be stopped.
The certificate is installed in order to enable remote control of the network communication module to install a certificate corresponding to the target device. And in the process of sending the instruction information to be transmitted, encrypting the instruction information to be transmitted by using the certificate, and in the process of analyzing the target equipment, verifying the instruction information to be transmitted according to the certificate.
Therefore, according to the method and the device for displaying the candidate instruction icons, the candidate instruction icons are displayed on the display interface of the auxiliary tool, so that the user can quickly find the instruction icon corresponding to the requirement and trigger the instruction icon, and further the working efficiency of the user can be improved.
In one embodiment of the application, the network communication module is controlled to execute corresponding target operation in response to the user selecting any one of the candidate instruction icons.
That is to say, when a user needs to control the network communication module, a target instruction is selected from a plurality of candidate instruction icons in a display interface of the client, and after the client obtains the target instruction, the network communication module executes corresponding operation according to the target instruction.
In an embodiment of the application, when the control instruction is a service operation state checking instruction, the current operation state of the network communication module is detected in response to the service operation state checking instruction, state information is obtained, and then the state information is displayed.
That is to say, since a user cannot directly, conveniently, and quickly specify the current operating state of the network communication module in the related art, in the embodiment of the present application, a service operating state viewing instruction is set in the auxiliary tool, that is, after responding to the service operating state viewing instruction, the client detects the operating state of the current network communication module, and obtains state information, for example, the state information includes: service is not running, service starting is successful, service running state is normal and the like. And finally, the state information is displayed on a display interface.
Therefore, the embodiment of the application can enable a user to clearly determine the running state of the network communication module by displaying the state information, and further can improve the working efficiency.
As a specific embodiment of the present application, as shown in fig. 4, fig. 4 shows a display interface 410 of the websocket assistant tool, which includes a function item list area 411 and a state information display area 412, where the function item list area 411 includes starting a service, stopping the service, checking a service running state, adding a system daemon task and starting the service, deleting the system daemon task and stopping the service, and installing a root certificate. The user can set out any instruction according to the requirement.
As another specific embodiment of the present application, in practical applications, the auxiliary tool may be called by using a command line parameter before the network communication module is installed and exits, so as to implement the instruction in the function item list.
Specifically, upon initial start-up of the auxiliary tool, if the service is already running, the status information display area 412 indicates that the service is running normally. If the service is not running, the status information presentation area 412 will show that the service is not running.
In an embodiment of the present application, the network communication module further configures a corresponding configuration file, and a user may modify relevant information in the configuration file. For example, the communication port number of the network communication module, the name of the network communication module, the SDK dynamic library file name, the name of the daemon, and the like may be changed in the configuration file.
In the related art, a universal websocket service program is not provided, so that when the SDK is required to interact with a webpage, the SDK must have a websocket service communication function, much time is required for code writing and debugging of the websocket service program, and the SDK, the types of interface functions, the parameters and the like in each project are different, so that the websocket service program needs to be embedded in the SDK. Corresponding instruction analysis is needed according to interaction instructions between each SDK and the page, then interface functions of dll are called according to actual requirements, each task needs to be adjusted and changed in such a way, codes are complicatedly written, and debugging is time-consuming and labor-consuming.
Therefore, the websocket SDK service program is subjected to standard arrangement to form a universal websocket service program, and any other SDK provided by a third party can only take charge of code and logic compiling and processing of an SDK layer when information interaction with a webpage is required to be realized, and code, compiling and debugging and the like related to the websocket service program are not required to be considered. The universal websocket service program provided by the application can be directly installed for use. It should be noted that, an interface function for information interaction needs to be implemented on the SDK according to the standard required by the websocket general service program, and the content of the configuration file in actual application is modified.
Therefore, the websocket SDK service program is subjected to standard arrangement to form a general websocket service program, and any other SDK provided by a third party is only responsible for code and logic compiling and processing of an SDK layer when information interaction with a webpage is required to be realized, and codes, compiling and debugging and the like related to the websocket service program are not required to be considered.
The above describes a method for controlling a network communication module in an embodiment of the present application, and an information interaction apparatus is described below.
As shown in fig. 5, the present application provides an apparatus 500 for information interaction, comprising: an instruction acquisition module 510, a first sending module 520 and a second sending module 530.
The instruction obtaining module 510 is configured to obtain instruction information to be transmitted, where the instruction information to be transmitted is obtained by a user through browser input.
A first sending module 520, configured to send the instruction information to be transmitted to an interaction module through a network communication module, where the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is configured to forward interaction information between the client and a target device, and the interaction information includes the instruction information to be transmitted.
A second sending module 530, configured to send the instruction information to be transmitted to the target device through the interaction module, so that the target device executes the instruction information to be transmitted.
In some embodiments of the present application, the network communication module includes a first communication sub-module, where a callback address function is configured in the first communication sub-module, and the callback address function is used for indicating a transfer direction in an information interaction process; the first sending module 520 configured to: when the client sends the instruction information to be transmitted to the target equipment for the first time, the callback address function and the instruction information to be transmitted are sent to the interaction module together through the first communication sub-module; or when the client sends the instruction information to be transmitted to the target device for the nth time, only sending the instruction information to be transmitted to the interaction module through the first communication submodule, wherein N is an integer greater than 1.
In some embodiments of the present application, the first sending module 520 is configured to: calling the callback address function through the interaction module; and sending feedback information to the network communication module according to the callback address function, wherein the feedback information is obtained by executing the instruction information to be transmitted by the target equipment.
In some embodiments of the present application, the interaction module includes a second communication sub-module, and the second communication sub-module is configured with an interface function therein; the first sending module 520 configured to: calling an interface function in the second communication sub-module through a network communication module; and sending the instruction information to be transmitted to an interaction module according to the interface function.
In the embodiment of the present application, the module shown in fig. 5 can implement each process in the method embodiments of fig. 1, fig. 2, and fig. 3. The operations and/or functions of the respective modules in fig. 5 are respectively for implementing the corresponding flows in the method embodiments in fig. 1, 2 and 3. Reference may be made specifically to the description of the above method embodiments, and a detailed description is appropriately omitted herein to avoid redundancy.
The present application provides a further apparatus for controlling a network communication module, the apparatus comprising: an instruction response module configured to control the network communication module according to any embodiment of the first aspect to execute a target operation corresponding to a control instruction in response to the control instruction of a user; wherein the network communication module is configured to communicate with the interaction module according to any embodiment of the first aspect.
In some embodiments of the present application, the instruction response module is configured to: and controlling the network communication module to execute corresponding target operation in response to the user selecting any one of the candidate instruction icons.
In some embodiments of the present application, the plurality of candidate instruction icons includes: starting service, stopping service, checking service running state, adding a system daemon task and starting service, deleting the system daemon task and stopping service and installing certificate.
In some embodiments of the present application, the control instruction is a view service operation state instruction; the instruction response module is configured to: responding to the instruction for checking the service running state, detecting the current running state of the network communication module, and acquiring state information; and displaying the state information.
In the embodiments of the present application, reference may be made to the description of the above method embodiments, and in order to avoid repetition, detailed description is appropriately omitted here.
As shown in fig. 6, an embodiment of the present application provides an electronic device 600, including: a processor 610, a memory 620 and a bus 630, wherein the processor is connected to the memory through the bus, the memory stores computer readable instructions, when the computer readable instructions are executed by the processor, for implementing the method according to any one of the above embodiments, specifically, the description of the above embodiments of the method can be referred to, and the detailed description is omitted here to avoid repetition.
Wherein the bus is used for realizing direct connection communication of the components. The processor in the embodiment of the present application may be an integrated circuit chip having signal processing capability. The Processor may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable gate array (FPGA) or other programmable logic device, discrete gate or transistor logic, discrete hardware components. The various methods, steps, and logic blocks disclosed in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The Memory may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read Only Memory (PROM), an Erasable Read Only Memory (EPROM), an electrically Erasable Read Only Memory (EEPROM), and the like. The memory stores computer readable instructions that, when executed by the processor, perform the methods described in the embodiments above.
It will be appreciated that the configuration shown in fig. 6 is merely illustrative and may include more or fewer components than shown in fig. 6 or have a different configuration than shown in fig. 6. The components shown in fig. 6 may be implemented in hardware, software, or a combination thereof.
Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a server, the method in any of the above-mentioned all embodiments is implemented, which may specifically refer to the description in the above-mentioned method embodiments, and in order to avoid repetition, detailed description is appropriately omitted here.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made to the present application by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (11)

1. A method for information interaction is applied to a client, and the method comprises the following steps:
acquiring instruction information to be transmitted, wherein the instruction information to be transmitted is acquired by inputting of a user through a browser;
sending the instruction information to be transmitted to an interaction module through a network communication module, wherein the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is used for forwarding interaction information between the client and target equipment, and the interaction information comprises the instruction information to be transmitted;
and sending the instruction information to be transmitted to the target equipment through the interaction module so as to enable the target equipment to execute the instruction information to be transmitted.
2. The method according to claim 1, wherein the network communication module comprises a first communication submodule, and a callback address function is configured in the first communication submodule and used for indicating a transfer direction in an information interaction process;
the sending the instruction information to be transmitted to an interaction module through a network communication module comprises:
when the client sends the instruction information to be transmitted to the target equipment for the first time, the callback address function and the instruction information to be transmitted are sent to the interaction module together through the first communication sub-module; or
And when the client sends the instruction information to be transmitted to the target equipment for the Nth time, only sending the instruction information to be transmitted to the interaction module through the first communication sub-module, wherein N is an integer greater than 1.
3. The method according to claim 2, wherein after the sending of the instruction information to be transmitted to the target device by the interaction module, the method further comprises:
calling the callback address function through the interaction module;
and sending feedback information to the network communication module according to the callback address function, wherein the feedback information is obtained by executing the instruction information to be transmitted by the target equipment.
4. The method according to any one of claims 1 to 3, wherein the interaction module comprises a second communication sub-module, and the second communication sub-module is configured with an interface function;
the sending the instruction information to be transmitted to an interaction module through a network communication module comprises:
calling an interface function in the second communication sub-module through a network communication module;
and sending the instruction information to be transmitted to an interaction module according to the interface function.
5. A method of controlling a network communication module, the method comprising:
in response to a control instruction of a user, controlling the network communication module according to any one of claims 1-4 to execute a target operation corresponding to the control instruction;
wherein the network communication module is configured to communicate with the interaction module of any of claims 1-4.
6. The method according to claim 5, wherein the controlling a network communication module to execute a target operation corresponding to a control instruction in response to the control instruction of the user comprises:
and controlling the network communication module to execute corresponding target operation in response to the user selecting any one of the candidate instruction icons.
7. The method of claim 6, wherein the plurality of candidate instruction icons comprises: starting service, stopping service, checking service running state, adding a system daemon task and starting service, deleting the system daemon task and stopping service and installing certificate.
8. The method of claim 7, wherein the control instruction is a view service operational status instruction;
the control network communication module is controlled to execute target operation corresponding to the control instruction in response to the control instruction of the user, and the control network communication module comprises:
responding to the instruction for checking the service running state, detecting the current running state of the network communication module, and obtaining state information;
and displaying the state information.
9. An information interaction device applied to a client, the device comprising:
the system comprises an instruction acquisition module, a transmission module and a display module, wherein the instruction acquisition module is configured to acquire instruction information to be transmitted, and the instruction information to be transmitted is acquired by a user through browser input;
the first sending module is configured to send the instruction information to be transmitted to an interaction module through a network communication module, wherein the network communication module and the interaction module are respectively and independently arranged in the client, the interaction module is used for forwarding interaction information between the client and target equipment, and the interaction information comprises the instruction information to be transmitted;
the second sending module is configured to send the instruction information to be transmitted to the target device through the interaction module, so that the target device executes the instruction information to be transmitted.
10. An electronic device, comprising: a processor, a memory, and a bus;
the processor is connected to the memory via the bus, the memory storing computer readable instructions for implementing the method of any one of claims 1-8 when the computer readable instructions are executed by the processor.
11. A computer-readable storage medium, having stored thereon a computer program which, when executed, implements the method of any one of claims 1-8.
CN202210542598.1A 2022-05-18 2022-05-18 Method, device and medium for information interaction and network communication module control Pending CN114968015A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210542598.1A CN114968015A (en) 2022-05-18 2022-05-18 Method, device and medium for information interaction and network communication module control

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210542598.1A CN114968015A (en) 2022-05-18 2022-05-18 Method, device and medium for information interaction and network communication module control

Publications (1)

Publication Number Publication Date
CN114968015A true CN114968015A (en) 2022-08-30

Family

ID=82982358

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210542598.1A Pending CN114968015A (en) 2022-05-18 2022-05-18 Method, device and medium for information interaction and network communication module control

Country Status (1)

Country Link
CN (1) CN114968015A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115514622A (en) * 2022-11-18 2022-12-23 阿里巴巴(中国)有限公司 Interactive object processing method, network communication system, device, and storage medium

Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106446647A (en) * 2016-08-26 2017-02-22 乐视控股(北京)有限公司 Method and device for processing browser webpage browsing
US20170331900A1 (en) * 2016-05-13 2017-11-16 Sap Se Clustering Websocket Communications With Configurable Master-Slave Servers
US20180227370A1 (en) * 2015-10-07 2018-08-09 Wacom Co., Ltd. Multi-user, cross-browser signature platform
CN109800148A (en) * 2018-12-14 2019-05-24 平安普惠企业管理有限公司 A kind of page adjustment method, device, readable storage medium storing program for executing and terminal device
CN109947582A (en) * 2019-03-29 2019-06-28 深圳市永兴元科技股份有限公司 The exchange method of browser and local application, equipment and readable storage medium storing program for executing
CN110175055A (en) * 2019-05-07 2019-08-27 成都交大光芒科技股份有限公司 A kind of call method of browser and fingerprint instrument based on service
KR20190120899A (en) * 2018-04-17 2019-10-25 이니텍(주) Single Sign-On Method Using Browser Fingerprint
CN110750437A (en) * 2018-07-23 2020-02-04 阿里巴巴集团控股有限公司 Equipment debugging method, device, equipment and system
CN110784525A (en) * 2019-10-14 2020-02-11 广州微算互联信息技术有限公司 Cloud mobile phone control method, system and storage medium based on H5 webpage technology
CN112199064A (en) * 2020-10-14 2021-01-08 Vidaa美国公司 Interaction method of browser application and system platform and display equipment
US20210011835A1 (en) * 2019-07-12 2021-01-14 HCL America Inc. System and method for debugging source code of an application
CN112988599A (en) * 2021-04-29 2021-06-18 腾讯科技(深圳)有限公司 Page debugging method and device, electronic equipment and storage medium
CN113239308A (en) * 2021-05-26 2021-08-10 杭州安恒信息技术股份有限公司 Page access method, device, equipment and storage medium
CN113918856A (en) * 2021-09-29 2022-01-11 上海浦东发展银行股份有限公司 Digital human application system, application method, computer device, and storage medium
CN114095555A (en) * 2021-12-08 2022-02-25 金蝶医疗软件科技有限公司 Information acquisition method and related equipment
CN114138511A (en) * 2021-11-25 2022-03-04 山东浪潮通软信息科技有限公司 Data interaction method, equipment and medium

Patent Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180227370A1 (en) * 2015-10-07 2018-08-09 Wacom Co., Ltd. Multi-user, cross-browser signature platform
US20170331900A1 (en) * 2016-05-13 2017-11-16 Sap Se Clustering Websocket Communications With Configurable Master-Slave Servers
CN106446647A (en) * 2016-08-26 2017-02-22 乐视控股(北京)有限公司 Method and device for processing browser webpage browsing
KR20190120899A (en) * 2018-04-17 2019-10-25 이니텍(주) Single Sign-On Method Using Browser Fingerprint
CN110750437A (en) * 2018-07-23 2020-02-04 阿里巴巴集团控股有限公司 Equipment debugging method, device, equipment and system
CN109800148A (en) * 2018-12-14 2019-05-24 平安普惠企业管理有限公司 A kind of page adjustment method, device, readable storage medium storing program for executing and terminal device
CN109947582A (en) * 2019-03-29 2019-06-28 深圳市永兴元科技股份有限公司 The exchange method of browser and local application, equipment and readable storage medium storing program for executing
CN110175055A (en) * 2019-05-07 2019-08-27 成都交大光芒科技股份有限公司 A kind of call method of browser and fingerprint instrument based on service
US20210011835A1 (en) * 2019-07-12 2021-01-14 HCL America Inc. System and method for debugging source code of an application
CN110784525A (en) * 2019-10-14 2020-02-11 广州微算互联信息技术有限公司 Cloud mobile phone control method, system and storage medium based on H5 webpage technology
CN112199064A (en) * 2020-10-14 2021-01-08 Vidaa美国公司 Interaction method of browser application and system platform and display equipment
CN112988599A (en) * 2021-04-29 2021-06-18 腾讯科技(深圳)有限公司 Page debugging method and device, electronic equipment and storage medium
CN113239308A (en) * 2021-05-26 2021-08-10 杭州安恒信息技术股份有限公司 Page access method, device, equipment and storage medium
CN113918856A (en) * 2021-09-29 2022-01-11 上海浦东发展银行股份有限公司 Digital human application system, application method, computer device, and storage medium
CN114138511A (en) * 2021-11-25 2022-03-04 山东浪潮通软信息科技有限公司 Data interaction method, equipment and medium
CN114095555A (en) * 2021-12-08 2022-02-25 金蝶医疗软件科技有限公司 Information acquisition method and related equipment

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
404NAME: "web项目接入指纹识别+识别过程信息推送", pages 1 - 6, Retrieved from the Internet <URL:《https://blog.csdn.net/weixin_45590872/article/details/120575673》> *
微尘小四儿: "ZKTeco live20R指纹采集识别适配谷歌浏览器", pages 1 - 34, Retrieved from the Internet <URL:《https://blog.csdn.net/lcj401175209/article/details/119081498》> *
王红勤;: "高校设备管理系统中Android客户端的设计与实现", 电脑知识与技术, no. 12, pages 146 - 149 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115514622A (en) * 2022-11-18 2022-12-23 阿里巴巴(中国)有限公司 Interactive object processing method, network communication system, device, and storage medium

Similar Documents

Publication Publication Date Title
CN109684054B (en) Information processing method and device, electronic equipment and memory
US10367920B2 (en) Mechanism for determining whether to redirect a request originally destined for a server based on a uniform resource locator
CN109800173B (en) Program debugging method, device and storage medium
CN110198247B (en) Interface test method and system
CN111478956B (en) Deployment and preview method and device of small program package
CN113360807B (en) Page display method and device of mixed-mode mobile application and related equipment
CN112835782B (en) Interface access test method and system
CN111813623B (en) Page monitoring method and device, electronic equipment and storage medium
CN114168460A (en) Remote debugging method, device and storage medium for front-end code in hybrid development
CN114968015A (en) Method, device and medium for information interaction and network communication module control
CN110795353B (en) Quick application debugging method, device, equipment and storage medium
CN112202824A (en) Network resource access processing method and device, server and terminal
CN111767229A (en) Performance test method, device and equipment
CN106952426B (en) Data processing method and device
CN111061448A (en) Log information display method and device, electronic equipment and storage medium
CN113626225B (en) Program calling method, terminal device and medium
CN106095886B (en) Data processing method and device
JP7230951B2 (en) Mobile terminal, information processing system, control method, and program
JP2006276939A (en) Program starting method for virtual machine, and client server system
CN113157274B (en) Software development method and device based on micro front end, electronic equipment and storage medium
CN111427770B (en) Resource testing method and related equipment
CN114327945A (en) Scanning method, device and system
CN110098980B (en) Network debugging method and device, computer equipment and storage medium
CN111158661A (en) System interface docking method, device, medium and electronic equipment
CN117492968B (en) Native application calling method and device, electronic equipment and readable storage medium

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