CN115865743A - Device and method for realizing network connectivity detection of fusion type set top box - Google Patents

Device and method for realizing network connectivity detection of fusion type set top box Download PDF

Info

Publication number
CN115865743A
CN115865743A CN202211469209.3A CN202211469209A CN115865743A CN 115865743 A CN115865743 A CN 115865743A CN 202211469209 A CN202211469209 A CN 202211469209A CN 115865743 A CN115865743 A CN 115865743A
Authority
CN
China
Prior art keywords
top box
network
unit
level signal
set top
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
CN202211469209.3A
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.)
Sichuan Tianyi Comheart Telecom Co Ltd
Original Assignee
Sichuan Tianyi Comheart Telecom 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 Tianyi Comheart Telecom Co Ltd filed Critical Sichuan Tianyi Comheart Telecom Co Ltd
Priority to CN202211469209.3A priority Critical patent/CN115865743A/en
Publication of CN115865743A publication Critical patent/CN115865743A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention belongs to the technical field of wireless communication, in particular to a device and a method for realizing network connectivity detection of a fusion type set top box; the method is characterized in that a gateway unit CPU is directly connected with a GPIO of a set-top box unit CPU, namely a virtual network card is simulated on a hardware level, a Linux kernel interrupt mechanism is combined to connect an input signal of the virtual network card with a network card interrupt number of a real network card of the set-top box unit, when the GPIO input signal is changed, the network card of the set-top box unit is disconnected, a kernel network interrupt mechanism is triggered, an Android system is informed through a kernel, and the kernel is further associated with a network management mechanism of the Android system; therefore, the current network change condition can be judged in time based on the application developed by the Android network mechanism.

Description

