Home gateway upgrading method and device and storage medium
By configuring multicast upgrade logos and displaying the upgrade status in the home gateway, the problem of long start time and unintuitive upgrade status of the home gateway is solved, and the convenience of user experience and problem troubleshooting is improved.
Patent Information
- Application Number
- CN202411270849.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-11
- Publication Date
- 2025-02-07
AI Technical Summary
The existing home gateway needs to detect multicast upgrades when starting, resulting in longer startup time of the device, poor user experience, and lack of intuitive upgrade status display, affecting usage and problem troubleshooting.
By presetting the multicast upgrade configuration program and multicast upgrade program in the home gateway, configure the multicast upgrade identifier based on whether it is currently in the production area, determine whether it enters the multicast upgrade process when the gateway is started, and displays the upgrade status through the LED indicator light .
It reduces the device startup time during normal use of users, and displays the upgrade status through intuitive LED indicators, improving the convenience of user experience and problem-solving.
Smart Images

Figure CN119402771A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to network communication technology, and in particular to a method, device and storage medium for upgrading a home gateway. Background Art
[0002] With the rapid development of Internet broadband and the popularization of broadband of various operators, home gateways, as broadband access devices, provide users with a variety of business functions such as Internet, IPTV, VOIP, etc. Multicast upgrade is an important method for upgrading home gateway software and an important means of repairing application system failures and failure to start. It only requires configuring a computer to upgrade, and with the addition of a switch, batch upgrades can be achieved. Therefore, it is widely used for emergency upgrades in production plants or warehouses.
[0003] Since the current gateway multicast upgrade is mainly implemented in the boot phase, it is necessary to detect the network connection status of the gateway and confirm whether there is a multicast message, which will cause the following problems: (1) The multicast upgrade is detected each time in the boot phase, which increases the startup time by an average of 10 seconds. During the normal use of the gateway by users, each multicast upgrade will cause the device startup time to increase and the user experience to deteriorate; (2) During the multicast upgrade process, there is no intuitive and effective means to display the upgrade status to the user, which is not conducive to use and problem troubleshooting. Summary of the invention
[0004] The technical problem to be solved by the present invention is: to propose a home gateway upgrade method, device and storage medium to reduce the device startup time during normal user use, and further solve the problem that the upgrade status is not intuitively displayed to the user, which is not conducive to use and problem troubleshooting.
[0005] The technical solution adopted by the present invention to solve the above technical problems is:
[0006] On the one hand, the present invention provides a method for upgrading a home gateway, which is applied to a home gateway, wherein a multicast upgrade configuration program and a multicast upgrade program are pre-installed in the home gateway, wherein the multicast upgrade program is placed in a gateway startup program; the method comprises the following steps:
[0007] The multicast upgrade configuration program configures the multicast upgrade identifier accordingly according to whether the home gateway is currently in the production area;
[0008] In the boot phase of the gateway, the multicast upgrade program determines whether to enter the multicast upgrade process based on the current multicast upgrade flag; if it is determined not to enter the multicast upgrade process, the gateway is started normally;
[0009] If it is determined to enter the multicast upgrade process, the Ethernet port status is first detected. If all Ethernet ports are not connected within T1 time, the multicast upgrade process is exited and the gateway is started normally; if any Ethernet port is connected within T1 time, the multicast message detection stage is entered;
[0010] In the multicast message detection phase, if no message is detected within T2 time, the multicast upgrade process is exited and the gateway is started normally; otherwise, the multicast message is received and verified, and after the verification is successful, the data is written to the flash of the gateway.
[0011] Furthermore, the multicast upgrade configuration program determines whether the home gateway is currently in the production area in the following ways:
[0012] The multicast upgrade configuration program reads the value in the area control identification field Area_code in the gateway memory to determine whether the gateway is currently in the production area. If the value in Area_code is 0, it is determined that it is currently in the production area, otherwise, it is determined that it is currently in the non-production area.
[0013] Furthermore, the multicast upgrade configuration program configures the multicast upgrade identifier accordingly, including:
[0014] If the home gateway is currently in the production area, configure the multicast upgrade flag to 1 to enable the multicast upgrade function; if the home gateway is currently in the non-production area and the network time of the gateway device is synchronized, configure the multicast upgrade flag to 0 to disable the multicast upgrade function; if the home gateway is currently in the non-production area and the network time of the gateway device is not synchronized, keep the multicast upgrade flag in its original state and retain the multicast upgrade function.
[0015] Furthermore, the multicast upgrade program determines whether to enter the multicast upgrade process according to the current multicast upgrade flag, including:
[0016] If the current multicast upgrade flag is 1, the multicast upgrade process is entered. If the current multicast upgrade flag is 0, the multicast upgrade process is not entered and the gateway is started normally.
[0017] Furthermore, receiving a multicast message refers to receiving an upgrade file sent by an upgrade server through a multicast protocol.
[0018] Furthermore, the home gateway is also provided with a forced upgrade button. During the boot phase of the gateway startup, if the multicast upgrade program detects that the forced upgrade button is triggered, the multicast upgrade process is automatically entered.
[0019] Furthermore, the home gateway is also provided with an LED indicator light for indicating the multicast upgrade status, and the method also includes: in the process of receiving multicast messages, controlling the LED indicator light to flash slowly; in the process of writing data into the flash of the gateway, controlling the LED indicator light to flash quickly; after writing into the flash is completed, controlling the LED indicator light to be always on.
[0020] In a second aspect, the present invention further provides a home gateway upgrading device, which includes a processor and a memory, wherein the memory stores a computer program, and the processor implements the steps of the above method by executing the computer program.
[0021] In a third aspect, the present invention further provides a storage medium having a computer program stored thereon, which implements the steps of the above method when the computer program is executed by a processor.
[0022] The beneficial effects of the present invention are:
[0023] The multicast upgrade configuration program configures the multicast upgrade flag accordingly according to whether the gateway is currently in the production area. For the production area, the multicast upgrade flag is set to 1. For the non-production area, if the network time is synchronized, the multicast upgrade flag is set to 0. If the network time is not synchronized, the upgrade flag is retained as 1. On this basis, in the boot phase of the gateway, the multicast upgrade program can determine whether to enter the multicast upgrade process based on the multicast upgrade flag.
[0024] For the normal user use stage, since the multicast upgrade flag is configured as 0, the network connection status and multicast message detection can be skipped during the boot stage of the gateway startup, and the device can be started normally directly, thereby reducing the device startup time during normal user use.
[0025] Furthermore, during the multicast upgrade process, this solution indicates the upgrade status through an LED indicator light, thereby intuitively showing the user the current multicast upgrade status of the home gateway.
[0026] Finally, in addition to automatically determining whether to enter the multicast upgrade process, this solution also provides a forced multicast upgrade function, that is, by detecting whether the forced upgrade button is triggered to determine whether to enter the multicast upgrade process, which has strong flexibility in use. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 This is a flow chart of a method for upgrading a home gateway in an embodiment of the present invention. DETAILED DESCRIPTION
[0028] The present invention aims to provide a method, device and storage medium for upgrading a home gateway, so as to reduce the device startup time during normal use by users, and further solve the problem that the upgrade status is not intuitively displayed to users, which is not conducive to use and troubleshooting. The core idea is to judge the current scene of the gateway, that is, to judge whether it is in the production area. If it is not in the production area, it is determined to be a customer application scene, and the corresponding multicast upgrade flag is automatically set. In the boot phase of the gateway startup, the multicast upgrade program determines whether to enter the multicast upgrade process according to the current multicast upgrade flag; then for the home gateway in the customer application scene, it can be directly determined according to the upgrade flag that the gateway does not enter the multicast upgrade process, and the detection of the network connection status and multicast message can be directly skipped, and the gateway can be directly started normally, thereby reducing the boot time. In addition, for the home gateway in the customer application scene, if a multicast upgrade is required, it can be triggered by a forced upgrade button. During the multicast upgrade process, the upgrade status is indicated by an LED indicator, so as to intuitively show the current multicast upgrade status of the home gateway to the user.
[0029] Example
[0030] The home gateway upgrade method provided in this embodiment is applied to the home gateway, wherein the home gateway is pre-installed with a multicast upgrade configuration program and a multicast upgrade program, wherein the multicast upgrade program is placed in the gateway startup program; the method flow is referred to in Figure 1 , which includes the following implementation steps:
[0031] S1. Configure the multicast upgrade flag;
[0032] In this step, the multicast upgrade configuration program configures the multicast upgrade identifier accordingly according to whether the home gateway is currently in the production area. The multicast upgrade configuration program shares information with the multicast upgrade program under boot in the home gateway application system by sharing flash storage.
[0033] In an exemplary scheme, the gateway's area control identification field Area_code is stored in the gateway's memory. The value of 0 corresponds to the production mode, that is, the gateway is in the production area; the value of non-0 corresponds to the non-production mode (customer mode), that is, the gateway is in the non-production area.
[0034] Therefore, the multicast upgrade configuration program can determine whether the current area is in the production area by reading the value of Area_code, and then configure the multicast upgrade identification field mc_upgrade in the following way:
[0035] If you are in the production area, configure the value of mc_upgrade to 1 to enable the multicast upgrade function.
[0036] If it is in a non-production area, check whether the device network time is synchronized. If so, read the multicast upgrade flag. If the value of mc_upgrade is not 0, configure mc_upgrade to 0, indicating that the multicast upgrade function is disabled. If the value of mc_upgrade is already 0, do nothing to avoid the potential risks caused by frequent flash writes.
[0037] If the time is not synchronized, it means that the device has not been officially used yet and no processing is performed. In this case, the value of mc_upgrade is still 1, that is, the multicast upgrade function is retained.
[0038] S2: In the boot phase of the gateway, determine whether to enter the multicast upgrade process according to the multicast upgrade flag;
[0039] In this step, during the boot phase of the gateway startup, the multicast upgrade program determines whether to enter the multicast upgrade process based on the current multicast upgrade flag: if the value of the current multicast upgrade flag mc_upgrade is 1, the multicast upgrade process is automatically entered; if the value of the current multicast upgrade flag mc_upgrade is 0, it means that the multicast upgrade process is not entered, and the gateway starts normally. There is no need to judge the network connection status and detect multicast messages, thereby achieving rapid startup of the gateway.
[0040] In addition, the gateway will cyclically detect whether there is a trigger signal of the forced upgrade button. If it is detected, it means that multicast upgrade is required, and the multicast upgrade process will be entered.
[0041] S3, network port status detection, message detection, data download and write under the multicast upgrade process;
[0042] In this step, in the multicast upgrade process, first check the status of the Ethernet port; if all network ports are not connected within T1, exit the multicast upgrade and enter normal startup. If any network port is connected within T1, enter the multicast message detection stage; if no message is detected within T2, exit the multicast upgrade and enter normal startup. If a multicast message is detected within T2, receive the message normally; after receiving the message, enter data verification; if the verification is successful, write the received program to the flash. In order to let the user see the upgrade status more intuitively, a two-color LED indicator can be used to indicate the upgrade status, for example: the indicator light flashes green slowly during the message reception process, the indicator light flashes green quickly during the process of writing the received program to the flash, and the indicator light is always green after the data is written to the flash; in any other error state, the indicator light is always red.
[0043] Finally, it should be noted that the above embodiments are only preferred implementations and are not intended to limit the present invention. It should be pointed out that for those skilled in the art, several modifications, equivalent replacements, improvements, etc. can be made without departing from the scope of the present invention and the scope of protection of the claims, and all of these should be included in the protection scope of the present invention.
Claims
1. A method for upgrading a home gateway, applied to a home gateway, characterized in that: The home gateway is pre-installed with a multicast upgrade configuration program and a multicast upgrade program, wherein the multicast upgrade program is placed in the gateway startup program; the method comprises the following steps: The multicast upgrade configuration program configures the multicast upgrade identifier accordingly according to whether the home gateway is currently in the production area; In the boot phase of the gateway, the multicast upgrade program determines whether to enter the multicast upgrade process based on the current multicast upgrade flag; if it is determined not to enter the multicast upgrade process, the gateway is started normally; If it is determined to enter the multicast upgrade process, the Ethernet port status is first detected. If all Ethernet ports are not connected within T1 time, the multicast upgrade process is exited and the gateway is started normally; if any Ethernet port is connected within T1 time, the multicast message detection stage is entered; In the multicast message detection phase, if no message is detected within T2 time, the multicast upgrade process is exited and the gateway is started normally; otherwise, the multicast message is received and verified, and after the verification is successful, the data is written to the flash of the gateway.
2. A method for upgrading a home gateway as claimed in claim 1, characterized in that: The multicast upgrade configuration program determines whether the home gateway is currently in the production area in the following ways: The multicast upgrade configuration program reads the value in the area control identification field Area_code in the gateway memory to determine whether the gateway is currently in the production area. If the value in Area_code is 0, it is determined that it is currently in the production area, otherwise, it is determined that it is currently in the non-production area.
3. A method for upgrading a home gateway as claimed in claim 1, characterized in that: The multicast upgrade configuration program configures the multicast upgrade flag accordingly, including: If the home gateway is currently in the production area, configure the multicast upgrade flag to 1 to enable the multicast upgrade function; if the home gateway is currently in the non-production area and the network time of the gateway device is synchronized, configure the multicast upgrade flag to 0 to disable the multicast upgrade function; if the home gateway is currently in the non-production area and the network time of the gateway device is not synchronized, keep the multicast upgrade flag in its original state and retain the multicast upgrade function.
4. A method for upgrading a home gateway as claimed in claim 3, characterized in that: The multicast upgrade program determines whether to enter the multicast upgrade process according to the current multicast upgrade flag, including: If the current multicast upgrade flag is 1, the multicast upgrade process is entered. If the current multicast upgrade flag is 0, the multicast upgrade process is not entered and the gateway is started normally.
5. A method for upgrading a home gateway as claimed in claim 1, characterized in that: The receiving of the multicast message refers to receiving the upgrade file sent by the upgrade server through the multicast protocol.
6. A method for upgrading a home gateway as claimed in claim 1, characterized in that: The home gateway is also provided with a forced upgrade button. During the boot phase of the gateway startup, if the multicast upgrade program detects that the forced upgrade button is triggered, the multicast upgrade process is automatically entered.
7. A method for upgrading a home gateway according to any one of claims 1 to 6, characterized in that: The home gateway is also provided with an LED indicator light for indicating the multicast upgrade status. The method further includes: in the process of receiving multicast messages, controlling the LED indicator light to flash slowly; in the process of writing data into the flash of the gateway, controlling the LED indicator light to flash quickly; after the writing into the flash is completed, controlling the LED indicator light to be always on.
8. A home gateway upgrade device, comprising a processor and a memory, characterized in that: The memory stores a computer program, and the processor implements the steps of the home gateway upgrade method as described in any one of claims 1 to 7 by executing the computer program.
9. A storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the home gateway upgrade method according to any one of claims 1 to 7 are implemented.