A weather warning method and system based on real-time position of weather warning watch
By obtaining and marking the position of the meteorological warning watch in real time, and broadcasting disaster warning information through other watches when disconnected, the problem that the meteorological warning watch cannot receive meteorological disaster information when disconnected is solved, ensuring that users can receive important information in a timely manner in dangerous scenarios.
Patent Information
- Application Number
- CN202411578623.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-07
- Publication Date
- 2025-03-11
- Estimated Expiration
- 2044-11-07
AI Technical Summary
In the prior art, when the meteorological warning watch using mobile communication network is disconnected, it is impossible to receive meteorological disaster information from the meteorological department in a timely manner, resulting in users being unable to receive important information in a timely manner in dangerous scenarios.
By connecting each weather warning watch to the same server, obtaining its coordinate position in real time, marking and displaying it in the mobile communication network area, the watch controls the heartbeat packets in real time, obtaining the locations where the heartbeat packets have not been received, and determining the nearest weather warning watch, controlling it to broadcast disaster warning information to the disconnected watch.
Even when the connection is disconnected, the weather warning watch can still receive and broadcast disaster warning information through other watches to ensure that users can receive important information in a timely manner in dangerous scenarios.
Smart Images

Figure CN119068634B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of weather warning based on the real-time position of a weather warning watch, and in particular relates to a weather warning method and system based on the real-time position of a weather warning watch. Background Art
[0002] At present, the general application scenarios of weather warning watches involve some remote mountains and suburban scenes. In such scenarios, disconnection is very likely to occur. Once disconnection occurs, important information such as weather warnings cannot be sent to users in time. For example, it is extremely dangerous for some power maintenance personnel to not receive meteorological disaster information from the meteorological department in the first time. Summary of the invention
[0003] Based on this, an embodiment of the present invention provides a weather warning method and system based on the real-time position of a weather warning watch, aiming to solve the problem in the prior art that when a weather warning watch using a mobile communication network is disconnected, the meteorological department's meteorological disaster information cannot be received.
[0004] A first aspect of an embodiment of the present invention provides a weather warning method based on the real-time position of a weather warning watch, which is applied to a scenario where the weather warning watch has a heartbeat collection function, as well as a broadcast sending and receiving function. The method includes:
[0005] Connect each weather warning watch to the same server and obtain the coordinates of each weather warning watch in real time;
[0006] Acquire a mobile communication network area, and mark and display corresponding coordinate points in the mobile communication network area according to the coordinate positions of each weather warning watch acquired in real time;
[0007] Control each weather warning watch to send heartbeat data packets to the server in real time;
[0008] Obtaining a first coordinate position and a first number of a weather warning watch corresponding to the current moment when the server does not receive a heartbeat data packet, and determining a second coordinate position and a second number of a weather warning watch closest to the first coordinate position;
[0009] The second-numbered weather warning watch is controlled to broadcast disaster warning information to the first-numbered weather warning watch.
[0010] Further, the step of obtaining the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining the second coordinate position and the second number of the weather warning watch closest to the first coordinate position includes:
[0011] Obtaining a first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area;
[0012] If it is determined that the first coordinate position is in a non-mobile communication network area outside the mobile communication network area, determining a first target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0013] Determine a first target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the first target coordinate point, and a first preset fan-shaped angle range;
[0014] intercepting the first target line segment from the corresponding non-mobile communication network area outline, and moving along the connecting line toward the first coordinate position until reaching the first coordinate position;
[0015] respectively obtaining the curvatures of both ends of the first target line segment, and extending both ends of the first target line segment according to the curvatures until they intersect with the corresponding non-mobile communication network area contour to obtain a first target area;
[0016] The mobile communication network area is updated according to the first target area.
[0017] Further, after the step of obtaining the first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area, the step also includes:
[0018] If it is determined that the first coordinate position is not in a non-mobile communication network area outside the mobile communication network area, determining whether the first coordinate position is in an adjustment area, wherein the adjustment area is an area between an initial non-mobile communication network area and a finally updated non-mobile communication network area;
[0019] If it is determined that the first coordinate position is within the adjustment area, determining a second target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0020] Determine a second target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the second target coordinate point, and a second preset sector angle range;
[0021] The second target line segment is intercepted and moved to the first coordinate position, and both ends of the second target line segment are respectively connected to the corresponding truncation points of the non-mobile communication network area to obtain a second target area;
[0022] If it is determined that the first coordinate position is not within the adjustment area, determining a third target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0023] The third target coordinate point is moved to the first coordinate position to obtain a third target area.
[0024] Furthermore, the step of respectively acquiring the curvatures of both ends of the first target line segment includes:
[0025] Divide the first target line segment into two segments according to the line connecting the first coordinate position and the first target coordinate point, and obtain the lengths of the two line segments respectively;
[0026] According to the preset unit length and the lengths of the two line segments, the two line segments are divided into a number of sub-line segments;
[0027] The curvature of each sub-segment in the two line segments is calculated respectively, and the curvatures at both ends of the first target line segment are determined according to the curvature distribution of each sub-segment in the two line segments.
[0028] Furthermore, the step of pulling the third target coordinate point to the first coordinate position to obtain the third target area includes:
[0029] Determine two tangent lines between the first coordinate position and the corresponding non-mobile communication network area contour, and determine the tangent point;
[0030] Determining a target contour on a corresponding non-mobile communication network area contour according to the tangent point;
[0031] The third target coordinate point is pulled to the first coordinate position. During the pulling process, the target outline changes accordingly to obtain a third target area.
[0032] Further, the step of obtaining the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining the second coordinate position and the second number of the weather warning watch closest to the first coordinate position includes:
[0033] Obtaining the broadcast transmission range of the weather warning watch, and determining whether the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number;
[0034] If it is determined that the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number, then when disaster warning information appears, the weather warning watch with the second number is controlled to broadcast;
[0035] If it is determined that the broadcast transmission range of the weather warning watch with the second number does not fully cover the non-mobile communication network area corresponding to the first number, the moving range of the weather warning watch with the first number is deduced, and it is determined whether the broadcast transmission range of the weather warning watch with the second number fully covers the moving range;
[0036] If it is determined that the broadcast transmission range of the second-numbered weather warning watch fully covers the moving range, then when disaster warning information appears, the second-numbered weather warning watch is controlled to broadcast;
[0037] If it is determined that the broadcast transmission range of the weather warning watch with the second number does not fully cover the moving range, the weather warning watch with the second number is controlled to broadcast the current weather information.
[0038] Furthermore, the first preset fan-shaped angle range is greater than the second preset fan-shaped angle range.
[0039] A second aspect of an embodiment of the present invention provides a weather warning system based on the real-time position of a weather warning watch, which is used to implement the weather warning method based on the real-time position of a weather warning watch described in the first aspect, and the system includes:
[0040] The acquisition module is used to connect each weather warning watch to the same server and obtain the coordinate position of each weather warning watch in real time;
[0041] A marking module is used to obtain a mobile communication network area, and mark and display corresponding coordinate points in the mobile communication network area according to the coordinate positions of each weather warning watch obtained in real time;
[0042] The first control module is used to control each weather warning watch to send a heartbeat data packet to the server in real time;
[0043] A determination module, used to obtain a first coordinate position and a first number of a weather warning watch corresponding to the current moment when the server does not receive a heartbeat data packet, and determine a second coordinate position and a second number of a weather warning watch closest to the first coordinate position;
[0044] The second control module is used to control the weather warning watch with the second number to broadcast disaster warning information to the weather warning watch with the first number.
[0045] A third aspect of an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the weather warning method based on the real-time position of a weather warning watch provided in the first aspect.
[0046] The fourth aspect of an embodiment of the present invention provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the weather warning method based on the real-time position of the weather warning watch provided in the first aspect is implemented.
[0047] A weather warning method and system based on the real-time position of a weather warning watch is provided in an embodiment of the present invention. The method connects each weather warning watch to the same server and obtains the coordinate position of each weather warning watch in real time; obtains a mobile communication network area, and marks and displays the corresponding coordinate point in the mobile communication network area based on the real-time coordinate position of each weather warning watch; controls each weather warning watch to send a heartbeat data packet to the server in real time; obtains the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determines the second coordinate position and the second number of the weather warning watch closest to the first coordinate position; controls the second-numbered weather warning watch to broadcast disaster warning information to the first-numbered weather warning watch. When a weather warning watch using the mobile communication network is disconnected, it can still receive disaster warning information received and broadcast by other weather warning watches. BRIEF DESCRIPTION OF THE DRAWINGS
[0048] Figure 1 A flow chart for implementing a weather warning method based on the real-time position of a weather warning watch provided in Embodiment 1 of the present invention;
[0049] Figure 2 A structural block diagram of a weather warning system based on the real-time position of a weather warning watch provided in Embodiment 2 of the present invention;
[0050] Figure 3 This is a structural block diagram of an electronic device provided in Embodiment 3 of the present invention. DETAILED DESCRIPTION
[0051] In order to facilitate the understanding of the present invention, the present invention will be described more fully below with reference to the relevant drawings. Several embodiments of the present invention are given in the drawings. However, the present invention can be implemented in many different forms and is not limited to the embodiments described herein. On the contrary, the purpose of providing these embodiments is to make the disclosure of the present invention more thorough and comprehensive.
[0052] It should be noted that when an element is referred to as being "fixed to" another element, it may be directly on the other element or there may be a central element. When an element is considered to be "connected to" another element, it may be directly connected to the other element or there may be a central element at the same time. The terms "vertical", "horizontal", "left", "right" and similar expressions used herein are for illustrative purposes only.
[0053] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which the present invention belongs. The terms used herein in the specification of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.
[0054] Embodiment 1
[0055] According to an embodiment of the present invention, there is provided an embodiment of a weather warning method based on the real-time position of a weather warning watch. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in an order different from that shown here.
[0056] In the first embodiment of the present invention, a weather warning method based on the real-time position of a weather warning watch is provided, which can be used in electronic devices, such as computers. It should be noted that the method is applied to scenarios where the weather warning watch has a heartbeat collection function, as well as a broadcast sending and receiving function.
[0057] See also Figure 1 , Figure 1 A flow chart of an implementation of a weather warning method based on the real-time position of a weather warning watch provided in the first embodiment of the present invention is shown, which specifically includes steps S01 to S05.
[0058] Step S01, connect each weather warning watch to the same server for communication, and obtain the coordinate position of each weather warning watch in real time.
[0059] Among them, the server is a central server. After the central server communicates with each weather warning watch, it can obtain the coordinate position of each weather warning watch. The coordinate position can be the longitude and latitude position, or the position in a pre-established rectangular coordinate system. It can be understood that there is a corresponding relationship between the position in the rectangular coordinate system and the actual longitude and latitude position.
[0060] Step S02, obtaining a mobile communication network area, and marking and displaying corresponding coordinate points in the mobile communication network area based on the coordinate positions of each weather warning watch obtained in real time.
[0061] Specifically, the mobile communication network area refers to the area covered by 4G, 5G and other mobile communication networks. In this area, data can be obtained through 4G, 5G and other mobile communication networks, including meteorological data and geographic location data. Since the geographic location data can be obtained, the corresponding coordinate points can be marked and displayed in the mobile communication network area.
[0062] In addition, mobile communication network areas and non-mobile communication network areas can be planned in advance based on conditions and parameters that affect mobile communication network coverage, such as terrain. Non-mobile communication network areas refer to areas that are not covered by the mobile communication network, that is, areas where Internet access is not available.
[0063] Step S03, controlling each weather warning watch to send the heartbeat data packet to the server in real time.
[0064] Since the weather warning watch has the heartbeat collection function, it can control each weather warning watch to send heartbeat data packets to the server in real time. It can be understood that in areas with mobile communication networks, weather warning watches can send heartbeat data packets and be accepted by the server, while in areas where the network is interrupted, the server cannot receive heartbeat data packets.
[0065] Step S04, obtaining the first coordinate position and first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining the second coordinate position and second number of the weather warning watch closest to the first coordinate position.
[0066] It should be noted that the first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet is obtained, and it is determined whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area;
[0067] If it is determined that the first coordinate position is in a non-mobile communication network area outside the mobile communication network area, determining a first target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0068] Determine a first target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the first target coordinate point, and a first preset sector angle range;
[0069] Cutting the first target line segment from the corresponding non-mobile communication network area outline, and moving it along the connecting line toward the first coordinate position until reaching the first coordinate position;
[0070] The curvatures of both ends of the first target line segment are respectively obtained, and according to the curvature, the two ends of the first target line segment are extended until they intersect with the corresponding non-mobile communication network area contour to obtain the first target area. Specifically, the step of respectively obtaining the curvatures of both ends of the first target line segment includes:
[0071] According to the line connecting the first coordinate position and the first target coordinate point, the first target line segment is divided into two segments, and the lengths of the two line segments are respectively obtained;
[0072] According to the preset unit length and the lengths of the two line segments, the two line segments are divided into a number of sub-line segments;
[0073] The curvature of each sub-segment in the two line segments is calculated respectively, and the curvatures at both ends of the first target line segment are determined according to the curvature distribution of each sub-segment in the two line segments. It should be noted that the curvature is divided into different gears in advance, and different gears correspond to a specific curvature. By understanding the curvature distribution of each sub-segment, that is, counting the gear in which the curvature of each sub-segment falls the most, the curvature of the corresponding gear is determined as the curvature for subsequent extension. For example, if the first target line segment is divided into left and right segments, the endpoint of the left line segment is extended using the curvature determined corresponding to the left line segment, and the endpoint of the right line segment is extended using the curvature determined corresponding to the right line segment;
[0074] updating the mobile communication network area according to the first target area;
[0075] If it is determined that the first coordinate position is not in the non-mobile communication network area outside the mobile communication network area, then determining whether the first coordinate position is in the adjustment area, wherein the adjustment area is an area between the initial non-mobile communication network area and the finally updated non-mobile communication network area;
[0076] If it is determined that the first coordinate position is within the adjustment area, determining a second target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0077] Determine a second target line segment of the corresponding non-mobile communication network area according to a line connecting the first coordinate position and the second target coordinate point, and a second preset fan-shaped angle range, wherein the first preset fan-shaped angle range is greater than the second preset fan-shaped angle range;
[0078] The second target line segment is intercepted and moved to the first coordinate position, and both ends of the second target line segment are respectively connected to the corresponding cut-off points of the non-mobile communication network area to obtain the second target area;
[0079] If it is determined that the first coordinate position is not within the adjustment area, determining a third target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0080] Pull the third target coordinate point to the first coordinate position to obtain a third target area. Specifically, determine two tangent lines between the first coordinate position and the corresponding non-mobile communication network area contour, and determine the tangent point, which is the outermost tangent point;
[0081] Determine the target contour on the corresponding non-mobile communication network area contour according to the tangent point;
[0082] The third target coordinate point is pulled to the first coordinate position. During the pulling process, the target contour changes accordingly to obtain the third target area. Specifically, the corresponding mapping relationship is determined according to the distance between the first coordinate position and the third target coordinate point. According to the mapping relationship, the other coordinate points on the target contour are converted, and the final connection result is the third target area.
[0083] The purpose of the above steps is to continuously update the mobile communication network area as the user with the weather warning watch moves around during work tasks, so that the mobile communication network area becomes more and more accurate, and the broadcast timing of the weather warning watch becomes more and more precise.
[0084] In some other embodiments of the present invention, the broadcast transmission range of the weather warning watch is obtained, and it is determined whether the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number;
[0085] If it is determined that the broadcast transmission range of the second numbered weather warning watch fully covers the non-mobile communication network area corresponding to the first numbered one, then when disaster warning information appears, the second numbered weather warning watch is controlled to broadcast;
[0086] If it is determined that the broadcast transmission range of the second-numbered weather warning watch does not fully cover the non-mobile communication network area corresponding to the first-numbered weather warning watch, the moving range of the first-numbered weather warning watch is deduced. In order to deduce the moving range, the user's historical moving speed is first analyzed. The analysis data comes from the data collected when there is a mobile communication network. Specifically, the user's moving speed on different roads is calculated, and the possible forward roads of the user in the non-mobile communication network area are obtained. According to the moving speed and the possible forward roads of the user, several routes are drawn, and the ends of the several routes are connected to form a moving range, and it is determined whether the broadcast transmission range of the second-numbered weather warning watch fully covers the moving range;
[0087] If it is determined that the broadcast transmission range of the second numbered weather warning watch will fully cover the mobile range, then when disaster warning information appears, the second numbered weather warning watch is controlled to broadcast;
[0088] If it is determined that the broadcast transmission range of the second-numbered weather warning watch does not fully cover the moving range, the second-numbered weather warning watch is controlled to broadcast the current weather information. It can be understood that when the second-numbered weather warning watch does not cover the moving range, the second-numbered weather warning watch is controlled to broadcast the current weather information.
[0089] Step S05, controlling the second-numbered weather warning watch to broadcast disaster warning information to the first-numbered weather warning watch.
[0090] Specifically, disaster warning information is preferentially broadcast through the second-numbered weather warning watch that is closest to the first-numbered weather warning watch. If the second-numbered weather warning watch has completely left its broadcast range, disaster warning information will be broadcast by other covered weather warning watches.
[0091] In summary, the weather warning method based on the real-time position of the weather warning watch in the above-mentioned embodiment of the present invention connects each weather warning watch to the same server, and obtains the coordinate position of each weather warning watch in real time; obtains the mobile communication network area, and marks and displays the corresponding coordinate point in the mobile communication network area according to the real-time coordinate position of each weather warning watch; controls each weather warning watch to send a heartbeat data packet to the server in real time; obtains the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determines the second coordinate position and the second number of the weather warning watch closest to the first coordinate position; controls the second-numbered weather warning watch to broadcast disaster warning information to the first-numbered weather warning watch, so that when the weather warning watch using the mobile communication network is disconnected, it can still receive the disaster warning information received and broadcast by other weather warning watches.
[0092] Embodiment 2
[0093] See also Figure 2 , Figure 2 1 is a structural block diagram of a weather warning system based on the real-time position of a weather warning watch provided in Example 2 of the present invention. The weather warning system 200 based on the real-time position of a weather warning watch is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" may be a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation in hardware, or a combination of software and hardware, is also possible and conceivable.
[0094] Specifically, the weather warning system 200 based on the real-time position of the weather warning watch is applied to the scenario where the weather warning watch has a heartbeat collection function, as well as a sending and receiving broadcast function, and includes: an acquisition module 21, a marking module 22, a first control module 23, a determination module 24 and a second control module 25, wherein:
[0095] The acquisition module 21 is used to connect each weather warning watch to the same server for communication and obtain the coordinate position of each weather warning watch in real time;
[0096] The marking module 22 is used to obtain the mobile communication network area, and mark and display the corresponding coordinate point in the mobile communication network area according to the coordinate position of each weather warning watch obtained in real time;
[0097] The first control module 23 is used to control each weather warning watch to send the heartbeat data packet to the server in real time;
[0098] The determination module 24 is used to obtain the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determine the second coordinate position and the second number of the weather warning watch closest to the first coordinate position;
[0099] The second control module 25 is used to control the weather warning watch with the second number to broadcast disaster warning information to the weather warning watch with the first number.
[0100] Further, in some optional embodiments of the present invention, the determining module 24 includes:
[0101] A first judgment unit is used to obtain a first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and to judge whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area;
[0102] A first determining unit, configured to determine, based on the first coordinate position, a first target coordinate point closest to the corresponding non-mobile communication network area contour if it is determined that the first coordinate position is in a non-mobile communication network area outside the mobile communication network area;
[0103] A second determining unit, configured to determine a first target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the first target coordinate point, and a first preset fan-shaped angle range;
[0104] An interception unit, configured to intercept the first target line segment from the corresponding non-mobile communication network area outline, and move the first target line segment along the connecting line toward the first coordinate position until reaching the first coordinate position;
[0105] An extending unit, configured to respectively obtain the curvatures of both ends of the first target line segment, and extend both ends of the first target line segment according to the curvature until they intersect with the corresponding non-mobile communication network area contour to obtain a first target area;
[0106] An updating unit, configured to update the mobile communication network area according to the first target area.
[0107] Furthermore, in some optional embodiments of the present invention, the determining module 24 further includes:
[0108] a second determining unit, configured to determine whether the first coordinate position is within an adjustment area if it is determined that the first coordinate position is not within a non-mobile communication network area outside the mobile communication network area, wherein the adjustment area is an area between an initial non-mobile communication network area and a finally updated non-mobile communication network area;
[0109] A third determining unit, configured to determine, if it is determined that the first coordinate position is within the adjustment area, a second target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position;
[0110] a fourth determining unit, configured to determine a second target line segment of the corresponding non-mobile communication network area according to a line connecting the first coordinate position and the second target coordinate point, and a second preset fan-shaped angle range, wherein the first preset fan-shaped angle range is greater than the second preset fan-shaped angle range;
[0111] A moving unit, used for intercepting the second target line segment and moving it to the first coordinate position, and connecting the two ends of the second target line segment to the corresponding truncation of the non-mobile communication network area, so as to obtain a second target area;
[0112] a fifth determining unit, configured to determine, according to the first coordinate position, a third target coordinate point closest to the corresponding non-mobile communication network area outline if it is determined that the first coordinate position is not within the adjustment area;
[0113] The stretching unit is used to stretch the third target coordinate point to the first coordinate position to obtain a third target area.
[0114] Further, in some optional embodiments of the present invention, the extension unit includes:
[0115] A first dividing subunit is used to divide the first target line segment into two segments according to the line connecting the first coordinate position and the first target coordinate point, and obtain the lengths of the two line segments respectively;
[0116] A second dividing sub-unit is used to divide the two line segments into a plurality of sub-line segments according to a preset unit length and the lengths of the two line segments;
[0117] The calculation subunit is used to calculate the curvature of each sub-segment in the two line segments respectively, and determine the curvatures at both ends of the first target line segment according to the curvature distribution of each sub-segment in the two line segments respectively.
[0118] Further, in some optional embodiments of the present invention, the stretching unit includes:
[0119] A first determining subunit, configured to determine two tangent lines between the first coordinate position and the corresponding non-mobile communication network area contour, and determine a tangent point;
[0120] A second determining subunit is used to determine a target contour on a corresponding non-mobile communication network area contour according to the tangent point;
[0121] The stretching subunit is used to pull the third target coordinate point to the first coordinate position. During the pulling process, the target contour changes accordingly to obtain a third target area.
[0122] Furthermore, in some optional embodiments of the present invention, the weather warning system 200 based on the real-time position of the weather warning watch further includes:
[0123] A first judgment module is used to obtain the broadcast transmission range of the weather warning watch, and judge whether the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number;
[0124] A third control module is used to control the second-numbered weather warning watch to broadcast when disaster warning information appears if it is determined that the broadcast transmission range of the second-numbered weather warning watch fully covers the non-mobile communication network area corresponding to the first number;
[0125] A second judgment module is used to deduce the moving range of the weather warning watch with the first number, and judge whether the broadcast sending range of the weather warning watch with the second number fully covers the moving range if it is judged that the broadcast sending range of the weather warning watch with the second number does not fully cover the non-mobile communication network area corresponding to the first number;
[0126] a fourth control module, for controlling the second-numbered weather warning watch to broadcast when disaster warning information appears, if it is determined that the broadcast transmission range of the second-numbered weather warning watch fully covers the moving range;
[0127] The fifth control module is used to control the second-numbered weather warning watch to broadcast the current weather information if it is determined that the broadcast transmission range of the second-numbered weather warning watch does not fully cover the moving range.
[0128] Embodiment 3
[0129] Another aspect of the present invention provides an electronic device, see Figure 3 , shown is an electronic device in Embodiment 3 of the present invention, including a memory 20, a processor 10, and a computer program 30 stored in the memory and executable on the processor. When the processor 10 executes the computer program 30, the weather warning method based on the real-time position of the weather warning watch as described above is implemented.
[0130] In some embodiments, the processor 10 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor or other data processing chip, used to run program codes or process data stored in the memory 20, such as executing access restriction programs.
[0131] Among them, the memory 20 includes at least one type of readable storage medium, and the readable storage medium includes a flash memory, a hard disk, a multimedia card, a card-type memory (for example, an SD or DX memory, etc.), a magnetic memory, a magnetic disk, an optical disk, etc. In some embodiments, the memory 20 can be an internal storage unit of an electronic device, such as a hard disk of the electronic device. In other embodiments, the memory 20 can also be an external storage device of an electronic device, such as a plug-in hard disk equipped on the electronic device, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (FlashCard), etc. Further, the memory 20 can also include both an internal storage unit of the electronic device and an external storage device. The memory 20 can not only be used to store application software and various types of data of the electronic device, but also can be used to temporarily store data that has been output or is to be output.
[0132] It should be pointed out that Figure 3 The structure shown does not constitute a limitation on the electronic device. In other embodiments, the electronic device may include fewer or more components than those shown in the figure, or combine certain components, or arrange the components differently.
[0133] The embodiment of the present invention further provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the weather warning method based on the real-time position of the weather warning watch as described above is implemented.
[0134] Those skilled in the art will appreciate that the logic and / or steps represented in the flowchart or otherwise described herein, for example, may be considered as an ordered list of executable instructions for implementing logical functions, and may be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in conjunction with such instruction execution systems, devices or apparatuses. For purposes of this specification, "computer-readable medium" may be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in conjunction with such instruction execution systems, devices or apparatuses.
[0135] More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or more wires (electronic device), a portable computer disk case (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be a paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering or, if necessary, processing in another suitable manner, and then stored in a computer memory.
[0136] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or a combination thereof: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0137] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0138] The above embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present invention. It should be pointed out that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention patent shall be subject to the attached claims.
Claims
1. A weather warning method based on the real-time position of a weather warning watch, characterized in that: Applied to the scenario where a weather warning watch has a heartbeat collection function, as well as a broadcast sending and receiving function, the method includes: Connect each weather warning watch to the same server and obtain the coordinates of each weather warning watch in real time; Acquire a mobile communication network area, and mark and display corresponding coordinate points in the mobile communication network area according to the coordinate positions of each weather warning watch acquired in real time; Control each weather warning watch to send heartbeat data packets to the server in real time; Obtaining a first coordinate position and a first number of a weather warning watch corresponding to the current moment when the server does not receive a heartbeat data packet, and determining a second coordinate position and a second number of a weather warning watch closest to the first coordinate position; Controlling the second-numbered weather warning watch to broadcast disaster warning information to the first-numbered weather warning watch; The step of obtaining the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining the second coordinate position and the second number of the weather warning watch closest to the first coordinate position comprises: Obtaining a first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area; If it is determined that the first coordinate position is in a non-mobile communication network area outside the mobile communication network area, determining a first target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position; Determine a first target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the first target coordinate point, and a first preset fan-shaped angle range; intercepting the first target line segment from the corresponding non-mobile communication network area outline, and moving along the connecting line toward the first coordinate position until reaching the first coordinate position; respectively obtaining the curvatures of both ends of the first target line segment, and extending both ends of the first target line segment according to the curvatures until they intersect with the corresponding non-mobile communication network area contour to obtain a first target area; The mobile communication network area is updated according to the first target area.
2. The weather warning method based on the real-time position of the weather warning watch according to claim 1, characterized in that: After the step of obtaining the first coordinate position of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining whether the first coordinate position is in a non-mobile communication network area outside the mobile communication network area, the step further includes: If it is determined that the first coordinate position is not in a non-mobile communication network area outside the mobile communication network area, determining whether the first coordinate position is in an adjustment area, wherein the adjustment area is an area between an initial non-mobile communication network area and a finally updated non-mobile communication network area; If it is determined that the first coordinate position is within the adjustment area, determining a second target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position; Determine a second target line segment of a corresponding non-mobile communication network area according to a line connecting the first coordinate position and the second target coordinate point, and a second preset sector angle range; The second target line segment is intercepted and moved to the first coordinate position, and both ends of the second target line segment are respectively connected to the corresponding cut-off points of the non-mobile communication network area to obtain a second target area; If it is determined that the first coordinate position is not within the adjustment area, determining a third target coordinate point closest to the corresponding non-mobile communication network area outline according to the first coordinate position; The third target coordinate point is moved to the first coordinate position to obtain a third target area.
3. The weather warning method based on the real-time position of the weather warning watch according to claim 2, characterized in that: The step of respectively acquiring the curvatures of both ends of the first target line segment comprises: Divide the first target line segment into two segments according to the line connecting the first coordinate position and the first target coordinate point, and obtain the lengths of the two line segments respectively; According to the preset unit length and the lengths of the two line segments, the two line segments are divided into a number of sub-line segments; The curvature of each sub-segment in the two line segments is calculated respectively, and the curvatures at both ends of the first target line segment are determined according to the curvature distribution of each sub-segment in the two line segments.
4. The weather warning method based on the real-time position of the weather warning watch according to claim 3, characterized in that: The step of pulling the third target coordinate point to the first coordinate position to obtain the third target area includes: Determine two tangent lines between the first coordinate position and the corresponding non-mobile communication network area contour, and determine the tangent point; Determining a target contour on a corresponding non-mobile communication network area contour according to the tangent point; The third target coordinate point is pulled to the first coordinate position. During the pulling process, the target outline changes accordingly to obtain a third target area.
5. The weather warning method based on the real-time position of the weather warning watch according to claim 4, characterized in that: The steps of obtaining the first coordinate position and the first number of the weather warning watch corresponding to the current moment when the server does not receive the heartbeat data packet, and determining the second coordinate position and the second number of the weather warning watch closest to the first coordinate position include: Obtaining the broadcast transmission range of the weather warning watch, and determining whether the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number; If it is determined that the broadcast transmission range of the weather warning watch with the second number fully covers the non-mobile communication network area corresponding to the first number, then when disaster warning information appears, the weather warning watch with the second number is controlled to broadcast; If it is determined that the broadcast transmission range of the weather warning watch with the second number does not fully cover the non-mobile communication network area corresponding to the first number, the moving range of the weather warning watch with the first number is deduced, and it is determined whether the broadcast transmission range of the weather warning watch with the second number fully covers the moving range; If it is determined that the broadcast transmission range of the second-numbered weather warning watch fully covers the moving range, then when disaster warning information appears, the second-numbered weather warning watch is controlled to broadcast; If it is determined that the broadcast transmission range of the weather warning watch with the second number does not fully cover the moving range, the weather warning watch with the second number is controlled to broadcast the current weather information.
6. The weather warning method based on the real-time position of the weather warning watch according to claim 5, characterized in that: The first preset sector angle range is greater than the second preset sector angle range.
7. A weather warning system based on the real-time position of a weather warning watch, characterized in that: A system for implementing a weather warning method based on the real-time position of a weather warning watch as described in any one of claims 1 to 6, the system comprising: The acquisition module is used to connect each weather warning watch to the same server and obtain the coordinate position of each weather warning watch in real time; A marking module is used to obtain a mobile communication network area, and mark and display corresponding coordinate points in the mobile communication network area according to the coordinate positions of each weather warning watch obtained in real time; The first control module is used to control each weather warning watch to send a heartbeat data packet to the server in real time; A determination module, used to obtain a first coordinate position and a first number of a weather warning watch corresponding to the current moment when the server does not receive a heartbeat data packet, and determine a second coordinate position and a second number of a weather warning watch closest to the first coordinate position; The second control module is used to control the weather warning watch with the second number to broadcast disaster warning information to the weather warning watch with the first number.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the weather warning method based on the real-time position of the weather warning watch as described in any one of claims 1 to 6 is implemented.
9. An electronic device, characterized in that: It includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, the weather warning method based on the real-time position of the weather warning watch as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Public network cluster converged communication method and system
CN114339951A