CN114509748A - Ranging method, ranging device, storage medium and equipment - Google Patents

Ranging method, ranging device, storage medium and equipment Download PDF

Info

Publication number
CN114509748A
CN114509748A CN202011183778.2A CN202011183778A CN114509748A CN 114509748 A CN114509748 A CN 114509748A CN 202011183778 A CN202011183778 A CN 202011183778A CN 114509748 A CN114509748 A CN 114509748A
Authority
CN
China
Prior art keywords
ranging
frame
information
receiving
time information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011183778.2A
Other languages
Chinese (zh)
Inventor
赵瑞祥
尹作彪
张西洋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tsingoal Beijing Technology Co ltd
Original Assignee
Tsingoal Beijing Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tsingoal Beijing Technology Co ltd filed Critical Tsingoal Beijing Technology Co ltd
Priority to CN202011183778.2A priority Critical patent/CN114509748A/en
Priority to PCT/CN2021/126964 priority patent/WO2022089519A1/en
Publication of CN114509748A publication Critical patent/CN114509748A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S11/00Systems for determining distance or velocity not using reflection or reradiation
    • G01S11/02Systems for determining distance or velocity not using reflection or reradiation using radio waves
    • G01S11/08Systems for determining distance or velocity not using reflection or reradiation using radio waves using synchronised clocks
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S11/00Systems for determining distance or velocity not using reflection or reradiation
    • G01S11/02Systems for determining distance or velocity not using reflection or reradiation using radio waves
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S19/00Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
    • G01S19/38Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system
    • G01S19/39Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system the satellite radio beacon positioning system transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
    • G01S19/42Determining position
    • G01S19/43Determining position using carrier phase measurements, e.g. kinematic positioning; using long or short baseline interferometry
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Radar Systems Or Details Thereof (AREA)

Abstract

The application discloses a distance measuring method, a distance measuring device, a storage medium and a distance measuring device, and relates to the technical field of communication. The method comprises the following steps: the method includes transmitting at least one ranging frame, and receiving the at least one ranging frame. By the method, the distance measurement between any two devices is realized.

Description

