This class provides description of ITS GeoNetworking protocol layer.
More...
#include <geonetworking_layer.hh>
|
| geonetworking_layer () |
|
| geonetworking_layer (const std::string &p_type, const std::string ¶m) |
|
virtual | ~geonetworking_layer () |
|
void | sendMsg (const LibItsGeoNetworking__TestSystem::GeoNetworkingReq &p_gn_req, Params &p_param) |
| Send GeoNetworking message to the lower layers. More...
|
|
virtual void | send_data (OCTETSTRING &data, Params ¶ms) |
| Send bytes formated data to the lower layers. More...
|
|
virtual void | receive_data (OCTETSTRING &data, Params &info) |
| Receive bytes formated data from the lower layers. More...
|
|
virtual OCTETSTRING | trigger_ac_event (OCTETSTRING &data, Params ¶ms) |
|
const LibItsGeoNetworking__TypesAndValues::LongPosVector * | get_lpv (const LibItsGeoNetworking__TypesAndValues::GN__Address &p_gn_address) |
|
void | start_beaconing () |
|
void | start_beaconing (const LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu &p_beacon) |
|
void | stop_beaconing () |
|
void | start_pass_beaconing (const LibItsGeoNetworking__TypesAndValues::BeaconHeader &p_beacon) |
|
void | stop_pass_beaconing () |
|
int | enable_secured_mode (const std::string &p_certificate_id, const boolean p_enforce_security=false) |
|
int | disable_secured_mode () |
|
| t_layer () |
| The list of the upper ports. More...
|
|
| t_layer (const std::string &p_type) |
| Specialized constructor Create a new instance of the layer class with its type description. More...
|
|
void | add_upper_port (LibItsGeoNetworking__TestSystem::GeoNetworkingPort *p_port) |
| Add a new upper port layer. More...
|
|
void | remove_upper_port (LibItsGeoNetworking__TestSystem::GeoNetworkingPort *) |
| Remove the specified upper layer port protocol from the list of the upper layers. More...
|
|
| layer () |
| Type description, it indicates the protocol type (e.g. CAM, DENM, GN, ETH, PCAP...) More...
|
|
| layer (const std::string &p_type) |
| Specialized constructor Create a new instance of the layer class with its type description. More...
|
|
virtual | ~layer () |
| Default destructor. More...
|
|
void | delete_layer () |
| Delete this layer. More...
|
|
void | add_upper_layer (layer *p_layer) |
| Add a new layer in the list of the upper layer. More...
|
|
void | remove_upper_layer (layer *p_layer) |
| Remove the specified upper layer protocol from the list of the upper layer. More...
|
|
const std::string & | to_string () const |
| Remove the specified upper layer protocol from the list of the upper layer. More...
|
|
|
void | fill_beacon (const OCTETSTRING &p_ll_address, const INTEGER p_station_type=5, const INTEGER p_country=0, const INTEGER type_of_address=1) |
| Initialize a beacon object for a stand alone beaconing This object could be replaced in case of start_beaconing call from the Adapter Control Port. More...
|
|
void | fill_gbc_packet (const OCTETSTRING &p_ll_address, const INTEGER &p_geoAreaPosLatitude, const INTEGER &p_geoAreaPosLongitude, const INTEGER &p_distanceA, const INTEGER &p_distanceB, const INTEGER &p_angle) |
| Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent. More...
|
|
void | fill_shb_packet (const OCTETSTRING &p_ll_address) |
| Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent. More...
|
|
void | fill_tsb_packet (const OCTETSTRING &p_ll_address, const int p_hop_number=3, const int p_max_hop_limit=5) |
| Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent. More...
|
|
void | fill_ls_reply (const OCTETSTRING &p_ll_address) |
| Initialize an LS_REPLY GeoNetworking packet to reply to an LS_REQUEST This object shall be updated before to be sent. More...
|
|
void | send_beacon () |
|
int | build_geonetworking_pdu (OCTETSTRING &data, Params ¶ms) |
|
int | build_secured_pdu (OCTETSTRING &data, Params ¶ms) |
|
int | decode_basic_header (const OCTETSTRING &p_data, LibItsGeoNetworking__TypesAndValues::BasicHeader &p_basic_header) |
|
int | setup_secured_mode () |
|
This class provides description of ITS GeoNetworking protocol layer.
◆ geonetworking_layer() [1/2]
geonetworking_layer::geonetworking_layer |
( |
| ) |
|
|
inlineexplicit |
◆ geonetworking_layer() [2/2]
geonetworking_layer::geonetworking_layer |
( |
const std::string & |
p_type, |
|
|
const std::string & |
param |
|
) |
| |
◆ ~geonetworking_layer()
geonetworking_layer::~geonetworking_layer |
( |
| ) |
|
|
virtual |
◆ build_geonetworking_pdu()
int geonetworking_layer::build_geonetworking_pdu |
( |
OCTETSTRING & |
data, |
|
|
Params & |
params |
|
) |
| |
|
private |
◆ build_secured_pdu()
int geonetworking_layer::build_secured_pdu |
( |
OCTETSTRING & |
data, |
|
|
Params & |
params |
|
) |
| |
|
private |
◆ decode_basic_header()
int geonetworking_layer::decode_basic_header |
( |
const OCTETSTRING & |
p_data, |
|
|
LibItsGeoNetworking__TypesAndValues::BasicHeader & |
p_basic_header |
|
) |
| |
|
private |
◆ disable_secured_mode()
int geonetworking_layer::disable_secured_mode |
( |
| ) |
|
◆ enable_secured_mode()
int geonetworking_layer::enable_secured_mode |
( |
const std::string & |
p_certificate_id, |
|
|
const boolean |
p_enforce_security = false |
|
) |
| |
◆ fill_beacon()
void geonetworking_layer::fill_beacon |
( |
const OCTETSTRING & |
p_ll_address, |
|
|
const INTEGER |
p_station_type = 5 , |
|
|
const INTEGER |
p_country = 0 , |
|
|
const INTEGER |
type_of_address = 1 |
|
) |
| |
|
private |
Initialize a beacon object for a stand alone beaconing This object could be replaced in case of start_beaconing call from the Adapter Control Port.
- Parameters
-
[in] | p_latitude | |
[in] | p_longitude | |
[in] | p_address | |
◆ fill_gbc_packet()
void geonetworking_layer::fill_gbc_packet |
( |
const OCTETSTRING & |
p_ll_address, |
|
|
const INTEGER & |
p_geoAreaPosLatitude, |
|
|
const INTEGER & |
p_geoAreaPosLongitude, |
|
|
const INTEGER & |
p_distanceA, |
|
|
const INTEGER & |
p_distanceB, |
|
|
const INTEGER & |
p_angle |
|
) |
| |
|
private |
Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent.
- Parameters
-
[in] | p_latitude | |
[in] | p_longitude | |
[in] | p_address | |
◆ fill_ls_reply()
void geonetworking_layer::fill_ls_reply |
( |
const OCTETSTRING & |
p_ll_address | ) |
|
|
private |
Initialize an LS_REPLY GeoNetworking packet to reply to an LS_REQUEST This object shall be updated before to be sent.
- Parameters
-
[in] | p_latitude | |
[in] | p_longitude | |
[in] | p_address | |
◆ fill_shb_packet()
void geonetworking_layer::fill_shb_packet |
( |
const OCTETSTRING & |
p_ll_address | ) |
|
|
private |
Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent.
- Parameters
-
[in] | p_latitude | |
[in] | p_longitude | |
[in] | p_address | |
◆ fill_tsb_packet()
void geonetworking_layer::fill_tsb_packet |
( |
const OCTETSTRING & |
p_ll_address, |
|
|
const int |
p_hop_number = 3 , |
|
|
const int |
p_max_hop_limit = 5 |
|
) |
| |
|
private |
Initialize a GeoNetworking packet to send GeoNetworking Facility messages This object shall be updated before to be sent.
- Parameters
-
[in] | p_latitude | |
[in] | p_longitude | |
[in] | p_address | |
[in] | p_hop_number | |
[in] | p_max_hop_number | |
◆ get_lpv()
const LongPosVector * geonetworking_layer::get_lpv |
( |
const LibItsGeoNetworking__TypesAndValues::GN__Address & |
p_gn_address | ) |
|
◆ receive_data()
void geonetworking_layer::receive_data |
( |
OCTETSTRING & |
data, |
|
|
Params & |
params |
|
) |
| |
|
virtual |
Receive bytes formated data from the lower layers.
- Parameters
-
[in] | p_data | The bytes formated data received |
[in] | p_params | Some lower layers parameters values when data was received |
Reimplemented from layer.
◆ send_beacon()
void geonetworking_layer::send_beacon |
( |
| ) |
|
|
private |
◆ send_data()
void geonetworking_layer::send_data |
( |
OCTETSTRING & |
data, |
|
|
Params & |
params |
|
) |
| |
|
virtual |
Send bytes formated data to the lower layers.
- Parameters
-
[in] | p_data | The data to be sent |
[in] | p_params | Some parameters to overwrite default value of the lower layers parameters |
Reimplemented from layer.
◆ sendMsg()
void geonetworking_layer::sendMsg |
( |
const LibItsGeoNetworking__TestSystem::GeoNetworkingReq & |
p_gn_req, |
|
|
Params & |
p_param |
|
) |
| |
Send GeoNetworking message to the lower layers.
- Parameters
-
[in] | p_gn_req | The GeoNetworking message to be sent |
[in] | p_params | Some parameters to overwrite default value of the lower layers parameters |
◆ setup_secured_mode()
int geonetworking_layer::setup_secured_mode |
( |
| ) |
|
|
private |
◆ start_beaconing() [1/2]
void geonetworking_layer::start_beaconing |
( |
| ) |
|
◆ start_beaconing() [2/2]
void geonetworking_layer::start_beaconing |
( |
const LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu & |
p_beacon | ) |
|
◆ start_pass_beaconing()
void geonetworking_layer::start_pass_beaconing |
( |
const LibItsGeoNetworking__TypesAndValues::BeaconHeader & |
p_beacon | ) |
|
◆ stop_beaconing()
void geonetworking_layer::stop_beaconing |
( |
| ) |
|
◆ stop_pass_beaconing()
void geonetworking_layer::stop_pass_beaconing |
( |
| ) |
|
◆ timer_irq_sigalrm_handler()
void geonetworking_layer::timer_irq_sigalrm_handler |
( |
int |
p_signal, |
|
|
siginfo_t * |
p_signal_info, |
|
|
void * |
p_uc |
|
) |
| |
|
staticprivate |
◆ trigger_ac_event()
OCTETSTRING geonetworking_layer::trigger_ac_event |
( |
OCTETSTRING & |
data, |
|
|
Params & |
params |
|
) |
| |
|
virtual |
◆ _beacon
LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu* geonetworking_layer::_beacon |
|
private |
Data structure used for beaconing
◆ _codec
◆ _device_mode
bool geonetworking_layer::_device_mode |
|
private |
◆ _enable_security_checks
bool geonetworking_layer::_enable_security_checks |
|
private |
◆ _encrypted_mode
bool geonetworking_layer::_encrypted_mode |
|
private |
◆ _freq_nanosecs
long long geonetworking_layer::_freq_nanosecs |
|
private |
◆ _gbc_packet
LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu* geonetworking_layer::_gbc_packet |
|
private |
Data structure used to encapsulate upper layer PDU into a GeoNetworking packet as a Geobroadcast
◆ _its
struct itimerspec geonetworking_layer::_its |
|
private |
◆ _latitude
int geonetworking_layer::_latitude |
|
private |
◆ _location_table
Location table, used when device_mode is set
◆ _longitude
int geonetworking_layer::_longitude |
|
private |
◆ _ls_reply
LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu* geonetworking_layer::_ls_reply |
|
private |
Data structure used to reply to an incoming LS_REQUEST
◆ _mask
sigset_t geonetworking_layer::_mask |
|
private |
◆ _params
Params geonetworking_layer::_params |
|
private |
◆ _pass_beacon_table
◆ _sa
struct sigaction geonetworking_layer::_sa |
|
private |
◆ _secured_mode
bool geonetworking_layer::_secured_mode |
|
private |
◆ _sendData
std::mutex geonetworking_layer::_sendData |
|
private |
◆ _sequence_number
unsigned int geonetworking_layer::_sequence_number |
|
private |
◆ _sev
struct sigevent geonetworking_layer::_sev |
|
private |
◆ _shb_packet
LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu* geonetworking_layer::_shb_packet |
|
private |
Data structure used to encapsulate upper layer PDU into a GeoNetworking packet as a SHB
◆ _signal_id
const int geonetworking_layer::_signal_id = SIGTERM |
|
private |
◆ _timerid
timer_t geonetworking_layer::_timerid |
|
private |
◆ _tsb_packet
LibItsGeoNetworking__TypesAndValues::GeoNetworkingPdu* geonetworking_layer::_tsb_packet |
|
private |
Data structure used to encapsulate upper layer PDU into a GeoNetworking packet as a TSB
The documentation for this class was generated from the following files: