CN102571761B - Information transmission method of network interface - Google Patents

Information transmission method of network interface Download PDF

Info

Publication number
CN102571761B
CN102571761B CN201110431722.9A CN201110431722A CN102571761B CN 102571761 B CN102571761 B CN 102571761B CN 201110431722 A CN201110431722 A CN 201110431722A CN 102571761 B CN102571761 B CN 102571761B
Authority
CN
China
Prior art keywords
data
processing
network interface
data packet
command
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
Application number
CN201110431722.9A
Other languages
Chinese (zh)
Other versions
CN102571761A (en
Inventor
蒋伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan Changhong Electric Co Ltd
Original Assignee
Sichuan Changhong Electric 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 Sichuan Changhong Electric Co Ltd filed Critical Sichuan Changhong Electric Co Ltd
Priority to CN201110431722.9A priority Critical patent/CN102571761B/en
Publication of CN102571761A publication Critical patent/CN102571761A/en
Application granted granted Critical
Publication of CN102571761B publication Critical patent/CN102571761B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)
  • Communication Control (AREA)

Abstract

The invention relates to an information transmission method of a network interface. The method comprises the following steps that: a master control module initiates data packet processing so as to enable a system to load each data packet protocol defined in the data packet processing; the system executes lexical analysis on each input word; the system executes syntax analysis after executing the lexical analysis to get corresponding semantics; and the system executes corresponding command action processing according to the obtained semantics, and forms the execution result into message data according to the data transmission format defined in the data packet processing so as to perform network transmission. In the method provided by the invention, the format of the data packet is not needed to be defined again, and corresponding data packet can be formed just by defining corresponding grammar and command functions according to the uniform data format, thus, data structure in network transmission is simplified, the universality and the flexibility of the data packet are improved, and the method is particularly suitable for the Socket interaction between a broadcast television service operation management system and a CA (Conditional Access) system.

Description