Device and method for realizing network connectivity detection of fusion type set top box
Technical Field
The invention belongs to the technical field of wireless communication, and particularly relates to a device and a method for realizing network connectivity detection of a fusion type set top box.
Background
The network of the set-top box unit is connected with the gateway unit and is directly communicated physically, and no physical independent interface exists externally; the set-top box unit cannot physically sense the network cable plugging or the optical fiber plugging of the gateway unit, and the gateway unit is required to inform the set-top box unit after detecting the network change condition; the network is the basis for realizing all other functions, so that the situation that the gateway unit informs the set-top box unit of the network change becomes a key and important technology, and the currently adopted technical scheme mainly comprises the following two modes:
1. through the ping mode, namely through the IP address or the domain name address appointed by ping, when the ping passes through the address, the network is considered to be passed; however, when this method is used, the ping address really exists, and if the IP or domain name fails in the using process, or if the IP and domain name address start to ping after being used for a while, the network state cannot be correctly judged by using the above method.
2. The network card two-layer data exchange mode is characterized in that the network card of the set top box unit is connected with the network card of the gateway unit, data transmission between the network card of the set top box unit and the network card of the gateway unit is completed through two-layer data exchange by using a socket, and the communication state of a network is informed; although network state data transmission can be completed through socket communication, data errors or delay can occur in the data transmission process, and certain influence is exerted on the accuracy and timeliness of network state judgment of the set top box unit. The most important point is that the mode is realized through an application layer, cannot be associated with a network mechanism of an Android system, and cannot trigger a network broadcast notification mechanism of the Android system.
Based on the above, there is a certain limitation to the sensing of the network state of the set-top box at present.
Disclosure of Invention
In order to solve the technical problems in the prior art, the invention provides a device and a method for realizing network connectivity detection of a fusion type set top box, aiming at solving the problem that the existing detection mode cannot correctly judge the network state.
In order to solve the technical problems, the technical scheme adopted by the invention is as follows:
a device for realizing network connectivity detection of a fusion type set top box comprises a set top box unit and a gateway unit, wherein a GPIO (general purpose input/output) interface of a CPU (central processing unit) of the gateway unit is used as an output port to be connected with a GPIO interface of the CPU of the set top box unit, and the set top box unit converts received high and low level signals into corresponding network state data.
The invention discloses a method for realizing network connectivity detection of a fusion set top box, which adopts the device to detect the network connectivity of the fusion set top box and comprises the following steps:
the gateway unit detects a network state, outputs a level signal to the set-top box unit based on the network state, and the set-top box unit judges whether the received level signal is a high level signal or a low level signal, and triggers a kernel interrupt mechanism to disconnect network connection if the received level signal is the low level signal; if the signal is high level, triggering a kernel interrupt mechanism to start network connection.
Further, when the gateway unit is just started, the system is initialized, if the gateway unit does not access a network cable or an optical fiber at the moment, no level signal is output by the gateway unit, and the GPIO port of the set-top box unit does not detect the change of the level signal, the kernel interrupt mechanism is triggered to disconnect the network connection; if the gateway unit is connected with the network cable or the optical fiber and is in a network state, the gateway unit outputs high level, and the set-top box unit triggers a kernel interrupt mechanism to start network connection after receiving the high level signal.
The beneficial effects of the invention include:
the method is characterized in that a gateway unit CPU is directly connected with a GPIO of a set-top box unit CPU, namely a virtual network card is simulated on a hardware level, a Linux kernel interrupt mechanism is combined to connect an input signal of the virtual network card with a network card interrupt number of a real network card of the set-top box unit, when the GPIO input signal is changed, the network card of the set-top box unit is disconnected, a kernel network interrupt mechanism is triggered, an Android system is informed through a kernel, and the kernel is further associated with a network management mechanism of the Android system; therefore, the current network change condition can be judged in time based on the application developed by the Android network mechanism. In addition, the method and the device utilize an interrupt response mechanism of the Linux kernel to quickly and accurately respond to the plugging and unplugging condition of the network cable or the optical fiber of the gateway unit and the change of the network state.
Drawings
FIG. 1 is a logic diagram of an implementation of the present invention.
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 embodiments of the present application, generally described and illustrated in the figures herein, may 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 invention is described in further detail below with reference to the accompanying drawing 1:
a device for realizing network connectivity detection of a fusion type set top box comprises a set top box unit and a gateway unit, wherein a GPIO (general purpose input/output) interface of a CPU (central processing unit) of the gateway unit is used as an output port to be connected with the GPIO interface of the CPU of the set top box unit, and the set top box unit converts received high and low level signals into corresponding network state data.
The GPIO interface of the CPU of the designated gateway unit is connected with the GPIO interface of the CPU of the set-top box unit, the GPIO interface of the CPU of the gateway unit is set to be in an output mode, the GPIO interface of the CPU of the set-top box unit is set to be in an input mode, the initialization of the gateway unit is completed in the process of powering on and starting the fusion type set-top box, the designated GPIO interface is pulled up and output at a high level after the network work is ready, the GPIO interface of the set-top box unit receives the input high level, the network is considered ready, and the system informs a kernel of starting the network connection work. If the network cable or the optical fiber of the gateway unit is not accessed in the starting-up stage, the GPIO interface of the set-top box unit has no level input, and the network part is always in a disconnected state;
when the fusion type set top box is used, a network cable or an optical fiber of the gateway unit is unplugged, the GPIO immediately outputs low level after the gateway unit detects that the network is disconnected, and the set top box unit informs a system kernel of network disconnection after detecting that the low level is input, and the kernel performs network disconnection operation. After the network cable or the optical fiber is accessed, the GPIO immediately outputs high level after the gateway unit detects that the network connection is successful, and the set-top box unit informs the kernel network of the system of being connected after detecting that the high level is input, and restarts the network connection operation.
Based on the technical scheme, the GPIO of the gateway unit CPU and the set-top box unit CPU is directly connected, namely a virtual network card is simulated on a hardware layer, a Linux kernel interrupt mechanism is combined to connect the input signal of the virtual network card with the network card interrupt number of the real network card of the set-top box unit, when the GPIO input signal is changed, the operation of disconnecting the network card of the set-top box unit is realized, then the kernel network interrupt mechanism is triggered, the Android system is informed through the kernel, and the kernel is further associated with the network management mechanism of the Android system; therefore, the current network change condition can be judged in time based on the application developed by the Android network mechanism. In addition, the method and the device utilize an interrupt response mechanism of the Linux kernel to quickly and accurately respond to the plugging and unplugging condition of the network cable or the optical fiber of the gateway unit and the change of the network state.
Referring to fig. 1, a method for implementing network connectivity detection of a fusion-type set top box includes the following specific implementation methods:
the fusion type set top box is powered on and started, the set top box unit is started before the gateway unit, and the network card of the set top box unit is ready;
the gateway unit is started and network preparation is successful, and the gateway unit CPU outputs high level through the GPIO interface of the gateway unit CPU;
the GPIO interface of the CPU of the set-top box unit receives the high-level signal to trigger the network card to be interrupted, and the kernel responds to an interruption mechanism to inform the system of starting network connection.
If the network cable or the optical fiber of the gateway unit is not accessed in the system starting stage, the GPIO interface of the CPU of the set-top box unit cannot detect the change of the level signal, and the network is considered to be in a disconnected state;
when a network cable or an optical fiber is unplugged, the gateway unit detects that the network connection is disconnected, the GPIO interface of the CPU of the gateway unit outputs a low level signal, and the level of the GPIO interface of the CPU of the set top box unit is pulled down, so that the detected signal is changed, the network card is triggered to be interrupted, and the kernel responds to an interruption mechanism to inform the system of network disconnection operation.
When the fusion type set top box is used, after a network cable or an optical fiber is accessed, the gateway unit detects that the network connection is successful, the GPIO immediately outputs high level, and after the set top box unit detects that the high level is input, the set top box unit informs a system kernel network that the network is connected and restarts the network connection operation.
According to the invention, data is analyzed and processed by the kernel of the set top box unit, the GPIO interface of the CPU of the set top box unit receives the change of the level signal so as to generate an interrupt, the interrupt is sent to the CPU of the set top box unit by the interrupt controller, and the GPIO interface is self-defined, so that the CPU of the set top box unit cannot make any response according to the signal received by the GPIO interface, therefore, the high level and low level signals received by the GPIO interface of the CPU of the set top box unit are associated with network interrupt or network connection, so that the plugging condition of a network cable or an optical fiber of the gateway unit and the change of the network state are responded quickly and accurately.
The above-mentioned embodiments only express the specific embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for those skilled in the art, without departing from the technical idea of the present application, several changes and modifications can be made, which are all within the protection scope of the present application.

