Method, apparatus and storage medium for controlling internet of things device traffic package
By acquiring call detail records (CDRs) and managing delayed tasks from IoT devices, the problem of low accuracy and flexibility in controlling data traffic packages for IoT devices has been solved, resulting in more efficient data traffic package management.
Patent Information
- Application Number
- CN202311254384.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-26
- Publication Date
- 2026-11-10
- Estimated Expiration
- 2043-09-26
AI Technical Summary
In existing technologies, the accuracy and flexibility of traffic package control for IoT devices are relatively low. Especially as the number of devices increases, the polling time becomes longer, leading to a decrease in control capability.
By acquiring call detail records (CDRs) generated from the current network communication activities of IoT devices, the traffic used in that instance is parsed and updated and switched in real time based on the usage of the data plan. Delayed task management is used to switch data plans, and a data plan queue is established for orderly management.
It improves the accuracy and flexibility of traffic package control for IoT devices, ensuring the timeliness and efficiency of traffic package management.
Smart Images

Figure CN117255317B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of Internet of Things (IoT) communication, and in particular to a method, apparatus, device, and storage medium for controlling data traffic packages for IoT devices. Background Technology
[0002] The Internet of Things (IoT) refers to a network of physical devices that are connected and interact through the Internet. It is a network composed of various sensors, devices, and other objects that can collect and exchange data. IoT technology is now widely used in various fields such as homes, industry, agriculture, and healthcare.
[0003] The core idea of the Internet of Things (IoT) is to connect various IoT devices to the internet, enabling them to communicate and interact with each other. Through connection with other devices and systems, the IoT can achieve intelligent functions and applications. To maintain communication and interaction between IoT devices, these devices need to subscribe to data plans from network operators to obtain data for network communication.
[0004] For network operators, it is necessary to control the data plans of IoT devices. Current technology generally uses the IoT SIM card information of IoT devices to poll the network operator's service operation platform to obtain the data plan usage information of IoT devices. However, as the number of IoT devices increases, the polling time will become longer, and correspondingly, the acquisition cycle of data plan usage information of IoT devices will also become longer. This will greatly reduce the network operator's ability to control the data plans of IoT devices, affecting the accuracy and flexibility of data plan control. Summary of the Invention
[0005] This application provides a method, apparatus, device, and storage medium for controlling data traffic packages for Internet of Things (IoT) devices, in order to solve the technical problem of low accuracy and flexibility in the control of data traffic packages for IoT devices in existing technologies.
[0006] According to a first aspect of this application, this application provides a method for controlling data traffic packages for Internet of Things (IoT) devices, applied to a service operation platform, wherein the service operation platform is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices, comprising:
[0007] Obtain call detail records (CDRs) generated by the current network communication activities of the IoT device;
[0008] The call detail record (CDR) information is sent to the Internet of Things (IoT) platform for the IoT platform to parse the CDR information and obtain the current data usage from the CDR information.
[0009] The system receives the current data usage data pushed by the IoT platform, adds the current data usage data to the previously used data usage data of the first data package associated with the IoT device, and updates the used data usage data.
[0010] If the used data volume reaches the limit of the first data plan, then a plan switch will be performed;
[0011] The package switching includes:
[0012] Determine whether there is a second data plan with unused data and time limits among the data plans already subscribed to by the IoT device;
[0013] If a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
[0014] In one feasible implementation, the method further includes:
[0015] Based on a preset period, the remaining usage time of the first data plan is periodically obtained;
[0016] If the remaining usage time is less than the preset period, a delayed task to perform the package switch is generated and the delayed task is added to the delayed queue; wherein, the delayed execution time of the delayed task is the remaining usage time.
[0017] In one feasible implementation, before obtaining the call detail records (CDRs) generated by the current network communication activity of the IoT device, the method further includes:
[0018] Receive a network connection request from the IoT device sent by the IoT platform; wherein the network connection request includes the integrated circuit card identification code of the IoT device;
[0019] Based on the network connection request, a network connection is established with the IoT device, and the data plan subscribed to by the IoT device is queried according to the integrated circuit card identification code;
[0020] Based on the network request, a network connection is established with the IoT device, and the corresponding data plan queue of the IoT device is queried according to the integrated circuit card identification code; wherein, the data plan queue stores the data plans that the IoT device has subscribed to in the order of subscription.
[0021] If there are data plans in the data plan queue, then select an untested data plan from the data plan queue as the first data plan to be tested.
[0022] If the data allowance and time duration of the first data plan to be tested are not used up, then the first data plan to be tested will be associated with the IoT device as the first data plan.
[0023] If the data allowance or time limit of the first data plan to be tested has been exhausted, then proceed to the step of selecting an untested data plan from the plan queue as the first data plan to be tested.
[0024] In one feasible implementation, the method further includes:
[0025] Obtain the status of the first data plan;
[0026] If the package status is not activated, then a grace period is set for the first data package;
[0027] If the grace period expires, or if a network connection request from the IoT device is received from the IoT platform, the first data plan will be activated.
[0028] In one feasible implementation, the method further includes:
[0029] Receive the IoT device subscription request sent by the IoT platform;
[0030] Based on the aforementioned data plan subscription request, a data plan is subscribed; wherein, the data plan includes a data allowance and a subscription duration;
[0031] If there is no data plan in the data plan queue, the data plan will not be activated and will be added to the head of the data plan queue.
[0032] If a data plan exists in the data plan queue, the data plan is activated and added to the end of the data plan queue.
[0033] In one feasible implementation, determining whether there is a second data plan with unused data allowance and time limit among the data plans already subscribed to by the IoT device includes:
[0034] Select one untested data plan from the data plan queue as the second data plan to be tested;
[0035] If the data allowance and time limit of the second data plan to be tested have not been used up, then the second data plan to be tested will be used as the second data plan, and it will be determined that the second data plan exists.
[0036] If the data allowance or time limit of the second data plan has been used up, then proceed to the step of selecting an untested data plan from the plan queue as the second data plan to be tested.
[0037] If the data allowance or time limit of all second data allowances to be tested in the data allowance queue has been exhausted, then it is determined that there is no second data allowance.
[0038] In one feasible implementation, the method further includes:
[0039] If the second data plan is not available, the network connection with the IoT device will be disconnected.
[0040] According to a second aspect of this application, this application provides a control device for data traffic packages of Internet of Things (IoT) devices, applied to a service operation platform, wherein the service operation platform is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices, comprising:
[0041] The call detail record (CDR) acquisition module is used to acquire call detail record (CDR) information generated by the current network communication activities of the IoT device.
[0042] The data transceiver module is used to send the call detail record (CDR) information to the Internet of Things (IoT) platform, so that the IoT platform can parse the CDR information and obtain the current data usage in the CDR information;
[0043] The traffic statistics module is used to receive the current traffic usage pushed by the IoT platform, add the current traffic usage to the previously used traffic of the first traffic package associated with the IoT device, and update the used traffic.
[0044] The data plan switching module is used to switch data plans if the used data volume reaches the limit of the first data plan.
[0045] The package switching includes:
[0046] Determine whether there is a second data plan with unused data and time limits among the data plans already subscribed to by the IoT device;
[0047] If a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
[0048] According to a third aspect disclosed in this application, an electronic device is provided, including a processor and a memory communicatively connected to the processor;
[0049] The memory stores computer-executed instructions;
[0050] The processor executes computer execution instructions stored in the memory to implement the method described in any one of the first aspects.
[0051] According to a fourth aspect disclosed in this application, a computer-readable storage medium is provided, wherein computer-executable instructions are stored therein, which, when executed by a processor, are used to implement the method described in any one of the first aspects.
[0052] According to the fifth aspect disclosed in this application, a computer program product is provided, comprising a computer program that, when executed by a processor, is used to implement the method described in any one of the first aspects.
[0053] Compared with the prior art, this application has the following advantages:
[0054] This application provides a method, apparatus, device, and storage medium for controlling data traffic packages for IoT devices. By parsing call detail records (CDRs) generated from the current network communication activities of the IoT device, the current data traffic usage of the IoT device is obtained. This current usage data is then used to update the IoT device's already used data traffic, thereby obtaining the latest data traffic usage of the IoT device. Compared to traditional polling methods for obtaining data traffic package usage information, this technique of obtaining IoT device data traffic package usage through CDRs provides a more accurate and flexible understanding of IoT device data traffic package usage, significantly improving the accuracy and flexibility of IoT device data traffic package control and management. Attached Figure Description
[0055] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0056] Figure 1 A flowchart illustrating a method for controlling data traffic packages for IoT devices provided in this application embodiment;
[0057] Figure 2 A flowchart illustrating another method for controlling data traffic packages for IoT devices provided in this application embodiment;
[0058] Figure 3 A schematic diagram of the structure of a control device for a data plan of an Internet of Things (IoT) device provided in an embodiment of this application;
[0059] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application.
[0060] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation
[0061] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.
[0062] The Internet of Things (IoT) refers to a network of physical devices that are connected and interact through the Internet. It is a network composed of various sensors, devices, and other objects that can collect and exchange data. IoT technology is now widely used in various fields such as homes, industry, agriculture, and healthcare.
[0063] The core idea of the Internet of Things (IoT) is to connect various IoT devices to the internet, enabling them to communicate and interact with each other. By connecting with other devices and systems, the IoT can realize intelligent functions and applications. For example, smart homes can connect various devices in the home through the IoT to achieve remote control and automated management; industrial IoT can be applied to equipment monitoring and optimization on production lines; and agricultural IoT can be applied to farmland irrigation, livestock management, and so on.
[0064] To maintain communication between IoT devices, these devices need to subscribe to data plans from network operators to obtain data for network communication. The network communication system for IoT devices typically includes the IoT devices, an IoT platform, and a service operation platform. The IoT devices communicate with the network operator's service operation platform through the IoT platform.
[0065] Specifically, Internet of Things (IoT) devices refer to physical devices that connect and interact with the internet. These can be various types of sensors, controllers, actuators, and smart devices, such as temperature sensors, smart switches, and smart air conditioners.
[0066] Specifically, an IoT platform is a comprehensive platform that provides functions such as device connectivity, data management, application development, and analysis. It offers integrated services for IoT device connectivity, data transmission, secure data communication, and application development. IoT devices typically integrate IoT cards for network communication. Furthermore, each IoT card has a unique Integrated Circuit Card Identity (ICCID) for identifying the IoT device.
[0067] Specifically, the service operation platform is a comprehensive platform used to manage and provide various network services. It provides network operators with functions such as Business Support System (BSS), Operation Support System (OSS), and Network Support System (NMS) to achieve effective operation and management of network services.
[0068] Specifically, data plans are data services provided by network operators, usually offered in the form of packages. Data plans typically include information such as package status, data allowance, and package duration.
[0069] For network operators, it is necessary to control the data plans of IoT devices. Current technology generally uses the IoT SIM card information of IoT devices to poll the network operator's service operation platform to obtain the data plan usage information of IoT devices. However, as the number of IoT devices increases, the polling time will become longer, and correspondingly, the acquisition cycle of data plan usage information of IoT devices will also become longer. This will greatly reduce the network operator's ability to control the data plans of IoT devices, affecting the accuracy and flexibility of data plan control.
[0070] To address the aforementioned technical issues, this application proposes a method for controlling data plans for IoT devices. By utilizing call detail records (CDRs) generated from the network communication activities of IoT devices, the usage status of data plans for IoT devices can be obtained in real time, thereby enabling more accurate and flexible control over the data plans of IoT devices based on the usage status.
[0071] The technical solution of the IoT device data plan control method provided in this application will be described in detail below through specific embodiments. It should be noted that the following embodiments may exist alone or in combination with each other, and the same or similar content may not be described again in different embodiments.
[0072] It should be noted that the execution entity of the IoT device traffic package control method provided in this application embodiment is the service operation platform, and correspondingly, the IoT device traffic package control device is also set in the service operation platform.
[0073] Figure 1A flowchart illustrating a method for controlling data plans for IoT devices provided in this application is shown below. Figure 1 In some embodiments, the method for controlling the data traffic package of IoT devices is applied to a service operation platform, which is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices. The method includes the following steps:
[0074] S101, Obtain call detail records (CDRs) generated by the current network communication activities of IoT devices.
[0075] Call detail records (CDRs) refer to detailed information about each network communication activity recorded by the service operation platform, including basic information such as the start time of the network communication, the time the CDR was generated, and the amount of data used in that transaction.
[0076] Specifically, because call detail records (CDRs) are generated in real time according to a preset generation cycle during the network communication activities of IoT devices, CDRs can reflect the data usage of IoT devices in real time. In contrast, the data retrieved by the traditional polling method is not necessarily generated in real time, which may lead to inaccurate data usage information and consequently, inaccurate control of IoT data plans.
[0077] S102, send the call detail record (CDR) information to the IoT platform so that the IoT platform can parse the CDR information and obtain the traffic used in the current call detail record.
[0078] The reason the service operation platform sends call detail records (CDRs) to the IoT platform is that due to the large number of IoT devices connected to the service operation platform, it cannot guarantee timely processing of CDR information, affecting the efficiency of IoT device data plan control. Therefore, the service operation platform sends CDR information to the IoT platform, which uses its computing power to parse the CDR information and obtain the data usage generated by the IoT device in that particular network communication. This allows the IoT platform to improve the efficiency of IoT device data plan control.
[0079] S103 receives the current usage data pushed by the IoT platform, adds the current usage data to the previously used data data of the first data package associated with the IoT device, and updates the used data data.
[0080] In the process of network communication of IoT devices, call detail records (CDRs) are continuously generated. After obtaining the data usage for the current time through the generated CDR, the data usage for the current time is added to the data usage of the previous time to obtain the data usage of the first data plan at the current time.
[0081] Specifically, the previously used data is the sum of the data used in all call detail records from the activation time of the first data plan to the current time.
[0082] S104. If the data usage has reached the limit of the first data plan, then perform a plan switch.
[0083] The package switching process includes: determining whether there is a second data package with unused data and time limits among the data packages already subscribed to by the IoT device; if a second data package exists, the first data package associated with the IoT device is switched to the second data package for network communication.
[0084] Specifically, the system compares the used data from the first data plan with the data allowance included in the first data plan to determine if the used data has reached the allowance. If the used data has reached the allowance, it further checks if a second data plan with unused data and time is available in the IoT device's subscribed data plan. If a second data plan exists, the system switches the IoT device's associated first data plan to the second data plan for network communication, thus completing the data plan switching control for the IoT device.
[0085] In this embodiment, by parsing the call detail records (CDRs) generated from the current network communication activities of IoT devices, the current data usage of the IoT device is obtained. This current data usage is then used to update the IoT device's already used data, thus obtaining the latest data usage of the IoT device. Compared to the traditional polling method for obtaining data plan usage information, the technique of obtaining IoT device data plan usage through CDR information can more accurately and flexibly grasp the data plan usage of IoT devices, improving the accuracy and flexibility of IoT device data plan control and management.
[0086] exist Figure 1 Based on the embodiments shown, the following is combined with Figure 2 The technical solution of the above-mentioned method for controlling the data traffic package of Internet of Things devices will be further introduced.
[0087] Figure 2 A flowchart illustrating another method for controlling data traffic packages for IoT devices provided in this application is shown below. Figure 2 In some embodiments, the method for controlling the data plan of the IoT device includes the following steps:
[0088] S201, Receive a network connection request from an IoT device sent by an IoT platform; wherein, the network connection request includes the integrated circuit card identification code of the IoT device.
[0089] Before controlling the data usage of IoT devices, a network connection must first be established between the IoT devices and the service operation platform. Therefore, the IoT device first generates a network connection request and sends it to the IoT platform, which then forwards the request to the service operation platform.
[0090] S202, establishes network connection with IoT devices based on network connection requests.
[0091] After receiving a network connection request from an IoT device, the operation service platform establishes a network connection with the IoT device.
[0092] S203, query the corresponding data plan queue for the IoT device based on the integrated circuit card identification code; wherein, the data plan queue stores the data plans that the IoT devices have subscribed to in the order of subscription.
[0093] After the operation service platform establishes a network connection with the IoT device, it uses the integrated circuit card identification code of the IoT device's IoT card to find the data plan subscribed to by the IoT device.
[0094] Specifically, data plans ordered by IoT devices will be stored in a plan queue in the order they were ordered. This makes it easier to switch and control data plans in the future, so that the data plans ordered earlier can be used first.
[0095] S204, determine if a data plan exists in the plan queue.
[0096] S205, if there are data plans in the data plan queue, select an untested data plan from the data plan queue as the first data plan to be tested.
[0097] If there is no data plan in the data plan queue, the subsequent data plan association operation can only be carried out after the IoT device subscribes to a data plan.
[0098] S206, determine whether the data allowance and time limit of the first data plan to be tested have been exhausted.
[0099] Specifically, the system compares the used data of the first data plan to be tested with the plan's data allowance to determine whether the data allowance of the first data plan to be tested has been exhausted.
[0100] Specifically, the system compares the used time of the first data plan to be tested with the plan's duration to determine whether the plan's duration has been exhausted. The used time refers to the time elapsed between the plan's activation date and the current time.
[0101] S207. If the data allowance or time limit of the first data plan to be tested has been used up, proceed to step S205.
[0102] S208, if the data allowance and time limit of the first data allowance to be tested are not used up, then the first data allowance to be tested will be associated with the IoT device as the first data allowance.
[0103] Since data plans need to be activated before IoT devices can use them for network communication, after associating IoT devices with the first data plan, the status of the first data plan should also be checked in order to activate the first data plan.
[0104] Preferably, the activation method for the first data plan specifically includes: obtaining the status of the first data plan; if the status is not activated, setting a grace period for the first data plan; if the grace period expires, or a network connection request from an IoT device is received from the IoT platform, then activating the first data plan.
[0105] Specifically, once an IoT device establishes a network connection with the operation service platform and determines the primary data plan that the IoT device is currently using, the status of that primary data plan is assessed. If the primary data plan is not activated, two activation conditions are set: one is to set a grace period after which it will be automatically activated; the other is to activate it by having the IoT device actively submit an activation request.
[0106] S209, Obtain call detail records (CDRs) generated by the current network communication activities of IoT devices.
[0107] Once the first data plan is activated, IoT devices will use the first data plan for network communication activities and generate corresponding call detail records (CDRs).
[0108] S210 sends the call detail record (CDR) information to the IoT platform for the IoT platform to parse the CDR information and obtain the traffic used in the current call detail record.
[0109] S211, receive the current usage data pushed by the IoT platform, add the current usage data to the previously used data of the first data package associated with the IoT device, and update the used data.
[0110] S212, If the data usage has reached the limit of the first data plan, then proceed to step S215.
[0111] S213 periodically retrieves the remaining usage time of the first data plan based on a preset period.
[0112] Since data plans have two control conditions—data allowance and plan duration—for example, a data plan might have 2048MB of data and a 60-day duration, with the duration typically calculated from the plan's activation date, data plans can be controlled not only by data allowance but also by plan duration. Therefore, periodically checking the remaining usage time of the first data plan can determine whether it's still usable.
[0113] However, this approach presents a problem: when the remaining usage time of the first data plan is less than the preset interval, the periodic control method cannot promptly detect when the first data plan has expired. For example, if the preset scanning interval is 10 minutes, and after the first scan it is found that only 5 minutes of the first data plan remain, and the next scan is 10 minutes later, by the time the first scan detects that the first data plan has exceeded its usage time, the first data plan has already expired by 5 minutes, leading to inaccurate control of data plans for IoT devices.
[0114] S214. If the remaining usage time is less than the preset period, a delayed task to be executed in step S215 is generated and the delayed task is added to the delay queue; wherein, the delay execution time of the delayed task is the remaining usage time.
[0115] In order to avoid the inability to control the data plan of IoT devices in a timely manner, when the remaining usage time is less than the preset period interval, a delayed task for switching the data plan is generated. The delay execution time of the delayed task is the remaining usage time. The delayed task is added to the delay queue, and when the delay execution time is reached, the delayed task will be executed automatically to switch the data plan of the IoT device.
[0116] Specifically, a delayed task refers to a task or operation that is delayed until a specified time or a certain period of time. It can be used to trigger a task at a specific moment or to perform some operations after a period of time. Delayed tasks are usually implemented using timers or timed task schedulers.
[0117] Specifically, a delayed queue is a queue structure that arranges tasks in order according to their delay times. Each task has a specified delay time, after which it can be retrieved from the queue and executed. Delayed queues are typically implemented using priority queues to ensure that tasks in the queue are arranged in order of their delay times.
[0118] S215, select an untested data plan from the plan queue as the second data plan to be tested.
[0119] S216, determine whether the data allowance and time limit of the second data plan to be tested have been exhausted.
[0120] S217. If the data allowance or time limit of the second data plan has been used up, proceed to step S215.
[0121] S218, if the data allowance and time limit of the second data allowance to be tested have not been used up, then the second data allowance to be tested will be used as the second data allowance, and it will be determined that the second data allowance exists.
[0122] S219, if a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
[0123] S220: If the data allowance or time limit of all second data allowances to be tested in the data allowance queue has been exhausted, then it is determined that there are no second data allowances.
[0124] S221, if no second data plan exists, disconnect the network connection with the IoT device.
[0125] In addition, if there is no second data plan available or no data plan is available in the data plan queue, IoT devices will subscribe to a new data plan.
[0126] Preferably, the system receives a data plan subscription request from an IoT device sent by the IoT platform; subscribes to a data plan based on the data plan subscription request; wherein the data plan includes data allowance and data usage duration; if there is no data plan in the data plan queue, the data plan is not activated and is added to the head of the data plan queue; if there is a data plan in the data plan queue, the data plan is activated and is added to the tail of the data plan queue.
[0127] In this process, after the service operation platform subscribes to a data plan based on the subscription request from an IoT device, if there are no other data plans in the plan queue, it means that the subscription is for an initial plan and no active activation is required. If there are other data plans in the plan queue, it means that the subscription is for a subsequent plan, and the subscribed data plan will be actively activated.
[0128] In this embodiment, by setting up a data plan queue, it is convenient to manage and control the data plan in an orderly manner according to the subscription time, which further improves the accuracy of data plan control for IoT devices.
[0129] Figure 3 This is a schematic diagram of the structure of a control device for a data plan of an Internet of Things (IoT) device provided in an embodiment of this application. (See attached diagram.) Figure 3 The control device for the IoT device data plan includes various functional modules for implementing the aforementioned control method for the IoT device data plan. Any functional module can be implemented by software and / or hardware.
[0130] In some embodiments, the control device 300 for the IoT device data plan is applied to a service operation platform, which is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices. The device includes a call detail record (CDR) acquisition module 301, a data transceiver module 302, a data traffic statistics module 303, and a data plan switching module 304.
[0131] Call detail record (CDR) acquisition module 301 is used to acquire call detail record (CDR) information generated by the current network communication activities of IoT devices;
[0132] The data transceiver module 302 is used to send call detail record (CDR) information to the Internet of Things (IoT) platform so that the IoT platform can parse the CDR information and obtain the current traffic usage in the CDR information.
[0133] The traffic statistics module 303 is used to receive the current traffic usage pushed by the IoT platform, and add the current traffic usage with the previously used traffic of the first traffic package associated with the IoT device to update the used traffic.
[0134] The data plan switching module 304 is used to switch data plans if the data usage has reached the limit of the first data plan.
[0135] The package switching includes:
[0136] Determine if there is a second data plan with unused data allowance and time in the data plan already subscribed to by the IoT device;
[0137] If a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
[0138] In some embodiments, the device further includes a delay switching module 305, which is specifically used for:
[0139] Based on a preset period, the remaining usage time of the first data plan is periodically obtained;
[0140] If the remaining usage time is less than the preset period, a delayed task to switch plans will be generated and added to the delayed queue; the delayed execution time of the delayed task is the remaining usage time.
[0141] In some embodiments, the device further includes a network connectivity module 306, which is specifically used for:
[0142] Receives network connection requests from IoT devices sent by the IoT platform; wherein, the network connection request includes the integrated circuit card identification code of the IoT device;
[0143] Establish a network connection with IoT devices based on network requests, and query the data plan subscribed to by IoT devices based on integrated circuit card identification codes;
[0144] Establish a network connection with IoT devices based on network requests, and query the corresponding data plan queue of IoT devices according to the integrated circuit card identification code; the data plan queue stores the data plans that IoT devices have subscribed to in the order of subscription.
[0145] If a data plan exists in the data plan queue, select an untested data plan from the queue as the first data plan to be tested.
[0146] If the data allowance and time limit of the first data plan to be tested are not used up, then the first data plan to be tested will be associated with the IoT device as the first data plan.
[0147] If the data allowance or time limit of the first data plan to be tested has been exhausted, proceed to the step of selecting an untested data plan from the plan queue as the first data plan to be tested.
[0148] In some embodiments, the device further includes a package activation module 307, which is specifically used for:
[0149] Get the status of the first data plan;
[0150] If the data plan is inactive, a grace period will be set for the first data plan.
[0151] If the grace period expires, or if a network connection request from an IoT device is received from the IoT platform, the first data plan will be activated.
[0152] In some embodiments, the device further includes a package ordering module 308, which is specifically used for:
[0153] Receive IoT device subscription requests sent by the IoT platform;
[0154] Subscribe to a data plan based on a data plan subscription request; whereby the data plan includes data allowance and data usage duration;
[0155] If there is no data plan in the plan queue, the data plan will not be activated and will be added to the head of the plan queue.
[0156] If a data plan exists in the plan queue, activate the data plan and add it to the end of the plan queue.
[0157] In some embodiments, the package switching module 304 is specifically used for:
[0158] Select one untested data plan from the data plan queue as the second data plan to be tested;
[0159] If the data allowance and time limit of the second data plan to be tested have not been used up, then the second data plan to be tested will be used as the second data plan, and it will be determined that a second data plan exists.
[0160] If the data allowance or time limit of the second data plan has been used up, proceed to the step of selecting an untested data plan from the plan queue as the second data plan to be tested.
[0161] If all second data plans in the data plan queue have exhausted their data allowance or time limit, then it is determined that there is no second data plan.
[0162] In some embodiments, the package switching module 304 is further configured to:
[0163] If a second data plan is not available, disconnect the network connection from the IoT device.
[0164] The IoT device data plan control device 300 provided in this application embodiment is used to execute the technical solution provided in the aforementioned IoT device data plan control method embodiment. Its implementation principle and technical effect are similar to those in the aforementioned method embodiment, and will not be repeated here.
[0165] It should be noted that the division of the various modules in the above device is merely a logical functional division. In actual implementation, they can be fully or partially integrated into a single physical entity, or they can be physically separated. Furthermore, these modules can be implemented entirely in software via processing elements, entirely in hardware, or partially in software via processing elements and partially in hardware. For example, the call detail record (CDR) acquisition module can be a separate processing element, or it can be integrated into a chip within the device. Alternatively, it can be stored as program code in the device's memory, invoked and executed by a processing element. The implementation of other modules is similar. Moreover, these modules can be fully or partially integrated together, or implemented independently. The processing element here can be an integrated circuit with signal processing capabilities. During implementation, each step of the above method or each of the above modules can be completed through integrated logic circuits in the processor element or through software instructions.
[0166] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. (See attached diagram.) Figure 4 The electronic device 400 includes: a processor 401, and a memory 402 communicatively connected to the processor 401;
[0167] Memory 402 stores instructions executed by the computer;
[0168] The processor 401 executes computer execution instructions stored in the memory 402 to implement the aforementioned technical solution of a method for controlling data traffic packages for Internet of Things (IoT) devices.
[0169] In the aforementioned electronic device 400, the memory 402 and processor 401 are electrically connected directly or indirectly to achieve data transmission or interaction. For example, these components can be electrically connected to each other through one or more communication buses or signal lines, such as bus connections. The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be classified as address buses, data buses, control buses, etc., but this does not mean that there is only one bus or one type of bus. The memory 402 stores computer execution instructions for implementing the control method of the aforementioned IoT device traffic package, including at least one software function module that can be stored in the memory 402 in the form of software or firmware. The processor 401 executes various functional applications and data processing by running the software program and module stored in the memory 402.
[0170] The memory 402 includes at least one type of readable storage medium, not limited to Random Access Memory (RAM), Read Only Memory (ROM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), Electrically Erasable Programmable Read-Only Memory (EEPROM), etc. The memory 402 stores programs, which are executed by the processor 401 upon receiving execution instructions. Furthermore, the software programs and modules within the memory 402 may also include an operating system, which may include various software components and / or drivers for managing system tasks (e.g., memory management, storage device control, power management, etc.) and can communicate with various hardware or software components to provide an operating environment for other software components.
[0171] Processor 401 can be an integrated circuit chip with signal processing capabilities. The aforementioned processor 401 can be a general-purpose processor, including a Central Processing Unit (CPU), a Network Processor (NP), a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor, or processor 401 can be any conventional processor.
[0172] The electronic device 400 is used to execute the technical solution provided in the aforementioned embodiment of the control method for IoT device data packages. Its implementation principle and technical effects are similar to those in the aforementioned method embodiment, and will not be repeated here.
[0173] This application also provides a computer-readable storage medium storing computer-executable instructions. When a processor executes the computer-executable instructions, it implements the aforementioned technical solution of a method for controlling data traffic packages for IoT devices.
[0174] The aforementioned computer-readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The computer-readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.
[0175] An exemplary readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Alternatively, the readable storage medium can be an integral part of the processor. Both the processor and the readable storage medium can reside in an Application Specific Integrated Circuit (ASIC). Alternatively, the processor and the readable storage medium can exist as discrete components within the control device of an IoT device's data plan control unit.
[0176] This application also provides a computer program product, including a computer program, which, when executed by a processor, is used to implement the aforementioned technical solution for controlling data traffic packages for IoT devices.
[0177] In the above embodiments, those skilled in the art will understand that the above method embodiments can be implemented entirely or partially by software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented entirely or partially in the form of a computer program product. A computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the flow or function according to the embodiments of the present invention is generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless network, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available media can be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., DVDs), or semiconductor media (e.g., solid-state drives (SSDs)).
[0178] In the above embodiments, the descriptions of each embodiment have their own emphasis. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments. The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as the combination of these technical features does not contradict each other, it should be considered within the scope of this specification.
[0179] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.
[0180] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.
Claims
1. A method for controlling data traffic packages for Internet of Things (IoT) devices, characterized in that, Applied to a service operation platform, the service operation platform is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices, including: Receive a network connection request from the IoT device sent by the IoT platform; wherein the network connection request includes the integrated circuit card identification code of the IoT device; Based on the network connection request, a network connection is established with the IoT device, and the data plan subscribed to by the IoT device is queried according to the integrated circuit card identification code; Based on the network request, a network connection is established with the IoT device, and the corresponding data plan queue of the IoT device is queried according to the integrated circuit card identification code; wherein, the data plan queue stores the data plans that the IoT device has subscribed to in the order of subscription. If there are data plans in the data plan queue, then select an untested data plan from the data plan queue as the first data plan to be tested. If the data allowance and time duration of the first data plan to be tested are not used up, then the first data plan to be tested will be associated with the IoT device as the first data plan. If the data allowance or time limit of the first data plan to be tested has been exhausted, then proceed to the step of selecting an untested data plan from the plan queue as the first data plan to be tested. Obtain call detail records (CDRs) generated by the current network communication activities of the IoT device; The call detail record (CDR) information is sent to the Internet of Things (IoT) platform for the IoT platform to parse the CDR information and obtain the current data usage from the CDR information. The system receives the current data usage data pushed by the IoT platform, adds the current data usage data to the previously used data usage data of the first data package associated with the IoT device, and updates the used data usage data. If the used data volume reaches the limit of the first data plan, then a plan switch will be performed; The package switching includes: Determine whether there is a second data plan with unused data and time limits among the data plans already subscribed to by the IoT device; If a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
2. The method according to claim 1, characterized in that, The method further includes: Based on a preset period, the remaining usage time of the first data plan is periodically obtained; If the remaining usage time is less than the preset period, a delayed task to perform the package switch is generated and the delayed task is added to the delayed queue; wherein, the delayed execution time of the delayed task is the remaining usage time.
3. The method according to claim 1, characterized in that, The method further includes: Obtain the status of the first data plan; If the package status is not activated, then a grace period is set for the first data package; If the grace period expires, or if a network connection request from the IoT device is received from the IoT platform, the first data plan will be activated.
4. The method according to claim 1, characterized in that, The method further includes: Receive the IoT device subscription request sent by the IoT platform; Based on the aforementioned data plan subscription request, a data plan is subscribed; wherein, the data plan includes a data allowance and a subscription duration; If there is no data plan in the data plan queue, the data plan will not be activated and will be added to the head of the data plan queue. If a data plan exists in the data plan queue, the data plan is activated and added to the end of the data plan queue.
5. The method according to claim 1, characterized in that, Determining whether there is a second data plan with unused data allowance and time among the data plans already subscribed to by the IoT device includes: Select one untested data plan from the data plan queue as the second data plan to be tested; If the data allowance and time limit of the second data plan to be tested have not been used up, then the second data plan to be tested will be used as the second data plan, and it will be determined that the second data plan exists. If the data allowance or time limit of the second data plan has been used up, then proceed to the step of selecting an untested data plan from the plan queue as the second data plan to be tested. If the data allowance or time limit of all second data allowances to be tested in the data allowance queue has been exhausted, then it is determined that there is no second data allowance.
6. The method according to any one of claims 1-5, characterized in that, The method further includes: If the second data plan is not available, the network connection with the IoT device will be disconnected.
7. A control device for data traffic packages of Internet of Things (IoT) devices, characterized in that, Applied to a service operation platform, the service operation platform is connected to multiple IoT platforms, and the IoT platforms are connected to multiple IoT devices, including: The network connection module is specifically used for: receiving a network connection request from the IoT device sent by the IoT platform; wherein the network connection request includes the integrated circuit card identification code of the IoT device; Based on the network connection request, a network connection is established with the IoT device, and the data plan subscribed to by the IoT device is queried according to the integrated circuit card identification code; Based on the network request, a network connection is established with the IoT device, and the corresponding data plan queue of the IoT device is queried according to the integrated circuit card identification code; wherein, the data plan queue stores the data plans that the IoT device has subscribed to in the order of subscription. If there are data plans in the data plan queue, then select an untested data plan from the data plan queue as the first data plan to be tested. If the data allowance and time duration of the first data plan to be tested are not used up, then the first data plan to be tested will be associated with the IoT device as the first data plan. If the data allowance or time limit of the first data plan to be tested has been exhausted, then proceed to the step of selecting an untested data plan from the plan queue as the first data plan to be tested. The call detail record (CDR) acquisition module is used to acquire call detail record (CDR) information generated by the current network communication activities of the IoT device. The data transceiver module is used to send the call detail record (CDR) information to the Internet of Things (IoT) platform, so that the IoT platform can parse the CDR information and obtain the current data usage in the CDR information; The traffic statistics module is used to receive the current traffic usage pushed by the IoT platform, add the current traffic usage to the previously used traffic of the first traffic package associated with the IoT device, and update the used traffic. The data plan switching module is used to switch data plans if the used data volume reaches the limit of the first data plan. The package switching includes: Determine whether there is a second data plan with unused data and time limits among the data plans already subscribed to by the IoT device; If a second data plan exists, the first data plan associated with the IoT device will be switched to the second data plan for network communication.
8. An electronic device, characterized in that, include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Internet of Things card dormancy method, device and equipment and storage medium
CN115580902A
Business processing method and device and storage medium
CN116015990A