The information transferring method of network interface
Technical field
The present invention relates to information transferring method, is the information transferring method of network interface concretely, is particularly suitable for but is not limited only to CA(condition reception) Socket(socket in system) communication of interface.
Background technology
Socket is a kind of interface for network programming, is called socket.Socket is the final cover contact that a process and another process are carried out both-way communication, and it is the IPC of computer system and the fundamental mechanism of the Heterogeneous Computers network interconnection of being released in Unix system by Berkeley.
The design of traditional network interface packet is all that the content of depositing agreement by the fixed position of an appointment in packet realizes.This mode is comparatively simple and clear, but underaction, when transmit data between different systems and agreement time, normal appearance can not be transplanted and situation that can not be compatible, therefore need different systems to define separately data transmission format and agreement, increased the development cost of system and the complexity of Internet Transmission.
Summary of the invention
For above problem, the invention provides a kind of information transferring method of network interface, do not need to redefine the form of packet, form corresponding packet according to the corresponding grammer of unified data format definition and command functions, the data structure of simplified network transmission, the versatility of raising packet.
The information transferring method of network interface of the present invention, comprising:
Processing data packets: for defining general data transmission format to form at least one data pack protocol, the field of data transmission format comprises: message origin identification, order length, message id and command context;
Morphological analysis: according to lexical analysis tool, the form of keyword vocabulary and the required keyword vocabulary of generation order in definition command;
Syntactic analysis: according to syntactic analysis instrument, the vocabulary generating taking Lexical Analysis Module, as basis, definition forms correct order by described vocabulary, completes the conversion of IP data to IP order;
Command action processing: comprise the handling procedure to order that syntax Analysis Module generates;
Main control module is integrated and is processed: comprise main frame program, for above-mentioned each Function Integration Mechanism is integrated, be then compiled into an executable program;
Carried out the initialization of processing data packets by main control module, make each data pack protocol of defining in system loads processing data packets step, and then the data pack protocol of selecting according to user carries out system initialization;
System receives after outside input, and each vocabulary of input is carried out to morphological analysis, if find that there is word and do not meet the morphology form of definition, exits parsing;
All input, by after morphological analysis, is carried out syntactic analysis by result and is obtained corresponding semanteme, if can not be resolved into the semanteme matching with the syntax format of definition, exits parsing;
The command action processing corresponding according to the semantic execution obtaining, according to the data transmission format generating messages data that define in processing data packets, is bundled to the result of execution in tcp data bag, to carry out Internet Transmission by described message data.
Method of the present invention is that the data in tcp data bag are reintegrated, and does not change the structure of TCP bag, and the packet that therefore the inventive method is transmitted is general in whole network.
Further, in order to make the treatment mechanism of system more perfect, improve the efficiency of transmission of data, process in command action the processing comprising bad command, improve the response time of system.
Under normal circumstances, because different Internet Transmission scenes has different protocol requirements, for saving resource, preferred a kind of scheme is that system is divided at least twice by the each data pack protocol defining in processing data packets step and loads.
Preferably, after syntactic analysis success, open a new process, in described new process, carry out corresponding command action processing, with antifouling external echo.
Further, command action is carried out message data after Internet Transmission in processing, and the resource that system by modulated use but does not discharge discharges, and exits current process.
Further, in the time carrying out packet packing, packet is carried out to interim conversation secret key encryption, to ensure the fail safe of packet.
Method of the present invention does not need to redefine the form of packet, only need be according to unified data format definition corresponding grammer and command functions can form corresponding packet, simplify thus the data structure of Internet Transmission, improving versatility and the flexibility of packet, be particularly suitable for broadcasting and TV business operation management system and CA(condition reception) Socket between system is mutual.
Below in conjunction with the embodiment by accompanying drawing illustrated embodiment, foregoing of the present invention is described in further detail again.But this should be interpreted as to the scope of the above-mentioned theme of the present invention only limits to following example.Without departing from the idea case in the present invention described above, various replacements or the change made according to ordinary skill knowledge and customary means, all should comprise within the scope of the invention.
Brief description of the drawings
Fig. 1 is the flow chart of the information transferring method of network interface of the present invention.
Embodiment
The information transferring method of network interface of the present invention as shown in Figure 1, comprising:
Processing data packets: for defining general data transmission format to form several data packet protocol, the field of data transmission format comprises: message origin identification, message header, order length, message id, command context and message Hash code; Wherein order length is variable, and for simplicity, definition command length is that n × 8(n is integer).Carry out processing data packets according to the data transmission format of definition, as package, unpack, encryption, network monitoring, network connection etc.
Morphological analysis: according to lexical analysis tool (as lex), the form of keyword vocabulary and the required keyword vocabulary of generation order in definition command;
Syntactic analysis: according to syntactic analysis instrument (as yacc), the vocabulary generating taking Lexical Analysis Module, as basis, definition forms correct order by described vocabulary, completes the conversion of IP data to IP order;
Command action processing: comprise handling procedure to order that syntax Analysis Module generates and the handling procedure of bad command;
Main control module is integrated and is processed: comprise main frame program, for above-mentioned each Function Integration Mechanism is integrated, be then compiled into an executable program;
Packet gauge outfit in the inventive method is consistent with tcp data bag gauge outfit, just the data division of tcp data bag is redefined, and it is become from data is a command set.The Socket message bag generating by the inventive method has also just been replaced the data division in tcp data bag.Therefore the packet of the inventive method is a tcp data bag, can in the whole network, carry out the transmission of TCP/IP.
Carried out the initialization of processing data packets by main control module, make each data pack protocol of defining in system loads processing data packets step, and then the data pack protocol of selecting according to user carries out system initialization.Because different Internet Transmission scenes has different protocol requirements, for saving resource, preferred a kind of scheme is that system is divided at least twice by described data pack protocol and loads.
System receives after outside input, and each vocabulary of input is carried out to morphological analysis, if find that there is word and do not meet the morphology form of definition, prints Log information and also exits parsing.Lexical Analysis Module can be selected existing software.
All input, by after morphological analysis, is carried out syntactic analysis by result and is obtained corresponding semanteme, if can not be resolved into the semanteme matching with the syntax format of definition, prints Log information and exits parsing.Syntax Analysis Module can be selected existing software.
Open a new process, the command action processing corresponding according to the semantic execution obtaining, with antifouling external echo.The result of execution, according to the data transmission format generating messages data that define in processing data packets, is together bundled to the direct transmission of carrying out resolving mutually end to end realization order in TCP/IP packet by described message data and message Hash code.When message data packing, packet is carried out to interim conversation secret key encryption, to ensure the fail safe of packet.After message data is transmitted, the modulated use of system but the resource that do not discharge discharge, and exit current process.

Claims (6)