Ranging method, ranging device, storage medium and equipment
Technical Field
The present application relates to the field of communications technologies, and in particular, to a ranging method, apparatus, storage medium, and device.
Background
With the development of information technology, communication technology is also developed, and further ranging technology is developed, wherein the ranging technology is used for measuring the distance between two devices; in the existing ranging system, ranging between some devices (for example, terminal devices such as mobile phones and computers) and a base station can be implemented to determine a distance between the device and the base station, but with the development of production and life, in addition to the distance between some devices and the base station, the distance between any two devices is more and more important, so how to implement ranging between any two devices becomes a key problem.
Disclosure of Invention
In view of the above, the present application provides a ranging method, apparatus, storage medium and device, which are used to solve at least one of the above technical problems.
According to a first aspect of the present application, there is provided a ranging method, performed by a first device, the method comprising:
transmitting at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is received.
In another possible implementation manner, the method further includes:
at least four pieces of time information are acquired by transmitting at least one ranging frame and receiving at least one ranging frame.
In another possible implementation, the method further comprises at least one of:
acquiring at least six pieces of time information by sending at least two ranging frames and at least one received ranging frame;
at least six pieces of time information are acquired by transmitting at least one ranging frame and receiving at least two ranging frames.
In another possible implementation manner, the method further includes:
receiving at least one time information;
wherein, the obtaining of the at least four time information by sending the at least one ranging frame and the received at least one ranging frame includes:
at least four pieces of time information are acquired by transmitting at least one ranging frame, receiving at least one ranging frame, and receiving the at least one piece of time information.
In another possible implementation manner, the received at least one ranging frame carries time information;
wherein, the obtaining of the at least four time information by sending the at least one ranging frame and the received at least one ranging frame includes:
at least four pieces of time information are obtained by sending at least one ranging frame, receiving at least one ranging frame and the time information carried in the received at least one ranging frame.
In another possible implementation manner, the method further includes:
receiving at least one time information;
wherein, the obtaining of at least six time information by sending at least two ranging frames and at least one received ranging frame includes:
acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and at least one piece of received time information;
wherein, the obtaining of at least six time information by sending at least one ranging frame and receiving at least two ranging frames comprises:
at least six pieces of time information are acquired by transmitting at least one ranging frame, receiving at least two ranging frames, and receiving at least one piece of time information.
In another possible implementation manner, the received at least one ranging frame carries time information;
wherein, the obtaining of at least six time information by sending at least two ranging frames and at least one received ranging frame includes:
acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and time information carried in the at least one received ranging frame;
wherein, the obtaining of at least six time information by sending at least one ranging frame and receiving at least two ranging frames comprises:
at least six pieces of time information are obtained by sending at least one ranging frame, at least two received ranging frames and the time information carried in the at least one received ranging frame.
In another possible implementation, the method further comprises at least one of: the at least two sent ranging frames at least comprise a Final frame;
the received at least two ranging frames comprise at least one Final frame.
In another possible implementation manner, the time information is carried in a ranging frame; and/or the time information is not carried by a ranging frame.
In another possible implementation manner, the method further includes:
when the time information is not carried by the ranging frame, the time information is sent through a first channel; and/or the presence of a gas in the gas,
when the time information is not carried by the ranging frame, the data frame is sent through a second channel;
wherein, the first channel comprises a channel for transceiving a ranging frame;
the second channel is a channel not containing a transceiving ranging frame.
In another possible implementation manner, the second channel is a bluetooth channel.
In another possible implementation manner, the frame format of the received ranging frame is specifically a fourth frame format;
wherein the fourth frame format does not contain payload data.
In another possible implementation, a frame format of the ranging frame includes at least one of:
a first frame format, a second frame format, and a third frame format.
In another possible implementation manner, the first frame format includes: synchronizing SYNC, a frame start symbol SFD, a physical frame header PHR and a packet load PHR Payload;
the second frame format includes: SYNC, SFD, scrambling time stamp sequence STS, PHR, PHY Payload;
the third frame format includes: SYNC, SFD, PHR, PHY Payload, STS.
In another possible implementation manner, the carried time information includes at least one of the following:
a transmission time of the received at least one ranging frame and reception time information of the transmitted at least one ranging frame;
transmitting transmission time information of the at least one ranging frame, and receiving reception time information of the at least one ranging frame.
In another possible implementation, the transmitting at least one ranging frame; and, receiving at least one ranging frame, comprising:
sending at least one ranging frame to at least two opposite terminal devices;
and receiving at least one ranging frame respectively sent by at least two opposite-end devices.
In another possible implementation manner, at least one ranging frame sent to the at least two peer devices is the same frame.
In another possible implementation manner, the sending at least one ranging frame includes:
the method includes sending at least one ranging initiation frame to at least one second device of at least two peer devices, and sending at least one ranging reply frame to at least one third device of the at least two peer devices.
In another possible implementation manner, the sending at least one ranging initiation frame to at least one second device of the at least two peer devices further includes:
receiving at least one ranging reply frame transmitted by the at least one second device;
wherein, sending at least one ranging reply frame to at least one third device of the at least two peer devices, the method further includes:
receiving at least one ranging initiation frame transmitted by the at least one third device.
In another possible implementation manner, the method further includes:
the at least one ranging initiation frame comprises the same frame as the corresponding ranging reply frame.
In another possible implementation manner, the method further includes:
and acquiring distance information between the first equipment and opposite equipment according to the at least four pieces of time information.
In another possible implementation manner, the obtaining, according to the at least four pieces of time information, distance information between the first device and an opposite device includes at least one of the following:
determining distance information between the first device and opposite-end equipment according to the sending time of sending the ranging frame, the receiving time of receiving the ranging frame and the received time information;
and receiving distance information between the first equipment and the opposite terminal equipment, which is sent by the opposite terminal equipment.
In another possible implementation manner, the method further includes:
and acquiring distance information between the first equipment and opposite equipment according to the at least six pieces of time information.
In another possible implementation manner, obtaining distance information between the first device and the peer device according to the at least six pieces of time information includes at least one of:
determining distance information between the first device and an opposite-end device according to sending time information respectively corresponding to at least two distance measuring frames, receiving time information corresponding to at least one distance measuring frame and the received time information;
determining distance information between the first device and opposite-end equipment according to sending time information of sending at least one ranging frame, receiving time corresponding to at least two ranging frames respectively and the received time information;
and receiving distance information between the first device and the opposite terminal device, which is sent by the opposite terminal device.
In another possible implementation manner, the determining, according to the sending time information corresponding to the sending of the at least two ranging frames, the receiving time information corresponding to the receiving of the at least one ranging frame, and the received time information, the distance information between the first device and the peer device includes:
determining distance information between the first equipment and opposite-end equipment according to sending time information of sending at least one ranging frame, sending time of sending a final frame and receiving time information of receiving at least one ranging frame;
wherein, the determining the distance information between the first device and the opposite device according to the sending time information of sending at least one ranging frame, the receiving time corresponding to at least two ranging frames respectively and the received time information comprises:
and determining the distance information between the first equipment and the opposite equipment according to the sending time information of sending at least one ranging frame, the receiving time information of receiving at least one ranging frame and the receiving time information of receiving a final frame.
In another possible implementation manner, the method further includes:
receiving a ranging instruction;
transmitting at least one ranging frame based on the ranging instruction; and the number of the first and second groups,
receiving at least one ranging frame based on the ranging instruction.
In another possible implementation manner, the ranging instruction includes: ranging time slot information;
wherein the sending at least one ranging frame based on the ranging instruction comprises:
transmitting at least one ranging frame based on the ranging slot information;
wherein the receiving at least one ranging frame based on the ranging instruction comprises:
receiving at least one ranging frame based on the ranging slot information.
In another possible implementation manner, the ranging slot information includes: presetting a time slot;
the transmitting at least one ranging frame based on the ranging slot information includes:
transmitting at least one ranging frame in a preset time slot;
wherein the receiving at least one ranging frame based on the ranging slot information comprises:
and receiving at least one ranging frame in the preset time slot.
In another possible implementation manner, the sending at least one ranging frame based on the ranging instruction; and receiving at least one ranging frame based on the ranging instruction, including:
transmitting at least one ranging frame within a random time slot based on the ranging instruction; and (c) a second step of,
receiving at least one ranging frame within a random time slot based on the ranging instruction.
In another possible implementation manner, the method further includes:
and determining the random time slot according to the self equipment information.
In another possible implementation manner, the method further includes:
and sending the equipment information so that the opposite terminal equipment determines the ranging instruction based on the equipment information.
In another possible implementation manner, the method further includes:
and sending the ranging command so that the equipment receiving the ranging command sends and/or receives the ranging frame.
In another possible implementation manner, the ranging instruction includes ranging slot information:
the method for determining the ranging slot information includes:
acquiring equipment information sent by opposite-end equipment;
and determining the ranging time slot information based on the equipment information sent by the opposite terminal equipment and the self equipment information.
In another possible implementation manner, the device information includes: a device identification;
wherein determining the ranging slot information based on the device information sent by the peer device and the device information of the peer device includes:
sorting processing is carried out based on the device identifications respectively corresponding to the devices;
determining the ranging slot information based on the sequencing result.
In another possible implementation manner, the method further includes:
the equipment information is transmitted through a first channel and/or a second channel;
the ranging instruction is transmitted through the first channel and/or the second channel.
In another possible implementation manner, the communication distance of the first channel is matched with the communication distance of the second channel.
In another possible implementation manner, the method further includes:
the first channel is specifically an ultra-wideband UWB channel; and/or the presence of a gas in the gas,
the second channel is specifically a bluetooth channel.
In another possible implementation manner, the method further includes:
uploading distance information between the first equipment and opposite-end equipment to corresponding equipment;
the corresponding device comprises at least one of:
a mobile terminal;
a gateway;
and (4) a server.
In another possible implementation manner, the uploading the distance information between the first device and the peer device to the corresponding device includes:
and uploading the distance information between the first equipment and the opposite terminal equipment to corresponding equipment through the first channel or the second channel.
In another possible implementation manner, the uploading the distance information between the first device and the peer device to the corresponding device, and then further includes:
receiving an upload success message sent by the corresponding device, wherein the upload success message is used for informing the first device of distance information of successful upload;
and deleting the distance information successfully uploaded based on the successful uploading message.
In another possible implementation, if the distance information is uploaded through at least two data packets, then,
based on the upload success message, deleting the distance information successfully uploaded, including:
determining a data packet successfully uploaded based on the successful uploading message;
and deleting the distance information corresponding to the successfully uploaded data packet.
According to a second aspect of the present application, there is provided a ranging apparatus comprising:
a first transmitting module, configured to transmit at least one ranging frame; and the number of the first and second groups,
the first receiving module is used for receiving at least one ranging frame.
In another possible implementation manner, the apparatus further includes: a first obtaining module, wherein,
the first obtaining module is configured to obtain at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame.
In another possible implementation manner, the apparatus further includes: at least one of a second acquisition module and a third acquisition module, wherein,
the second obtaining module is configured to obtain at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame;
the third obtaining module is configured to obtain at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames.
In another possible implementation, wherein,
the first receiving module is further configured to receive at least one piece of time information;
the first obtaining module is specifically configured to, when obtaining at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame:
at least four pieces of time information are acquired by transmitting at least one ranging frame, receiving at least one ranging frame, and receiving the at least one piece of time information.
In another possible implementation manner, the received at least one ranging frame carries time information;
the first obtaining module is specifically configured to, when obtaining at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame:
at least four pieces of time information are obtained by sending at least one ranging frame, receiving at least one ranging frame and the time information carried in the received at least one ranging frame.
In another possible implementation, wherein,
the first receiving module is further configured to receive at least one piece of time information;
the second obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame:
acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and at least one piece of received time information;
the third obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames:
at least six pieces of time information are acquired by transmitting at least one ranging frame, receiving at least two ranging frames, and receiving at least one piece of time information.
In another possible implementation manner, the received at least one ranging frame carries time information;
the second obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame:
acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and time information carried in the at least one received ranging frame;
the third obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames:
at least six pieces of time information are obtained by sending at least one ranging frame, at least two received ranging frames and the time information carried in the at least one received ranging frame.
In another possible implementation manner, the apparatus further includes: the at least two sent ranging frames at least comprise a Final frame; and/or the presence of a gas in the gas,
the at least two received ranging frames comprise at least one Final frame.
In another possible implementation manner, the time information is carried in a ranging frame; and/or the time information is not carried by a ranging frame.
In another possible implementation manner, the apparatus method further includes:
when the time information is not carried by the ranging frame, the time information is sent through a first channel; and/or the presence of a gas in the gas,
when the time information is not carried by the ranging frame, the data frame is sent through a second channel;
wherein, the first channel comprises a channel for transceiving a ranging frame;
the second channel is a channel not containing a transceiving ranging frame.
In another possible implementation manner, the second channel is a bluetooth channel.
In another possible implementation manner, the frame format of the received ranging frame is specifically a fourth frame format;
wherein the fourth frame format does not contain payload data.
In another possible implementation, a frame format of the ranging frame includes at least one of:
a first frame format, a second frame format, and a third frame format.
In another possible implementation manner, the first frame format includes: synchronizing SYNC, a frame start symbol SFD, a physical frame header PHR and a packet load PHR Payload;
the second frame format includes: SYNC, SFD, scrambling time stamp sequence STS, PHR, PHY Payload;
the third frame format includes: SYNC, SFD, PHR, PHY Payload, STS.
In another possible implementation manner, the carried time information includes at least one of the following:
a transmission time of the received at least one ranging frame and reception time information of the transmitted at least one ranging frame;
transmitting transmission time information of the at least one ranging frame, and receiving reception time information of the at least one ranging frame.
In another possible implementation manner, the first sending module is specifically configured to send at least one ranging frame to at least two peer devices when sending the at least one ranging frame; and when receiving at least one ranging frame, the first receiving module is specifically configured to:
and receiving at least one ranging frame respectively sent by at least two opposite-end devices.
In another possible implementation manner, at least one ranging frame sent to the at least two peer devices is the same frame.
In another possible implementation manner, when the first sending module sends at least one ranging frame, the first sending module is specifically configured to:
the method includes sending at least one ranging initiation frame to at least one second device of at least two peer devices, and sending at least one ranging reply frame to at least one third device of the at least two peer devices.
In another possible implementation manner, the first receiving module is further configured to receive at least one ranging reply frame sent by the at least one second device;
wherein the first receiving module is further configured to: receiving at least one ranging initiation frame transmitted by the at least one third device.
In another possible implementation manner, the apparatus further includes:
the at least one ranging initiation frame comprises the same frame as the corresponding ranging reply frame.
In another possible implementation manner, the apparatus further includes: a fourth obtaining module, wherein,
the fourth obtaining module is configured to obtain distance information between the first device and the peer device according to the at least four pieces of time information.
In another possible implementation manner, when the fourth obtaining module obtains the distance information between the first device and the peer device according to the at least four pieces of time information, the fourth obtaining module is specifically configured to at least one of:
determining distance information between the first device and opposite-end equipment according to the sending time of sending the ranging frame, the receiving time of receiving the ranging frame and the received time information;
and receiving distance information between the first equipment and the opposite terminal equipment, which is sent by the opposite terminal equipment.
In another possible implementation manner, the apparatus further includes: a fifth obtaining module, wherein,
and the fifth obtaining module is configured to obtain distance information between the first device and the peer device according to the at least six pieces of time information.
In another possible implementation manner, when obtaining the distance information between the first device and the peer device according to the at least six pieces of time information, the fifth obtaining module is specifically configured to at least one of:
determining distance information between the first device and an opposite-end device according to sending time information respectively corresponding to at least two distance measuring frames, receiving time information corresponding to at least one distance measuring frame and the received time information;
determining distance information between the first device and opposite-end equipment according to sending time information of sending at least one ranging frame, receiving time corresponding to at least two ranging frames respectively and the received time information;
and receiving distance information between the first device and the opposite terminal device, which is sent by the opposite terminal device.
In another possible implementation manner, when determining the distance information between the first device and the peer device according to the sending time information corresponding to the sending of the at least two ranging frames, the receiving time information corresponding to the receiving of the at least one ranging frame, and the received time information, the fifth obtaining module is specifically configured to:
determining distance information between the first equipment and opposite-end equipment according to sending time information of sending at least one ranging frame, sending time of sending a final frame and receiving time information of receiving at least one ranging frame;
the fifth obtaining module is specifically configured to, when determining distance information between the first device and the peer device according to sending time information for sending at least one ranging frame, receiving time corresponding to each of at least two ranging frames, and the received time information:
and determining the distance information between the first equipment and the opposite terminal equipment according to the sending time information of sending at least one ranging frame, the receiving time information of receiving at least one ranging frame and the receiving time information of receiving a final frame.
In another possible implementation manner, the apparatus further includes:
the first receiving module is further used for receiving a ranging instruction;
the first sending module is further configured to send at least one ranging frame based on the ranging instruction; and the number of the first and second groups,
the first receiving module is further configured to receive at least one ranging frame based on the ranging instruction.
In another possible implementation manner, the ranging instruction includes: ranging time slot information;
the first sending module is specifically configured to, when sending at least one ranging frame based on the ranging instruction: transmitting at least one ranging frame based on the ranging slot information;
the first receiving module is specifically configured to, when receiving at least one ranging frame based on the ranging instruction: receiving at least one ranging frame based on the ranging slot information.
In another possible implementation manner, the ranging slot information includes: presetting a time slot;
the first sending module, when sending at least one ranging frame based on the ranging slot information, is specifically configured to:
transmitting at least one ranging frame in a preset time slot;
wherein, when receiving at least one ranging frame based on the ranging slot information, the first receiving module is specifically configured to:
and receiving at least one ranging frame in the preset time slot.
In another possible implementation manner, when the first sending module sends at least one ranging frame based on the ranging instruction, the first sending module sends the at least one ranging frame in a random time slot based on the ranging instruction; and when receiving at least one ranging frame based on the ranging instruction, the first receiving module is specifically configured to: receiving at least one ranging frame within a random time slot based on the ranging instruction.
In another possible implementation manner, the apparatus further includes: a determination module that determines, among other things,
the determining module is configured to determine the random time slot according to the device information of the determining module.
In another possible implementation manner, the apparatus further includes: the first sending module is further configured to send device information, so that the peer device determines the ranging instruction based on the device information.
In another possible implementation manner, the apparatus further includes:
the first sending module is further configured to send a ranging instruction, so that a device receiving the ranging instruction sends and/or receives a ranging frame.
In another possible implementation manner, the ranging instruction includes ranging slot information:
when determining the ranging slot information, the determining module is specifically configured to:
acquiring equipment information sent by opposite-end equipment;
and determining the ranging time slot information based on the equipment information sent by the opposite terminal equipment and the self equipment information.
In another possible implementation manner, the device information includes: a device identification;
wherein, when determining the ranging slot information based on the device information sent by the peer device and the device information of the peer device, the determining module is specifically configured to:
sorting processing is carried out based on the device identifications respectively corresponding to the devices;
determining the ranging slot information based on the sequencing result.
In another possible implementation manner, the apparatus further includes:
the equipment information is transmitted through a first channel and/or a second channel;
the ranging instruction is transmitted through the first channel and/or the second channel.
In another possible implementation manner, the communication distance of the first channel is matched with the communication distance of the second channel.
In another possible implementation manner, the apparatus further includes:
the first channel is specifically an ultra-wideband UWB channel; and/or the presence of a gas in the gas,
the second channel is specifically a bluetooth channel.
In another possible implementation manner, the apparatus further includes: an upload module, wherein the upload module is capable of,
the uploading module is used for uploading the distance information between the first equipment and the opposite terminal equipment to the corresponding equipment;
the corresponding device comprises at least one of:
a mobile terminal;
a gateway;
and (4) a server.
In another possible implementation manner, when uploading the distance information between the first device and the peer device to the corresponding device, the uploading module is specifically configured to:
and uploading the distance information between the first equipment and the opposite terminal equipment to corresponding equipment through the first channel or the second channel.
In another possible implementation manner, the first receiving module is further configured to receive an upload success message sent by the corresponding device, where the upload success message is used to inform the first device of distance information that the upload is successful;
the device further comprises: a deletion module for deleting, wherein,
and the deleting module is used for deleting the distance information which is successfully uploaded based on the successful uploading message.
In another possible implementation, when the distance information is uploaded through at least two data packets,
the deleting module is specifically configured to, when deleting the successfully uploaded distance information based on the successfully uploaded message:
determining a data packet successfully uploaded based on the successful uploading message;
and deleting the distance information corresponding to the successfully uploaded data packet.
According to a third aspect of the present application, there is provided a storage medium for storing computer instructions which, when executed on a computer, enable the computer to perform the ranging method according to the first aspect or any possible implementation manner shown in the first aspect.
According to a fourth aspect of the present application, there is provided a first device,
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: and executing the operation corresponding to the ranging method according to the first aspect or any possible implementation manner shown in the first aspect.
According to a fifth aspect of the present application, there is provided a ranging method, performed by a second device, comprising:
receiving at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is transmitted.
In one possible implementation, the receiving at least one ranging frame includes:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the gas,
receiving at least one ranging frame transmitted by at least one third device;
wherein the transmitting at least one ranging frame comprises:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one third device.
In another possible implementation manner, if the number of the first devices is at least two, then,
at least one ranging frame is the same frame in at least one ranging frame sent to each first device.
In another possible implementation manner, if the number of the third devices is at least two, then,
at least one ranging frame is the same frame in at least one ranging frame sent to each third device.
In another possible implementation manner, the method further includes:
at least one ranging frame in the at least one ranging frame transmitted to the at least one third device and at least one ranging frame in the at least one ranging frame transmitted to the at least one first device are the same ranging frame.
In another possible implementation manner, the method further includes:
for each first device, acquiring at least four pieces of time information by receiving at least one ranging frame and transmitting at least one ranging frame; and/or the presence of a gas in the gas,
for each first device, acquiring at least six pieces of time information by receiving at least two ranging frames and transmitting at least one ranging frame; and/or the presence of a gas in the gas,
for each first device, at least six pieces of time information are acquired by receiving at least one ranging frame and transmitting at least two ranging frames.
In another possible implementation, the method further comprises at least one of:
for each first device, obtaining distance information between the second device and each first device based on the at least four pieces of time information;
for each first device, obtaining distance information between the second device and the each first device based on the at least six pieces of time information.
In another possible implementation, the method further comprises at least one of:
for each third device, acquiring at least four pieces of time information by transmitting at least one ranging frame and receiving at least one ranging frame;
for each third device, acquiring at least six pieces of time information by transmitting at least two ranging frames and receiving at least one ranging frame;
for each third device, at least six pieces of time information are acquired by transmitting at least one ranging frame and receiving at least two ranging frames.
In another possible implementation, the method further comprises at least one of:
for each third device, obtaining distance information between the second device and each third device based on the at least two pieces of time information;
for each third device, obtaining distance information between the second device and each third device based on the at least four pieces of time information;
for each third device, obtaining distance information between the second device and the each third device based on the at least six pieces of time information.
In another possible implementation manner, the method further includes:
at least one received ranging frame is a ranging initiating frame;
at least one of the ranging frames transmitted is a ranging reply frame.
According to a sixth aspect of the present application, there is provided a ranging apparatus comprising:
a second receiving module, configured to receive at least one ranging frame; and the number of the first and second groups,
and a second sending module, configured to send at least one ranging frame.
In a possible implementation manner, when receiving at least one ranging frame, the second receiving module is specifically configured to:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the gas,
receiving at least one ranging frame transmitted by at least one third device;
wherein, when the second sending module sends at least one ranging frame, the second sending module is specifically configured to:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one third device.
In another possible implementation manner, when there are at least two first devices, at least one of the at least one ranging frame sent to each first device is the same frame.
In another possible implementation, when the third devices are at least two,
at least one ranging frame is the same frame in at least one ranging frame sent to each third device.
In another possible implementation manner, the apparatus further includes:
at least one ranging frame in the at least one ranging frame transmitted to the at least one third device and at least one ranging frame in the at least one ranging frame transmitted to the at least one first device are the same ranging frame.
In another possible implementation manner, the apparatus further includes: a sixth obtaining module;
the sixth obtaining module is configured to obtain, for each first device, at least four pieces of time information by receiving at least one ranging frame and sending at least one ranging frame; and/or the presence of a gas in the gas,
the sixth obtaining module is configured to obtain, for each first device, at least six pieces of time information by receiving at least two ranging frames and sending at least one ranging frame; and/or the presence of a gas in the gas,
the sixth obtaining module is configured to obtain, for each first device, at least six pieces of time information by receiving at least one ranging frame and sending at least two ranging frames.
In another possible implementation manner, the apparatus further includes: a seventh obtaining module, wherein,
the seventh obtaining module is configured to, for each first device, obtain distance information between the second device and each first device based on the at least four pieces of time information; and/or the presence of a gas in the gas,
the seventh obtaining module is configured to, for each first device, obtain distance information between the second device and each first device based on the at least six pieces of time information.
In another possible implementation manner, the apparatus further includes: an eighth obtaining module, wherein,
the eighth obtaining module is configured to obtain, for each third device, at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame; and/or the presence of a gas in the gas,
the eighth obtaining module is configured to obtain, for each third device, at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame; and/or the presence of a gas in the gas,
the eighth obtaining module is configured to obtain, for each third device, at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames.
In another possible implementation manner, the apparatus further includes: a ninth obtaining module, wherein,
the ninth obtaining module is configured to obtain, for each third device, distance information between the second device and each third device based on the at least four pieces of time information; and/or the presence of a gas in the gas,
the ninth obtaining module is configured to, for each third device, obtain distance information between the second device and each third device based on the at least six pieces of time information.
In another possible implementation manner, the apparatus further includes:
at least one received ranging frame is a ranging initiating frame;
at least one of the ranging frames transmitted is a ranging reply frame.
According to a seventh aspect of the present application, there is provided a storage medium for storing computer instructions which, when run on a computer, cause the computer to perform the ranging method according to the fifth aspect or any possible implementation manner shown in the fifth aspect.
According to an eighth aspect of the present application, there is provided a second apparatus,
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: and performing an operation corresponding to the ranging method according to the fifth aspect or any possible implementation manner shown in the fifth aspect.
According to a ninth aspect of the present application, there is provided a ranging method, performed by a third device, comprising:
receiving at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is transmitted.
In another possible implementation manner, the receiving at least one ranging frame includes:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the gas,
at least one ranging frame transmitted by at least one second device is received.
Wherein the transmitting at least one ranging frame comprises:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one second device.
In another possible implementation manner, if the number of the first devices is at least two, then,
at least one ranging frame exists in the received at least one ranging frame sent by each first device and is the same frame.
In another possible implementation manner, if the number of the second devices is at least two, then,
at least one ranging frame exists in the received at least one ranging frame sent by each second device and is the same frame.
In another possible implementation manner, the method further includes:
at least one ranging frame in the at least one ranging frame transmitted to the at least one second device and at least one ranging frame in the at least one ranging frame transmitted to the at least one first device are the same ranging frame.
In another possible implementation manner, the method further includes: at least one sent ranging frame is a ranging initiating frame;
the at least one frame received is a ranging reply frame.
According to a tenth aspect of the present application, there is provided a ranging apparatus comprising:
a third receiving module, configured to receive at least one ranging frame; and the number of the first and second groups,
and a third sending module, configured to send at least one ranging frame.
In a possible implementation manner, when receiving at least one ranging frame, the third receiving module is specifically configured to:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the gas,
at least one ranging frame transmitted by at least one second device is received.
Wherein, when the third sending module sends at least one ranging frame, the third sending module is specifically configured to:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one second device.
In another possible implementation manner, when the number of the first devices is at least two, at least one of the received at least one ranging frame sent by each first device is the same frame.
In another possible implementation manner, when there are at least two second devices, at least one of the received at least one ranging frame sent by each second device is the same frame.
In another possible implementation manner, the apparatus further includes:
at least one ranging frame in the at least one ranging frame transmitted to the at least one second device and at least one ranging frame in the at least one ranging frame transmitted to the at least one first device are the same ranging frame.
In another possible implementation manner, the apparatus further includes:
at least one sent ranging frame is a ranging initiating frame;
the at least one frame received is a ranging reply frame.
According to an eleventh aspect of the present application, there is provided a storage medium for storing computer instructions which, when run on a computer, cause the computer to perform the ranging method according to any possible implementation manner shown in the above ninth aspect or the ninth aspect.
According to a twelfth aspect of the present application, there is provided a third apparatus,
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: and executing the operation corresponding to the ranging method according to the ninth aspect or any possible implementation manner shown in the ninth aspect.
Compared with the prior art, the ranging method, the ranging device, the storage medium and the first device provided by the application have the advantages that the first device sends at least one ranging frame and receives at least one ranging frame, and in the application, the first device can realize ranging between any two devices by sending and/or receiving at least one ranging frame.
Compared with the prior art, the ranging method, the ranging device, the storage medium and the second device provided by the application, the second device receives at least one ranging frame and sends the at least one ranging frame.
Compared with the prior art, the ranging method, the ranging device, the storage medium and the third device provided by the application, in the application, the third device receives at least one ranging frame, and the third device sends the at least one ranging frame.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1a illustrates a schematic view of a ranging application scenario provided in an embodiment of the present application;
fig. 1b is a schematic flowchart illustrating a ranging method according to an embodiment of the present application;
fig. 2 is a schematic structural diagram illustrating a distance measuring device according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a first device provided in an embodiment of the present application;
fig. 4 is a schematic diagram illustrating a connection manner of a base station, an industrial personal computer host and a switch provided in the embodiment of the present application;
fig. 5 is a schematic diagram illustrating a packet upload provided by an embodiment of the present application;
FIG. 6 is a diagram illustrating a ranging frame transmitted between devices according to an embodiment of the present disclosure;
FIG. 7 is a diagram illustrating device discovery in an embodiment of the present application;
fig. 8 shows a frame configuration diagram in an embodiment of the present application;
FIG. 9 is a flow chart illustrating another ranging method in an embodiment of the present application;
FIG. 10 is a flow chart illustrating a further ranging method in an embodiment of the present application;
FIG. 11 is a flow chart illustrating a further ranging method in an embodiment of the present application;
FIG. 12 is a flow chart illustrating a further ranging method in an embodiment of the present application;
fig. 13 is a schematic flow chart illustrating a further ranging method in an embodiment of the present application;
FIG. 14 is a flow chart illustrating a further ranging method in an embodiment of the present application;
FIG. 15 is a schematic diagram illustrating four timestamp acquisition modes in an embodiment of the present application;
FIG. 16 is a schematic diagram illustrating six timestamp acquisition modes in an embodiment of the present application;
fig. 17 is a schematic diagram illustrating a relationship between ranging apparatuses provided in an embodiment of the present application;
fig. 18 is a schematic structural diagram of another distance measuring device provided in the embodiment of the present application;
fig. 19 shows a schematic structural diagram of another distance measuring device provided in the embodiment of the present application.
Detailed Description
Exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. While exemplary embodiments of the present application are shown in the drawings, it should be understood that the present application may be embodied in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the disclosure to those skilled in the art.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that such uses are interchangeable under appropriate circumstances such that the embodiments of the application described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the term "include" and its variants are to be read as open-ended terms meaning "including, but not limited to".
In production and life, in many application scenarios, the distance between any two devices needs to be measured, for example, between people carrying devices such as tags, between people and devices, and between devices, so that safety can be guaranteed, and important guiding significance is brought to production and life.
For example, as shown in fig. 1a, when five people (1, 2,3,4, 5) are relatively close, we need to measure the distance between the five people, i.e. the exact distance between each person and all people in its vicinity. As shown in FIG. 1a, the distances between 1, 2,3,4, 5 are measured in real time, i.e. d is obtained12、d13、d14、d15,d23、d24、d34
Therefore, how to implement ranging between any two devices becomes a key issue.
The distance measuring method, device, storage medium and equipment provided by the embodiment of the application aim to solve the technical problems in the prior art.
The following describes the technical solutions of the present application and how to solve the above technical problems with specific embodiments. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present application will be described below with reference to the accompanying drawings.
The embodiment of the application provides a ranging method, which is executed by first equipment, wherein in the embodiment of the application, the first equipment can be electronic equipment; in an embodiment of the present application, an electronic device may include: mobile tags, cell phones, tablet computers, and the like; as shown in fig. 1b, the specific implementation is as follows:
step S101, at least one ranging frame is sent;
step S102, at least one ranging frame is received.
Further, in this embodiment of the present application, step S101 may be executed before step S102, or after step S102, or may be executed simultaneously with step S102, which is not limited in this embodiment of the present application, where fig. 1b only shows one possible implementation manner, and is not limited to a specific execution order.
Specifically, step S101 and step S102 are performed simultaneously, that is, the receiving end device (for receiving at least one ranging frame sent by the first device in step S101) corresponding to step S101 and the transmitting end device (for sending at least one ranging frame received by the first device in step S102) corresponding to step S102 are different devices, and the corresponding transceiving frequencies are also different.
Compared with the prior art, in the ranging method provided by the embodiment of the application, the first device sends at least one ranging frame and receives at least one ranging frame.
Specifically, in this embodiment of the present application, in step S101, the ranging frame sent by the first device may be a ranging initiation frame or a ranging reply frame; in step S102, the ranging frame received by the first device may be a ranging initiation frame or a ranging reply frame. In this embodiment of the application, the ranging frame sent and/or the ranging frame received by the first device is a ranging initiation frame and/or a ranging reply frame, and is specifically determined for different application scenarios, which is not limited in this embodiment of the application.
Specifically, between any two devices, one ranging initiation frame and one ranging reply frame constitute one ranging round trip.
In another possible implementation manner of the embodiment of the present application, the method further includes: step Sa3 (not shown), in which,
step Sa3, obtaining at least four time information by sending at least one ranging frame and at least one received ranging frame.
Specifically, if four pieces of time information are obtained, the four pieces of time information may be obtained through any one of the sent at least one ranging frame and the received at least one ranging frame, and any one of the sent ranging frame and the received ranging frame. In this embodiment, any sent ranging frame may be a ranging initiation frame or a ranging reply frame, and any received ranging frame may be a ranging initiation frame or a ranging reply frame.
Specifically, in this embodiment of the present application, the four pieces of time information may be four time stamps, and specifically may include: the method comprises the steps that a first device sends a sending timestamp of a ranging frame to an opposite-end device, the opposite-end device receives a receiving timestamp of the ranging frame sent by the first device, the opposite-end device sends the sending timestamp of the ranging frame to the first device, and the first device receives the receiving timestamp of the ranging frame sent by the opposite-end device.
Further, in the embodiment of the present application, the four pieces of time information may also be embodied as two time difference values; in the embodiment of the application, each time difference value is a difference value between two time stamps; in this embodiment, the two time difference values may include: the method comprises the steps that the first device sends a difference value between a sending time stamp of a ranging frame sent to the opposite-end device and a receiving time stamp of the ranging frame received by the first device to the opposite-end device room, and the opposite-end device receives a difference value between a receiving time stamp of the ranging frame sent by the first device and a sending time stamp of the ranging frame sent by the opposite-end device to the first device. In the embodiments of the present application, no limitation is imposed.
Further, in the embodiment of the present application, the four pieces of time information may also be embodied as two time stamps and a time difference (the time difference is a difference between the two time stamps); in this embodiment of the present application, the time difference is a difference between a sending time stamp of a ranging frame sent by an opposite end device to a first device and a receiving time stamp of the ranging frame sent by the first device and received by the opposite end device; the two timestamps include: the first device sends a sending time stamp of the ranging frame to the opposite device, and the first device receives a receiving time stamp of the ranging frame sent by the opposite device. In the embodiments of the present application, no limitation is imposed.
Further, in this embodiment of the application, at least four pieces of time information acquired by the first device may be used for ranging, that is, distance information between the first device and the peer device is determined. Of course, the first device may also implement other operations according to the acquired at least four pieces of time information.
The first device does not need to repeat the description in the embodiment of the present application in a manner of implementing other operations according to the acquired at least four pieces of time information; the manner in which the first device performs ranging according to the at least four pieces of acquired time information is described in detail in the following embodiments.
Further, in the above embodiment, taking four pieces of time information as an example, the first device may, by sending a ranging frame and receiving the ranging frame, generally, accurately determine a sending time stamp of the ranging frame sent by the first device and a receiving time stamp of the ranging frame sent by the opposite device received by the first device (it may also be a difference between the receiving time stamp of the ranging frame sent by the opposite device received by the first device and the sending time stamp of the ranging frame sent by the first device), but the receiving time of the ranging frame sent by the opposite device received by the opposite device and the sending time stamp of the ranging frame sent by the opposite device to the first device cannot be accurately determined, in order to obtain ranging information between the first device and the opposite device more accurately, so as to implement more accurate ranging, the method further includes: step Sb (not shown in the figure), in which,
step Sb, receiving at least one piece of time information;
specifically, in this embodiment of the present application, a distance (a distance between any two devices) is determined through a ranging round trip (that is, a ranging initiation frame and a ranging reply frame). The embodiments of the present application are not limited thereto.
Specifically, in this embodiment of the present application, the at least one piece of time information may include: the method comprises the steps that opposite-end equipment receives a time stamp of a ranging frame sent by first equipment and sends the time stamp of the ranging frame to the first equipment; and/or, the at least one time information may further comprise: and the opposite terminal equipment sends difference information between the timestamp of the ranging frame sent to the first equipment and the timestamp of the ranging frame sent by the first equipment and received by the opposite terminal equipment.
Specifically, in this embodiment of the present application, if the time information can be received through a ranging frame and a non-ranging frame that are not in the ranging round trip, the frame format of the received ranging frame is specifically the fourth frame format;
it should be noted that the received ranging frame referred to herein is a ranging frame used for ranging above, and is not an additional ranging frame used for carrying time information herein.
Wherein, the fourth frame format does not contain payload data. For example, the fourth frame format may include: synchronization (SYNC), Frame Start (SFD), and Scrambled Timestamp Sequence (STS), specifically, a Frame format shown in fig. 8 as Scrambled Timestamp Sequence packet configuration 3(STS packet configuration 3). In the embodiment of the present application, the ranging frame for performing ranging between devices does not contain payload, and the frame length of the ranging frame is shorter than that of the ranging frame containing payload, so that the ranging power consumption can be reduced.
On the basis that the first device receives the at least one piece of time information, the method for acquiring the at least four pieces of time information by sending the at least one ranging frame and the received at least one ranging frame comprises the following steps: at least four pieces of time information are acquired by transmitting at least one ranging frame, receiving at least one ranging frame, and receiving at least one piece of time information.
In the foregoing embodiment, the first device may receive at least one piece of time information sent by a ranging frame and/or a non-ranging frame in a non-local ranging round trip, and in order to reduce the number of ranging frames and improve the device capacity of the ranging system, that is, improve the number of devices performing ranging in the ranging system, in this embodiment, the method may further include: at least one time information carried in the received at least one ranging frame. The at least one ranging frame referred to herein is a ranging frame used for ranging this time. In an embodiment of the present application, the at least one time information is similar to the at least one time information received via the ranging frame and/or the non-ranging frame in the non-ranging round trip in the above-described embodiment. In addition, in the embodiment of the application, the at least one piece of time information is carried in the ranging frame for ranging, and an additional frame is not required to carry the at least one piece of time information, so that frame transmission between the first device and the opposite device can be saved, and the device capacity of the ranging system is improved.
For example, when the device 1 (corresponding to the first device in the foregoing) and the device 2 (corresponding to the peer device in the foregoing) perform ranging, the device 1 sends a ranging initiation frame to the device 2, and the device 1 receives a ranging reply frame sent by the device 2, the ranging reply frame received by the device 1 may carry at least one piece of time information, that is, the method includes: the time stamp of the ranging initiation frame sent by the device 1 received by the device 2, and the sending time stamp of the ranging reply frame sent by the device 2, may also or alternatively include: the difference between the transmission timestamp of the ranging reply frame transmitted by device 2 and the timestamp of the ranging initiation frame received by device 2 from device 1. In this embodiment, the sending timestamp of the ranging reply frame sent by the device 2 may be a preset sending timestamp, or may also be a real sending timestamp. The present embodiment is not limited thereto.
Specifically, on the basis of the above embodiment, acquiring at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame includes: at least four pieces of time information are obtained by sending at least one ranging frame, receiving at least one ranging frame and the received time information carried in at least one ranging frame. In the embodiment of the present application, the carried time information includes: a transmission time of the received at least one ranging frame and reception time information of the transmitted at least one ranging frame; and/or transmitting transmission time information of the at least one ranging frame, and receiving reception time information of the at least one ranging frame.
In the above embodiment, whether at least two pieces of time information or at least four pieces of time information are acquired for ranging, further, in order to perform ranging more accurately, at least six pieces of time information (timestamps) may be acquired, and then ranging is performed according to the acquired at least six pieces of time information.
In another possible implementation manner of the embodiment of the present application, the method further includes: at least one of step Sd (not shown) and step Se (not shown), wherein,
and Sd, acquiring at least six pieces of time information by sending at least two ranging frames and at least one received ranging frame.
And step Se, acquiring at least six pieces of time information by sending at least one ranging frame and at least two received ranging frames.
Specifically, in this embodiment of the application, taking six timestamps as an example, because when performing ranging between any two devices, if the two devices want to obtain the six timestamps, at least three ranging frames need to be received and transmitted, that is, if the first device acquires the at least six timestamps when performing ranging, the at least three ranging frames need to be received and transmitted, that is, the first device acquires the at least six timestamps by sending the at least two ranging frames and receiving the at least one ranging frame, or the first device acquires the at least six timestamps by sending the at least one ranging frame and receiving the at least two ranging frames. In this embodiment of the application, by acquiring at least six timestamps, and then ranging according to the acquired at least six timestamps, the accuracy of ranging can be further improved.
Specifically, in this embodiment of the present application, the at least six timestamps may include: the method comprises the steps that a first device sends at least two sending time stamps corresponding to ranging frames to an opposite device respectively, the first device receives a receiving time stamp corresponding to at least one ranging frame, the opposite device receives a receiving time stamp corresponding to at least two ranging frames sent by the first device respectively, and the opposite device sends at least one ranging frame to the first device.
Specifically, in this embodiment of the present application, the at least six timestamps may further include: the method comprises the steps that a first device sends at least one sending timestamp of a ranging frame to an opposite device, the first device receives at least two receiving timestamps corresponding to the ranging frame, the opposite device receives a receiving timestamp corresponding to the ranging frame sent by the first device, and the opposite device sends at least two sending timestamps corresponding to the ranging frame to the first device;
in the above embodiment, if the first device obtains at least six timestamps by sending at least two ranging frames and receiving at least one ranging frame, the first device may obtain the sending timestamps of sending the at least two ranging frames and the receiving timestamp of receiving the at least one ranging frame, respectively, but the receiving timestamps of receiving the at least two ranging frames by the peer device and the sending timestamp of sending the at least one ranging frame by the peer device, and the first device may obtain the at least two ranging frames by the received ranging frame in the non-local ranging round trip, may also obtain the at least two ranging frames by the received non-ranging frame, and may of course obtain the at least two ranging frames by the received ranging frame (i.e., the ranging frame in the local ranging round trip);
further, if the first device obtains at least six timestamps by sending at least one ranging frame and receiving at least two ranging frames, the manner in which the first device obtains at least six timestamps is as follows.
In another possible implementation manner of the embodiment of the present application, the method further includes: step Sf (not shown in the figures), in which,
and step Sf, receiving at least one piece of time information.
Specifically, in this embodiment of the present application, the first device may receive at least one piece of time information sent by the peer device through an additional ranging frame, and may also receive at least one piece of time information sent by the peer device through a non-ranging frame. The embodiments of the present application are not limited thereto.
Specifically, on the basis of step Sf, at least six pieces of time information are acquired by sending at least two ranging frames and at least one received ranging frame, and the method includes: acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and at least one piece of received time information; in this embodiment of the present application, for a receiving timestamp that an opposite device receives a corresponding to each of at least two ranging frames sent by a first device, at least one timestamp in a sending timestamp of at least one ranging frame sent by the opposite device to the first device, and the first device may obtain from a received additional ranging frame and/or an additional non-ranging frame.
Specifically, on the basis of step Sf, at least six pieces of time information are acquired by sending at least one ranging frame and receiving at least two ranging frames, including: at least six pieces of time information are acquired by transmitting at least one ranging frame, receiving at least two ranging frames, and receiving at least one piece of time information. In this embodiment of the present application, for a receiving timestamp corresponding to at least one ranging frame sent by a first device received by an opposite-end device, sending timestamps corresponding to at least two ranging frames sent by the opposite-end device to the first device, respectively, the first device may obtain the ranging frame and/or the non-ranging frame in the non-local ranging round trip.
Further, in the above embodiment, if the received at least one piece of time information may be obtained through a ranging frame and/or a non-ranging frame in a non-local ranging round trip, a frame format of the received ranging frame is specifically a fourth frame format;
wherein, the fourth frame format does not contain payload data. In the embodiment of the present application, the ranging frames (ranging frames used for ranging) sent and received between the devices are all in the fourth frame format, that is, do not contain Payload data, so that the ranging power consumption is the lowest.
For example, the fourth frame format may include: SYNC, SFD, STS.
For the embodiment of the present application, in order to reduce the number of ranging frames and increase the capacity of the ranging device in the ranging system, at least one piece of time information may be obtained from the ranging frames that have been received for ranging (ranging frames within the present ranging round trip). The details are as follows:
in another possible implementation manner of the embodiment of the present application, the method further includes: a step Sg (not shown in the figure) in which,
step Sg, carrying time information in at least one received ranging frame;
for the embodiment of the present application, the time information may be carried in at least one received ranging frame, and the first device acquires the time information from the at least one received ranging frame for ranging (a sending timestamp for the peer device to send the ranging frame and a receiving timestamp for the peer device to receive the ranging frame).
Specifically, on the basis of step Sg, at least six pieces of time information are acquired by transmitting at least two ranging frames and at least one received ranging frame, including: acquiring at least six pieces of time information by sending at least two ranging frames, receiving at least one ranging frame and receiving time information carried in at least one ranging frame; in this embodiment of the application, if the first device acquires at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame, the peer device may receive at least one of the receiving timestamps corresponding to the at least two ranging frames respectively and the sending timestamp of the at least one ranging frame sent by the peer device, and may acquire the at least one ranging frame that has been received.
Specifically, on the basis of step Sg, at least six pieces of time information are acquired by sending at least one ranging frame and at least two received ranging frames, including: at least six pieces of time information are obtained by sending at least one ranging frame, receiving at least two ranging frames and time information carried in the received at least one ranging frame. In this embodiment of the present application, if the first device obtains at least six timestamps by sending at least one ranging frame and receiving at least two ranging frames, the receiving timestamps corresponding to the at least two ranging frames respectively received by the peer device and at least one timestamp in the sending timestamp of the at least one ranging frame sent by the peer device may be obtained by at least one ranging frame in the at least two received ranging frames.
Another possible implementation manner of the embodiment of the present application is that at least six pieces of time information are obtained by sending at least one ranging frame and receiving at least one ranging frame, and the method includes:
acquiring at least six pieces of time information by sending at least two ranging frames and at least one received ranging frame, wherein the sent at least two ranging frames at least comprise a Final frame; and/or the presence of a gas in the gas,
at least six pieces of time information are obtained by sending at least one ranging frame and at least two received ranging frames, wherein the at least two received ranging frames at least comprise a Final frame.
Specifically, in the embodiments of the present application, the sending of at least two ranging frames and the receiving of at least one ranging frame may constitute at least two ranging roundtrips. In the embodiment of the application, even if the two sent ranging frames at least comprise one Final frame, at least two ranging round trips can be formed; that is, in one possible implementation, two ranging round trips may be made by sending one ranging frame, receiving one ranging frame, and sending one Final frame. Where six time messages are available for two ranging round trips.
That is, in the embodiment of the present application, if at least six pieces of time information are obtained, the first device needs to transmit and receive at least three ranging frames (including sending at least two ranging frames and receiving at least one ranging frame, and/or sending at least one ranging frame and receiving at least two ranging frames) with the peer device, where in the embodiment of the present application, the at least three ranging frames that are transmitted and received may include at least one Final frame.
Further, as can be seen from the above embodiments, the time information is carried in the ranging frame; and/or the time information is not carried by the ranging frame.
In another possible implementation manner of the embodiment of the present application, a frame format of the ranging frame includes at least one of: a first frame format, a second frame format, and a third frame format.
The first frame format includes: synchronizing SYNC, a frame start symbol SFD, a physical frame header PHR and a packet load PHR Payload;
the second frame format includes: SYNC, SFD, scrambling time stamp sequence STS, PHR, PHY Payload;
the third frame format includes: SYNC, SFD, PHR, PHY Payload, STS.
Specifically, the first frame format includes: synchronizing SYNC, a frame start symbol SFD, a physical frame header PHR and a packet load PHR Payload; the second frame format includes: SYNC, SFD, Scrambled Timestamp Sequence (STS), PHR, PHY Payload; the third frame format includes: SYNC, SFD, PHR, PHY Payload, STS. In the embodiment of the present application, as shown in fig. 8, the configuration of the first frame format may also be referred to as a Scrambled time series packet configuration (STS packet configuration), and when the value of the STS packet configuration is set to 0, the frame format is configured as the first frame format, and includes SYNC, SFD, PHR, and PHR Payload, that is, the first frame format does not include STS; when the value of STS packet configuration is set to 1, the frame format is configured as a second frame format including SYNC, SFD, STS, PHR, PHY Payload; when the value of STS packet configuration is set to 2, the frame format is configured as a third frame format, including SYNC, SFD, PHR, PHY Payload, STS; when the value of STS packet configuration is set to 3, the frame format is configured as a fourth frame format including: SYNC, SFD, STS.
In another possible implementation manner of the embodiment of the application, when the time information is not carried by the ranging frame, the time information is sent through the first channel; and/or when the time information is not carried by the ranging frame, the time information is sent through a second channel;
wherein, the first channel comprises a channel for receiving and transmitting the ranging frame; the second channel is a channel not containing the transceiving ranging frame. In the embodiment of the application, when the time information is transmitted through the channel which does not contain the transceiving ranging frame, the capacity of the ranging equipment in the ranging system can be improved.
Specifically, the first channel is a UWB channel and/or the second channel is a bluetooth channel.
Further, the distance measuring method may be applied to a distance measuring system, where the distance measuring system may include two devices or a plurality of devices, and when the distance measuring system includes two devices, the distance measuring between the two devices may be performed, and a specific distance measuring method may be detailed in the above embodiment.
When the ranging system comprises a plurality of devices, in another possible implementation manner of the embodiment of the present application, at least one ranging frame is sent; and, receiving at least one ranging frame, comprising: sending at least one ranging frame to at least two opposite terminal devices; and receiving at least one ranging frame respectively sent by at least two opposite-end devices.
That is, when the first device performs ranging with at least two peer devices in the ranging system, the first device sends at least one ranging frame to the at least two peer devices and receives at least one ranging frame sent by the at least two peer devices, respectively, to implement ranging.
For example, the ranging system includes a device 1, a device 2, and a device 3, where the device 1 needs to perform ranging with the device 2 and the device 3, the device 1 sends at least one ranging frame to the device 2 and the device 3, and receives at least one ranging frame sent by the device 2 and the device 3, respectively, to implement ranging.
When sending the ranging frame to at least two peer devices, the first device may send at least one ranging frame to each peer device, or at least one ranging frame sent to at least two peer devices may be the same frame. In this embodiment of the application, the first device and the at least two peer devices perform ranging, in order to reduce frame transmission between the devices, capacity of the ranging device in the ranging system is improved, and when the first device performs ranging with the at least two peer devices, the ranging frame may be multiplexed, that is, the first device may include at least one ranging frame as the same ranging frame in at least one ranging frame that is sent to the at least two peer devices. That is, if the first device sends at least two ranging frames to at least two devices, respectively, at least one of the at least two ranging frames may be the same ranging frame.
For example, the ranging system includes device 1, device 2, and device 3, where device 1 needs to perform ranging with device 2 and device 3, and device 1 may send the same ranging frame to device 2 and device 3; that is, if the device 1 initiates ranging, the ranging initiation frames sent by the device 1 to the devices 2 and 3 are the same frame. If the device 1 sends at least two ranging frames to the device 2 and also sends at least two ranging frames to the device 3, at least one ranging frame in the at least two ranging frames sent by the device 1 to the device 2 is the same as at least one ranging frame in the at least two ranging frames sent by the device 1 to the device 3. That is, the device 1 sends the ranging initiation frame to the devices 2 and 3, then receives the ranging reply frames sent by the devices 2 and 3, respectively, and then the device 1 sends the ranging initiation frame to the devices 2 and 3, so that the ranging initiation frames sent by the device 1 to the devices 2 and 3 at each time may be the same frame, or the ranging frames sent to the devices 2 and 3 at one time may be the same frame.
Further, in the ranging system, the first device may be any device that initiates ranging, or may also be a device that does not initiate ranging, and when the ranging system includes a plurality of ranging devices, the first device may also be a device that initiates ranging, or may also be a device that does not initiate ranging. The details are as follows:
another possible implementation manner of the embodiment of the present application, sending at least one ranging frame includes: the method includes sending at least one ranging initiation frame to at least one second device of the at least two peer devices, and sending at least one ranging reply frame to at least one third device of the at least two peer devices.
Specifically, in this embodiment of the present application, the step of sending the at least one ranging initiation frame to the at least one second device of the at least two peer devices may be performed before the step of sending the at least one ranging reply frame to the at least one third device of the at least two peer devices, may also be performed after the step of sending the at least one ranging reply frame to the at least one third device of the at least two peer devices, and may also be performed simultaneously with the step of sending the at least one ranging reply frame to the at least one third device of the at least two peer devices. The embodiments of the present application are not limited thereto. In an embodiment of the present application, the first device is a ranging initiating device for the at least one second device, and the first device is not a ranging initiating device for the at least one third device (or the first device is a ranging responding device for the at least one third device).
For example, if the ranging system includes device 1, device 2, device 3, and device 4, in the process of ranging between device 1 and devices 2,3, and 4, device 1 is a ranging initiating device (that is, device 1 is a ranging initiating device of device 2, device 3, and device 4) with respect to device 2,3, and 4, device 2 is a ranging initiating device in the process of ranging between device 2 and devices 3 and 4, device 2 is a ranging initiating device, and device 3 is a ranging initiating device in the process of ranging between device 3 and device 4; that is, if the device 2 is the first device, the device 1 is the third device, and the devices 3 and 4 are the second devices; if the device 3 is a first device, the devices 1 and 2 are third devices, and the device 4 is a second device, as shown in fig. 17.
Further, at least one ranging initiation frame is sent to at least one second device in at least two peer devices, and then the method further includes: at least one ranging reply frame transmitted by at least one second device is received. Sending at least one ranging reply frame to at least one third device of the at least two peer devices, wherein the method further comprises the following steps: receiving at least one ranging initiation frame transmitted by at least one third device.
Specifically, a first device sends at least one ranging initiation frame to at least one second device, and receives a ranging reply frame sent by the at least one second device to implement ranging; in another possible implementation manner, the first device receives a ranging initiation frame sent by at least one third device, and the first device returns a ranging reply frame to the at least one third device.
In the above embodiment, the first device may determine the distance between the first device and each of the second devices, and then send the determined distance information to each of the second devices; the distance information between the third device and the first device can be determined in the third device, and then the distance information is sent to the first device, namely after the distance information of the third device to the opposite-end device is determined by the third device, the distance information is sent to the opposite-end device, and the opposite-end device is prevented from ranging again, so that the capacity of the ranging device in the ranging system can be improved, and the waste of computing capacity and the like of the device can be avoided.
For example, the ranging system includes 4 devices, including: device 1, device 2, device 3, and device 4, wherein device 1 may initiate ranging to device 2, device 3, and device 4 respectively, device 2 may initiate ranging to device 3 and device 4 respectively, and device 3 may initiate ranging to device 4 to realize ranging between any two devices. In a specific implementation manner, the device 1 sends at least one ranging initiation frame to the device 2, the device 3, and the device 4, and the device 1 receives ranging reply frames sent by the device 2, the device 3, and the device 4, respectively; the device 2 sends at least one ranging initiation frame to the device 3 and the device 4, and the device 2 receives ranging reply frames sent by the device 3 and the device 4 respectively; device 3 sends at least one ranging initiation frame to device 4 and receives at least one ranging reply frame sent by device 4 to enable ranging.
Specifically, the at least one ranging initiation frame includes that the at least one ranging initiation frame and the corresponding ranging reply frame are the same frame. That is, if the first device can send the ranging initiation frame and the ranging recovery frame, the frame multiplexing may be performed to save frame transmission in the ranging system and improve the capacity of the ranging device in the ranging system. For example, the ranging initiation frame sent by device 2 to devices 3 and 4 may be the same ranging frame as the ranging reply frame sent by device 2 to device 1.
Further, in order to maximally improve the capacity of the ranging devices in the ranging system, when there are at least two second devices, there is one third device, where the ranging initiation frame sent by the first device to the at least two second devices may be the same frame (that is, the ranging initiation frame is sent to the at least two second devices by multiplexing), the ranging reply frame sent by the first device to the third device is also the same frame as the ranging initiation frame sent by the first device to the at least two second devices; when the number of the third devices is at least two, the number of the second devices is one, the ranging reply frames sent by the first device to the at least two third devices may be the same frame, the ranging initiation frame sent by the first device to the second device is the same frame as the ranging reply frame sent by the first device to the at least two third devices; when the number of the second devices is at least two, the number of the third devices is also at least two, the ranging initiation frames sent by the first device to the at least two second devices may be the same frame, the ranging reply frames sent by the first device to the at least two third devices may also be the same frame, and the initiation frame and the reply frame are the same frame.
In another possible implementation manner of the embodiment of the present application, the method further includes: a step Sh (not shown in the figure) in which,
and Sh, acquiring distance information between the first equipment and opposite equipment according to at least four pieces of time information.
Specifically, the at least four pieces of time information referred to in the embodiments of the present application refer to at least four time stamps. In this embodiment of the present application, the first device may determine distance information between the first device and the peer device based on at least four pieces of time information, and may also obtain the distance information between the first device and the peer device, which is sent by the peer device. In this embodiment, the peer device may be any device except the first device in the ranging system.
Specifically, the step Sh may specifically include: at least one of a step Sh1 (not shown) and a step Sh2 (not shown), wherein,
sh1, determining distance information between the first device and the opposite device according to the sending time of the sending ranging frame, the receiving time of the receiving ranging frame and the received time information;
the time information received in the embodiment of the present application may include: the receiving time of the ranging frame received by the opposite terminal equipment and the sending time of the ranging frame sent by the opposite terminal equipment. Specifically, if the first device is a device initiating ranging, the sending time of the ranging frame, the receiving time of the ranging frame received by the peer device, and the sending time of the ranging frame sent by the peer device may specifically be: the method comprises the steps that the sending time of a ranging initiation frame sent by first equipment, the receiving time of a ranging reply frame received by the first equipment, the time of a ranging initiation frame received by opposite-end equipment and the sending time of the ranging reply frame sent by the opposite-end equipment are determined; if the first device is not a device initiating ranging, the sending time of the ranging frame, the receiving time of the ranging frame received by the peer device, and the sending time of the ranging frame sent by the peer device may specifically include: the method comprises the steps of sending time of a ranging reply frame sent by first equipment, receiving time of a ranging initiation frame of the next frame received by the first equipment, receiving time of a ranging initiation frame received by opposite-end equipment and sending time of the ranging initiation frame of the next frame sent by the opposite-end equipment.
Specifically, in this embodiment of the application, after the first device acquires the time information, the distance information between the first device and the peer device may be determined according to formula 1.
Figure BDA0002750894310000331
Wherein, TS1Transmission time, TS, for transmitting a ranging frame for a first device2Receiving time, TS, of ranging frame received by opposite terminal equipment3Sending time, TS, of ranging frame for peer device4C is the receiving time of the ranging frame received by the first device, and C is the speed of light.
Further, after determining the distance information between the first device and the peer device, the first device sends the determined distance information between the first device and the peer device to the peer device, and specifically, the determined distance information between the first device and the peer device may be sent to the peer device through the first channel and/or the second channel.
And step Sh2, receiving distance information between the first device and the opposite terminal device, which is sent by the opposite terminal device.
For the embodiment of the application, the distance information between the first device and the peer device may also be determined by the peer device, and after the peer device determines the distance information between the first device and the peer device, the distance information between the first device and the peer device is sent to the first device.
As for the above example, the ranging system includes four devices, device 1, device 2, device 3, and device 4, and if the first device is device 1, the first device (device 1) determines the distance information between the first device and the peer device according to the sending time of sending the ranging frame, the receiving time of receiving the ranging frame, and the received time information, that is, only step Sh1 needs to be executed; when the first device is the device 4, the first device (the device 4) receives the distance information between the device 1, the device 2, and the device 3 and the device 4, that is, only the step Sh2 needs to be executed; similarly, when the first device is the device 3, the first device (device 3) determines the distance information between the device 2 and each of the devices 3 and 4, and also needs to receive the distance information between the device 1 and the device 2 sent by the device 1, that is, needs to execute the step Sh1 and the step Sh2, and when the first device is the device 3, the first device (device 3) determines the distance information between the device 3 and the device 4, and also needs to receive the distance information between the device 1 and each of the devices 2 and each of the devices 3, that is, needs to execute the step Sh1 and the step Sh 2.
Further, in the above example, for the pair of device 1 and device 3, the F1 frame is the initiating frame at the device 1 end, and the subsequent F3 frame is the reply frame at the device 3, and these two frames are stamped with 4 timestamps, so that the distance between the device 1 and the device 3 can be recorded at the device 1 end.
In the above embodiment, the distance measurement is performed through four timestamps, the four timestamps are acquired in the manner shown in fig. 15, the device 1 and the device 3 perform the distance measurement, the device 1 sends the distance measurement frame 1 to the device 3, the device 1 receives the distance measurement frame sent by the device 2, and through the three distance measurement frames, one distance measurement round trip can be obtained to obtain four timestamps, that is, the timestamp 1, the timestamp 2, the timestamp 3, and the timestamp 4 shown in fig. 15.
Further, in the above embodiment, when the first device receives the distance information between the first device and the peer device, that is, the distance information between the first device and the peer device is calculated (determined) by the peer device, in this embodiment of the present application, a manner of determining the distance information between the first device and the peer device by the peer device is detailed in a manner of determining the distance information by the first device, which is not described herein again.
In the above description, the distance information between the first device and the peer device is obtained through at least four pieces of time information, and in order to obtain more accurate distance information, the distance information between the first device and the peer device may be obtained according to at least six pieces of time information. In the embodiment of the application, because the ranging is performed according to at least six pieces of time information, that is, at least six pieces of time information can form at least two ranging round trips, each ranging round trip can obtain one piece of distance information, and the averaging processing is performed according to at least two pieces of distance information, the crystal oscillator error of the local clock of the device can be eliminated, so that the accuracy of obtaining the ranging information can be further improved. For example, as shown in fig. 16, device 1 and device 3 perform ranging, device 1 transmits ranging frame 1 to device 3, device 1 receives ranging frame transmitted by device 3, device 1 transmits ranging frame to device 3, and two ranging round trips can be obtained through the three ranging frames to obtain six timestamps, that is, timestamp 1, timestamp 2, timestamp 3, timestamp 4, timestamp 5, and timestamp 6 shown in fig. 16.
In another possible implementation manner of the embodiment of the present application, the method further includes: step Si (not shown in the figure), in which,
and step Si, acquiring distance information between the first equipment and opposite equipment according to at least six pieces of time information.
Specifically, the at least six pieces of time information referred to in the embodiments of the present application refer to at least six time stamps. In this embodiment of the present application, the first device may determine distance information between the first device and the peer device based on at least six pieces of time information, and may also obtain the distance information between the first device and the peer device, which is sent by the peer device. In this embodiment, the peer device may be any device except the first device in the ranging system.
Specifically, step Si may specifically include: at least one of step Si1 (not shown), step Si2 (not shown), and step Si3 (not shown), wherein,
step Si1, determining distance information between the first device and the peer device according to the sending time information corresponding to the sending of the at least two ranging frames, the receiving time information corresponding to the receiving of the at least one ranging frame, and the received time information. In this embodiment of the present application, the received time information may include: and the opposite terminal equipment receives the receiving time information respectively corresponding to at least two ranging frames sent by the first equipment and the sending time corresponding to at least one ranging frame sent by the opposite terminal equipment.
Specifically, step Si1 may specifically include: and determining the distance information between the first equipment and the opposite equipment according to the sending time information of sending the at least one ranging frame, the sending time of sending the final frame and the receiving time information of receiving the at least one ranging frame. In the embodiments of the present application, detailed descriptions of final frames are given in the above embodiments, and are not repeated herein.
Step Si2, determining distance information between the first device and the peer device according to the sending time information of sending at least one ranging frame, the receiving time corresponding to receiving at least two ranging frames, and the received time information. In this embodiment of the present application, the received time information may include: and the opposite terminal equipment receives at least one ranging frame to obtain receiving time information, and the opposite terminal equipment sends at least two ranging frames to respectively obtain sending time information.
Specifically, step Si2 may specifically include: and determining the distance information between the first equipment and the opposite equipment according to the sending time information of sending the at least one ranging frame, the receiving time information of receiving the at least one ranging frame and the receiving time information of receiving the final frame.
And step Si3, receiving distance information between the first device and the peer device, which is sent by the peer device.
Specifically, the first device may also only need to perform the receiving step without determining the distance information between the first device and the peer device, that is, receive the distance information between the first device and the peer device, which is sent by the peer device. In this embodiment of the present application, the first device receives distance information between the first device and the peer device, which is sent by the peer device, and can avoid the first device from ranging with the peer device according to the ranging frame received and sent, so that computing resources can be saved.
For the embodiment of the application, the peer device may determine distance information between the first device and the peer device based on the obtained at least six pieces of time information. In this embodiment of the application, a manner in which the peer device determines the distance information between the first device and the peer device based on the at least six pieces of time information is similar to a manner in which the first device determines the distance information between the first device and the peer device based on the at least six pieces of time information, and details are not specifically described here.
In the above example, the distance measurement system includes four devices, i.e., device 1, device 2, device 3, and device 4, and the device side directly calculates the distance:
the device 1 side: d12,d13,d14
And 2, equipment: d23,d24
And 3, equipment terminal:d34
subsequently, the device that directly calculates the distance broadcasts its local calculated distance in turn via a second channel or UWB channel, e.g. device 1 will broadcast d12,d13,d14The R1 frame (backhaul frame) is broadcasted, and after the backhaul frame is received by the device 2,3,4, the device 2,3,4 can obtain its distance from the device 1. In the embodiment of the present application, the backhaul frame may be a ranging frame in a non-ranging round trip, or may be a non-ranging frame.
After the devices 123 broadcast the ranging frames in sequence, all the devices can obtain the distance information with other devices.
Figure BDA0002750894310000371
Specifically, in the embodiment of the present application, the F1 frame, the F2 frame, the F3 frame, and the F4 frame are all ranging frames. In the embodiment of the present application, the F1 frame and the F2 frame form a ranging round trip, the F2 frame and the F3 frame form a ranging round trip, the F3 frame and the F4 frame form a ranging round trip, the F1 frame and the F3 frame may form a ranging round trip, and the F1 frame and the F4 frame form a ranging round trip. Further, in the embodiment of the present application, the R1 frame, the R2 frame, and the R3 frame are backhaul frames, and details of the backhaul frames are specifically described in the above embodiments and are not repeated herein.
The distance information between the devices (device 1, device 2, device 3, and device 4) obtained by the above-mentioned devices may be at least two pieces of time information, at least four pieces of time information, or at least six pieces of time information, where a specific implementation manner is detailed in the above-mentioned embodiment and is not described herein again.
In the above embodiments, a specific implementation of ranging between devices (between any two devices) is described, and in the following embodiments, preparation work before ranging is described, specifically, see the following embodiments:
in another possible implementation manner in this embodiment of the application, the method further includes: receiving a ranging instruction; transmitting at least one ranging frame based on the ranging instruction; and receiving at least one ranging frame based on the ranging instruction.
From the above embodiment, it can be seen that: the first device receives and transmits a ranging frame based on the received ranging command, and in this embodiment, the method further includes: and sending the equipment information so that the opposite terminal equipment determines the ranging instruction based on the equipment information. That is, before the first device receives the ranging instruction, the first device transmits device information so that the opposite-end device (an opposite-end device) determines the ranging instruction based on the received device information. In this embodiment of the present application, an opposite-end device (a device at an opposite end) may determine a ranging instruction corresponding to a first device only based on received device information of the first device, and may also determine the ranging instruction based on the received device information of the first device and a device of the opposite-end device; when the ranging system includes a plurality of devices, an opposite-end device (a device at an opposite end) may also determine a ranging instruction based on all received device information and its own device information, and a specific manner of determining the ranging instruction is not limited in this embodiment.
In the above embodiment, the first device receives and transmits the ranging frame through the received ranging command, so that frame collision caused by the fact that the devices receive and transmit the ranging frame can be avoided, and further ranging failure can be caused.
Further, in this embodiment, the first device may receive the ranging instruction through the first channel and/or the second channel. In an embodiment of the present application, the first channel may include: the UWB channel and the second channel may comprise a bluetooth channel. In this application embodiment, because the bluetooth passageway is lower for other passageways, the consumption, the range finding instruction passes through the bluetooth passageway transmission, can reduce the consumption to can practice thrift the resource of range finding channel, and then can further promote the capacity of range finding equipment among the range finding system. Further, in this application embodiment, the range finding instruction passes through the transmission of bluetooth passageway, then just can the UWB range finding to can avoid opening UWB range finding all the time, thereby can reduce the range finding consumption.
Further, after the peer device determines the ranging instruction, the peer device sends the ranging instruction to the first device.
For the embodiment of the present application, the ranging command includes at least one of the following: ranging time slot information and equipment information corresponding to the ranging opposite terminal. In the embodiment of the application, the ranging time slot information is used for determining the time slot for transmitting and/or receiving the ranging frame; and the equipment information of the ranging opposite terminal is used for determining the equipment information corresponding to the opposite terminal equipment to be subjected to ranging.
Specifically, the ranging instruction includes: ranging time slot information; based on the ranging instruction, transmitting at least one ranging frame, comprising: transmitting at least one ranging frame based on the ranging slot information; receiving at least one ranging frame based on the ranging instruction, comprising: at least one ranging frame is received based on the ranging slot information. In this embodiment, the ranging slot information may be a specific ranging slot or a relationship with a certain slot, and after the specific slot is determined based on the ranging slot information, at least one ranging frame is sent in the determined specific slot. In this embodiment, the time slots for the first device to send the ranging frame to the different devices may be the same, may also be different, or may be at least two of the same, which is not limited in this embodiment.
Further, in this embodiment of the present application, the ranging slot information may further include slot information corresponding to each peer device, so that the first device may determine a slot (a slot in which each peer device sends a ranging frame) corresponding to each peer device, so that the first device receives the ranging frame sent by each other peer device in the corresponding slot.
Specifically, the ranging slot information includes: presetting a time slot; when the ranging time slot information contains a preset time slot, at least one ranging frame is sent based on the ranging time slot information, and the method comprises the following steps: transmitting at least one ranging frame in a preset time slot; receiving at least one ranging frame based on the ranging slot information, including: at least one ranging frame is received within a preset time slot.
That is, because the ranging instruction is received by the first device and sent by another device, the other device (a certain device) may preset the ranging slot information corresponding to each device in the ranging system, may also preset only the ranging slot corresponding to the first device, or may determine the ranging slot corresponding to the first device based on the other information, and of course, after receiving the ranging instruction, the first device may also determine the corresponding ranging slot according to the ranging instruction, so that the first device sends at least one ranging frame in the preset slot.
In another possible implementation manner of the embodiment of the application, based on the ranging instruction, at least one ranging frame is sent; and receiving at least one ranging frame based on the ranging instruction, including: transmitting at least one ranging frame within a random time slot based on the ranging instruction; and receiving at least one ranging frame within a random time slot based on the ranging instruction. In this embodiment, the first device may randomly select one slot to transmit the ranging frame at each ranging. In this embodiment of the present application, the random time slot selected by the first device may be determined based on no parameter, or may be determined based on the device information of the first device. In this embodiment, the self device information may include a device identifier. For example, the ranging system includes 3 devices, the device identifiers are device 1, device 2, and device 3, and the corresponding device identifiers are 1, 2, and 3, respectively, then the device 1 determines that the random time slot of the device 1 may be time slot 1 according to the device identifier 1, the device 2 determines that the random time slot of the device 2 may be time slot 2 according to the device identifier 2, and the device 3 determines that the random time slot of the device 3 may be time slot 3 according to the device identifier 3. Furthermore, the first device may determine, based on the ranging instruction, time slot information of the ranging frame sent by the peer device, so that the peer device receives at least one ranging frame in a random time slot.
In another possible implementation manner of the embodiment of the application, the first device may receive the ranging instruction determined by other devices (the peer device and/or devices in the ranging system other than the first device and the peer device), or may send the ranging instruction after determining the ranging instruction by itself, so that the device that receives the ranging instruction sends and/or receives the ranging frame. In the embodiment of the application, the distance measurement command is sent, so that the equipment receiving the distance measurement command receives and sends the distance measurement frame according to the distance measurement command, and the condition that the distance measurement fails due to frame collision between the equipment can be avoided.
Specifically, when the ranging command includes ranging slot information, determining a mode of the ranging slot information includes: acquiring equipment information sent by opposite-end equipment; and determining ranging time slot information based on the equipment information sent by the opposite terminal equipment and the self equipment information. In this embodiment of the present application, the first device obtains device information corresponding to each device, determines ranging time slot information based on the device information corresponding to each device, and then sends the ranging time slot information to each device, so that each device receives and sends a ranging frame according to the ranging time slot information. In this embodiment, determining the ranging slot information based on the device information of the peer device may refer to accuracy of the determined ranging slot information.
Specifically, the device information is transmitted through a first channel and/or a second channel; in the embodiment of the present application, no matter the first device acquires the device information of each other device, or the first device sends the device information to the opposite device, the device information may be transmitted through the first channel and/or the second channel. In the embodiment of the present application, the first channel is a ranging channel, and the second channel is a non-ranging channel. In an embodiment of the present application, the first channel and/or the second channel may include: UWB channels, nth generation mobile communication technology channels (N is 3,4, 5 … …), bluetooth channels, ZigBee (ZigBee), wireless fidelity (Wi-Fi), and the like. Specifically, the first channel is a UWB channel and the second channel is a bluetooth channel. In this application embodiment, the bluetooth passageway is lower for other passageways, and moreover, equipment information etc. transmit through the bluetooth passageway, can save the channel resource of range finding channel, promote the capacity of range finding equipment among the ranging system.
Specifically, the device information includes: a device identification; in this embodiment of the present application, determining ranging slot information based on device information sent by an opposite device and device information of the opposite device includes: sorting processing is carried out based on the device identifications respectively corresponding to the devices; and determining ranging slot information based on the sequencing result. In this embodiment, the ranging slot information may include ranging slots respectively corresponding to the devices. That is, each device transmits the ranging frame in the determined ranging slot. In the embodiment of the application, the determined ranging time slot information may be a ranging time slot list, and the list includes ranging time slots respectively corresponding to each device; the determined ranging time slot information may also be the ranging time slots corresponding to the respective devices, or the determined ranging time slot information is the sequencing information of the respective devices. In the embodiment of the application, the device identifiers respectively corresponding to the devices are sorted, and the ranging time slot is determined based on the sorting result, so that the accuracy of the determined ranging time slot can be improved.
For example, the ranging system includes 3 devices, a device 1, a device 2, and a device 3, where the device 1, the device 2, and the device 3 are 1, 2, and 3, respectively, and the device 1 is a first device, the device 1 determines, based on the device identifiers 1, 2, and 3, that the ranking result of each device is the device 1, the device 2, and the device 3, and the determined ranging slot information may be the ranking result (the device 1, the device 2, and the device 3); or determining that the ranging time slot information is the ranging time slot 1, the ranging time slot 2 and the ranging time slot 3 respectively based on the ranging sequencing result, the determined ranging time slot information may be the ranging time slot 1, the ranging time slot 2 and the ranging time slot 3, or may be a ranging list including the ranging time slot 1, the ranging time slot 2 and the ranging time slot 3. In this example, device 1 and device 2 perform ranging, device 1 transmits a ranging frame in ranging slot 1, and device 2 receives the ranging frame transmitted by device 1 in ranging slot 1; and device 2 transmits a ranging frame in ranging slot 2 and device 1 receives a ranging frame in ranging slot 2.
Specifically, the ranging instruction is transmitted through the first channel and/or the second channel. In this embodiment of the present application, when the first device determines the ranging instruction, the ranging instruction may be sent to other ranging devices (peer devices or other devices in the ranging system except the peer devices) through the first channel and/or the second channel, or may be transmitted to the first device after the other devices determine the ranging instruction. In the embodiment of the present application, the first channel is a ranging channel, and the second channel is a non-ranging channel. Specifically, the first channel is a UWB channel and the second channel is a bluetooth channel.
Further, in the above embodiment, a manner of determining ranging slot information is described by taking the first device as an example, and a manner of determining ranging slot information by each other device is similar to the manner of determining ranging slot information by the first device, which is not described in detail in this embodiment of the present application.
In the above embodiments, the ranging instruction information and/or the device information may be transmitted through the first channel and/or the second channel. In the embodiment of the present application, the communication distance of the first channel matches the communication distance of the second channel. In the embodiment of the present application, the communication distance of the first channel and the communication distance of the second channel may be the same, and the communication distance of the first channel and the communication distance of the second channel may also be different by a small amount; in the embodiment of the present application, the communication distance of the first channel and the communication distance of the second channel may be determined to each other. For example, the communication distance of the first channel and the communication distance of the second channel may be about ten or more meters to twenty meters.
Further, in this application embodiment, first passageway can be the UWB passageway, and the second passageway can be the bluetooth passageway, and the communication distance of bluetooth passageway and the communication distance phase-match of UWB passageway also can transmit the equipment of range finding instruction, can carry out the UWB range finding to can avoid the equipment that need not carry out the range finding to carry out the UWB range finding, and then lead to the waste of range finding resource, also can further promote the range finding capacity of range finding equipment among the range finding system.
Specifically, when transmitting in the second channel, the transmission power is controlled so that the communication distance of the second channel matches the communication distance of the first channel. In the embodiment of the present application, the communication distance through the second channel matches the communication distance through the first channel, so that the information (ranging instruction information and/or device information, etc.) sent on the second channel can be received by other devices. In the embodiment of the application, the communication distance through the first channel is not greatly different from the communication distance through the second channel, so that the power consumption can be further saved.
Specifically, the communication distance of the second channel is not greater than a preset threshold, and the preset threshold is determined according to the communication distance of the first channel.
In the following embodiments, a distance measurement manner is introduced in a specific example manner, where a first device and an opposite device related to the foregoing embodiments are located in a distance measurement system, and devices included in the distance measurement system may be fixed or may dynamically change in real time; in this embodiment of the present application, if devices included in the ranging system are dynamically changed, each device may send a frame discovery frame at preset intervals, and other devices in the ranging system start frame reception, and determine a device included in the current ranging system after receiving the frame discovery. In this embodiment, the discovery frame sent by each device at preset intervals may be a UWB ranging frame (that is, a ranging frame sent in a UWB ranging channel), a UWB broadcast frame (that is, a ranging frame broadcast in a UWB ranging channel), or an outband broadcast frame (that is, a ranging frame broadcast in a second channel). In this embodiment of the present application, each device may always start frame reception, and receive a discovery frame sent by each device, and certainly, may also start channel reception for a whole period every certain number of periods, for example, every 5 periods (T), and start reception for a whole period, as shown in fig. 7 specifically. Since the on-time is a whole period and other devices broadcast periodically, the whole period can receive the broadcast of other devices. If the devices included in the ranging system are fixed, each device in the ranging system may determine the devices included in the ranging system in advance, or each device may transmit a discovery frame in advance, so that each device receives the discovery frame transmitted by another device to determine the devices included in the ranging system. In the embodiment of the present application, the discovery frame carries device information, so that a device receiving the discovery frame can know devices existing nearby. Further, in the embodiment of the present application, since the devices included in the ranging system are dynamically changed, the ranging between any two devices can be implemented through the above embodiments.
Further, the discovery frame sent by each device may carry device information corresponding to each device, for example, an identifier of each device, and after each device receives the device information sent by other devices, it may determine a ranging initiation device during ranging. In this embodiment of the present application, each device may determine, according to the obtained device ID and the device ID of itself, a ranging initiation device when ranging is performed between any two devices. In this embodiment of the present application, the device with the smallest device ID may determine the ranging time slot corresponding to each device, and send the ranging time slot to each device.
For example, the ranging system includes four devices, device 1, device 2, device 3, and device 4, where the device identifiers 1, 2,3, and 4 correspond to the devices, respectively, and when ranging is performed between device 1 and device 2, device 3, and device 4, device 1 transmits a ranging initiation frame to device 2, device 3, and device 4 in a frame multiplexing manner, when ranging is performed between device 2 and device 3 and device 4, device 2 transmits a ranging initiation frame to device 3 and device 4 in a frame multiplexing manner, when ranging is performed between device 3 and device 4, device 3 transmits a ranging initiation frame to device 4, and in addition, the ranging initiation frame and the ranging reply frame may be multiplexed frames, that is, the ranging reply frame transmitted by device 2 to device 1 and the ranging initiation frame transmitted by device 2 to device 3 and device 4 are the same frame, device 3 transmits a ranging initiation frame to device 4 and the ranging reply frame transmitted by device 3 to device 1 and device 2 are the same frame, the ranging reply frames sent by the device 4 to the devices 1, 2,3, and 4 are the same frame.
For example, as shown in fig. 6, device 1 transmits an F1 ranging frame (ranging initiation frame) to devices 2,3, and 4, device 2 transmits an F2 frame (ranging initiation frame) to devices 3 and 4, device 2 transmits an F2 frame (ranging reply frame) to device 1, device 3 transmits an F3 frame (ranging initiation frame) to device 4, device 3 transmits an F3 frame (ranging reply frame) to devices 1 and 2, and device 4 transmits an F4 frame (ranging reply frame) to devices 1, 2, and 3.
Further, in the above embodiment, the device information is transmitted, so that the device receiving the device information determines the devices included in the periphery, and further determines the ranging slot information and the like, so that the device can perform ranging by transmitting and receiving the ranging frame through the ranging slot information and the like. However, in another possible implementation manner of the embodiment of the present application, any two ranging devices are in a fixed ranging system, that is, each device learns device information of other devices, corresponding ranging slot information, and the like in advance, that is, before ranging, it is not necessary to perform operations of sending the device information between the devices and determining the ranging slot information and the like as shown in the above embodiment, but ranging between any two devices may be directly performed according to the device information and the ranging slot information, and the like, which are learned in advance.
Further, after the distance measurement is performed in the manner in the above embodiment and the distance information is acquired, in order to analyze and use the distance information between the devices in the following, another possible implementation manner of the embodiment of the present application uploads the distance information between the first device and the peer device to the corresponding device;
wherein the corresponding device comprises at least one of:
a mobile terminal;
a gateway;
and (4) a server.
For the embodiment of the application, after the first device acquires the distance information between the first device and the opposite-end device, the acquired distance information can be uploaded to the corresponding device, so that subsequent analysis and use are facilitated. Of course, the first device may store the distance information by itself for subsequent analysis and use, and in the embodiment of the present application, if the device needs to store the distance information and the like, the device needs to mount a memory chip and the like.
Furthermore, a data collection base station, a gateway and the like are also required to be arranged in the scene. The data collection base station and/or the gateway and the like are arranged at key positions of a scene, such as a gate, a stair opening and the like, so that the opportunity that the equipment possibly contacts the base station and/or the gateway when the equipment moves is guaranteed. There may be one or more data collection base stations in a scenario. In the embodiment of the application, after the base station receives the uploaded distance information, the collected distance information is uploaded to the industrial personal computer host. The connection mode of the base station, the industrial personal computer host and the switch is shown in fig. 4, wherein information interaction is performed between the industrial personal computer host and the switch, and information interaction is performed between the switch and the base station.
Further, the first device may also upload distance information between the first device and the peer device to the mobile terminal device or the server, so as to facilitate subsequent analysis and use.
Specifically, uploading distance information between the first device and the peer device to the corresponding device includes: and uploading the distance information between the first equipment and the opposite terminal equipment to the corresponding equipment through the first channel or the second channel. In the embodiment of the application, the distance information between the first device and the opposite-end device is uploaded through the first channel, transmission by a communication module except the ranging module is not needed, and the distance information between the first device and the opposite-end device is uploaded through the second channel, so that the ranging channel resource can be further saved, and the capacity of the ranging device in the ranging system is saved.
Specifically, the first channel may be a UWB channel and the second channel may be a bluetooth channel. In the embodiment of the present application, the advantages of transmitting the distance information through the bluetooth channel are specifically described in the above embodiment, and are not described in detail in the embodiment of the present application.
Another possible implementation manner of the embodiment of the present application, uploading distance information between the first device and the peer device to the corresponding device, and then further including: receiving an upload success message sent by corresponding equipment; and deleting the distance information successfully uploaded based on the uploading success message.
The uploading success message is used for informing the first equipment of the distance information which is uploaded successfully.
Specifically, if the distance information is uploaded through at least two data packets, based on the upload success message, deleting the distance information that is successfully uploaded, including: determining a successfully uploaded data packet based on the successfully uploaded message; and deleting the distance information corresponding to the successfully uploaded data packet.
For the embodiment of the present application, when the first device uploads the distance information to the corresponding device, the corresponding device may send an upload success message to the first device as long as receiving the data packet, may also receive a preset number of data packets, and then send the upload success message to the first device, and may also send the upload success message to the first device after receiving all the data packets. In this embodiment of the present application, the upload success message may carry packet information of a data packet that has been successfully uploaded. For example, the packet information may include: identification of the data packet.
For the embodiment of the application, after the device completes ranging in one period, the main control chip stores the obtained distance information into the storage chip, the tag searches for a nearby base station at intervals, the data information is packed and uploaded to the data collection base station in a segmented manner after the base station is searched, the corresponding data segment is deleted after the uploading is successful, and the storage space is released.
Further, after the device and the base station establish connection through exploring the base station frame and the reply frame of the base station, and upload a plurality of data packets, the base station replies the label with the reply frame once, and tells the label which packets with sequence numbers are successfully received. The tag then deletes the corresponding packet, freeing up storage space. Then, this process is repeated, and the data packet is uploaded continuously, for example, as shown in fig. 5, the device establishes a connection with the data collection base station through the discovery base station frame and the reply discovery frame, then the device uploads the data packet 1 and the data packet 2 … … data n in sequence, then the data collection base station determines the successfully uploaded data packet and transmits a successful upload message, so that the device deletes the successfully uploaded data packet and releases the storage space.
Many times this distance value needs to be encrypted, e.g. ranging between persons, which cannot be read and viewed at will based on considerations protecting the privacy of the persons. In the scene of the requirement, an encryption chip is required to be carried in the equipment, once distance information is generated, the distance information is encrypted by the encryption chip and then stored, and the information is reported later and stored in an industrial personal computer and the like, wherein the operation is also used for the encrypted information. In the embodiment of the application, the decrypted key is stored in a department which has authority to view the private information, and when the distance information of a certain device needs to be viewed, an authorized party of the department needs to view the distance information.
The following embodiments describe a method of ranging by way of specific examples, which are specifically shown as follows:
example one: in some embodiments, the second channel is a bluetooth channel, that is, the ranging system includes device 1 and device 2 … …, the device 1 and device 2 … … are connected via bluetooth, in this embodiment, a ranging instruction and the like are transmitted via the bluetooth connection, so that each device performs ranging on a first channel (for example, a UWB channel), that is, each device 1 and device 2 … … starts UWB ranging, the device 1 sends ranging control information to each device 2 … … and device N, for example, the ranging control information may be sent via a first frame format, then the device 1 sends a ranging start message (or may be sent via a ranging start frame) to each device 2 … … and device N, for example, the ranging start message may be sent via a second frame format, and then each device 2 … … and device N returns a ranging response message to the device 1, and the ranging response message may carry a ranging report message (the ranging report message may carry at least one ranging response message) Time information), the ranging response message may be sent through a ranging reply frame in this example, and the frame format may be a third frame format, as shown in fig. 9 in particular. In the embodiment of the present application, the ranging control information includes ranging related parameters, including a time slice length (i.e., a length of a ranging slot), a ranging method type, and the like. In this embodiment of the present application, a Phase in which the device 1 sends the Ranging Control message to the devices 2 and 3 belongs to a Ranging Control Phase (RCP), and a Phase in which the Ranging initiation message is sent belongs to a Ranging Initiation Phase (RIP); the Phase of sending ranging response carrying the ranging Report message to the device 1 by the device 2 and the device 3 belongs to a Result Report Phase (RRP) and a Measurement Report Phase (MRP); wherein, in the result reporting phase, the device 2 and the device 3 can respectively send at least one piece of time information locally recorded by the device 2 and the device 3 to the device 1; in the measurement report phase, the device 2 and the device 3 may send, to the device 1, at least one piece of time difference information and/or at least one piece of distance information locally acquired by the device 2 and the device 3, respectively; the result reporting phase may also be the same as the measurement reporting phase, in other words, the device 2 sends the time information and the distance information to the device 1 in the same frame, and the device 3 sends the time information and the distance information to the device 1 in the same frame;
example two: the ranging system includes a device 1, a device 2 … …, a device N, a bluetooth connection is used between the device 1 and the device 2 … …, and each of the device 1 and the device 2 … … starts UWB ranging, the device 1 sends a ranging start message carrying a ranging control message to each of the device 2 … …, the frame format used may be a second frame format (specifically, the ranging start message may be sent via a ranging start frame), then the device 1 sends a ranging start message (may also be sent via a ranging start frame) to each of the device 2 … …, the ranging start message may be sent via the second frame format, for example, then each of the device 2 … …, the ranging response message may carry a ranging report message, and in this example, the ranging response message may be sent via a ranging reply frame, the frame format may be a second frame format, and the ranging report message may generally carry at least one of time information and determined range information. In the embodiment of the present application, the Phase of sending the Ranging initiation message belongs to a Ranging Initiation Phase (RIP); the Phase of sending a ranging response carrying a ranging Report message to device 1 by device 2 and device 3 belongs to a Result Report Phase (RRP) and a Measurement Report Phase (MRP), where in the Result Report Phase, device 2 and device 3 may send at least one piece of time information locally recorded by device 2 and device 3 to device 1 respectively; in the measurement report phase, the device 2 and the device 3 may send, to the device 1, at least one piece of time difference information and/or at least one piece of distance information locally acquired by the device 2 and the device 3, respectively; in other words, the device 2 sends the time information and the distance information to the device 1 in the same frame, and the device 3 sends the time information and the distance information to the device 1 in the same frame, as shown in fig. 10.
Example three: the ranging system includes a device 1, a device 2 … …, a device 1, a device 2 … …, a device 1, a device 2 … …, a device 2 … …, a device N, and a device 2 … …, wherein the device 1 starts UWB ranging, the device 1 sends ranging control information to the device 2 … …, the ranging control information may be sent through a first frame format, the device 1 sends a ranging start message (or may be sent through a ranging start frame) to the device 2 … …, the ranging start message may be sent through a second frame format, and the device 2 … … returns a ranging response message to the device 1, the ranging response message may carry a ranging report message, in this example, the ranging response message may be sent through a ranging reply frame, the frame format may be the second frame format, and the device 1 sends a ranging final message carrying the ranging report message to the device 2 … …, specifically, the Ranging result may be sent through a Ranging final frame, where the frame format may be a second frame format, and then each device in device 2 … … device N returns a Ranging result report message to device 1, where the frame format may include a first frame format, and a Phase of sending a Ranging start message in this embodiment belongs to a Ranging Initiation Phase (RIP); a Phase in which the device 2 and the device 3 transmit a Ranging response carrying a Ranging Report message to the device 1 belongs to a Result Reporting Phase (RRP) and a Measurement Reporting Phase (MRP), a Phase in which the device 1 transmits a Ranging Final message carrying a Ranging Report message to the device 2 … device N belongs to a Final Ranging Phase (RFP) and a Ranging reporting Phase (MRP), and a Phase in which the device 2 and the device 3 … transmit a Ranging Result Report message to the device 1 belongs to a Ranging Result Reporting Phase (RRRP), wherein in the Result reporting Phase, the device 2 and the device 3 can transmit at least one piece of time information locally recorded by the device 2 and the device 3 to the device 1, respectively; in the measurement report phase, the device 2 and the device 3 may send, to the device 1, at least one piece of time difference information and/or at least one piece of distance information locally acquired by the device 2 and the device 3, respectively; in other words, the device 2 sends the time information and the distance information to the device 1 in the same frame, and the device 3 sends the time information and the distance information to the device 1 in the same frame, as shown in fig. 11.
Example four: the ranging system includes a device 1 and a device 2 … … N, the device 1 and the device 2 … … are connected via bluetooth, and each of the device 1 and the device 2 … … starts UWB ranging, the device 1 sends a ranging start message (specifically, may send via a ranging start frame) carrying a ranging control message to each of the device 2 … … and the device N, where the frame format used may be a second frame format, and then the device 1 sends a ranging start message (which may also be sent via a ranging start frame) to each of the device 2 … … and the device N, for example, via the second frame format, and each of the device 2 … … and the device N returns a ranging response message to the device 1, where the ranging response message may carry a ranging report message, and in this example, the ranging response message may be sent via a ranging reply frame, the frame format may be a second frame format, then device 1 sends a Ranging final message carrying a Ranging report message to each device in device 2 … …, and may specifically send the Ranging final message through the Ranging final frame, where the frame format may be the second frame format, and then each device in device 2 … … returns a Ranging result report message to device 1, where the frame format may include the first frame format, and a Phase of sending a Ranging start message carrying a Ranging control message in this embodiment belongs to a Ranging Initiation Phase (RIP) and an RCP; a Phase in which the device 2 and the device 3 transmit a Ranging response carrying a Ranging Report message to the device 1 belongs to a Result Reporting Phase (RRP) and a Measurement Reporting Phase (MRP), a Phase in which the device 1 transmits a Ranging Final message carrying a Ranging Report message to the device 2 … device N belongs to a Final Ranging Phase (RFP) and a Ranging reporting Phase (MRP), and a Phase in which the device 2 and the device 3 … transmit a Ranging Result Report message to the device 1 belongs to a Ranging Result Reporting Phase (RRRP), wherein in the Result reporting Phase, the device 2 and the device 3 can transmit at least one piece of time information locally recorded by the device 2 and the device 3 to the device 1, respectively; in the measurement report phase, the device 2 and the device 3 may send at least one piece of time difference information locally acquired by the device 2 and the device 3 to the device 1, respectively; in the ranging report phase, the device 2 and the device 3 may send at least one piece of distance information locally acquired by the device 2 and the device 3 to the device 1, respectively; as shown in particular in fig. 12.
In the embodiment of the present application, the first device may be a certain device in a ranging system, and after the first device determines that the first device performs ranging with the first device, the device for initiating ranging is the third device when performing ranging with the first device; the device for replying to ranging is a second device; for example, the ranging system includes a device 1, a device 2, a device 3, and a device 4, where if the device 1 performs ranging with the device 2, the device 3, and the device 4, the device 1 is a ranging initiating device, and if the device 2 performs ranging with the device 3 and the device 4, the device 2 is a ranging initiating device, and if the device 3 initiates ranging with the device 4, the device 3 is a ranging initiating device. That is, if the device 2 is a first device, the devices 3 and 4 are second devices, and the device 1 is a third device; if the device 3 is a first device, the device 4 is a second device, and the devices 1 and 2 are third devices; furthermore, if the device 1 is a first device, the devices 2,3 and 4 are second devices; if the device 4 is a first device, the device 1, the device 2, and the device 3 are all third devices;
an embodiment of the present application provides a ranging method, which is executed by a second device, where in this application, the second device is an electronic device, as shown in fig. 13, and includes:
step S201, receiving at least one ranging frame;
step S202, at least one ranging frame is sent.
For the embodiment of the present application, step S201 may be performed before step S202, or after step S202, or may be performed simultaneously with step S202, and fig. 13 is only one possible implementation manner, and is not limited to the embodiment of the present application.
In another possible implementation manner of the embodiment of the present application, step S201 may include: receiving at least one ranging frame transmitted by at least one first device; and/or receiving at least one ranging frame sent by at least one third device; specifically, step S201 and step S202 are executed simultaneously, that is, the transmitting end device (for transmitting the at least one ranging frame received in step S201) corresponding to step S201 and the receiving end device (for receiving the at least one ranging frame transmitted in step S202) corresponding to step S202 are different devices, and the corresponding transceiving frequencies are also different.
Specifically, step S202 may include: transmitting at least one ranging frame to at least one first device; and/or transmitting the at least one ranging frame to the at least one third device.
In another possible implementation manner of the embodiment of the present application, step S201 may specifically include: receiving at least one ranging frame transmitted by at least one first device; and/or receiving at least one ranging frame transmitted by at least one third device;
specifically, the received at least one ranging frame is a ranging initiation frame. In the embodiment of the application, at least one ranging initiation frame sent by at least one first device is received; and/or receiving at least one ranging initiation frame sent by at least one third device;
specifically, the at least one ranging frame transmitted is a ranging reply frame. In an embodiment of the present application, at least one ranging reply frame is transmitted to at least one first device; and/or transmitting at least one ranging reply frame to at least one third device.
In another possible implementation manner of the embodiment of the present application, if there are at least two first devices, at least one ranging frame exists in at least one ranging frame sent to each first device and is the same frame.
Specifically, if there are at least two first devices, at least one ranging frame in at least one ranging reply frame sent by the second device to each first device is the same frame, so that frame multiplexing can be realized, frame transmission in the ranging system is saved, and the device capacity of the ranging system is improved.
In another possible implementation manner of the embodiment of the present application, if there are at least two third devices, at least one ranging frame exists in the at least one ranging frame sent to each third device and is the same frame.
Specifically, if there are at least two third devices, at least one ranging frame in at least one ranging frame sent by the second device to each third device is the same frame. In the embodiment of the application, the frame multiplexing can be realized by ranging in the above manner, the frame transmission in the ranging system is saved, and the equipment capacity of the ranging system can be improved.
In another possible implementation manner of the embodiment of the present application, the method further includes: at least one ranging frame in the at least one ranging frame transmitted to the at least one third device and at least one ranging frame in the at least one ranging frame transmitted to the at least one first device are the same ranging frame. In the embodiment of the application, the frame multiplexing can be realized by ranging in the above manner, the frame transmission in the ranging system is saved, and the equipment capacity of the ranging system can be improved.
For example, a ranging frame 1 is sent to the third device, and a ranging frame 2 is sent to the first device, where the ranging frame 1 and the ranging frame 2 are the same ranging frame.
In another possible implementation manner of the embodiment of the present application, the method further includes: for each first device, acquiring at least two pieces of time information by receiving at least one ranging frame and transmitting at least one ranging frame; and/or, for each first device, acquiring at least four pieces of time information by receiving at least one ranging frame and transmitting at least one ranging frame; and/or, for each first device, acquiring at least six pieces of time information by receiving at least two ranging frames and transmitting at least one ranging frame; and/or, for each first device, acquiring at least six pieces of time information by receiving at least one ranging frame and transmitting at least two ranging frames.
For the embodiment of the present application, the manner in which the second device obtains at least four pieces of time information and/or at least six pieces of time information is similar to the manner in which the first device obtains at least four pieces of time information and/or at least six pieces of time information, which is described in detail in the above embodiment.
In another possible implementation manner of the embodiment of the present application, the method further includes: for each first device, acquiring distance information between the second device and each first device based on at least two pieces of time information; and/or acquiring distance information between the second equipment and each first equipment based on at least four pieces of time information aiming at each first equipment; and/or acquiring distance information between the second device and each first device based on at least six pieces of time information for each first device.
For the embodiment of the present application, the manner in which the second device obtains the distance information based on at least two pieces of time information, and/or the second device obtains the distance information based on at least four pieces of time information, and/or the manner in which the second device obtains the distance information based on at least six pieces of time information is similar to the manner in which the first device obtains the distance information based on at least two pieces of time information, and/or obtains the distance information based on at least four pieces of time information, and/or obtains the distance information based on at least six pieces of time information, which is specifically described in the above embodiment.
In another possible implementation manner of the embodiment of the present application, the method further includes: for each third device, acquiring at least two pieces of time information by transmitting at least one ranging frame and receiving at least one ranging frame; and/or, for each third device, acquiring at least four pieces of time information by transmitting at least one ranging frame and receiving at least one ranging frame; and/or, for each third device, acquiring at least six pieces of time information by transmitting at least two ranging frames and receiving at least one ranging frame; and/or, for each third device, acquiring at least six pieces of time information by transmitting at least one ranging frame and receiving at least two ranging frames.
For the embodiment of the present application, the manner in which the second device acquires at least two pieces of time information and/or the second device acquires at least four pieces of time information and/or the second device acquires at least six pieces of time information is described in detail in the manner in which the first device acquires time information. Details are not described in the embodiments of the present application.
In another possible implementation manner of the embodiment of the present application, the method further includes: for each third device, obtaining distance information between the second device and each third device based on the at least two pieces of time information; and/or, for each third device, obtaining distance information between the second device and each third device based on the at least four pieces of time information; and/or, for each third device, obtaining distance information between the second device and each third device based on the at least six pieces of time information.
For the embodiment of the present application, the manner in which the second device obtains the distance information based on at least two pieces of time information, and/or the second device obtains the distance information based on at least four pieces of time information, and/or the manner in which the second device obtains the distance information based on at least six pieces of time information is similar to the manner in which the first device obtains the distance information based on at least two pieces of time information, and/or obtains the distance information based on at least four pieces of time information, and/or obtains the distance information based on at least six pieces of time information, which is specifically described in the above embodiment.
Further, in the embodiment of the present application, the manner in which the second device performs ranging is similar to the manner in which the first device performs ranging, that is, the manner in which the first device performs ranging is also applicable to the manner in which the second device performs ranging. No further description is given in this embodiment.
The embodiment of the present application further provides a ranging method, which is executed by a third device, where in the embodiment of the present application, the third device is an electronic device, as shown in fig. 14 in particular, where,
step S301, receiving at least one ranging frame;
step S302, at least one ranging frame is sent.
For the embodiment of the present application, step S301 may be performed before step S302, or after step S302, or may be performed simultaneously with step S302, and fig. 14 is only one possible implementation manner, and is not limited to the embodiment of the present application.
In another possible implementation manner of the embodiment of the present application, step S301 may specifically include: receiving at least one ranging frame transmitted by at least one first device; and/or receiving at least one ranging frame transmitted by at least one second device.
Specifically, the received at least one frame is a ranging reply frame. In the embodiment of the application, at least one ranging reply frame sent by at least one first device is received; and/or receiving at least one ranging reply frame sent by at least one third device;
specifically, step S302 may specifically include: transmitting at least one ranging frame to at least one first device; and/or transmitting at least one ranging frame to at least one second device.
Specifically, at least one sent ranging frame is a ranging initiation frame; in an embodiment of the present application, at least one ranging initiation frame is sent to at least one first device; and/or transmitting at least one ranging initiation frame to at least one third device.
Specifically, if there are at least two first devices, at least one of the received at least one ranging frame sent by each first device is the same frame. In the embodiment of the present application, at least one ranging frame exists in at least one ranging frame sent by each first device and received by the third device, so that frame multiplexing can be achieved, frame transmission in the ranging system can be saved, and the device capacity of the ranging system can be improved.
Specifically, if there are at least two second devices, at least one of the received at least one ranging frame sent by each second device is the same frame. In the embodiment of the present application, at least one ranging frame exists in at least one ranging frame sent by each second device and received by the third device, so that frame multiplexing can be achieved, frame transmission in the ranging system can be saved, and the device capacity of the ranging system can be improved.
Further, at least one ranging frame transmitted to the at least one second device is the same as at least one ranging frame in the at least one ranging frame transmitted to the at least one first device. In the embodiment of the application, the frame multiplexing can be realized by the ranging in the above manner, the frame transmission in the ranging system is saved, and the capacity of the ranging equipment in the ranging system can be improved.
In the embodiment of the present application, a manner of performing ranging by the third device is similar to that of performing ranging by the first device, and details may be described in an embodiment corresponding to the manner of performing ranging by the first device, which is not limited in the embodiment of the present application.
The above embodiment introduces a distance measuring method from the perspective of a method flow, and on the basis of the above embodiment, the following embodiment introduces a distance measuring device from the perspective of a module or a unit, which is applicable to the above method embodiment, and specifically as follows:
an embodiment of the present application provides a distance measuring device, as shown in fig. 2, the distance measuring device 20 may include: a first sending module 21 and a first receiving module 22, wherein,
a first transmitting module 21, configured to transmit at least one ranging frame; and the number of the first and second groups,
a first receiving module 22, configured to receive at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: a first obtaining module, wherein,
the first obtaining module is configured to obtain at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: at least one of a second acquisition module and a third acquisition module, wherein,
the second acquisition module is used for acquiring at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame;
and the third acquisition module is used for acquiring at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames.
Another possible implementation of the embodiments of the present application, wherein,
a first receiving module 22, further configured to receive at least one time information;
the first obtaining module is specifically configured to, when obtaining at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame: at least four pieces of time information are acquired by transmitting at least one ranging frame, receiving at least one ranging frame, and receiving at least one piece of time information.
In another possible implementation manner of the embodiment of the application, at least one received ranging frame carries time information;
the first obtaining module is specifically configured to, when obtaining at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame: at least four pieces of time information are obtained by sending at least one ranging frame, receiving at least one ranging frame and the received time information carried in at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, the first receiving module 22 is further configured to receive at least one piece of time information;
the second obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame: acquiring at least six pieces of time information by sending at least two ranging frames, at least one received ranging frame and at least one piece of received time information;
the third obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames: at least six pieces of time information are acquired by transmitting at least one ranging frame, receiving at least two ranging frames, and receiving at least one piece of time information.
In another possible implementation manner of the embodiment of the application, at least one received ranging frame carries time information;
the second obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame: acquiring at least six pieces of time information by sending at least two ranging frames, receiving at least one ranging frame and time information carried in the received at least one ranging frame;
the third obtaining module is specifically configured to, when obtaining at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames: at least six pieces of time information are obtained by sending at least one ranging frame, receiving at least two ranging frames and time information carried in the received at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: the at least two sent ranging frames at least comprise a Final frame; and/or, the received at least two ranging frames comprise at least one Final frame.
In another possible implementation manner of the embodiment of the application, the time information is carried in the ranging frame; and/or the time information is not carried by the ranging frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes:
when the time information is not carried by the ranging frame, the time information is sent through a first channel; and/or the presence of a gas in the gas,
when the time information is not carried by the ranging frame, the data frame is sent through a second channel;
wherein, the first channel comprises a channel for receiving and transmitting the ranging frame;
the second channel is a channel not containing the transceiving ranging frame.
In another possible implementation manner of the embodiment of the present application, the second channel is a bluetooth channel.
In another possible implementation manner of the embodiment of the present application, a frame format of the received ranging frame is specifically a fourth frame format;
wherein, the fourth frame format does not contain payload data.
In another possible implementation manner of the embodiment of the present application, a frame format of the ranging frame includes at least one of:
a first frame format, a second frame format, and a third frame format.
In another possible implementation manner of the embodiment of the present application, the first frame format includes: synchronizing SYNC, a frame start symbol SFD, a physical frame header PHR and a packet load PHR Payload;
the second frame format includes: SYNC, SFD, scrambling time stamp sequence STS, PHR, PHY Payload;
the third frame format includes: SYNC, SFD, PHR, PHY Payload, STS.
Another possible implementation manner of the embodiment of the present application, the carried time information includes at least one of the following:
a transmission time of the received at least one ranging frame and reception time information of the transmitted at least one ranging frame;
transmitting transmission time information of the at least one ranging frame, and receiving reception time information of the at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, when sending at least one ranging frame, the first sending module 21 is specifically configured to send the at least one ranging frame to at least two peer devices; and when receiving at least one ranging frame, the first receiving module is specifically configured to: and receiving at least one ranging frame respectively sent by at least two opposite-end devices.
In another possible implementation manner of the embodiment of the present application, at least one ranging frame sent to at least two peer devices is the same frame.
In another possible implementation manner of the embodiment of the present application, when the first sending module 21 sends at least one ranging frame, the first sending module is specifically configured to: the method includes sending at least one ranging initiation frame to at least one second device of the at least two peer devices, and sending at least one ranging reply frame to at least one third device of the at least two peer devices.
In another possible implementation manner of the embodiment of the present application, the first receiving module 22 is further configured to receive at least one ranging reply frame sent by at least one second device;
the first receiving module 22 is further configured to: receiving at least one ranging initiation frame transmitted by at least one third device.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes:
the at least one ranging initiation frame comprises the same frame as the corresponding ranging reply frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: a fourth obtaining module, wherein,
and the fourth obtaining module is used for obtaining the distance information between the first equipment and the opposite terminal equipment according to the at least four pieces of time information.
In another possible implementation manner of the embodiment of the application, when the fourth obtaining module obtains the distance information between the first device and the peer device according to the at least four pieces of time information, the fourth obtaining module is specifically configured to at least one of the following:
determining distance information between the first device and the opposite-end device according to the sending time of the sending ranging frame, the receiving time of the receiving ranging frame and the received time information;
and receiving distance information between the first device and the opposite terminal device, which is sent by the opposite terminal device.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: a fifth obtaining module, wherein,
and the fifth obtaining module is used for obtaining the distance information between the first equipment and the opposite terminal equipment according to the at least six pieces of time information.
In another possible implementation manner of the embodiment of the application, when the fifth obtaining module obtains the distance information between the first device and the peer device according to at least six pieces of time information, the fifth obtaining module is specifically configured to at least one of the following:
determining distance information between the first device and the opposite-end device according to sending time information respectively corresponding to at least two distance measuring frames, receiving time information corresponding to at least one distance measuring frame and the received time information;
determining distance information between the first equipment and opposite-end equipment according to sending time information of sending at least one ranging frame, receiving time corresponding to at least two ranging frames respectively and the received time information;
and receiving distance information between the first device and the opposite terminal device, which is sent by the opposite terminal device.
In another possible implementation manner of this embodiment, the fifth obtaining module, when determining distance information between the first device and the peer device according to sending time information corresponding to sending at least two ranging frames, receiving time information corresponding to receiving at least one ranging frame, and the received time information, is specifically configured to:
determining distance information between the first equipment and opposite-end equipment according to the sending time information of sending at least one ranging frame, the sending time of sending a final frame and the receiving time information of receiving at least one ranging frame;
the fifth obtaining module is specifically configured to, when determining distance information between the first device and the peer device according to the sending time information for sending the at least one ranging frame, the receiving time corresponding to each of the at least two ranging frames, and the received time information:
and determining the distance information between the first equipment and the opposite equipment according to the sending time information of sending the at least one ranging frame, the receiving time information of receiving the at least one ranging frame and the receiving time information of receiving the final frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes:
the first receiving module 22 is further configured to receive a ranging instruction;
a first sending module 21, further configured to send at least one ranging frame based on the ranging instruction; and the number of the first and second groups,
the first receiving module 22 is further configured to receive at least one ranging frame based on the ranging instruction.
In another possible implementation manner of the embodiment of the present application, the ranging instruction includes: ranging time slot information;
the first sending module 21 is specifically configured to, when sending at least one ranging frame based on the ranging instruction: transmitting at least one ranging frame based on the ranging slot information;
the first receiving module 22 is specifically configured to, when receiving at least one ranging frame based on the ranging instruction: at least one ranging frame is received based on the ranging slot information.
In another possible implementation manner of the embodiment of the present application, the ranging slot information includes: presetting a time slot;
the first sending module 21 is specifically configured to, when sending at least one ranging frame based on the ranging slot information: transmitting at least one ranging frame in a preset time slot;
the first receiving module 22 is specifically configured to, when receiving at least one ranging frame based on the ranging slot information: at least one ranging frame is received within a preset time slot.
In another possible implementation manner of the embodiment of the present application, when the first sending module 21 sends at least one ranging frame based on the ranging instruction, the first sending module sends the at least one ranging frame in a random time slot based on the ranging instruction; and when receiving at least one ranging frame based on the ranging instruction, the first receiving module 22 is specifically configured to: at least one ranging frame is received within a random time slot based on the ranging instruction.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: and the determining module is used for determining the random time slot according to the self equipment information.
In another possible implementation manner of the embodiment of the present application, the first sending module 21 is further configured to send the device information, so that the peer device determines the ranging instruction based on the device information.
In another possible implementation manner of the embodiment of the present application, the first sending module 21 is further configured to send a ranging instruction, so that a device that receives the ranging instruction sends and/or receives a ranging frame.
In another possible implementation manner of the embodiment of the application, the ranging instruction includes ranging time slot information; when determining the ranging slot information, the determining module is specifically configured to: acquiring equipment information sent by opposite-end equipment; and determining ranging time slot information based on the equipment information sent by the opposite terminal equipment and the self equipment information.
In another possible implementation manner of the embodiment of the present application, the device information includes: a device identification;
the determining module is specifically configured to, when determining ranging slot information based on device information sent by an opposite-end device and device information of the determining module, determine: sorting processing is carried out based on the device identifications respectively corresponding to the devices; and determining ranging slot information based on the sequencing result.
In another possible implementation manner of the embodiment of the application, the device information is transmitted through the first channel and/or the second channel; the ranging command is transmitted through the first channel and/or the second channel.
In another possible implementation manner of the embodiment of the present application, a communication distance of the first channel is matched with a communication distance of the second channel.
In another possible implementation manner of the embodiment of the present application, the first channel is specifically an ultra wideband UWB channel; and/or the second channel is specifically a bluetooth channel.
In another possible implementation manner of the embodiment of the present application, the apparatus 20 further includes: an upload module, wherein the upload module is capable of,
the uploading module is used for uploading distance information between the first equipment and the opposite terminal equipment to the corresponding equipment;
the corresponding device comprises at least one of:
a mobile terminal;
a gateway;
and (4) a server.
In another possible implementation manner of the embodiment of the application, when uploading the distance information between the first device and the peer device to the corresponding device, the uploading module is specifically configured to: and uploading the distance information between the first equipment and the opposite terminal equipment to the corresponding equipment through the first channel or the second channel.
In another possible implementation manner of the embodiment of the application, the first receiving module 22 is further configured to receive an upload success message sent by the corresponding device, where the upload success message is used to inform the first device of distance information of successful upload;
wherein the apparatus 20 further comprises: a deletion module for deleting, wherein,
and the deleting module is used for deleting the distance information which is successfully uploaded based on the successful uploading message.
In another possible implementation manner of the embodiment of the application, when the distance information is uploaded through at least two data packets, the deleting module is specifically configured to, when deleting the distance information successfully uploaded based on the upload success message: determining a successfully uploaded data packet based on the successfully uploaded message; and deleting the distance information corresponding to the successfully uploaded data packet.
For the embodiment of the present application, the first obtaining module, the second obtaining module, the third obtaining module, the fourth obtaining module, and the fifth obtaining module are all the same module, or all different modules, or at least two of the first obtaining module, the second obtaining module, the third obtaining module, the fourth obtaining module, and the fifth obtaining module are the same module, which is not limited in the embodiment of the present application.
Compared with the prior art, in the ranging apparatus provided in the embodiment of the present application, the first device sends at least one ranging frame and receives at least one ranging frame, and in the embodiment of the present application, the first device sends and/or receives at least one ranging frame, so that ranging between devices can be implemented.
The distance measuring device provided in the embodiment of the present application is applicable to the method embodiments described above, and is not described herein again.
Another distance measuring device is provided in the embodiment of the present application, as shown in fig. 18, the device 180 includes: a second receiving module 181 and a second transmitting module 182, wherein,
a second receiving module 181, configured to receive at least one ranging frame; and the number of the first and second groups,
a second sending module 182, configured to send at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, when receiving at least one ranging frame, the second receiving module 181 is specifically configured to:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the gas,
receiving at least one ranging frame transmitted by at least one third device;
when the second sending module 182 sends at least one ranging frame, it is specifically configured to:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one third device.
In another possible implementation manner of the embodiment of the present application, when there are at least two first devices, at least one ranging frame is the same frame in at least one ranging frame sent to each first device.
In another possible implementation manner of the embodiment of the application, when the number of the third devices is at least two,
at least one ranging frame is the same frame in at least one ranging frame sent to each third device.
In another possible implementation manner of the embodiment of the present application, at least one of the at least one ranging frame sent to the at least one third device and the at least one ranging frame sent to the at least one first device is the same ranging frame.
In another possible implementation manner of the embodiment of the present application, the apparatus 180 further includes: a sixth obtaining module;
the sixth obtaining module is configured to obtain, for each first device, at least four pieces of time information by receiving at least one ranging frame and sending at least one ranging frame; and/or the presence of a gas in the gas,
the sixth obtaining module is configured to obtain, for each first device, at least six pieces of time information by receiving at least two ranging frames and sending at least one ranging frame; and/or the presence of a gas in the gas,
the sixth obtaining module is configured to obtain, for each first device, at least six pieces of time information by receiving at least one ranging frame and sending at least two ranging frames.
In another possible implementation manner of the embodiment of the present application, the apparatus 180 further includes: a seventh obtaining module, wherein,
the seventh obtaining module is configured to, for each first device, obtain distance information between the second device and each first device based on the at least four pieces of time information; and/or the presence of a gas in the gas,
the seventh obtaining module is configured to, for each first device, obtain distance information between the second device and each first device based on the at least six pieces of time information.
In another possible implementation manner of the embodiment of the present application, the apparatus 180 further includes: an eighth obtaining module, wherein,
the eighth obtaining module is configured to obtain, for each third device, at least four pieces of time information by sending at least one ranging frame and receiving at least one ranging frame; and/or the presence of a gas in the gas,
the eighth acquiring module is configured to acquire, for each third device, at least six pieces of time information by sending at least two ranging frames and receiving at least one ranging frame; and/or the presence of a gas in the gas,
the eighth obtaining module is configured to obtain, for each third device, at least six pieces of time information by sending at least one ranging frame and receiving at least two ranging frames.
In another possible implementation manner of the embodiment of the present application, the apparatus 180 further includes: a ninth obtaining module, wherein,
the ninth obtaining module is configured to obtain, for each third device, distance information between the second device and each third device based on the at least four pieces of time information; and/or the presence of a gas in the atmosphere,
the ninth obtaining module is configured to, for each third device, obtain distance information between the second device and each third device based on the at least six pieces of time information.
In another possible implementation manner of the embodiment of the present application, the received at least one ranging frame is a ranging initiation frame; at least one of the ranging frames transmitted is a ranging reply frame.
Compared with the prior art, in the ranging apparatus provided in the embodiment of the present application, the second device receives at least one ranging frame and the second device sends the at least one ranging frame, and in the embodiment of the present application, the second device sends and/or receives the at least one ranging frame, so that ranging between any two devices can be implemented.
The embodiment of the present application further provides another distance measuring device, as shown in fig. 19, including: a third receiving module 191 and a third transmitting module 192, wherein the third receiving module 191 is configured to receive at least one ranging frame; and the number of the first and second groups,
a third sending module 192, configured to send at least one ranging frame.
In another possible implementation manner of the embodiment of the present application, when receiving at least one ranging frame, the third receiving module 191 is specifically configured to:
receiving at least one ranging frame transmitted by at least one first device; and/or the presence of a gas in the atmosphere,
at least one ranging frame transmitted by at least one second device is received.
The third sending module 192 is specifically configured to, when sending at least one ranging frame:
transmitting at least one ranging frame to the at least one first device; and/or the presence of a gas in the gas,
transmitting at least one ranging frame to the at least one second device.
In another possible implementation manner of the embodiment of the present application, when there are at least two first devices, at least one ranging frame exists in at least one ranging frame sent by each first device and is the same frame.
In another possible implementation manner of the embodiment of the present application, when there are at least two second devices, at least one ranging frame exists in at least one ranging frame sent by each second device and is the same frame.
In another possible implementation manner of the embodiment of the present application, at least one of the at least one ranging frame sent to the at least one second device and the at least one ranging frame sent to the at least one first device is the same ranging frame.
In another possible implementation manner of the embodiment of the present application, the at least one ranging frame that is sent is a ranging initiation frame; the at least one frame received is a ranging reply frame.
Compared with the prior art, in the ranging apparatus provided in the embodiment of the present application, the third device receives at least one ranging frame and sends the at least one ranging frame, and in the embodiment of the present application, the third device sends and/or receives the at least one ranging frame, so that ranging between any two devices can be implemented.
The embodiment of the application also provides a first device, which comprises a memory and a processor; the memory has a computer program stored therein; the processor is adapted to perform the methods provided in the above-described method embodiments when running the computer program.
Embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program may implement the method provided in the above-mentioned method embodiments of the present application.
As an example, fig. 3 shows a schematic structural diagram of a first device 3000 to which the embodiments of the present application can be applied, where the first device 3000 includes a memory 3003 and a processor 3001, the memory 3003 stores therein a computer program, and the processor 3001 is configured to execute any one of the methods described above when the computer program is executed.
Specifically, the first device may be a terminal, a server, or other possible devices, and fig. 3 shows only an alternative schematic structure of the first device. The structure of the first device 3000 shown in fig. 3 is not intended to limit the embodiments of the present application.
The processor 3001 is coupled to the memory 3003, such as via a bus 3002. Optionally, the first device 3000 may further comprise a transceiver 3004. It should be noted that the transceiver 3004 is not limited to one in practical applications, and the transceiver 3004 may be specifically used for communication between the first device 3000 and other devices.
The Processor 3001 may be a CPU (Central Processing Unit), a general-purpose Processor, a DSP (Digital Signal Processor), an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array) or other Programmable logic device, a transistor logic device, a hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure of the present application. The processor 3001 may also be a combination of computing functions, e.g., comprising one or more microprocessors, a combination of a DSP and a microprocessor, or the like.
Bus 3002 may include a path that conveys information between the aforementioned components. The bus 3002 may be a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, or the like. The bus 3002 may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in FIG. 3, but this does not mean only one bus or one type of bus.
The Memory 3003 may be a ROM (Read Only Memory) or other type of static storage device that can store static information and instructions, a RAM (Random Access Memory) or other type of dynamic storage device that can store information and instructions, an EEPROM (Electrically Erasable Programmable Read Only Memory), a CD-ROM (Compact Disc Read Only Memory) or other optical Disc storage, optical Disc storage (including Compact Disc, laser Disc, optical Disc, digital versatile Disc, blu-ray Disc, etc.), a magnetic Disc storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, but is not limited to these.
The memory 3003 is used for storing application program codes for performing the present scheme, and is controlled to be executed by the processor 3001. The processor 3001 is configured to execute application program code stored in the memory 3003 to implement the content shown in any of the above method embodiments.
The embodiment of the application also provides a second device, wherein the first device comprises a memory and a processor; the memory has a computer program stored therein; the processor is adapted to perform the method of the above-described method embodiment performed by the second device when running the computer program.
An embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the program is executed by a processor, the computer program may implement the method provided by the second device in the foregoing method embodiment of the present application.
The embodiment of the application also provides a third device, wherein the first device comprises a memory and a processor; the memory has a computer program stored therein; the processor is adapted to perform the method of the above-described method embodiment, performed by the third device, when running the computer program.
An embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program may implement the method provided by the third device in the foregoing method embodiment of the present application.
Further, the structures corresponding to the second device and the second device are similar to the first device, and specific details are described in the foregoing embodiment for the structure of the first device, which are not described in detail in this embodiment.
It should be understood that, although the steps in the flowcharts of the figures are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not performed in the exact order shown and may be performed in other orders unless explicitly stated herein. Moreover, at least a portion of the steps in the flow chart of the figure may include multiple sub-steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, which are not necessarily performed in sequence, but may be performed alternately or alternately with other steps or at least a portion of the sub-steps or stages of other steps.
The foregoing is only a partial embodiment of the present application, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present application, and these modifications and decorations should also be regarded as the protection scope of the present application.

Claims (12)

1. A method of ranging, performed by a first device, comprising:
transmitting at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is received.
2. A ranging apparatus, comprising:
a first transmitting module, configured to transmit at least one ranging frame; and the number of the first and second groups,
the first receiving module is used for receiving at least one ranging frame.
3. A first apparatus, characterized in that it comprises:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: performing a ranging method according to claim 1.
4. A computer-readable storage medium for storing computer instructions which, when executed on a computer, cause the computer to perform the ranging method of claim 1.
5. A method of ranging, performed by a second device, comprising:
receiving at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is transmitted.
6. A ranging method, performed by a third device, comprising:
receiving at least one ranging frame; and the number of the first and second groups,
at least one ranging frame is transmitted.
7. A ranging apparatus, comprising:
a second receiving module, configured to receive at least one ranging frame; and the number of the first and second groups,
and a second sending module, configured to send at least one ranging frame.
8. A ranging apparatus, comprising:
a third receiving module, configured to receive at least one ranging frame; and the number of the first and second groups,
and a third sending module, configured to send at least one ranging frame.
9. A second apparatus, characterized in that it comprises:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: performing the ranging method of claim 5.
10. A computer-readable storage medium for storing computer instructions which, when executed on a computer, cause the computer to perform the ranging method of claim 5.
11. A third apparatus, characterized in that it comprises:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more programs configured to: performing the ranging method of claim 6.
12. A computer-readable storage medium for storing computer instructions which, when executed on a computer, cause the computer to perform the ranging method of claim 6.
CN202011183778.2A 2020-10-29 2020-10-29 Ranging method, ranging device, storage medium and equipment Pending CN114509748A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202011183778.2A CN114509748A (en) 2020-10-29 2020-10-29 Ranging method, ranging device, storage medium and equipment
PCT/CN2021/126964 WO2022089519A1 (en) 2020-10-29 2021-10-28 Ranging method and apparatus, storage medium and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011183778.2A CN114509748A (en) 2020-10-29 2020-10-29 Ranging method, ranging device, storage medium and equipment

Publications (1)

Publication Number Publication Date
CN114509748A true CN114509748A (en) 2022-05-17

Family

ID=81381968

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011183778.2A Pending CN114509748A (en) 2020-10-29 2020-10-29 Ranging method, ranging device, storage medium and equipment

Country Status (2)

Country Link
CN (1) CN114509748A (en)
WO (1) WO2022089519A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115865377A (en) * 2023-02-16 2023-03-28 长沙驰芯半导体科技有限公司 Time slice-based ultra-wideband ranging scheduling method and system
WO2024045834A1 (en) * 2022-08-31 2024-03-07 华为技术有限公司 Method for transmitting ranging signal in uwb and related device

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9366748B2 (en) * 2013-06-12 2016-06-14 Qualcomm Incorporated Position location system architecture: peer to peer measurement mode
US10342013B2 (en) * 2015-04-20 2019-07-02 Apple Inc. Neighbor awareness networking ranging
CN107948920B (en) * 2017-12-27 2020-03-17 合肥工业大学 Underground UWB (ultra wide band) multi-base-station positioning area judgment method based on ADS-TWR (automatic dependent surveillance-time-frequency radar)
CN109444866A (en) * 2018-11-15 2019-03-08 荆门博谦信息科技有限公司 Distance measuring method and user terminal
CN111372185A (en) * 2018-12-25 2020-07-03 深圳市优必选科技有限公司 Wireless positioning method and device
CN112637948B (en) * 2019-10-09 2023-04-14 深圳市优必选科技股份有限公司 Positioning method, system, positioning label and base station
CN110972063B (en) * 2019-10-25 2020-12-11 珠海格力电器股份有限公司 Distance measurement method, device and system and readable medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024045834A1 (en) * 2022-08-31 2024-03-07 华为技术有限公司 Method for transmitting ranging signal in uwb and related device
CN115865377A (en) * 2023-02-16 2023-03-28 长沙驰芯半导体科技有限公司 Time slice-based ultra-wideband ranging scheduling method and system

