CN104410841B - A kind of connection method and device based on MAC layer - Google Patents
A kind of connection method and device based on MAC layer Download PDFInfo
- Publication number
- CN104410841B CN104410841B CN201410795865.1A CN201410795865A CN104410841B CN 104410841 B CN104410841 B CN 104410841B CN 201410795865 A CN201410795865 A CN 201410795865A CN 104410841 B CN104410841 B CN 104410841B
- Authority
- CN
- China
- Prior art keywords
- equipment
- mac frame
- hard disk
- video recorder
- mac
- 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.)
- Expired - Fee Related
Links
Abstract
The present invention is applied to the communications field, there is provided a kind of connection method and device based on MAC layer, methods described include:First equipment self-timing sends broadcast MAC frame, wherein the mac frame content includes the device type of first equipment, sequence number or MAC Address;First equipment receives the broadcast MAC frame that second equipment is sent;The broadcast MAC frame that first equipment is sent to second equipment received parses, and obtains device type, sequence number or the MAC Address of second equipment;Equipment corresponding to source MAC is added to device channels list in the broadcast MAC frame that first equipment sends second equipment received.The present invention implements to send broadcast MAC frame automatically by web camera or network hard disk video recorder and receives the broadcast MAC frame that other side sends simultaneously, so as to realize the automatic connection between equipment.
Description
Technical field
The invention belongs to the communications field, more particularly to a kind of connection method and device based on MAC layer.
Background technology
Network Video Surveillance be by wired, Wireless IP network and electric power networks video information in the form of digitized come
It is transmitted, is the integrated product of the multinomial new and high technologies such as an item collection computer, network, communication and coding and decoding video.With biography
The video monitoring of system is compared, Network Video Surveillance be more convenient for computer carry out the compression of video information, storage, analysis display and
The automatic business processings such as alarm, it is unattended so as to realize, remote monitor is realized by the network platform, utilizes advanced software
System can not only complete substantial amounts of data analysis in traditional video surveillance within a few minutes, improve monitoring efficiency, and can obtain
Obtain more true to nature, clearly digitized image quality and more convenient, practical monitoring management and maintenance.
In Network Video Surveillance field, as Internet video increasingly substitutes the popularization of past analog video monitoring with answering
With " foolproof " operation of, map network video camera (IPC) and network hard disk video recorder (NVR) have changed into one it is extremely important
Demand, but the connection of the IP address-based web camera of in general and network hard disk video recorder need to IP address carry out
Configuration, so as to which automatic connection, complex operation can not be realized.
The content of the invention
The embodiment of the present invention provides a kind of connection method based on MAC layer, it is intended to solves IP address-based connection procedure
In need to configure IP address, so as to realize automatic connection, the problem of complex operation.
The embodiment of the present invention is achieved in that a kind of connection method based on MAC layer, and methods described includes:
First equipment self-timing sends broadcast MAC frame, wherein the mac frame content includes the equipment of first equipment
Type, sequence number or MAC Address, it can be judged so as to receive the second equipment of the mac frame by the type of first equipment
Can the mac frame verify that second equipment uniquely determines described the by the sequence number of first equipment by matching
One equipment, second equipment uniquely determine the position of first equipment in a network by the MAC Address of first equipment
Put;
First equipment receives the broadcast MAC frame that second equipment is sent;
The broadcast MAC frame that first equipment is sent to second equipment received parses, and obtains institute
Device type, sequence number or the MAC Address of the second equipment are stated, so as to which first equipment can pass through the type of second equipment
Judge that can the mac frame verify that first equipment uniquely determines institute by the sequence number of second equipment by matching
The second equipment is stated, first equipment uniquely determines second equipment in a network by the MAC Address of second equipment
Position;
Source MAC is corresponding in the broadcast MAC frame that first equipment sends second equipment received
Equipment be added to device channels list;
Wherein, first equipment can be web camera, then second equipment is network hard disk video recorder;It is described
First equipment can also be network hard disk video recorder, then second equipment is web camera.
The embodiment of the present invention also provides a kind of attachment means based on MAC layer, and described device includes:
Mac frame transmitting element, broadcast MAC frame is sent for the first equipment self-timing, wherein the mac frame content includes
The device type of first equipment, sequence number or MAC Address, can be by described so as to receive the second equipment of the mac frame
The type of first equipment judges that can the mac frame be verified by matching, the sequence that second equipment passes through first equipment
Row number uniquely determines first equipment, and second equipment uniquely determines described by the MAC Address of first equipment
The position of one equipment in a network;
Mac frame receiving unit, the broadcast MAC frame of the second equipment transmission is received for first equipment;
Mac frame resolution unit, the broadcast MAC sent for first equipment to second equipment received
Frame is parsed, and obtains device type, sequence number or the MAC Address of second equipment, so as to which first equipment can pass through
The type of second equipment judges that can the mac frame verify that first equipment passes through second equipment by matching
Sequence number uniquely determine second equipment, first equipment uniquely determines institute by the MAC Address of second equipment
State the position of the second equipment in a network;
Equipment adding device, the broadcast MAC for sending second equipment received for first equipment
Equipment corresponding to source MAC is added to device channels list in frame;
Wherein, first equipment can be web camera, then second equipment is network hard disk video recorder;It is described
First equipment can also be network hard disk video recorder, then second equipment is web camera.
The embodiment of the present invention also provides a kind of network shooting generator terminal including the attachment means based on MAC layer, described device
Including:
Mac frame transmitting element, broadcast MAC frame is sent for web camera self-timing, wherein the mac frame content bag
The device type of the web camera, sequence number or MAC Address are included, so as to receive the network hard disk video recorder of the mac frame
It can judge that can the mac frame verify that the network hard disk video recorder leads to by matching by the type of the web camera
The sequence number for crossing the web camera uniquely determines the web camera, and the network hard disk video recorder passes through the network
The MAC Address of video camera uniquely determines the position of the web camera in a network;
Mac frame receiving unit, the broadcast MAC of the network hard disk video recorder transmission is received for the web camera
Frame;
Mac frame resolution unit, the network hard disk video recorder received is sent for the web camera
Broadcast MAC frame parsed, device type, sequence number or the MAC Address of the network hard disk video recorder are obtained, so as to described
Web camera can judge that can the mac frame be verified by matching by the type of the network hard disk video recorder, the net
Network video camera uniquely determines the network hard disk video recorder, the network shooting by the sequence number of the network hard disk video recorder
Machine uniquely determines the position of the network hard disk video recorder in a network by the MAC Address of the network hard disk video recorder;
Equipment adding device, the broadcast for sending the network hard disk video recorder received for the web camera
Equipment corresponding to source MAC is added to device channels list in mac frame.
The embodiment of the present invention also provides a kind of network hard disk video recorder for including the attachment means based on MAC layer, the dress
Put including:
Mac frame transmitting element, broadcast MAC frame is sent for network hard disk video recorder self-timing, wherein in the mac frame
Holding includes the device type of the network hard disk video recorder, sequence number or MAC Address, is taken the photograph so as to receive the network of the mac frame
Camera can judge that can the mac frame be verified by matching by the type of the network hard disk video recorder, the network shooting
Machine uniquely determines the network hard disk video recorder by the sequence number of the network hard disk video recorder, and the web camera passes through
The MAC Address of the network hard disk video recorder uniquely determines the position of the network hard disk video recorder in a network;
Mac frame receiving unit, the broadcast MAC of the web camera transmission is received for the network hard disk video recorder
Frame;
Mac frame resolution unit, the web camera received is sent for network hard disk video recorder wide
Broadcast mac frame to be parsed, obtain device type, sequence number or the MAC Address of the web camera, so as to the network hard disc
Video recorder can judge that can the mac frame be verified by matching by the type of the web camera, the network hard disc record
Camera uniquely determines the web camera by the sequence number of the web camera, and the network hard disk video recorder passes through institute
The MAC Address for stating web camera uniquely determines the position of the web camera in a network;
Equipment adding device, the broadcast for sending the web camera received for the network hard disk video recorder
Equipment corresponding to source MAC is added to device channels list in mac frame.
The present invention implements to send broadcast MAC frame automatically by web camera or network hard disk video recorder and simultaneously receive
The broadcast MAC frame that other side sends, so as to realize the automatic connection between equipment.
Brief description of the drawings
Fig. 1 is the implementation environment figure of the connection method provided in an embodiment of the present invention based on MAC layer;
Fig. 2 is the implementation process figure of the connection method provided in an embodiment of the present invention based on MAC layer;
Fig. 3 is the signal timing diagram for the connection method based on MAC layer that first embodiment of the invention provides;
Fig. 4 is the signal timing diagram for the connection method based on MAC layer that second embodiment of the invention provides;
Fig. 5 is the attachment means provided in an embodiment of the present invention based on MAC layer.
Embodiment
In order to make the purpose , technical scheme and advantage of the present invention be clearer, it is right below in conjunction with drawings and Examples
The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and
It is not used in the restriction present invention.
The present invention implements to send broadcast MAC frame automatically by web camera or network hard disk video recorder and simultaneously receive
The broadcast MAC frame that other side sends, so as to realize the automatic connection between equipment.
Fig. 1 shows the implementation environment of the connection method provided in an embodiment of the present invention based on MAC layer, for the ease of saying
It is bright, it illustrate only the part related to the embodiment of the present invention.
Web camera 100 absorbs video image, and it is enterprising the vedio data absorbed can be transferred into storage device
Row storage.
Network hard disk video recorder 200, which can store, to be transmitted to the data of network hard disk video recorder.
Router 300 can will be connected between the equipment of same router 300 and be communicated.
In embodiments of the present invention, router 300 can be cable router, or wireless router.
As one embodiment of the present of invention, route can be passed through between web camera 100 and network hard disk video recorder 200
Device 300 is communicated, and web camera 100 passes through established communication connection and sends data to network hard disk video recorder 200.
In embodiments of the present invention, led between web camera 100 and network hard disk video recorder 200 based on MAC layer
Letter, upper layer communication agreement use class ICP/IP protocol.
Refering to Fig. 2, Fig. 3 and Fig. 4, Fig. 2 shows the realization of the connection method provided in an embodiment of the present invention based on MAC layer
Flow, Fig. 3 show the signal timing diagram for the connection method based on MAC layer that first embodiment of the invention provides, and Fig. 4 is shown
The signal timing diagram for the connection method based on MAC layer that second embodiment of the invention provides, details are as follows:
In step s 201, the first equipment self-timing sends broadcast MAC frame.
In embodiments of the present invention, the first equipment upon actuation, then can self-timing send broadcast MAC frame set to second
It is standby.
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described
When first equipment is network hard disk video recorder, second equipment is web camera.
In the first embodiment of the invention, web camera 100 upon actuation, then can self-timing send broadcast MAC frame,
The content of wherein mac frame is self-defined, including the device type of web camera 100, sequence number, so as to which web camera 100 can
Judge that can the mac frame verify that web camera 100 passes through network by matching by the type of network hard disk video recorder 200
The sequence number of DVR 200 uniquely determines the network hard disk video recorder 200, and web camera 100 is recorded by network hard disc
The MAC Address of camera 200 uniquely determines the position of network hard disk video recorder 200 in a network.
As the first embodiment of the present invention, due between web camera 100 to be realized and network hard disk video recorder 200
Connection, so network hard disk video recorder 200 is arranged into recrive-only equipment type for transmitted by network hard disk video recorder 200
Mac frame, so as to be only found bag for web camera 100 send when, network hard disk video recorder 200 receive the discovery bag when could
It is identified, namely the discovery bag is verified by matching.By each equipment of Serial No. is dispatched from the factory unique volume of when institute's band
Number, so as to which network hard disk video recorder 200 can uniquely determine the equipment by the sequence number of web camera 100, due to MAC Address
For equipment network interface card possessed whole world unique number, so network hard disk video recorder 200 can pass through the MAC of web camera 100
Address uniquely determines the unique positions of web camera 100 in a network.Realizing uniquely determining to web camera 100
Afterwards, then can be based on this realization to network hard disk video recorder 200 and the connection procedure of web camera 100.
In second embodiment of the invention, network hard disk video recorder 200 upon actuation, then can self-timing transmission broadcast
The data division of mac frame, wherein mac frame is self-defined, including the device type of network hard disk video recorder 200, sequence number and MAC
Location, so as to which network hard disk video recorder 200 can judge that can the mac frame be verified by matching by the type of web camera 100,
Network hard disk video recorder 200 uniquely determines the web camera 100, network hard disc record by the sequence number of web camera 100
Camera 200 uniquely determines the position of web camera 100 in a network by the MAC Address of web camera 100.
As the second embodiment of the present invention, due between web camera 100 to be realized and network hard disk video recorder 200
Connection, so web camera 100 is arranged into recrive-only equipment type for the MAC transmitted by network hard disk video recorder 200
Frame, so as to be only found bag for network hard disk video recorder 200 send when, web camera 100 receive the discovery bag when could be right
It is identified, namely the discovery bag is verified by matching.By each equipment of Serial No. is dispatched from the factory the unique number of when institute's band,
So as to which web camera 100 can uniquely determine the equipment by the sequence number of network hard disk video recorder 200, because MAC Address is
Equipment network interface card possessed whole world unique number, so web camera 100 can by the MAC of network hard disk video recorder 200
Location uniquely determines the unique positions of network hard disk video recorder 200 in a network.Realizing to network hard disk video recorder 200 only
, then can be based on this realization to web camera 100 and the connection procedure of network hard disk video recorder 200 after one determines.
In the first embodiment of the invention, web camera 100 upon actuation, then can be sent out automatically at a certain time interval
Broadcast MAC frame is sent, the content of wherein mac frame is self-defined, including the device type of web camera 100, sequence number and MAC
Location, so as to which web camera 100 can judge that can the mac frame be verified by matching by the type of network hard disk video recorder 200,
Web camera 100 uniquely determines the network hard disk video recorder 200 by the sequence number of network hard disk video recorder 200, and network is taken the photograph
Camera 100 uniquely determines the position of network hard disk video recorder 200 in a network by the MAC Address of network hard disk video recorder 200.
As the present invention a preferred embodiment, web camera 100 upon actuation, with 10 seconds intervals once from
It is dynamic to send broadcast MAC frame.
In second embodiment of the invention, network hard disk video recorder 200 upon actuation, then can at a certain time interval certainly
Dynamic to send broadcast MAC frame, the content of wherein mac frame is self-defined, including the device type of network hard disk video recorder 200, sequence number
And MAC Address, so as to network hard disk video recorder 200 can be judged by the type of web camera 100 mac frame can by
With checking, network hard disk video recorder 200 uniquely determines the web camera 100, network by the sequence number of web camera 100
DVR 200 uniquely determines the position of web camera 100 in a network by the MAC Address of web camera 100.
As a preferred embodiment of the second embodiment of the present invention, network hard disk video recorder 200 upon actuation, with
10 seconds intervals once send broadcast MAC frame automatically.
In step S202, the first equipment receives the broadcast MAC frame that the second equipment is sent.
In embodiments of the present invention, after the second equipment self-timing sends broadcast MAC frame, the first equipment receives second and set
The broadcast MAC frame that preparation is sent.
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described
When first equipment is network hard disk video recorder, second equipment is web camera.
In the first embodiment of the invention, when sending broadcast MAC frame by the self-timing of web camera 100, due to net
Network video camera 100 and network hard disk video recorder 200 are in same LAN, and use same upper layer communication agreement, then net
Network DVR 200 includes the mac frame that source MAC is web camera 100 by this is received.
In second embodiment of the invention, when sending broadcast MAC frame by the self-timing of network hard disk video recorder 200, by
Same LAN is in web camera 100 and network hard disk video recorder 200, and uses same upper layer communication agreement,
Then web camera 100 includes the mac frame that source MAC is network hard disk video recorder 200 by this is received.
In step S203, the broadcast MAC frame for the second equipment transmission that the first equipment interconnection receives is parsed.
In embodiments of the present invention, after the first equipment receives the broadcast MAC frame of the second equipment transmission, the first equipment pair
The broadcast MAC frame that the second equipment received is sent is parsed.
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described
When first equipment is network hard disk video recorder, second equipment is web camera.
In the first embodiment of the invention, when network hard disk video recorder 200 receives the bag sent by web camera 100
During containing the mac frame that source MAC is web camera 100, the broadcast MAC frame is parsed.
In second embodiment of the invention, when web camera 100 receives the bag sent by network hard disk video recorder 200
During containing the mac frame that source MAC is network hard disk video recorder 200, the broadcast MAC frame is parsed.
As the first embodiment of the present invention, when network hard disk video recorder 200 receives what is sent by web camera 100
During comprising the mac frame that source MAC is web camera 100, the broadcast MAC frame is parsed, obtains web camera 100
Type, sequence number or MAC Address, so as to network hard disk video recorder 200, can be judged by the type of web camera 100 should
Can mac frame verify that network hard disk video recorder 200 uniquely determines the net by the sequence number of web camera 100 by matching
Network video camera 100, network hard disk video recorder 200 uniquely determine the web camera by the MAC Address of web camera 100
100 position in a network.
As the second embodiment of the present invention, when web camera 100 receives what is sent by network hard disk video recorder 200
During comprising the mac frame that source MAC is network hard disk video recorder 200, the broadcast MAC frame is parsed, according to upper layer communication
Agreement judges whether the mac frame is the mac frame needed, obtains type, sequence number or the MAC Address of network hard disk video recorder 200,
So as to which network hard disk video recorder 200 can judge that can the mac frame be verified by matching by the type of web camera 100, net
Network DVR 200 uniquely determines the web camera 100, network hard disc video recording by the sequence number of web camera 100
Machine 200 uniquely determines the position of web camera 100 in a network by the MAC Address of web camera 100.
In step S204, source MAC is corresponding in the broadcast MAC frame that the first equipment sends the second equipment received
Equipment be added to device channels list.
In embodiments of the present invention, when the broadcast MAC frame that the second equipment that the first equipment interconnection receives is sent is parsed
Afterwards, equipment corresponding to source MAC is added to equipment and led in the broadcast MAC frame that the first equipment sends the second equipment received
Road list.
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described
When first equipment is network hard disk video recorder, second equipment is web camera.
In the first embodiment of the invention, when sending broadcast MAC frame by the self-timing of web camera 100, the broadcast
The source MAC of mac frame is web camera 100, then receives the broadcast MAC frame and to it in network hard disk video recorder 200
After being parsed, according to customized upper layer communication agreement, network hard disk video recorder 200 can be identified and sent out by web camera 100
The broadcast MAC bags sent, network corresponding to source MAC in the broadcast MAC frame for receiving this so as to network hard disk video recorder 200
Video camera 100 is added in the channel list for the all-network video camera 100 that connection can be established with the network hard disk video recorder 200
And the source MAC is recorded simultaneously, the equipment being present in the channel list can then be built with the network hard disk video recorder 200 automatically
Vertical connection, so as to represent that web camera 100 corresponding to source MAC can be built with the network hard disk video recorder 200 in the mac frame
Vertical connection.
, should when sending broadcast MAC frame by the self-timing of network hard disk video recorder 200 in second embodiment of the invention
The source MAC of broadcast MAC frame is network hard disk video recorder 200, then receives the broadcast MAC frame simultaneously in web camera 100
After being parsed to it, according to customized upper layer communication agreement, web camera 100 can be identified by network hard disk video recorder
The 200 broadcast MAC bags sent, so as to web camera 100, net corresponding to source MAC in the broadcast MAC frame that this is received
Network DVR 200 is added to the channel list for the all-network video camera 100 that connection can be established with the web camera 100
In and simultaneously record the source MAC, the equipment being present in the channel list can then be established with the web camera 100 automatically
Connection, so as to represent that network hard disk video recorder 200 corresponding to source MAC can be established with the web camera 100 in the mac frame
Connection.
In embodiments of the present invention, step S201 and step S202 execution sequence can change.
The signal timing diagram in the present invention is implemented based on web camera, Fig. 4 are represented referring to Fig. 3 and Fig. 4, Fig. 3
Represent the signal timing diagram based on network hard disk video recorder in embodiments of the present invention.
In embodiments of the present invention, when web camera 100 and network hard disk video recorder 200 start, web camera
100 and network hard disk video recorder 200 send broadcast MAC frame together, so as to web camera 100 and network hard disk video recorder 200
Network hard disk video recorder 200 and web camera 100 will be recognized respectively, other side is increased in the channel list of oneself and same
The Shi Jilu source MACs.When web camera 100 and network hard disk video recorder 200 are respectively in the channel list of other side, then
Automatic to establish connection, when a side sends data, the opposing party will receive data automatically.
In one embodiment of the invention, one network hard disk video recorder of corresponding connection of web camera 100
200。
As one embodiment of the present of invention, a web camera 100, which can correspond to, connects multiple network hard disk video recorders
200, a network hard disk video recorder 200 can also correspond to and connect multiple web cameras 100, so when realizing data communication,
Then the communication between each equipment is according to the order carry out order communication inside channel list.
Fig. 5 shows the attachment means provided in an embodiment of the present invention based on MAC layer, for convenience of description, illustrate only
The part related to the embodiment of the present invention.
The self-timing of mac frame transmitting element 400 sends broadcast MAC frame.
In the first embodiment of the invention, web camera 100 upon actuation, then can be by mac frame transmitting element 400 certainly
Dynamic timing sends broadcast MAC frame, and the data division of wherein mac frame is self-defined, including the device type of web camera 100, sequence
Row number and MAC Address, so as to which web camera 100 can judge that can the mac frame lead to by the type of network hard disk video recorder 200
Overmatching verifies that web camera 100 uniquely determines the network hard disk video recorder by the sequence number of network hard disk video recorder 200
200, web camera 100 uniquely determines the network hard disk video recorder 200 by the MAC Address of network hard disk video recorder 200 and existed
Position in network.
In second embodiment of the invention, network hard disk video recorder 200 upon actuation, then can pass through mac frame transmitting element
400 self-timings send broadcast MAC frame, and the data division of wherein mac frame is self-defined, including network hard disk video recorder 200 is set
Standby type, sequence number and MAC Address, so as to which network hard disk video recorder 200 can judge to be somebody's turn to do by the type of web camera 100
Can mac frame verify that network hard disk video recorder 200 uniquely determines the net by the sequence number of web camera 100 by matching
Network video camera 100, network hard disk video recorder 200 uniquely determine the web camera by the MAC Address of web camera 100
100 position in a network.
In the first embodiment of the invention, web camera 100 upon actuation, then can by mac frame transmitting element 400 with
Certain time interval sends broadcast MAC frame automatically, and the data division of wherein mac frame is self-defined, including web camera 100
Device type, sequence number and MAC Address, so as to which web camera 100 can judge to be somebody's turn to do by the type of network hard disk video recorder 200
Can mac frame verify that web camera 100 uniquely determines the net by the sequence number of network hard disk video recorder 200 by matching
Network DVR 200, web camera 100 uniquely determine network hard disc by the MAC Address of network hard disk video recorder 200 and recorded
The position of camera 200 in a network.
As the preferred embodiment of the present invention, web camera 100 upon actuation, then can be sent by mac frame
Unit 400 sent broadcast MAC frame automatically with 10 seconds intervals once.
In second embodiment of the invention, network hard disk video recorder 200 upon actuation, then can pass through mac frame transmitting element
400 send broadcast MAC frame automatically at a certain time interval, and the data division of wherein mac frame is self-defined, including network hard disc record
Device type, sequence number and the MAC Address of camera 200, so as to which network hard disk video recorder 200 can pass through web camera 100
Type judges that can the mac frame be verified by matching, network hard disk video recorder 200 by the sequence number of web camera 100 only
One determines the web camera 100, and network hard disk video recorder 200 uniquely determines the net by the MAC Address of web camera 100
The position of network video camera 100 in a network.
As a preferred embodiment of the second embodiment of the present invention, network hard disk video recorder 200 upon actuation, then
Broadcast MAC frame can be sent automatically with 10 seconds intervals once by mac frame transmitting element 400.
Mac frame receiving unit 500 receives the broadcast MAC frame that the second equipment is sent.
In the first embodiment of the invention, when sending broadcast MAC frame by the self-timing of web camera 100, due to net
Network video camera 100 and network hard disk video recorder 200 are in same LAN, and use same upper layer communication agreement, then net
Network DVR 200 will receive this by mac frame receiving unit 500 and include the MAC that source MAC is web camera 100
Frame.
In second embodiment of the invention, when sending broadcast MAC frame by the self-timing of network hard disk video recorder 200, by
Same LAN is in web camera 100 and network hard disk video recorder 200, and uses same upper layer communication agreement,
Then web camera 100 will receive this by mac frame receiving unit 500 and include source MAC as network hard disk video recorder 200
Mac frame simultaneously parses to it.
The broadcast MAC frame that mac frame resolution unit 600 is sent to the second equipment received parses.
In the first embodiment of the invention, when network hard disk video recorder 200 receives the bag sent by web camera 100
During containing the mac frame that source MAC is web camera 100, mac frame resolution unit 600 parses to the broadcast MAC frame.
In second embodiment of the invention, when web camera 100 receives the bag sent by network hard disk video recorder 200
During containing the mac frame that source MAC is network hard disk video recorder 200, mac frame resolution unit 600 solves to the broadcast MAC frame
Analysis.
As the first embodiment of the present invention, when network hard disk video recorder 200 receives what is sent by web camera 100
During comprising the mac frame that source MAC is web camera 100, mac frame resolution unit 600 parses to the broadcast MAC frame,
Type, sequence number or the MAC Address of web camera 100 are obtained, so as to which network hard disk video recorder 200 can pass through web camera
100 type judges that can the mac frame be verified by matching, the sequence that network hard disk video recorder 200 passes through web camera 100
Number the web camera 100 is uniquely determined, network hard disk video recorder 200 is uniquely determined by the MAC Address of web camera 100
The position of web camera 100 in a network.
As the second embodiment of the present invention, when web camera 100 receives what is sent by network hard disk video recorder 200
During comprising the mac frame that source MAC is network hard disk video recorder 200, mac frame resolution unit 600 solves to the broadcast MAC frame
Analysis, according to upper layer communication agreement judge the mac frame whether be need mac frame, obtain network hard disk video recorder 200 type,
Sequence number or MAC Address, so as to which network hard disk video recorder 200 can judge that can the mac frame by the type of web camera 100
Verified by matching, network hard disk video recorder 200 uniquely determines the web camera by the sequence number of web camera 100
100, network hard disk video recorder 200 uniquely determines the web camera 100 in network by the MAC Address of web camera 100
In position.
Equipment corresponding to source MAC in the broadcast MAC frame that equipment adding device 700 sends the second equipment received
It is added to device channels list.
In the first embodiment of the invention, when sending broadcast MAC frame by the self-timing of web camera 100, the broadcast
The source MAC of mac frame is web camera 100, then receives the broadcast MAC frame and to it in network hard disk video recorder 200
After being parsed, according to customized upper layer communication agreement, network hard disk video recorder 200 can be identified and sent out by web camera 100
The broadcast MAC bags sent, network corresponding to source MAC in the broadcast MAC frame for receiving this so as to network hard disk video recorder 200
Video camera 100 is added to by equipment adding device 700 to be taken the photograph with the all-network of the network hard disk video recorder 200 foundation connection
In the channel list of camera 100 and simultaneously record the source MAC, the equipment being present in the channel list then can automatically with this
Network hard disk video recorder 200 establishes connection, so as to represent that web camera 100 can be with this corresponding to source MAC in the mac frame
Network hard disk video recorder 200 establishes connection.
, should when sending broadcast MAC frame by the self-timing of network hard disk video recorder 200 in second embodiment of the invention
The source MAC of broadcast MAC frame is network hard disk video recorder 200, then receives the broadcast MAC frame simultaneously in web camera 100
After being parsed to it, according to customized upper layer communication agreement, web camera 100 can be identified by network hard disk video recorder
The 200 broadcast MAC bags sent, so as to web camera 100, net corresponding to source MAC in the broadcast MAC frame that this is received
Network DVR 200 is added to the all-network that connection can be established with the web camera 100 by equipment adding device 700
In the channel list of video camera 100 and simultaneously record the source MAC, the equipment being present in the channel list then can automatically with
The web camera 100 establishes connection, so as to represent in the mac frame that network hard disk video recorder 200 corresponding to source MAC can be with
The web camera 100 establishes connection.
The present invention implements to send broadcast MAC frame automatically by web camera or network hard disk video recorder and simultaneously receive
The broadcast MAC frame that other side sends, so as to realize the automatic connection between equipment.
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the invention, all essences in the present invention
All any modification, equivalent and improvement made within refreshing and principle etc., should be included in the scope of the protection.
Claims (10)
1. a kind of connection method based on MAC layer, it is characterised in that methods described includes:
First equipment self-timing sends broadcast MAC frame, wherein the mac frame content includes the equipment class of first equipment
Type, sequence number and MAC Address, institute can be judged by the type of first equipment so as to receive the second equipment of the mac frame
Can mac frame be stated verify that second equipment uniquely determines described first by the sequence number of first equipment by matching
Equipment, second equipment uniquely determine the position of first equipment in a network by the MAC Address of first equipment;
First equipment receives the broadcast MAC frame that second equipment is sent;
The broadcast MAC frame that first equipment is sent to second equipment that receives parses, and obtains described the
Device type, sequence number and the MAC Address of two equipment, so as to which first equipment can be judged by the type of second equipment
Can the mac frame verify that first equipment uniquely determines described the by the sequence number of second equipment by matching
Two equipment, first equipment uniquely determine the position of second equipment in a network by the MAC Address of second equipment
Put;
Set in the broadcast MAC frame that first equipment sends second equipment received corresponding to source MAC
It is standby to be added to device channels list;
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described first
When equipment is network hard disk video recorder, second equipment is web camera.
2. the connection method based on MAC layer as claimed in claim 1, it is characterised in that the first equipment self-timing hair
The broadcast MAC frame is sent to be specially:
First equipment sends the broadcast MAC frame automatically at a certain time interval.
3. the connection method based on MAC layer as claimed in claim 1, it is characterised in that in the first equipment self-timing
Before sending broadcast MAC frame, methods described also includes:
Set in the broadcast MAC frame that first equipment sends second equipment received corresponding to source MAC
It is standby to record source MAC when being added to device channels list.
4. a kind of attachment means based on MAC layer, it is characterised in that described device includes:
Mac frame transmitting element, broadcast MAC frame is sent for the first equipment self-timing, wherein the mac frame content is including described
The device type of first equipment, sequence number and MAC Address, can be by described first so as to receive the second equipment of the mac frame
The type of equipment judges that can the mac frame be verified by matching, the sequence number that second equipment passes through first equipment
First equipment is uniquely determined, second equipment uniquely determines described first by the MAC Address of first equipment and set
Standby position in a network;
Mac frame receiving unit, the broadcast MAC frame of the second equipment transmission is received for first equipment;
Mac frame resolution unit, the broadcast MAC frame sent for first equipment to second equipment received enter
Row parsing, device type, sequence number and the MAC Address of second equipment are obtained, so as to which first equipment can be by described
The type of second equipment judges that can the mac frame be verified by matching, the sequence that first equipment passes through second equipment
Row number uniquely determines second equipment, and first equipment uniquely determines described by the MAC Address of second equipment
The position of two equipment in a network;
Equipment adding device, for first equipment by the broadcast MAC frame of second equipment transmission received
Equipment corresponding to source MAC is added to device channels list;
Wherein, when first equipment is web camera, second equipment is network hard disk video recorder;When described first
When equipment is network hard disk video recorder, second equipment is web camera.
5. the attachment means based on MAC layer as claimed in claim 4, it is characterised in that the first equipment self-timing hair
The broadcast MAC frame is sent to be specially:
First equipment sends the broadcast MAC frame automatically at a certain time interval.
6. the attachment means based on MAC layer as claimed in claim 4, it is characterised in that described device further comprises:
Set in the broadcast MAC frame that first equipment sends second equipment received corresponding to source MAC
It is standby to record source MAC when being added to device channels list, wherein, first equipment can be web camera, then described
Second equipment is network hard disk video recorder;First equipment can also be network hard disk video recorder, then second equipment is
Web camera.
7. a kind of web camera for including the attachment means based on MAC layer, it is characterised in that described device includes:
Mac frame transmitting element, broadcast MAC frame is sent for web camera self-timing, wherein the mac frame content includes institute
The device type of web camera, sequence number and MAC Address are stated, can be led to so as to receive the network hard disk video recorder of the mac frame
The type for crossing the web camera judges that can the mac frame verify that the network hard disk video recorder passes through institute by matching
The sequence number for stating web camera uniquely determines the web camera, and the network hard disk video recorder passes through the network shooting
The MAC Address of machine uniquely determines the position of the web camera in a network;
Mac frame receiving unit, the broadcast MAC frame of the network hard disk video recorder transmission is received for the web camera;
Mac frame resolution unit, the network hard disk video recorder received is sent for the web camera wide
Broadcast mac frame to be parsed, obtain device type, sequence number and the MAC Address of the network hard disk video recorder, so as to the network
Video camera can judge that can the mac frame verify that the network is taken the photograph by matching by the type of the network hard disk video recorder
Camera uniquely determines the network hard disk video recorder by the sequence number of the network hard disk video recorder, and the web camera leads to
The MAC Address for crossing the network hard disk video recorder uniquely determines the position of the network hard disk video recorder in a network;
Equipment adding device, the broadcast MAC for sending the network hard disk video recorder received for the web camera
Equipment corresponding to source MAC is added to device channels list in frame.
8. the web camera of the attachment means based on MAC layer as claimed in claim 7, it is characterised in that the network is taken the photograph
Camera self-timing sends broadcast MAC frame:
The web camera sends the broadcast MAC frame automatically at a certain time interval.
9. a kind of network hard disk video recorder for including the attachment means based on MAC layer, it is characterised in that described device includes:
Mac frame transmitting element, broadcast MAC frame is sent for network hard disk video recorder self-timing, wherein the mac frame content bag
The device type of the network hard disk video recorder, sequence number and MAC Address are included, so as to receive the web camera of the mac frame
It can judge that can the mac frame verify that the web camera leads to by matching by the type of the network hard disk video recorder
The sequence number for crossing the network hard disk video recorder uniquely determines the network hard disk video recorder, and the web camera passes through described
The MAC Address of network hard disk video recorder uniquely determines the position of the network hard disk video recorder in a network;
Mac frame receiving unit, the broadcast MAC frame of the web camera transmission is received for the network hard disk video recorder;
Mac frame resolution unit, the broadcast MAC sent for network hard disk video recorder to the web camera received
Frame is parsed, and obtains device type, sequence number and the MAC Address of the web camera, so as to which the network hard disc is recorded a video
Machine can judge that can the mac frame be verified by matching by the type of the web camera, the network hard disk video recorder
The web camera is uniquely determined by the sequence number of the web camera, the network hard disk video recorder passes through the net
The MAC Address of network video camera uniquely determines the position of the web camera in a network;
Equipment adding device, the broadcast MAC for sending the web camera received for the network hard disk video recorder
Equipment corresponding to source MAC is added to device channels list in frame.
10. the network hard disk video recorder of the attachment means based on MAC layer as claimed in claim 9, it is characterised in that the net
Network DVR self-timing sends broadcast MAC frame:
The network hard disk video recorder sends the broadcast MAC frame automatically at a certain time interval.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410795865.1A CN104410841B (en) | 2014-12-19 | 2014-12-19 | A kind of connection method and device based on MAC layer |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410795865.1A CN104410841B (en) | 2014-12-19 | 2014-12-19 | A kind of connection method and device based on MAC layer |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104410841A CN104410841A (en) | 2015-03-11 |
CN104410841B true CN104410841B (en) | 2018-04-10 |
Family
ID=52648428
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410795865.1A Expired - Fee Related CN104410841B (en) | 2014-12-19 | 2014-12-19 | A kind of connection method and device based on MAC layer |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104410841B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105187781A (en) * | 2015-08-17 | 2015-12-23 | 浙江宇视科技有限公司 | Method and device for adding monitoring equipment automatically |
CN105959644B (en) * | 2016-06-21 | 2019-10-18 | 浙江宇视科技有限公司 | A kind of configuration method and device of video monitoring equipment |
CN108683701A (en) * | 2018-04-03 | 2018-10-19 | 浙江大华技术股份有限公司 | A kind of connection method and rear end equipment, IPC |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101027703A (en) * | 2004-08-20 | 2007-08-29 | 索尼电子有限公司 | Isochronous transmission for IP-oriented network |
CN102333132A (en) * | 2011-09-13 | 2012-01-25 | 成都华迈通信技术有限公司 | Method for automatically searching cameras and solving IP conflicts |
CN102348107A (en) * | 2011-10-27 | 2012-02-08 | 北京汉邦高科数字技术股份有限公司 | Method for realizing plug and play of network monitoring video |
CN102801798A (en) * | 2012-08-03 | 2012-11-28 | 浙江宇视科技有限公司 | Method and device for distributing IP (Internet Protocol) address |
CN103873301A (en) * | 2014-03-20 | 2014-06-18 | 浙江宇视科技有限公司 | System and method for automatically finding and adding devices |
CN103905787A (en) * | 2012-12-27 | 2014-07-02 | 广州市九安光电技术股份有限公司 | Straight connection type plug-and-play network video recorder system and realization method |
CN104105096A (en) * | 2014-07-28 | 2014-10-15 | 浙江宇视科技有限公司 | Wireless access method of internet protocol camera (IPC) devices |
CN104144230A (en) * | 2014-07-30 | 2014-11-12 | 浙江宇视科技有限公司 | Simple method and device for binding monitoring terminals |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR101336636B1 (en) * | 2013-10-08 | 2013-12-04 | 파인트론 주식회사 | Network video recorder connected through analog coaxial cable with ip camera and method automatically assigning an ip address |
-
2014
- 2014-12-19 CN CN201410795865.1A patent/CN104410841B/en not_active Expired - Fee Related
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101027703A (en) * | 2004-08-20 | 2007-08-29 | 索尼电子有限公司 | Isochronous transmission for IP-oriented network |
CN102333132A (en) * | 2011-09-13 | 2012-01-25 | 成都华迈通信技术有限公司 | Method for automatically searching cameras and solving IP conflicts |
CN102348107A (en) * | 2011-10-27 | 2012-02-08 | 北京汉邦高科数字技术股份有限公司 | Method for realizing plug and play of network monitoring video |
CN102801798A (en) * | 2012-08-03 | 2012-11-28 | 浙江宇视科技有限公司 | Method and device for distributing IP (Internet Protocol) address |
CN103905787A (en) * | 2012-12-27 | 2014-07-02 | 广州市九安光电技术股份有限公司 | Straight connection type plug-and-play network video recorder system and realization method |
CN103873301A (en) * | 2014-03-20 | 2014-06-18 | 浙江宇视科技有限公司 | System and method for automatically finding and adding devices |
CN104105096A (en) * | 2014-07-28 | 2014-10-15 | 浙江宇视科技有限公司 | Wireless access method of internet protocol camera (IPC) devices |
CN104144230A (en) * | 2014-07-30 | 2014-11-12 | 浙江宇视科技有限公司 | Simple method and device for binding monitoring terminals |
Also Published As
Publication number | Publication date |
---|---|
CN104410841A (en) | 2015-03-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103647954B (en) | Mobile video monitor system based on 3G channels Yu intelligent terminal | |
CN101488967B (en) | Video transmission method, embedded monitoring terminal and monitoring platform server | |
CN102196248B (en) | Mobile video monitoring system and method | |
CN107172443A (en) | Net cast methods, devices and systems | |
CN108124173A (en) | A kind of one-to-many throw shields display methods, system and storage medium | |
CN105491337B (en) | Network Video Surveillance Device-General cut-in method and device based on SDK level of abstraction | |
CN104539749B (en) | A kind of connection method and device based on virtual ip address | |
CN104038533B (en) | It is used for the apparatus and method for creating groups of users in communication terminal, server | |
CN107318003A (en) | A kind of monitoring device and security-protecting and monitoring method and system | |
CN102202210B (en) | Method for mobile phone to play real-time monitoring video and mobile phone to play real-time monitoring video | |
CN104113727A (en) | Monitoring video playing method, device and system | |
CN103369305B (en) | Realize the method for speech talkback synchronization and playback in video monitoring system | |
CN104410841B (en) | A kind of connection method and device based on MAC layer | |
CN101741898A (en) | Monitoring method in video-type safety-protection system | |
CN105592336A (en) | Data combined acquisition and transmission method, multiple intelligent devices, and cloud server | |
CN105282110A (en) | Mobile phone streaming media transmission method fusing GPS positioning information and system thereof | |
CN103259709A (en) | End-to-end mobile phone real-time video transmission method based on virtual private network | |
CN101262499B (en) | A remote monitoring system | |
CN104243477A (en) | Security industry data collecting method and system implemented on basis of XMPP | |
CN110290570A (en) | Wireless network access method and relevant device, storage device | |
CN107197320A (en) | Net cast methods, devices and systems | |
CN108028961A (en) | The method and apparatus that data are sent and received in communication system | |
CN101697587B (en) | Method and mobile terminal for realizing wireless video monitoring | |
CN108235111A (en) | Information sharing method and Intelligent set top box | |
CN104581036A (en) | Multi-screen control method and device for performing video and audio multi-screen display |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20180410 Termination date: 20211219 |