1. the information transferring method of network interface, is characterized by and comprise:
Processing data packets: for defining general data transmission format to form at least one data pack protocol, the field of data transmission format comprises: message origin identification, order length, message id and command context;
Morphological analysis: according to lexical analysis tool, the form of keyword vocabulary and the required keyword vocabulary of generation order in definition command;
Syntactic analysis: according to syntactic analysis instrument, the vocabulary generating taking Lexical Analysis Module, as basis, definition forms correct order by described vocabulary, completes the conversion of IP data to IP order;
Command action processing: comprise the handling procedure to order that syntax Analysis Module generates;
Main control module is integrated and is processed: comprise main frame program, for above-mentioned each Function Integration Mechanism is integrated, be then compiled into an executable program;
Carried out the initialization of processing data packets by main control module, make each data pack protocol of defining in system loads processing data packets step, and then the data pack protocol of selecting according to user carries out system initialization;
System receives after outside input, and each vocabulary of input is carried out to morphological analysis, if find that there is word and do not meet the morphology form of definition, exits parsing;
All input, by after morphological analysis, is carried out syntactic analysis by result and is obtained corresponding semanteme, if can not be resolved into the semanteme matching with the syntax format of definition, exits parsing;
The command action processing corresponding according to the semantic execution obtaining, according to the data transmission format generating messages data that define in processing data packets, is bundled to the result of execution in tcp data bag, to carry out Internet Transmission by described message data.
2. the information transferring method of network interface as claimed in claim 1, is characterized by: process in command action the processing comprising bad command.
3. the information transferring method of network interface as claimed in claim 1, is characterized by: system is divided at least twice by the each data pack protocol defining in processing data packets step and loads.
4. the information transferring method of network interface as claimed in claim 1, is characterized by: after syntactic analysis success, open a new process, carry out corresponding command action processing in described new process.
5. the information transferring method of network interface as claimed in claim 1, is characterized by: command action is carried out message data after Internet Transmission in processing, system by modulated use but the resource not discharging discharge, and exit current process.
6. the information transferring method of network interface as described in one of claim 1 to 5, is characterized by: in the time carrying out packet packing, packet is carried out to interim conversation secret key encryption.
CN201110431722.9A 2011-12-21 2011-12-21 Information transmission method of network interface Active CN102571761B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110431722.9A CN102571761B (en) 2011-12-21 2011-12-21 Information transmission method of network interface

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110431722.9A CN102571761B (en) 2011-12-21 2011-12-21 Information transmission method of network interface

Publications (2)

Publication Number Publication Date
CN102571761A CN102571761A (en) 2012-07-11
CN102571761B true CN102571761B (en) 2014-08-20

Family

ID=46416240

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110431722.9A Active CN102571761B (en) 2011-12-21 2011-12-21 Information transmission method of network interface

Country Status (1)

Country Link
CN (1) CN102571761B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103236901B (en) * 2013-04-15 2015-11-25 天脉聚源(北京)传媒科技有限公司 A kind of method of transfer instruction and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6978447B1 (en) * 2001-02-28 2005-12-20 Cisco Technology, Inc. Method and system for efficiently interpreting a computer program
CN100383755C (en) * 2006-02-27 2008-04-23 华为技术有限公司 Software interface testing method and apparatus
CN100424640C (en) * 2006-09-26 2008-10-08 四川长虹电器股份有限公司 Domestic network intermediate parts development platform and codes conversion method thereof

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050102474A1 (en) * 2003-11-06 2005-05-12 Sridhar Lakshmanamurthy Dynamically caching engine instructions

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6978447B1 (en) * 2001-02-28 2005-12-20 Cisco Technology, Inc. Method and system for efficiently interpreting a computer program
CN100383755C (en) * 2006-02-27 2008-04-23 华为技术有限公司 Software interface testing method and apparatus
CN100424640C (en) * 2006-09-26 2008-10-08 四川长虹电器股份有限公司 Domestic network intermediate parts development platform and codes conversion method thereof

Also Published As

Publication number Publication date
CN102571761A (en) 2012-07-11

Similar Documents

Publication Publication Date Title
CN102202093B (en) A kind of method and system realizing transducer adaptation
WO2018059137A1 (en) Internet of things terminal access device and method, and computer storage medium
CN101483651B (en) Data transmission method based map queue
CN102866925B (en) Communication method and system for middleware and user interface
CN102790781A (en) Middleware, M2M (machine-to-machine) system with industrial application middleware and application method of system
CN107423142A (en) It is a kind of based on issue, the database message Notification Method of subscribing mode and system
CN104852939B (en) A kind of method and system of deployment ability interface
CN113556359B (en) Communication protocol conversion method, device, system and gateway device
CN112688952B (en) Message processing method, device, radio remote unit and medium
CN114449459B (en) Message transmission method and platform function application function
CN103246547A (en) Remote object calling method and system
CN107396049A (en) A kind of equipment access system and its method of compatible multi-protocols
CN107657031A (en) Method based on android system management intelligent sound box voice technical ability
CN102779071A (en) Method, device and system for calling software interface
KR20110065448A (en) Composing message processing pipelines
CN110071839B (en) CORBA communication device supporting digital signal processor
KR102094041B1 (en) System having the Semantic Engine based on RDF Graph for Autonomous Interaction between IoT Devices in Real-Time
CN114885044A (en) Adaptive analysis processing method for heterogeneous monitoring data packet of measurement and control equipment
Azzara et al. The icsi m2m middleware for iot-based intelligent transportation systems
CN102571761B (en) Information transmission method of network interface
CN101529807B (en) A method and system for realizing universal interfaces in the network management system
CN117176633A (en) Bus cross-device communication method, device, equipment and storage medium
CN112817539A (en) Industrial data storage method and system, electronic device and storage medium
CN111343201A (en) Analysis method, device and system for rapidly adapting to protocol change
CN103731345A (en) Network message processing method and equipment

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant