#include <uwranging_tdoa.h>
Class that represents a UwRangingTDOA Node.
Definition at line 69 of file uwranging_tdoa.h.
◆ UwRangingTDOA()
UwRangingTDOA::UwRangingTDOA |
( |
| ) |
|
◆ ~UwRangingTDOA()
virtual UwRangingTDOA::~UwRangingTDOA |
( |
| ) |
|
|
virtualdefault |
◆ calcOptEntries()
int UwRangingTDOA::calcOptEntries |
( |
std::vector< int > * |
sorted_entries = nullptr | ) |
const |
|
protectedvirtual |
Compute the optimal number of entries for the ranging message.
- Parameters
-
std::vector<int> | Vector of entries to sort. |
- Returns
- int Number of optimal entries.
Definition at line 300 of file uwranging_tdoa.cpp.
◆ command()
int UwRangingTDOA::command |
( |
int |
argc, |
|
|
const char *const * |
argv |
|
) |
| |
|
overridevirtual |
TCL command interpreter.
It implements the following OTcl methods:
- Parameters
-
argc | Number of arguments in argv. |
argv | Array of strings which are the command parameters |
- Returns
- TCL_OK or TCL_ERROR
Definition at line 615 of file uwranging_tdoa.cpp.
◆ entryWeight()
double UwRangingTDOA::entryWeight |
( |
int |
entry, |
|
|
int |
pkt_size, |
|
|
int |
mode |
|
) |
| const |
|
protectedvirtual |
Compute the weight of the entry given the packet size in bits.
- Parameters
-
int | n-th entries. |
int | size of the n-th entries in bit |
int | mode to use to compute the optimal number of entries |
Definition at line 264 of file uwranging_tdoa.cpp.
◆ isValid() [1/2]
bool UwRangingTDOA::isValid |
( |
const tdoa_entry & |
entry | ) |
const |
|
protectedvirtual |
Check if all elements of a tdoa entry are not negative.
- Parameters
-
- Returns
- true if valid, false otherwise
Definition at line 609 of file uwranging_tdoa.cpp.
◆ isValid() [2/2]
bool UwRangingTDOA::isValid |
( |
double |
value | ) |
const |
|
protectedvirtual |
Check if value is not negative.
- Parameters
-
- Returns
- true if valid, false otherwise
Definition at line 603 of file uwranging_tdoa.cpp.
◆ rangeRX()
void UwRangingTDOA::rangeRX |
( |
const Packet * |
p | ) |
|
|
protectedvirtual |
◆ rangeTX()
void UwRangingTDOA::rangeTX |
( |
| ) |
|
|
protectedvirtual |
◆ recv() [1/2]
void UwRangingTDOA::recv |
( |
Packet * |
p | ) |
|
|
overridevirtual |
Performs the reception of packets from upper and lower layers.
- Parameters
-
Packet* | Pointer to the packet will be received. |
Definition at line 166 of file uwranging_tdoa.cpp.
◆ recv() [2/2]
void UwRangingTDOA::recv |
( |
Packet * |
p, |
|
|
Handler * |
h |
|
) |
| |
|
overridevirtual |
Performs the reception of packets from upper and lower layers.
- Parameters
-
Packet* | Pointer to the packet will be received. |
Handler* | Handler. |
Definition at line 181 of file uwranging_tdoa.cpp.
◆ recvSyncClMsg()
int UwRangingTDOA::recvSyncClMsg |
( |
ClMessage * |
m | ) |
|
|
overridevirtual |
◆ start()
void UwRangingTDOA::start |
( |
| ) |
|
|
virtual |
◆ stop()
void UwRangingTDOA::stop |
( |
| ) |
|
|
virtual |
◆ throttleTX()
void UwRangingTDOA::throttleTX |
( |
| ) |
|
|
protectedvirtual |
◆ updateHoldoverTime()
void UwRangingTDOA::updateHoldoverTime |
( |
Packet * |
p, |
|
|
double |
tx_duration |
|
) |
| |
|
protectedvirtual |
Update the holdover time with the actual time of transmission.
- Parameters
-
Packet* | Pointer to the packet received. |
double | Transmission duration computed by the physical layer. |
Definition at line 453 of file uwranging_tdoa.cpp.
◆ UwRangeTimer
◆ ber
std::vector<double> UwRangingTDOA::ber |
|
protected |
◆ debug_tdoa
int UwRangingTDOA::debug_tdoa |
|
protected |
◆ delay_start
double UwRangingTDOA::delay_start |
|
protected |
◆ dist_num
int UwRangingTDOA::dist_num |
|
protected |
◆ entries_mat
std::vector<std::vector<std::vector<tdoa_entry> > > UwRangingTDOA::entries_mat |
|
protected |
◆ entries_timestamps
std::vector<double> UwRangingTDOA::entries_timestamps |
|
protected |
◆ entry_last_tx
std::vector<double> UwRangingTDOA::entry_last_tx |
|
protected |
Vector of the last (actual) TX times of each entry.
Definition at line 202 of file uwranging_tdoa.h.
◆ full_pkt_tx_dur
double UwRangingTDOA::full_pkt_tx_dur |
|
protected |
◆ last_ids
std::vector<int> UwRangingTDOA::last_ids |
|
protected |
◆ mac2phy_delay
double UwRangingTDOA::mac2phy_delay |
|
protected |
◆ max_age
double UwRangingTDOA::max_age |
|
protected |
◆ max_tt
double UwRangingTDOA::max_tt |
|
protected |
Floating numbers within this value won't be discarded by NNLS.
Max travel time between nodes in seconds.
Definition at line 189 of file uwranging_tdoa.h.
◆ n_nodes
int UwRangingTDOA::n_nodes |
|
protected |
◆ node_id
int UwRangingTDOA::node_id |
|
protected |
◆ packet_id
int UwRangingTDOA::packet_id |
|
protected |
id of the last ranging packet sent (= node_id + k*n_nodes)
Definition at line 175 of file uwranging_tdoa.h.
◆ phy_id
int UwRangingTDOA::phy_id |
|
protected |
◆ PKTIDMAX
const size_t UwRangingTDOA::PKTIDMAX = std::numeric_limits<uwrange_pkt_t>::max() |
|
protected |
Max number of ranging packets that can be saved.
Definition at line 206 of file uwranging_tdoa.h.
◆ poisson_traffic
int UwRangingTDOA::poisson_traffic |
|
protected |
If true the ranging packets are sent according to a poisson process with rate range_period.
Definition at line 179 of file uwranging_tdoa.h.
◆ queue_size
int UwRangingTDOA::queue_size |
|
protected |
Counts the packet sent to the MAC waiting to be transmitted.
Definition at line 186 of file uwranging_tdoa.h.
◆ range_bytes_sent
int UwRangingTDOA::range_bytes_sent |
|
protected |
◆ range_entries
int UwRangingTDOA::range_entries |
|
protected |
Number of entries per ranging packet, if <= 0 enable adaptive payload size.
Definition at line 178 of file uwranging_tdoa.h.
◆ range_period
double UwRangingTDOA::range_period |
|
protected |
◆ range_pkts_err
int UwRangingTDOA::range_pkts_err |
|
protected |
◆ range_pkts_recv
int UwRangingTDOA::range_pkts_recv |
|
protected |
◆ range_pkts_sent
int UwRangingTDOA::range_pkts_sent |
|
protected |
◆ saved_entries
int UwRangingTDOA::saved_entries |
|
protected |
Total number of entries not sent in the ranging packets.
Definition at line 184 of file uwranging_tdoa.h.
◆ scheduler_active
bool UwRangingTDOA::scheduler_active |
|
protected |
True if the ranging scheduler is been activated with Tcl "start" command.
Definition at line 172 of file uwranging_tdoa.h.
◆ send_timer
◆ soundspeed
double UwRangingTDOA::soundspeed |
|
protected |
◆ time_of_flights
std::vector<double> UwRangingTDOA::time_of_flights |
|
protected |
◆ times_mat
std::vector<std::vector<double> > UwRangingTDOA::times_mat |
|
protected |
◆ tof_map
std::vector<std::vector<int> > UwRangingTDOA::tof_map |
|
protected |
◆ tx_timestamp
Vector of the TX timestamp for each packet to be sent.
Definition at line 203 of file uwranging_tdoa.h.
The documentation for this class was generated from the following files: