Method, device, terminal and storage medium for determining operation area
By acquiring and determining the position captured by the position calibrator, the robot can quickly divide the working area, solving the problem of low efficiency in the existing technology and achieving efficient working area determination.
Patent Information
- Application Number
- CN202111443073.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-30
- Publication Date
- 2025-09-16
- Estimated Expiration
- 2041-11-30
AI Technical Summary
In the prior art, the efficiency of robots in determining the working area is low and they are unable to quickly know the scope of the working area.
By obtaining the first position collected by the user using a position calibrator in the working area, the second and third positions are determined in different preset directions based on the position, and the working area is divided into preset area shapes according to these positions.
This improves the efficiency of the robot in knowing the working area, enabling it to quickly determine and work within the working area.
Smart Images

Figure CN116203935B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and in particular to a method, device, terminal and storage medium for determining an operation area. Background Art
[0002] The work area in the work zone can be a construction site, an equipment work area, or other similar area. When the work area is a construction site, the robot can perform construction work in the work area. When the work area is a work area, the work area is the area where the equipment is operating. Currently, when a robot is required to work in a work area, the robot can only determine the area of the work area based on location parameters manually entered by the user.
[0003] However, the efficiency of existing robots in obtaining the working area is low, which is not conducive to the robot quickly determining the working area in the working area. Summary of the Invention
[0004] The embodiments of the present application provide a method, device, terminal, and storage medium for determining an operation area, which can improve the efficiency of a robot in obtaining an operation area.
[0005] The present invention provides a method for determining an operation area, including:
[0006] Obtaining a first position collected by a user using a position calibrator in a work area;
[0007] Based on the first position, determining a second position in a first predetermined direction of the first position;
[0008] Based on the first position, determining the third position in a second predetermined direction of the first position, or based on the second position, determining the third position in a predetermined direction of the second position, wherein the first predetermined direction of the first position and the second predetermined direction of the first position are two different directions;
[0009] According to the first position, the second position and the third position, a working area is divided into a preset area shape in the working area.
[0010] The present application also provides a device for determining an operation area, including:
[0011] A first position obtaining unit, configured to obtain a first position set by a user in a work area;
[0012] a second position determining unit, configured to determine a second position in a preset direction of the first position based on the first position;
[0013] a third position determining unit, configured to determine a third position based on the first position and in a second preset direction of the first position, or to determine the third position based on the second position and in a preset direction of the second position, wherein the first preset direction of the first position and the second preset direction of the first position are two different directions;
[0014] The operation area determination unit is used to divide the operation area into a preset area shape in the working area according to the first position, the second position and the third position.
[0015] In some embodiments, the operation area determination unit is configured to:
[0016] determining a fourth position based on the first position, the second position, and the third position;
[0017] The first position, the second position, the third position and the fourth position are connected according to a preset area shape to obtain a working area in the working area.
[0018] In some embodiments, determining the fourth position based on the first position, the second position, and the third position includes:
[0019] Connecting the first position and the second position to obtain a first boundary line;
[0020] Connect the second position and the third position to obtain a second boundary line;
[0021] Obtaining a third boundary line according to the first boundary line and the distance from the first boundary line to the third position;
[0022] Obtaining a fourth boundary line according to the second boundary line and the distance from the second boundary line to the first position;
[0023] A fourth position is determined according to the intersection of the third boundary line and the fourth boundary line.
[0024] In some embodiments, the work area includes multiple work areas, the multiple work areas include a first work area and a second work area, and after the first position, the second position, the third position, and the fourth position are connected according to a preset area shape to obtain the work area in the work area, the following steps are further included:
[0025] Acquire endpoint positions in a plurality of operation areas, where the endpoint positions of the operation areas include a first position, a second position, a third position, and a fourth position;
[0026] When the two end points of the first operating area are located within the second operating area or on the boundary of the second operating area, the first operating area and the second operating area are spliced together.
[0027] In some embodiments, the working area is rectangular or triangular in shape.
[0028] In some embodiments, determining the second position in a first predetermined direction of the first position based on the first position includes:
[0029] Get the first length value entered by the user;
[0030] Determine a second position in a first preset direction of the first position according to the first length value and the first position;
[0031] Determining a third position in a second preset direction of the first position based on the first position, or determining the third position in a preset direction of the second position based on the second position, includes:
[0032] Get the second length value entered by the user;
[0033] The third position is determined in the second preset direction of the first position according to the second length value and the first position, or the third position is determined in the preset direction of the second position according to the second length value and the second position.
[0034] In some embodiments, the working area is divided into a plurality of operation areas of preset area shapes, and boundary areas of adjacent operation areas overlap, and the boundary area is an area shared by the adjacent operation areas.
[0035] An embodiment of the present application also provides a terminal, including a memory storing multiple instructions; the processor loads instructions from the memory to execute the steps in any one of the operation area determination methods provided in the embodiments of the present application.
[0036] An embodiment of the present application also provides a computer-readable storage medium, which stores multiple instructions, and the instructions are suitable for a processor to load to execute the steps in any one of the work area determination methods provided in the embodiment of the present application.
[0037] The embodiment of the present application can obtain a first position collected by a user using a position calibrator in a working area; based on the first position, determine a second position in a first preset direction of the first position; based on the first position, determine a third position in a second preset direction of the first position, or based on the second position, determine the third position in a preset direction of the second position, the first preset direction of the first position and the second preset direction of the first position are two different directions; and divide the working area into a preset area shape according to the first position, the second position and the third position in the working area.
[0038] In this application, the user uses a position calibrator to collect the first position in the working area, so that the second position and the third position can be quickly determined based on the first position, and then the working area is divided into a preset area shape according to the first position, the second position and the third position in the working area. Therefore, this solution can improve the efficiency of the robot in obtaining the working area so that the robot can work within the working area. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0040] Figure 1a This is a flow chart of the method for determining the working area provided in the embodiment of the present application.
[0041] Figure 1b Schematic diagram of a method for determining an operation area according to an embodiment of the present application;
[0042] Figure 1c Schematic diagram of a method for determining an operation area according to an embodiment of the present application;
[0043] Figure 2 2 is a schematic diagram of the method for determining an operation area provided in an embodiment of the present application applied in an airport scenario;
[0044] Figure 3 is a structural diagram of an operating area determination device provided in an embodiment of the present application;
[0045] Figure 4 It is a schematic diagram of the structure of the terminal provided in an embodiment of the present application. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without making creative efforts are within the scope of protection of this application.
[0047] Embodiments of the present application provide a method, device, terminal, and storage medium for determining an operation area.
[0048] The operation area determination device may be integrated into an electronic device, such as a terminal or a server. The terminal may be a mobile phone, tablet computer, smart Bluetooth device, laptop computer, or personal computer (PC); the server may be a single server or a server cluster consisting of multiple servers.
[0049] In some embodiments, the operation area determination device can also be integrated into multiple electronic devices. For example, the operation area determination device can be integrated into multiple servers, and the operation area determination method of the present application can be implemented by multiple servers.
[0050] In some embodiments, the server may also be implemented in the form of a terminal.
[0051] The electronic device can obtain a first position collected by a user using a position calibrator in a working area; based on the first position, determine a second position in a first preset direction of the first position; based on the first position, determine a third position in a second preset direction of the first position, or based on the second position, determine the third position in a preset direction of the second position, the first preset direction of the first position and the second preset direction of the first position are two different directions; and divide the working area into a preset area shape according to the first position, the second position and the third position in the working area.
[0052] Among them, when determining the working area, the user can use the position calibrator to quickly determine the first position in the working area, and then use the first position as the starting point to determine the second position in the first preset direction of the first position, and then use the first position as the starting point to determine the third position in the second preset direction of the first position, or use the second position as the starting point to determine the third position in the preset direction of the second position. In this way, the first position, the second position and the third position can be quickly determined, and the working area can be divided into the preset area shape in the working area according to the first position, the second position and the third position, which can improve the efficiency of the robot in knowing the working area so that the robot can work in the working area.
[0053] It should be noted that the serial numbers of the following embodiments are not intended to limit the preferred order of the embodiments.
[0054] In this embodiment, a method for determining an operation area is provided, such as Figure 1a As shown, the specific process of the operation area determination method can be as follows:
[0055] 110. Obtain a first position collected by the user in the working area using a position calibrator.
[0056] Among them, the position calibrator is a locator installed with a positioning system, for example, the position calibrator can use Global Positioning System (GPS) positioning, base station positioning, WiFi assisted positioning, Assisted Global Positioning System (AGPS) positioning, GLONASS (GLOBAL NAVIGATIONSATELLITE SYSTEM) positioning, and Beidou positioning.
[0057] The work area is an area where work needs to be carried out. For example, the work area can be an area on an airport pavement to be constructed, an area on a playground to be constructed, an area where equipment is running, and so on.
[0058] The first position is the first determined position coordinate.
[0059] For example, the user utilizes the positioning system in the position calibrator to locate and thereby collect the first position. The user may also set up a mobile base station in the work area and determine the first position through interaction between the mobile base station and the position calibrator, and so on.
[0060] Obtaining a first location captured by a user using a position calibrator in the work area. For example, the user holds the position calibrator and walks to the first location. The coordinates of the point are collected by setting the position calibrator. The user can click a button on the position calibrator to record the current location coordinates and record the current location coordinates as the first location. The first location is an endpoint of the work area, and the electronic device receives the first location sent by the position calibrator.
[0061] Among them, the electronic device is used to receive the position sent by the position calibrator, and generate the working area and working path according to the received position, and send the working area and action path to the robot. The robot performs the work in the working area according to the working path.
[0062] The electronic device may be a host computer.
[0063] 120. Based on the first position, determine a second position in a first preset direction of the first position.
[0064] Among them, the first preset direction of the first position is a direction pre-set at the first position. For example, the first preset direction of the first position can be the x direction of the first position, or the y direction of the first position, or the 45° clockwise direction of the first position, and so on.
[0065] The second position is the second determined position coordinate.
[0066] For example, with the first position as the origin, the second position is determined in the x direction of the first position.
[0067] For example, with the first position as the origin, the second position is determined in the y direction of the first position.
[0068] For example, with the first position as the origin, the second position is determined in a 45° clockwise direction of the first position.
[0069] Determining a second position in a first preset direction of the first position based on the first position includes:
[0070] For example, after the electronic device receives the first position, the user uses the position calibrator to determine the second position along the first preset direction of the first position, collects the coordinates of the point by setting on the position calibrator, and records the coordinates of the point as the second position. The second position is an end point of the working area, and the electronic device receives the second position sent by the position calibrator.
[0071] For example, after the electronic device receives the first position, the electronic device determines the second position according to a first preset direction of the first position.
[0072] 130. Based on the first position, determine the third position in the second preset direction of the first position, or based on the second position, determine the third position in the preset direction of the second position, the first preset direction of the first position and the second preset direction of the first position being two different directions.
[0073] Among them, the second preset direction of the first position is another direction pre-set at the first position. For example, the first preset direction of the first position can be the x direction of the first position, or the y direction of the first position, or the 45° clockwise direction of the first position, and so on.
[0074] Among them, the preset direction of the second position is a direction pre-set at the second position. For example, the preset direction of the second position can be the x direction of the second position, or the y direction of the second position, or the 45° clockwise direction of the second position, etc.
[0075] The third position is the third determined position coordinate.
[0076] For example, when the second position is in the x direction of the first position, the third position may be in the y direction of the second position, or the third position may be in the y direction of the first position.
[0077] Determining a third position in a second preset direction of the first position based on the first position includes:
[0078] For example, after the electronic device receives the first position, the user uses the position calibrator to determine the third position along the second preset direction of the first position, collects the coordinates of the point by setting on the position calibrator, and records the coordinates of the point as the third position. The third position is an end point of the working area, and the electronic device receives the third position sent by the position calibrator.
[0079] For example, after the electronic device receives the first position, the electronic device determines the third position according to the second preset direction of the first position.
[0080] Determining a third position in a preset direction of the second position based on the second position includes:
[0081] For example, after the electronic device receives the second position, the user uses the position calibrator to determine the third position along the preset direction of the second position, collects the coordinates of the point by setting on the position calibrator, and records the coordinates of the point as the third position. The third position is an end point of the working area, and the electronic device receives the third position sent by the position calibrator.
[0082] For example, after the electronic device obtains the second position, the electronic device determines the third position in a preset direction of the second position.
[0083] 140. Divide the working area into a work area according to a preset area shape based on the first position, the second position, and the third position.
[0084] The preset area shape is a pre-set area shape, for example, the preset area shape may be a triangle or a rectangle.
[0085] The operation area is an area in the working area where operations are performed. For example, the operation area may be an area in which a robot works in the working area.
[0086] For example, after receiving the first position, the second position and the third position, the electronic device divides the first position, the second position and the third position into a working area according to a preset area shape in the working area based on the convex hull algorithm, calculates the working path of the robot in the working area, and sends the working area and the working path to the robot, so that the robot can quickly receive the working area and working path sent by the electronic device, and walk according to the working path in the working area.
[0087] For example, when the working area is the area where the robot works, the robot works in the working area determined by the working area determination method, and the working area of the present application facilitates the robot to walk in the working area according to GPS positioning, Beidou positioning, etc. The first position, second position, third position and fourth position in the working area are used to limit the walking range of the robot. The robot can walk in a serpentine manner in the working area, and any one of the first position, second position, third position and fourth position is the initial position of the robot's walking.
[0088] In some embodiments, in order to obtain a rectangular working area, the working area determination unit is configured to:
[0089] determining a fourth position based on the first position, the second position, and the third position;
[0090] The first position, the second position, the third position and the fourth position are connected according to a preset area shape to obtain a working area in the working area.
[0091] Among them, the fourth position is the fourth determined position.
[0092] For example, the electronic device divides the first position, the second position, and the third position into operating areas in a work area according to a preset area shape based on a convex hull algorithm.
[0093] In some embodiments, in order to obtain the fourth position, determining the fourth position according to the first position, the second position, and the third position includes:
[0094] Connecting the first position and the second position to obtain a first boundary line;
[0095] Connect the second position and the third position to obtain a second boundary line;
[0096] Obtaining a third boundary line according to the first boundary line and the distance from the first boundary line to the third position;
[0097] Obtaining a fourth boundary line according to the second boundary line and the distance from the second boundary line to the first position;
[0098] A fourth position is determined according to the intersection of the third boundary line and the fourth boundary line.
[0099] The first boundary line is a boundary line of the operation area.
[0100] The second boundary line is a boundary line connected to the first boundary line.
[0101] The third boundary line is a boundary line connected to the second boundary line.
[0102] Wherein, two ends of the fourth boundary line are respectively connected to the first boundary line and the third boundary line.
[0103] In some embodiments, in order to achieve the effect of splicing the working area in the working area, the working area includes multiple working areas, and the multiple working areas include a first working area and a second working area. After the first position, the second position, the third position, and the fourth position are connected according to a preset area shape to obtain the working area in the working area, the following steps are further included:
[0104] Acquire endpoint positions in a plurality of operation areas, where the endpoint positions of the operation areas include a first position, a second position, a third position, and a fourth position;
[0105] When the two end points of the first operating area are located within the second operating area or on the boundary of the second operating area, the first operating area and the second operating area are spliced together.
[0106] Among them, the first operating area is an operating area spliced with other operating areas.
[0107] Among them, the second working area is the working area spliced with the first working area.
[0108] For example, when the two endpoints of the first operating area fall within the second operating area, or fall on the boundary of the second operating area, the first operating area and the second operating area are spliced.
[0109] In some embodiments, the working area is rectangular or triangular in shape.
[0110] In some embodiments, to achieve the effect of obtaining the second position based on the first position, obtaining the third position based on the first position, and obtaining the third position based on the second position, determining the second position in a first preset direction of the first position based on the first position includes:
[0111] Get the first length value entered by the user;
[0112] Determine a second position in a first preset direction of the first position according to the first length value and the first position;
[0113] Determining a third position in a second preset direction of the first position based on the first position, or determining the third position in a preset direction of the second position based on the second position, includes:
[0114] Get the second length value entered by the user;
[0115] The third position is determined in the second preset direction of the first position according to the second length value and the first position, or the third position is determined in the preset direction of the second position according to the second length value and the second position.
[0116] The first length value is a side length value of the working area. For example, when the working area is a rectangular area, the first length value can be the length value of the working area or the width value of the working area.
[0117] The second length value is another side length value of the working area. For example, when the working area is a rectangular area, the second length value can be the length value of the working area or the width value of the working area.
[0118] For example, the electronic device determines the third position in the second preset direction of the first position according to the first length value input by the user.
[0119] For example, the electronic device determines the third position in the second preset direction of the first position according to the second length value input by the user, or the electronic device determines the third position in the preset direction of the second position according to the second length value input by the user.
[0120] In some embodiments, the working area is divided into a plurality of operation areas of preset area shapes, and boundary areas of adjacent operation areas overlap, and the boundary area is an area shared by the adjacent operation areas.
[0121] The working area is 01, the first operating area is 02, the second operating area is 03, the first position is 04, the second position is 05, the third position is 06, the fourth position is 07, and the boundary area is 08.
[0122] like Figure 1b As shown, the two end points of the first working area 02 are located within the second working area 03 .
[0123] like Figure 1c As shown, the two end points of the first working area 02 are located on the boundary of the second working area 03 .
[0124] From the above, it can be seen that the embodiment of the present application can obtain the first position collected by the user using a position calibrator in the working area; based on the first position, determine the second position in the first preset direction of the first position; based on the first position, determine the third position in the second preset direction of the first position, or based on the second position, determine the third position in the preset direction of the second position, the first preset direction of the first position and the second preset direction of the first position are two different directions; according to the first position, the second position and the third position, the working area is divided according to the preset area shape in the working area.
[0125] In an embodiment of the present application, a user uses a position calibrator to collect a first position in the working area, so that the second position and the third position can be quickly determined based on the first position, and then the working area is divided into a preset area shape according to the first position, the second position and the third position in the working area. Therefore, this solution can improve the efficiency of the robot in obtaining the working area so that the robot can work within the working area.
[0126] The method described in the above embodiment will be further described below.
[0127] In this embodiment, the method of the embodiment of the present application is described in detail by taking the determination of the operation area at an airport as an example, wherein the preset area shape of the operation area is a rectangle.
[0128] like Figure 2 As shown, a specific process of a method for determining an operation area is as follows:
[0129] (1) Obtain the GPS coordinates of the robot's operating starting position in the working area A by the position calibrator, and set the position as the first position B, which is the starting position of the robot's operation.
[0130] (2) Obtain the GPS coordinates of the position calibrator in the longitudinal direction (y direction) to obtain the second position C.
[0131] (3) Taking the first position B or the second position C as the starting point, obtain the GPS coordinates of the position calibrator in the width direction (x direction) to obtain the third position D.
[0132] In some embodiments, the fourth position E is determined based on the first position B, the second position C, and the third position D.
[0133] (4) Divide the first position B, the second position C, the third position D, and the fourth position E into a rectangular area F.
[0134] From the above, it can be seen that this solution can improve the efficiency of the robot in obtaining the working area, so that the robot can start the road surface detection work according to the working area information.
[0135] To better implement the above method, the present application also provides an operating area determination device. The operating area determination device can be integrated into an electronic device, such as a terminal or a server. The terminal can be a mobile phone, tablet computer, smart Bluetooth device, laptop computer, personal computer, etc. The server can be a single server or a server cluster consisting of multiple servers.
[0136] For example, in this embodiment, the method of the embodiment of the present application will be described in detail by taking the specific integration of the operation area determination device into a terminal as an example.
[0137] For example, Figure 3 As shown, the operation area determination device may include a first position acquisition unit 310, a second position determination unit 320, a third position determination unit 330, and an operation area determination unit 340, as follows:
[0138] (1) First position acquisition unit 310.
[0139] The first position acquiring unit 310 is configured to acquire a first position set by a user in a work area.
[0140] (2) Second position determination unit 320.
[0141] The second position determining unit 320 is configured to determine a second position in a preset direction of the first position based on the first position.
[0142] (3) The third position determining unit 330.
[0143] The third position determination unit 330 is used to determine the third position in the second preset direction of the first position based on the first position, or to determine the third position in the preset direction of the second position based on the second position, wherein the first preset direction of the first position and the second preset direction of the first position are two different directions.
[0144] (4) Operation area determination unit 340.
[0145] The operation area determining unit 340 is configured to divide the operation area into an operation area according to a preset area shape in the working area based on the first position, the second position, and the third position.
[0146] In some embodiments, the operation area determination unit is configured to:
[0147] determining a fourth position based on the first position, the second position, and the third position;
[0148] The first position, the second position, the third position and the fourth position are connected according to a preset area shape to obtain a working area in the working area.
[0149] In some embodiments, determining the fourth position based on the first position, the second position, and the third position includes:
[0150] Connecting the first position and the second position to obtain a first boundary line;
[0151] Connect the second position and the third position to obtain a second boundary line;
[0152] Obtaining a third boundary line according to the first boundary line and the distance from the first boundary line to the third position;
[0153] Obtaining a fourth boundary line according to the second boundary line and the distance from the second boundary line to the first position;
[0154] A fourth position is determined according to the intersection of the third boundary line and the fourth boundary line.
[0155] In some embodiments, the work area includes multiple work areas, the multiple work areas include a first work area and a second work area, and after the first position, the second position, the third position, and the fourth position are connected according to a preset area shape to obtain the work area in the work area, the following steps are further included:
[0156] Acquire endpoint positions in a plurality of operation areas, where the endpoint positions of the operation areas include a first position, a second position, a third position, and a fourth position;
[0157] When the two end points of the first operating area are located within the second operating area or on the boundary of the second operating area, the first operating area and the second operating area are spliced together.
[0158] In some embodiments, the working area is rectangular or triangular in shape.
[0159] In some embodiments, determining the second position in a first predetermined direction of the first position based on the first position includes:
[0160] Get the first length value entered by the user;
[0161] Determine a second position in a first preset direction of the first position according to the first length value and the first position;
[0162] Determining a third position in a second preset direction of the first position based on the first position, or determining the third position in a preset direction of the second position based on the second position, includes:
[0163] Get the second length value entered by the user;
[0164] The third position is determined in the second preset direction of the first position according to the second length value and the first position, or the third position is determined in the preset direction of the second position according to the second length value and the second position.
[0165] In some embodiments, the working area is divided into a plurality of operation areas of preset area shapes, and boundary areas of adjacent operation areas overlap, and the boundary area is an area shared by the adjacent operation areas.
[0166] In specific implementation, the above units can be implemented as independent entities, or can be arbitrarily combined to be implemented as the same or several entities. The specific implementation of the above units can be found in the previous method embodiments and will not be repeated here.
[0167] As can be seen from the above, the working area determination device of this embodiment obtains the first position set by the user in the working area by the first position acquisition unit; the second position determination unit determines the second position in the preset direction of the first position based on the first position; the third position determination unit determines the third position in the second preset direction of the first position based on the first position, or determines the third position in the preset direction of the second position based on the second position, and the first preset direction of the first position and the second preset direction of the first position are two different directions; the working area determination unit divides the working area into a preset area shape according to the first position, the second position and the third position in the working area.
[0168] Therefore, the embodiments of the present application can improve the efficiency of the robot in knowing the working area so that the robot can work within the working area.
[0169] Accordingly, an embodiment of the present application also provides a computer device, which may be a terminal or a server, and the terminal may be a smart phone, tablet computer, laptop computer, touch screen, game console, personal computer, personal digital assistant (PDA) and other terminal devices.
[0170] like Figure 4 As shown, Figure 4 This is a schematic diagram of the structure of a computer device provided in an embodiment of the present application. The computer device 400 includes a processor 410 having one or more processing cores, a memory 420 having one or more computer-readable storage media, and a computer program stored in the memory 420 and executable on the processor. The processor 410 is electrically connected to the memory 420. Those skilled in the art will appreciate that the computer device structure shown in the figure does not limit the computer device and may include more or fewer components than shown, or combine certain components, or arrange the components differently.
[0171] The processor 410 is the control center of the computer device 400. It uses various interfaces and lines to connect various parts of the entire computer device 400. By running or loading software programs and / or modules stored in the memory 420 and calling data stored in the memory 420, it executes various functions of the computer device 400 and processes data, thereby monitoring the computer device 400 as a whole.
[0172] In the embodiment of the present application, the processor 410 in the computer device 400 loads instructions corresponding to one or more application processes into the memory 420 according to the following steps, and the processor 410 runs the application stored in the memory 420 to implement various functions:
[0173] Obtaining a first position collected by a user using a position calibrator in a work area;
[0174] Based on the first position, determining a second position in a first predetermined direction of the first position;
[0175] Based on the first position, determining the third position in a second predetermined direction of the first position, or based on the second position, determining the third position in a predetermined direction of the second position, wherein the first predetermined direction of the first position and the second predetermined direction of the first position are two different directions;
[0176] According to the first position, the second position and the third position, a working area is divided into a preset area shape in the working area.
[0177] The specific implementation of the above operations can be found in the previous embodiments and will not be repeated here.
[0178] Optional, such as Figure 4 As shown, the computer device 400 further includes: a touch screen 430, a radio frequency circuit 440, an audio circuit 450, an input unit 460, a power supply 470, and a positioning unit 480. Among them, the processor 410 is electrically connected to the touch screen 430, the radio frequency circuit 440, the audio circuit 450, the input unit 460, and the power supply 470 respectively. It can be understood by those skilled in the art that Figure 4 The computer device structure shown in the figure does not constitute a limitation to the computer device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0179] The touch display screen 430 can be used to display a graphical user interface and receive operation instructions generated by the user acting on the graphical user interface. The touch display screen 430 may include a display panel and a touch panel. Among them, the display panel can be used to display information input by the user or information provided to the user and various graphical user interfaces of the computer device, and these graphical user interfaces can be composed of graphics, text, icons, videos and any combination thereof. Optionally, the display panel can be configured in the form of a liquid crystal display (LCD, Liquid Crystal Display), an organic light emitting diode (OLED, Organic Light-Emitting Diode), etc. The touch panel can be used to collect the user's touch operations on or near it (such as the user uses any suitable object or accessory such as a finger, stylus, etc. on the touch panel or near the touch panel) and generate corresponding operation instructions, and the operation instructions execute the corresponding program. Optionally, the touch panel may include two parts: a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch direction, detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into the touch point coordinates, and then sends it to the processor 410, and can receive the command sent by the processor 410 and execute it. The touch panel can cover the display panel. When the touch panel detects a touch operation on or near it, it is transmitted to the processor 410 to determine the type of touch event, and then the processor 410 provides a corresponding visual output on the display panel according to the type of touch event. In an embodiment of the present application, the touch panel and the display panel can be integrated into the touch display screen 430 to realize input and output functions. However, in some embodiments, the touch panel and the touch panel can be used as two independent components to realize input and output functions. That is, the touch display screen 430 can also be used as part of the input unit 460 to realize the input function.
[0180] The radio frequency circuit 440 may be used to transmit and receive radio frequency signals, thereby establishing wireless communication with a network device or other computer device through wireless communication, and transmitting and receiving signals between the network device or other computer device.
[0181] Audio circuit 450 can be used to provide an audio interface between the user and the computer device through a speaker and microphone. Audio circuit 450 can convert received audio data into electrical signals and transmit them to the speaker, which then converts them into sound signals for output. The microphone, on the other hand, converts collected sound signals into electrical signals, which are received by audio circuit 450 and converted into audio data. The audio data is then output to processor 410 for processing, and then transmitted via RF circuit 440 to, for example, another computer device. Alternatively, the audio data can be output to memory 420 for further processing. Audio circuit 450 may also include an earphone jack to allow communication between external headphones and the computer device.
[0182] The input unit 460 may be used to receive input numbers, character information, or user feature information (such as fingerprint, iris, facial information, etc.), and to generate keyboard, mouse, joystick, optical, or trackball signal inputs related to user settings and function control.
[0183] Power supply 470 is used to supply power to various components of computer device 400. Optionally, power supply 470 can be logically connected to processor 410 via a power management system, thereby enabling the power management system to manage charging, discharging, and power consumption. Power supply 470 can also include one or more DC or AC power supplies, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and other arbitrary components.
[0184] The positioning unit 480 can perform GPS position positioning.
[0185] although Figure 4 Not shown in the figure, the computer device 400 may also include a camera, a sensor, a wireless fidelity module, a Bluetooth module, etc., which will not be described in detail here.
[0186] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0187] As can be seen from the above, the computer device provided in this embodiment can improve the efficiency of the robot in obtaining the working area, so that the robot can work within the working area.
[0188] Those skilled in the art will appreciate that all or part of the steps in the various methods of the above embodiments may be accomplished by instructions, or by controlling related hardware through instructions. The instructions may be stored in a computer-readable storage medium and loaded and executed by a processor.
[0189] To this end, an embodiment of the present application provides a computer-readable storage medium storing a plurality of computer programs, which can be loaded by a processor to execute the steps of any of the methods for determining an operating area provided in the embodiments of the present application. For example, the computer program can execute the following steps:
[0190] Obtaining a first position collected by a user using a position calibrator in a work area;
[0191] Based on the first position, determining a second position in a first predetermined direction of the first position;
[0192] Based on the first position, determining the third position in a second predetermined direction of the first position, or based on the second position, determining the third position in a predetermined direction of the second position, wherein the first predetermined direction of the first position and the second predetermined direction of the first position are two different directions;
[0193] According to the first position, the second position and the third position, a working area is divided into a preset area shape in the working area.
[0194] The specific implementation of the above operations can be found in the previous embodiments and will not be repeated here.
[0195] The storage medium may include a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0196] Since the computer program stored in the storage medium can execute the steps in any one of the work area determination methods provided in the embodiments of the present application, the beneficial effects that can be achieved by any one of the work area determination methods provided in the embodiments of the present application can be achieved. Please refer to the previous embodiments for details and will not be repeated here.
[0197] The above is a detailed introduction to the method, device, storage medium and computer equipment for determining the working area provided in the embodiments of the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea; at the same time, for technical personnel in this field, based on the ideas of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A method for determining an operation area, characterized in that: include: Obtaining a first position collected by a user using a position calibrator in a work area; determining a second position based on the first position and in a first predetermined direction of the first position; determining a third position in a second preset direction of the first position based on the first position, or determining the third position in a preset direction of the second position based on the second position, wherein the first preset direction of the first position and the second preset direction of the first position are two different directions; Divide the working area into a preset area shape according to the first position, the second position and the third position, including: determining the fourth position according to the first position, the second position and the third position, including: connecting the first position and the second position to obtain a first boundary line; connecting the second position and the third position to obtain a second boundary line; obtaining a third boundary line according to the first boundary line and the distance from the first boundary line to the third position; obtaining a fourth boundary line according to the second boundary line and the distance from the second boundary line to the first position; determining the fourth position according to the intersection of the third boundary line and the fourth boundary line; connecting the first position, the second position, the third position and the fourth position according to the preset area shape to obtain a working area in the working area.
2. The method for determining an operation area according to claim 1, wherein: The working area includes a plurality of working areas, the plurality of working areas including a first working area and a second working area. After the first position, the second position, the third position, and the fourth position are connected according to a preset area shape to obtain the working area in the working area, the method further includes: Acquire endpoint positions in the plurality of operation areas, where the endpoint positions of the operation areas include the first position, the second position, the third position, and the fourth position; When the two end points of the first operating area are within the second operating area or on the boundary of the second operating area, the first operating area and the second operating area are spliced together.
3. The method for determining an operation area according to claim 1, wherein: The shape of the working area is rectangular or triangular.
4. The method for determining an operation area according to claim 1, wherein: The determining, based on the first position, a second position in a first preset direction of the first position includes: Get the first length value entered by the user; Determine a second position in a first preset direction of the first position according to the first length value and the first position; The determining of the third position in a second preset direction of the first position based on the first position, or determining the third position in a preset direction of the second position based on the second position, includes: Get the second length value entered by the user; A third position is determined in a second preset direction of the first position according to the second length value and the first position, or a third position is determined in a preset direction of the second position according to the second length value and the second position.
5. The method for determining an operation area according to claim 1, wherein: The working area is divided into a plurality of operation areas of preset area shapes, and boundary areas of adjacent operation areas overlap, and the boundary areas are areas shared by adjacent operation areas.
6. A device for determining an operation area, characterized in that: include: A first position obtaining unit, configured to obtain a first position set by a user in a work area; a second position determining unit, configured to determine a second position in a preset direction of the first position based on the first position; a third position determining unit, configured to determine a third position based on the first position and in a second preset direction of the first position, or to determine the third position based on the second position and in a preset direction of the second position, wherein the first preset direction of the first position and the second preset direction of the first position are two different directions; An operation area determination unit is used to divide the operation area in the work area according to a preset area shape based on the first position, the second position and the third position, and is also used to determine a fourth position based on the first position, the second position and the third position, and is also used to connect the first position and the second position to obtain a first boundary line; connect the second position and the third position to obtain a second boundary line; obtain a third boundary line based on the first boundary line and the distance from the first boundary line to the third position; obtain a fourth boundary line based on the second boundary line and the distance from the second boundary line to the first position; determine the fourth position based on the intersection of the third boundary line and the fourth boundary line; connect the first position, the second position, the third position and the fourth position according to the preset area shape to obtain a operation area in the work area.
7. A terminal, characterized in that: The system comprises a processor and a memory, wherein the memory stores a plurality of instructions; the processor loads instructions from the memory to execute the steps in the method for determining an operation area according to any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor to execute the steps in the method for determining an operation area according to any one of claims 1 to 5.
Citation Information
Patent Citations
Robot control method and device and electronic equipment
CN108983776A