Claims (3)

1. A device for realizing network connectivity detection of a fusion type set top box comprises a set top box unit and a gateway unit, and is characterized in that a GPIO interface of a gateway unit CPU is used as an output port to be connected with the GPIO interface of the set top box unit CPU, and the set top box unit converts the received high and low level signals into corresponding network state data.
2. A method for detecting network connectivity of a convergence set-top box, wherein the step of detecting network connectivity of the convergence set-top box by using the apparatus of claim 1 is as follows:
the gateway unit detects a network state, outputs a level signal to the set-top box unit based on the network state, and the set-top box unit judges whether the received level signal is a high level signal or a low level signal, and triggers a kernel interrupt mechanism to disconnect network connection if the received level signal is the low level signal; if the signal is high level, triggering a kernel interrupt mechanism to start network connection.
3. The method for realizing network connectivity detection of the fusion type set top box according to claim 2, wherein when the gateway unit is just started, the system is initialized, if the gateway unit does not access the network cable or the optical fiber at the moment, no level signal is output from the gateway unit, and the GPIO port of the set top box unit does not detect the change of the level signal, the kernel interrupt mechanism is triggered to disconnect the network connection; if the gateway unit is connected with the network cable or the optical fiber and is in a network state, the gateway unit outputs high level, and the set-top box unit triggers a kernel interrupt mechanism to start network connection after receiving the high level signal.
CN202211469209.3A 2022-11-22 2022-11-22 Device and method for realizing network connectivity detection of fusion type set top box Pending CN115865743A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211469209.3A CN115865743A (en) 2022-11-22 2022-11-22 Device and method for realizing network connectivity detection of fusion type set top box

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211469209.3A CN115865743A (en) 2022-11-22 2022-11-22 Device and method for realizing network connectivity detection of fusion type set top box

Publications (1)

Publication Number Publication Date
CN115865743A true CN115865743A (en) 2023-03-28

Family

ID=85665069

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211469209.3A Pending CN115865743A (en) 2022-11-22 2022-11-22 Device and method for realizing network connectivity detection of fusion type set top box

Country Status (1)

Country Link
CN (1) CN115865743A (en)

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070294738A1 (en) * 2006-06-16 2007-12-20 Broadcom Corporation Single chip cable set-top box supporting DOCSIS set-top Gateway (DSG) protocol and high definition advanced video codec (HD AVC) decode
WO2011113349A1 (en) * 2010-03-16 2011-09-22 华为终端有限公司 Power management method and apparatus of a network access module
CN102664766A (en) * 2012-04-12 2012-09-12 Tcl王牌电器(惠州)有限公司 Detection device and detection method of network port
CN103078663A (en) * 2012-12-31 2013-05-01 上海斐讯数据通信技术有限公司 Energy-saving network equipment
US20130163437A1 (en) * 2011-12-22 2013-06-27 Hon Hai Precision Industry Co., Ltd. Network card detecting circuit
CN103298013A (en) * 2013-06-24 2013-09-11 京信通信系统(中国)有限公司 Service restoration method and device
CN105208438A (en) * 2015-09-24 2015-12-30 深圳市九洲电器有限公司 Function switching circuit and gateway type set top box
CN105282577A (en) * 2015-10-19 2016-01-27 安徽广行物联科技有限公司 Smart home set top box
CN105429867A (en) * 2014-09-19 2016-03-23 中国移动通信集团公司 Fused type home gateway and access method of application service thereof
WO2016184049A1 (en) * 2015-05-19 2016-11-24 深圳市中兴微电子技术有限公司 Method and device for detecting network port insertion, terminal and storage medium
CN107396183A (en) * 2017-07-20 2017-11-24 烽火通信科技股份有限公司 The start network detecting method and system of convergent terminal equipment
CN209402541U (en) * 2019-03-05 2019-09-17 广州视源电子科技股份有限公司 Data transmission device and equipment
CN112399211A (en) * 2019-08-14 2021-02-23 青岛海信宽带多媒体技术有限公司 Operation method and convergence gateway

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070294738A1 (en) * 2006-06-16 2007-12-20 Broadcom Corporation Single chip cable set-top box supporting DOCSIS set-top Gateway (DSG) protocol and high definition advanced video codec (HD AVC) decode
WO2011113349A1 (en) * 2010-03-16 2011-09-22 华为终端有限公司 Power management method and apparatus of a network access module
US20130163437A1 (en) * 2011-12-22 2013-06-27 Hon Hai Precision Industry Co., Ltd. Network card detecting circuit
CN102664766A (en) * 2012-04-12 2012-09-12 Tcl王牌电器(惠州)有限公司 Detection device and detection method of network port
CN103078663A (en) * 2012-12-31 2013-05-01 上海斐讯数据通信技术有限公司 Energy-saving network equipment
CN103298013A (en) * 2013-06-24 2013-09-11 京信通信系统(中国)有限公司 Service restoration method and device
CN105429867A (en) * 2014-09-19 2016-03-23 中国移动通信集团公司 Fused type home gateway and access method of application service thereof
WO2016184049A1 (en) * 2015-05-19 2016-11-24 深圳市中兴微电子技术有限公司 Method and device for detecting network port insertion, terminal and storage medium
CN106294057A (en) * 2015-05-19 2017-01-04 深圳市中兴微电子技术有限公司 Detection method, device and the terminal that a kind of network interface inserts
CN105208438A (en) * 2015-09-24 2015-12-30 深圳市九洲电器有限公司 Function switching circuit and gateway type set top box
CN105282577A (en) * 2015-10-19 2016-01-27 安徽广行物联科技有限公司 Smart home set top box
CN107396183A (en) * 2017-07-20 2017-11-24 烽火通信科技股份有限公司 The start network detecting method and system of convergent terminal equipment
CN209402541U (en) * 2019-03-05 2019-09-17 广州视源电子科技股份有限公司 Data transmission device and equipment
CN112399211A (en) * 2019-08-14 2021-02-23 青岛海信宽带多媒体技术有限公司 Operation method and convergence gateway

Similar Documents

Publication Publication Date Title
US9366712B2 (en) Determination of physical connectivity status of devices based on electrical measurement
US9864607B2 (en) Methods and physical computer-readable storage media for initiating re-enumeration of USB 3.0 compatible devices
US20120023278A1 (en) Expander to control multipaths in a storage network
US8260977B2 (en) CEC communications device, audio and visual device using thereof, and CEC communications method
WO2019210681A1 (en) Smart tablet, channel switching method, and computer readable storage medium
CN111581144B (en) Vehicle-mounted camera hot-plug self-recovery method and device and storage medium
WO2022105448A1 (en) Method and system for maintaining pcie signal connection by using in-place signal, device, and medium
CN102355380A (en) Hardware testing device and method for synchronous asynchronous serial interface
US20200136912A1 (en) Method, Device, and System for Implementing MUX Machine
WO2020088351A1 (en) Method for sending device information, computer device and distributed computer device system
US5379437A (en) Reset of peripheral printing devices after a hot plug state
CN111417034B (en) Switch and hot plug method, device and system for switch board card thereof
CN104536853B (en) A kind of device ensureing dual controller storage device resource continuous availability
CN115865743A (en) Device and method for realizing network connectivity detection of fusion type set top box
CN116137603B (en) Link fault detection method and device, storage medium and electronic device
CN104850203A (en) Electronic apparatus reset method and electronic apparatus
US9825901B2 (en) Method, device, and system for acquiring internet protocol address
CN101136756A (en) Electric self-checking method, system and BMC chip on network long-range control host machine
CN115509333A (en) Server collaborative power-on and power-off device, method, system and medium
US11334506B2 (en) Interface connection device, system and method thereof
CN104850522B (en) A kind of signal output method and device
CN108809756B (en) Communication method of photoelectric conversion module under linux system and related product
JP2518514B2 (en) Automatic fault detection system
CN100549930C (en) Know method and network element device that disk is pulled out
CN112217717A (en) Network switching method and system based on dual-computer hot standby

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