Summary of the invention
The invention provides a kind of things-internet gateway, comprise credible board, described credible board is inserted in the master control slot of described things-internet gateway, is connected by PCI-E bus communication with the master control board card of another slot,
After described master control board card powers up, described master control board card runs start-up loading Bootloading program, and initializes memory interface and RAM interface, be set to follower mode by described PCI-E bus driver,
The integrality of described credible board to the memory of the loading boot loader of described master control board card, operating system nucleus, operating system and main application program verifies, the CPU having verified the described master control board card of rear control continues to start, release PCI-E bus
Described master control board card has continued follow-up kernel loads, file system loads, application program loads, thus completes the startup of described master control board card.
The present invention also provides a kind of intelligent domestic system, comprises foregoing things-internet gateway, concentrator, the wireless sensor devices in each room and client, and node communication equipment.
In the present invention, credible board in things-internet gateway is connected by PCI-E bus communication with master control board card, when PCI-E bus is set to follower mode by master control board card, credible board can verify master control board card, thus realize the credible startup of initiatively board, ensure that the credibility of things-internet gateway.
Embodiment
The embodiment of the present invention provides a kind of things-internet gateway, in the present embodiment, things-internet gateway is the nucleus equipment of intelligent domestic system, possesses the management of home wireless internet of things equipment, Intelligent housing, the function of sensor data fusion, storage and initial analysis process, and realize the information interaction with domestic household according to analysis processing result by client.
See Fig. 1, things-internet gateway 101 comprises credible board 1011, and credible board 1011 is inserted in the master control slot of things-internet gateway 101, is connected by PCI-E bus communication with the master control board card 1012 of another slot,
After master control board card 1012 powers up, master control board card 1012 runs start-up loading (Bootloading) program, and initializes memory interface and RAM interface, be set to follower mode by PCI-E bus driver.
The integrality of the memory being loaded with boot loader of credible board 1011 pairs of master control board cards 1012, operating system nucleus, operating system and main application program verifies, the CPU having verified rear control master control board card 1012 continues to start, release PCI-E bus.
Master control board card 1012 has continued follow-up kernel loads, file system loads, application program loads, thus completes the startup of master control board card 1012.
In embodiments of the present invention, credible board 1011 in things-internet gateway 101 is connected by PCI-E bus communication with master control board card 1012, when PCI-E bus is set to follower mode by master control board card 1012, credible board 1011 can verify master control board card 1012, thus realize the credible startup of initiatively board 1012, ensure that the credibility of things-internet gateway.
The embodiment of the present invention also provides another kind of things-internet gateway, see Fig. 2, in the present embodiment, things-internet gateway not only comprises the credible board 1011 and master control board card 1012 that describe in an as above embodiment, things-internet gateway also comprises network communication module, in the present embodiment, be described in detail to the network service flow process of things-internet gateway.
201, network communication module judge things-internet gateway whether with client in same local area network (LAN),
Intelligent domestic system can pass through local area network access control, also can be controlled by wide-area network access.Network communication module in things-internet gateway judge things-internet gateway whether with client in same local area network (LAN), then to conduct interviews control according to judged result.
Network communication module can pass through User Datagram Protoco (UDP) (UDP, User Datagram Protocol) issue the broadcast of local area network (LAN), if client receives, network communication module then judges that things-internet gateway and client are in same local area network (LAN), and udp port is 5000.
202, if so, client is directly communicated mutually by local area network (LAN) with things-internet gateway,
The judged result of step 201 be things-internet gateway and client in same local area network (LAN), then perform step 202, client is directly communicated mutually by local area network (LAN) with things-internet gateway,
203, if not, client is communicated mutually by wide area network with things-internet gateway.
The judged result of step 201 be things-internet gateway and client not in same local area network (LAN), then perform step 203, client is communicated mutually by wide area network with things-internet gateway.
Client is communicated mutually by wide area network with the network communication module in things-internet gateway, be specially: communication initiator first accesses the Cloud Server in wide area network, trigger Cloud Server and set up data channel, the data channel accessing communication recipient of communication initiator by setting up.
Or, client is communicated mutually by wide area network with the network communication module in things-internet gateway, be specially: by easily extensible communication and presentation protocol (XMPP, Extensible Messaging and Presence Protocol), session negotiation passage (Session Negotiation Channel) is set up between communication initiator and Cloud Server, communication initiator is by the Cloud Server in session negotiation channel access wide area network, trigger Cloud Server and set up data channel, the data channel accessing communication recipient of communication initiator by setting up.
Session negotiation passage (Session Negotiation Channel) is the ditch circulation passage for data connection service, session negotiation passage is used to request one connection, exchanges candidate scheme and consulting session details (coding of such as socket addresses, needs, the file of exchange, is connected change request and stop asking), this Article 1 being things-internet gateway and client are set up with Cloud Server separately links, and only has this link to be successfully established and just can set up data channel (Data Channel) between things-internet gateway and client.Data channel transmits the passage of real data (audio frequency, video, file etc.) between things-internet gateway and client, the data transmitted are by TCP or UDP encapsulating dress, which kind of mode of concrete use is relevant with the result of consulting, these data are not through XMPP server, can be forwarded by RELAY server when the direct-connected mode of P2P cannot be set up, real-time video code stream does not forward.
The message that network communication module communicates with HA_Daemon with clientAdmin is JSON form, is also JSON form with the message of Video_Daemon 5011 port communication, with Video_Daemon 5012 port communication be H264 code stream.
Network communication module is connected to the data in the 5002 port accepts ZigBee-networks of HA_Daemon, then sends to the client connected through wide area network.It should be noted that, in the present embodiment, the transducer in intelligent domestic system is based on ZigBee-network Node configuration.
Network communication module should keep long with HA_Daemon and be connected, and within every 5 seconds, sends out a heartbeat packet, connects 5002 ports being disconnected and needing to reconnect HA_Daemon if long.
Network communication module is connected to 5012 ports of Video_Daemon, receives the real-time video code stream of web camera, then sends to the client connected through wide area network P2P, does not forward real-time video code stream for the client connected by RELAY mode.
Network communication module is connected to 5016 ports of clientAdmin_Daemon, receives the announcement information that user login information changes, and then issues the client connected through wide area network.
Network communication module needs 5003 ports of a monitoring TCP, receives the message such as pattern, room, list of devices that HA_Daemon pushes.
Network communication module needs 5013 ports of a monitoring TCP, receives the message such as another name, password that clientAdmin cgi pushes.
HA_Daemon, Video_Daemon, clientAdmin_Daemon, clientAdmin cgi mentioned in the present embodiment is the usual vocabulary of this area.
Network communication module can also be used for resolving http protocol, provides CGI(Common gateway interface) (CGI, Common Gateway Interface) to support.Client and network communication module are by the 5001 port communication control ZigBee sensor terminals of CGI and HA_Daemon, by the 5011 port communication net control video camera IPC of CGI and Video_Daemon, logged in by CGI and clientAdmin Control on Communication user.When client sends a GET request, network communication module runs corresponding cgi script, and operation result is returned to client by http response.
As shown in Figure 3, the embodiment of the present invention also provides a kind of intelligent domestic system, and this intelligent domestic system comprises things-internet gateway 301, concentrator 302, the wireless sensor devices 303 in each room and client 304, and node communication equipment 305.Things-internet gateway 301 in the present embodiment can adopt the gateway in embodiment as shown in Figure 1, also can adopt the things-internet gateway of embodiment as shown in Figure 2.
A kind of things-internet gateway provided the embodiment of the present invention above and intelligent domestic system are described in detail, for one of ordinary skill in the art, according to the thought of the embodiment of the present invention, all will change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.