Also Published As

Publication number Publication date
WO2022089519A1 (en) 2022-05-05

Similar Documents

Publication Publication Date Title
EP3745768B1 (en) Resource selection method and terminal device
TWI619397B (en) Methods and systems for a ranging protocol
CN104756418B (en) It is embedded in new wave-carring type (NCT) information in synchronizing signal
EP3358892A1 (en) User equipment and synchronization method
US10638341B2 (en) Wireless environment information collection system and method
US8831520B2 (en) Information sharing method in cognitive radio communication, cognitive radio communication device, and cognitive radio communication system
US20150382217A1 (en) Radio frequency data collection
JP6522742B2 (en) Wideband ranging in cellular using unlicensed radio frequency spectrum band
CN114509748A (en) Ranging method, ranging device, storage medium and equipment
EP2946606A1 (en) Discovery signal in cluster-based small cell
US20140317406A1 (en) Communication between network nodes that are not directly connected
US20200177349A1 (en) Electronic device and user equipment in wireless communication system and wireless communication method
US20150143122A1 (en) Methods and apparatus for private service identifiers in neighborhood aware networks
CN109041105B (en) Sending method of adjacent cell information, and processing method and device of adjacent cell information
US20150050954A1 (en) Terminal device, mobile management device, communication system, and communication method
CN111971990B (en) Measuring method and device
US20160109554A1 (en) ADAPTIVE OPTIMIZATION OF TIME OF FLIGHT (ToF) EXCHANGE
EP3678416A1 (en) Carrier switching method on unlicensed spectrum, base station, and terminal device
WO2021051364A1 (en) Communication method, apparatus and device
US9571973B1 (en) Determining distances
Shi et al. Enabling cross-technology communication from LoRa to ZigBee via payload encoding in sub-1 GHz bands
CN112399449B (en) Base station opening method and device
US10823829B2 (en) Determining distances
Sulyman et al. Experimental data on connecting proprietary IoT systems to cellular networks
KR101415946B1 (en) Method and system for measuring wireless communication network quality

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination