ITS
|
#include <caBasicService.h>
Public Slots | |
void | execute () |
execute Slot used for the first loop. More... | |
void | checkToSendCAM () |
checkToSendCAM Slot used when there need to check if we need to send CAM. More... | |
Public Member Functions | |
caBasicService (GeoNet *geonet, FakeGPSProvider *paramGPS, ParameterConfiguration *paramConf, FakeApplicationProvider *paramAppli, FakeCANProvider *paramCAN) | |
caBasicService caBasicService constructor. More... | |
quint16 | T_GenCam_DCC () const |
T_GenCam_DCC T_GenCam_DCC getter. More... | |
quint16 | T_GenCam () const |
T_GenCam T_GenCam getter. More... | |
quint16 | N_GenCam () const |
N_GenCam N_GenCam getter. More... | |
quint16 | T_CheckGenCam () const |
T_CheckGenCam T_CheckCamm getter. More... | |
CAM_t | currentCAM () const |
currentCAM Current CAM getter. More... | |
CAM_t | previousCAM () const |
previousCAM Previous CAM getter More... | |
QTime | previousTime () const |
previousTime Time of the previous CAM getter. More... | |
QTime | lastLF () const |
lastLF Last time where a CAM had a LowFrequencyContainer. More... | |
quint64 | timestamp () const |
timestamp Current timestamp getter. More... | |
void | setT_GenCam_DCC (quint16 t) |
setT_GenCam_DCC Set the T_GenCam_DCC. More... | |
void | setT_GenCam (quint16 t) |
setT_GenCam Set the T_GenCam. More... | |
void | setN_GenCam (quint16 n) |
setN_GenCam Set the N_GenCam More... | |
void | setT_CheckGenCam (quint16 t) |
setT_CheckGenCam Set the T_CheckGenCam. More... | |
void | setCurrentCAM (CAM_t c) |
setCurrentCAM Set the current CAM. More... | |
void | setPreviousCAM (CAM_t c) |
setPreviousCAM Set the previous CAM. More... | |
void | setPreviousTime (QTime p) |
setPreviousTime Set the time where the previous CAM was sent. More... | |
void | setLastLF (QTime l) |
setLastLF Set the time where the last CAM had a LowFrequencyContainer. More... | |
bool | checkCamGeneration () |
checkCamGeneration Check if a CAM needs to be generated. More... | |
CAM_t | collectMandatoryData () |
collectMandatoryData Collect the CAM mandatory data. More... | |
bool | checkForOptionalContainers () |
checkForOptionalContainers Check if there need optional data. More... | |
void | checkAndCollectDataForOptionalContainers (CAM_t *cam) |
checkAndCollectDataForOptionalContainers Check and collect data for optional containers. More... | |
void | PassCamToNetworkAndTransportLayer (char *cam, int camLength) |
PassCamToNetworkAndTransportLayer Pass the encoded CAM to the N&T layer. More... | |
BasicContainer_t | collectMandatoryData_BasicContainer () |
collectMandatoryData_BasicContainer Collect mandatory data for the BasicContainer. More... | |
BasicVehicleContainerHighFrequency_t | collectMandatoryData_BasicVehicleContainerHighFrequency () |
collectMandatoryData_BasicVehicleContainerHighFrequency Collect mandatory data for the BasicVehicleContainerHighFrequency. More... | |
RSUContainerHighFrequency_t | collectMandatoryData_RSUContainerHighFrequency () |
collectMandatoryData_RSUContainerHighFrequency Collect mandatory data for the RSUContainerHighFrequency. More... | |
BasicVehicleContainerLowFrequency_t | collectOptionalData_BasicVehicleContainerLowFrequency () |
collectOptionalData_BasicVehicleContainerLowFrequency Collect optional data for the BasicVehicleContainerLowFrequency. More... | |
SpecialVehicleContainer_t | collectOptionalData_SpecialVehicleContainer (VehicleRole_t v) |
collectOptionalData_SpecialVehicleContainer Collect optional data for the SpecialVehicleContainer. More... | |
PublicTransportContainer_t | collectOptionalData_PublicTransportContainer () |
collectOptionalData_PublicTransportContainer Collect optional data for the PublicTransportContainer. More... | |
SpecialTransportContainer_t | collectOptionalData_SpecialTransportContainer () |
collectOptionalData_SpecialTransportContainer Collect optional data for the SpecialTransportContainer. More... | |
DangerousGoodsContainer_t | collectOptionalData_DangerousGoodsContainer () |
collectOptionalData_DangerousGoodsContainer Collect optional data for the DangerousGoodsContainer. More... | |
RoadWorksContainerBasic_t | collectOptionalData_RoadWorksContainerbasic () |
collectOptionalData_RoadWorksContainerbasic Collect optional data for the RoadWorksContainerBasic. More... | |
RescueContainer_t | collectOptionalData_RescueContainer () |
collectOptionalData_RescueContainer Collect optional data for the RescueContainer. More... | |
EmergencyContainer_t | collectOptionalData_EmergencyContainer () |
collectOptionalData_EmergencyContainer Collect optional data for the EmergencyContainer. More... | |
SafetyCarContainer_t | collectOptionalData_SafetyCarContainer () |
collectOptionalData_SafetyCarContainer Collect optional data for the SafetyCarContainer. More... | |
bool | needSpecialVehicleContainer (VehicleRole_t role) |
needSpecialVehicleContainer Check if there need SpecialVehicleContainer. More... | |
PathHistory_t | getPathHistory () |
getPathHistory PathHistory getter. More... | |
PathPoint_t | getPathPoint (int i) |
getPathPoint PathPoint getter. More... | |
void | checkPathPoint (int i) |
checkPathPoint Check a PathPoint. More... | |
void | utInitialize () |
utInitialize Initialize the CA Basic Service. More... | |
Private Member Functions | |
void | reset () |
Private Attributes | |
quint16 | m_T_GenCam_DCC |
quint16 | m_T_GenCam |
quint16 | m_N_GenCam |
quint16 | m_T_CheckGenCam |
CAM_t | m_currentCAM |
CAM_t | m_previousCAM |
QUdpSocket * | udpSocket |
QTime | m_previousTime |
QTime | m_lastLF |
ItsPduHeader_t | header |
QElapsedTimer | m_elapsed |
bool | m_quick |
int | m_generedCam |
QTimer | m_timer |
FakeGPSProvider * | m_paramGPS |
GeoNet * | m_geonet |
ParameterConfiguration * | m_paramConf |
FakeApplicationProvider * | m_paramAppli |
FakeCANProvider * | m_paramCAN |
QList< ReferencePosition_t > | m_listReferencePosition |
QList< GenerationDeltaTime_t > | m_listGenerationDeltaTime |
PathPoint_t | m_listPathPoint [MAX_REFERENCEPOSITION] |
Definition at line 33 of file caBasicService.h.
caBasicService::caBasicService | ( | GeoNet * | geonet, |
FakeGPSProvider * | paramGPS, | ||
ParameterConfiguration * | paramConf, | ||
FakeApplicationProvider * | paramAppli, | ||
FakeCANProvider * | paramCAN | ||
) |
caBasicService caBasicService constructor.
geonet | The GeoNetworking layer. |
paramGPS | The GPS. |
paramConf | The global configuration. |
paramAppli | The application configuration. |
paramCAN | The CAN bus. |
Definition at line 10 of file caBasicService.cpp.
References checkToSendCAM(), FakeApplicationProvider::data(), DEFAULT_N_GEN_CAM, firstCAM, header, m_geonet, m_paramAppli, m_paramCAN, m_paramConf, m_paramGPS, m_T_GenCam, m_T_GenCam_DCC, ItsPduHeader::messageID, messageID_cam, ItsPduHeader::protocolVersion, protocolVersion_currentVersion, setN_GenCam(), setT_CheckGenCam(), ItsPduHeader::stationID, ParameterApplication::stationID(), T_GenCamMax, and udpSocket.
void caBasicService::checkAndCollectDataForOptionalContainers | ( | CAM_t * | cam | ) |
checkAndCollectDataForOptionalContainers Check and collect data for optional containers.
cam | The CAM to fill. |
Definition at line 377 of file caBasicService.cpp.
References CamParameters::basicContainer, LowFrequencyContainer::LowFrequencyContainer_u::basicVehicleContainerLowFrequency, CAM::cam, CoopAwareness::camParameters, LowFrequencyContainer::choice, collectOptionalData_BasicVehicleContainerLowFrequency(), collectOptionalData_SpecialVehicleContainer(), CamParameters::lowFrequencyContainer, LowFrequencyContainer_PR_basicVehicleContainerLowFrequency, needSpecialVehicleContainer(), LowFrequencyContainer::present, CamParameters::specialVehicleContainer, BasicContainer::stationType, StationType_bus, StationType_cyclist, StationType_heavyTruck, StationType_lightTruck, StationType_moped, StationType_motorcycle, StationType_passengerCar, StationType_pedestrian, StationType_roadSideUnit, StationType_specialVehicles, StationType_trailer, StationType_tram, and BasicVehicleContainerLowFrequency::vehicleRole.
Referenced by checkToSendCAM().
bool caBasicService::checkCamGeneration | ( | ) |
checkCamGeneration Check if a CAM needs to be generated.
Definition at line 153 of file caBasicService.cpp.
References CamParameters::basicContainer, HighFrequencyContainer::HighFrequencyContainer_u::basicVehicleContainerHighFrequency, CAM::cam, CoopAwareness::camParameters, HighFrequencyContainer::choice, FakeGPSProvider::data(), dist(), firstCAM, BasicVehicleContainerHighFrequency::heading, ParameterGPS::heading(), Heading::headingValue, CamParameters::highFrequencyContainer, ReferencePosition::latitude, ReferencePosition::longitude, m_elapsed, m_generedCam, m_N_GenCam, m_paramGPS, m_quick, m_T_GenCam, MIN, previousCAM(), BasicContainer::referencePosition, ParameterGPS::referencePosition(), reset(), ParameterGPS::speed(), Speed::speedValue, T_GenCam_DCC(), T_GenCamMax, and T_GenCamMin.
Referenced by checkToSendCAM().
bool caBasicService::checkForOptionalContainers | ( | ) |
checkForOptionalContainers Check if there need optional data.
Definition at line 365 of file caBasicService.cpp.
References FakeApplicationProvider::data(), firstCAM, lastLF(), m_paramAppli, ParameterApplication::stationType(), and StationType_roadSideUnit.
Referenced by checkToSendCAM().
void caBasicService::checkPathPoint | ( | int | i | ) |
checkPathPoint Check a PathPoint.
i | The i-th PathPoint to check. |
Definition at line 649 of file caBasicService.cpp.
References DeltaReferencePosition::deltaAltitude, DeltaAltitude_unavailable, DeltaReferencePosition::deltaLatitude, DeltaLatitude_unavailable, DeltaReferencePosition::deltaLongitude, DeltaLongitude_unavailable, m_listPathPoint, and PathPoint::pathPosition.
Referenced by getPathHistory().
|
slot |
checkToSendCAM Slot used when there need to check if we need to send CAM.
Definition at line 62 of file caBasicService.cpp.
References asn_DEF_CAM, checkAndCollectDataForOptionalContainers(), checkCamGeneration(), checkForOptionalContainers(), collectMandatoryData(), cpy_CAM(), asn_enc_rval_s::encoded, asn_enc_rval_s::failed_type, firstCAM, m_elapsed, m_previousCAM, m_timer, MSG_LENGTH, asn_TYPE_descriptor_s::name, PassCamToNetworkAndTransportLayer(), setLastLF(), setPreviousTime(), T_GenCamMin, and uper_encode_to_buffer().
Referenced by caBasicService(), and execute().
CAM_t caBasicService::collectMandatoryData | ( | ) |
collectMandatoryData Collect the CAM mandatory data.
Definition at line 239 of file caBasicService.cpp.
References CamParameters::basicContainer, HighFrequencyContainer::HighFrequencyContainer_u::basicVehicleContainerHighFrequency, CAM::cam, CoopAwareness::camParameters, HighFrequencyContainer::choice, collectMandatoryData_BasicContainer(), collectMandatoryData_BasicVehicleContainerHighFrequency(), collectMandatoryData_RSUContainerHighFrequency(), FakeApplicationProvider::data(), firstCAM, CoopAwareness::generationDeltaTime, CAM::header, CamParameters::highFrequencyContainer, HighFrequencyContainer_PR_basicVehicleContainerHighFrequency, HighFrequencyContainer_PR_NOTHING, HighFrequencyContainer_PR_rsuContainerHighFrequency, CamParameters::lowFrequencyContainer, m_listGenerationDeltaTime, m_paramAppli, m_paramGPS, make_CAM(), make_HighFrequencyContainer(), MAX_REFERENCEPOSITION, HighFrequencyContainer::present, HighFrequencyContainer::HighFrequencyContainer_u::rsuContainerHighFrequency, CamParameters::specialVehicleContainer, ItsPduHeader::stationID, ParameterApplication::stationID(), BasicContainer::stationType, StationType_bus, StationType_cyclist, StationType_heavyTruck, StationType_lightTruck, StationType_moped, StationType_motorcycle, StationType_passengerCar, StationType_pedestrian, StationType_roadSideUnit, StationType_specialVehicles, StationType_trailer, StationType_tram, and FakeGPSProvider::timestamp().
Referenced by checkToSendCAM().
BasicContainer_t caBasicService::collectMandatoryData_BasicContainer | ( | ) |
collectMandatoryData_BasicContainer Collect mandatory data for the BasicContainer.
Definition at line 286 of file caBasicService.cpp.
References FakeApplicationProvider::data(), FakeGPSProvider::data(), firstCAM, m_listReferencePosition, m_paramAppli, m_paramGPS, make_BasicContainer(), MAX_REFERENCEPOSITION, BasicContainer::referencePosition, ParameterGPS::referencePosition(), BasicContainer::stationType, and ParameterApplication::stationType().
Referenced by collectMandatoryData().
BasicVehicleContainerHighFrequency_t caBasicService::collectMandatoryData_BasicVehicleContainerHighFrequency | ( | ) |
collectMandatoryData_BasicVehicleContainerHighFrequency Collect mandatory data for the BasicVehicleContainerHighFrequency.
Definition at line 305 of file caBasicService.cpp.
References BasicVehicleContainerHighFrequency::accelerationControl, ParameterCAN::accelerationControl(), BasicVehicleContainerHighFrequency::cenDsrcTollingZone, cpy_AccelerationControl(), cpy_LateralAcceleration(), cpy_VerticalAcceleration(), BasicVehicleContainerHighFrequency::curvature, ParameterCAN::curvature(), BasicVehicleContainerHighFrequency::curvatureCalculationMode, ParameterCAN::curvatureCalculationMode(), FakeCANProvider::data(), FakeGPSProvider::data(), BasicVehicleContainerHighFrequency::driveDirection, ParameterCAN::driveDirection(), BasicVehicleContainerHighFrequency::heading, ParameterGPS::heading(), BasicVehicleContainerHighFrequency::lanePosition, BasicVehicleContainerHighFrequency::lateralAcceleration, ParameterCAN::lateralAcceleration(), BasicVehicleContainerHighFrequency::longitudinalAcceleration, ParameterCAN::longitudinalAcceleration(), m_paramCAN, m_paramConf, m_paramGPS, make_BasicVehicleContainerHighFrequency(), BasicVehicleContainerHighFrequency::performanceClass, BasicVehicleContainerHighFrequency::speed, ParameterGPS::speed(), BasicVehicleContainerHighFrequency::steeringWheelAngle, ParameterCAN::steeringWheelAngle(), BasicVehicleContainerHighFrequency::vehicleLength, ParameterConfiguration::vehicleLength(), BasicVehicleContainerHighFrequency::vehicleWidth, ParameterConfiguration::vehicleWidth(), BasicVehicleContainerHighFrequency::verticalAcceleration, ParameterCAN::verticalAcceleration(), BasicVehicleContainerHighFrequency::yawRate, and ParameterCAN::yawRate().
Referenced by collectMandatoryData().
RSUContainerHighFrequency_t caBasicService::collectMandatoryData_RSUContainerHighFrequency | ( | ) |
collectMandatoryData_RSUContainerHighFrequency Collect mandatory data for the RSUContainerHighFrequency.
Definition at line 353 of file caBasicService.cpp.
References FakeApplicationProvider::data(), m_paramAppli, ParameterApplication::protectedCommunicationZones(), and RSUContainerHighFrequency::protectedCommunicationZonesRSU.
Referenced by collectMandatoryData().
BasicVehicleContainerLowFrequency_t caBasicService::collectOptionalData_BasicVehicleContainerLowFrequency | ( | ) |
collectOptionalData_BasicVehicleContainerLowFrequency Collect optional data for the BasicVehicleContainerLowFrequency.
Definition at line 448 of file caBasicService.cpp.
References FakeCANProvider::data(), FakeApplicationProvider::data(), BasicVehicleContainerLowFrequency::exteriorLights, ParameterCAN::exteriorLights(), getPathHistory(), m_paramAppli, m_paramCAN, make_BasicVehicleContainerLowFrequency(), BasicVehicleContainerLowFrequency::pathHistory, BasicVehicleContainerLowFrequency::vehicleRole, and ParameterApplication::vehicleRole().
Referenced by checkAndCollectDataForOptionalContainers().
DangerousGoodsContainer_t caBasicService::collectOptionalData_DangerousGoodsContainer | ( | ) |
collectOptionalData_DangerousGoodsContainer Collect optional data for the DangerousGoodsContainer.
Definition at line 528 of file caBasicService.cpp.
References DangerousGoodsContainer::dangerousGoodsBasic, ParameterApplication::dangerousGoodsBasic(), FakeApplicationProvider::data(), m_paramAppli, and make_DangerousGoodsContainer().
Referenced by collectOptionalData_SpecialVehicleContainer().
EmergencyContainer_t caBasicService::collectOptionalData_EmergencyContainer | ( | ) |
collectOptionalData_EmergencyContainer Collect optional data for the EmergencyContainer.
Definition at line 563 of file caBasicService.cpp.
References ParameterApplication::causeCodeEmergency(), FakeCANProvider::data(), FakeApplicationProvider::data(), EmergencyContainer::emergencyPriority, ParameterApplication::emergencyPriority(), EmergencyContainer::incidentIndication, EmergencyContainer::lightBarSirenInUse, ParameterCAN::lightBarSirenInUse(), m_paramAppli, m_paramCAN, and make_EmergencyContainer().
Referenced by collectOptionalData_SpecialVehicleContainer().
PublicTransportContainer_t caBasicService::collectOptionalData_PublicTransportContainer | ( | ) |
collectOptionalData_PublicTransportContainer Collect optional data for the PublicTransportContainer.
Definition at line 503 of file caBasicService.cpp.
References FakeApplicationProvider::data(), PublicTransportContainer::embarkationStatus, ParameterApplication::embarkationStatus(), m_paramAppli, make_PublicTransportContainer(), PublicTransportContainer::ptActivation, and ParameterApplication::ptActivation().
Referenced by collectOptionalData_SpecialVehicleContainer().
RescueContainer_t caBasicService::collectOptionalData_RescueContainer | ( | ) |
collectOptionalData_RescueContainer Collect optional data for the RescueContainer.
Definition at line 553 of file caBasicService.cpp.
References FakeCANProvider::data(), RescueContainer::lightBarSirenInUse, ParameterCAN::lightBarSirenInUse(), m_paramCAN, and make_RescueContainer().
Referenced by collectOptionalData_SpecialVehicleContainer().
RoadWorksContainerBasic_t caBasicService::collectOptionalData_RoadWorksContainerbasic | ( | ) |
collectOptionalData_RoadWorksContainerbasic Collect optional data for the RoadWorksContainerBasic.
Definition at line 538 of file caBasicService.cpp.
References RoadWorksContainerBasic::closedLanes, ParameterApplication::closedLanes(), FakeCANProvider::data(), FakeApplicationProvider::data(), RoadWorksContainerBasic::lightBarSirenInUse, ParameterCAN::lightBarSirenInUse(), m_paramAppli, m_paramCAN, make_RoadWorksContainerBasic(), RoadWorksContainerBasic::roadworksSubCauseCode, and ParameterApplication::roadworksSubCauseCode().
Referenced by collectOptionalData_SpecialVehicleContainer().
SafetyCarContainer_t caBasicService::collectOptionalData_SafetyCarContainer | ( | ) |
collectOptionalData_SafetyCarContainer Collect optional data for the SafetyCarContainer.
Definition at line 578 of file caBasicService.cpp.
References ParameterApplication::causeCodeSafety(), FakeCANProvider::data(), FakeApplicationProvider::data(), SafetyCarContainer::incidentIndication, SafetyCarContainer::lightBarSirenInUse, ParameterCAN::lightBarSirenInUse(), m_paramAppli, m_paramCAN, make_SafetyCarContainer(), SafetyCarContainer::speedLimit, ParameterApplication::speedLimit(), SafetyCarContainer::trafficRule, and ParameterApplication::trafficRule().
Referenced by collectOptionalData_SpecialVehicleContainer().
SpecialTransportContainer_t caBasicService::collectOptionalData_SpecialTransportContainer | ( | ) |
collectOptionalData_SpecialTransportContainer Collect optional data for the SpecialTransportContainer.
Definition at line 516 of file caBasicService.cpp.
References FakeCANProvider::data(), FakeApplicationProvider::data(), SpecialTransportContainer::lightBarSirenInUse, ParameterCAN::lightBarSirenInUse(), m_paramAppli, m_paramCAN, make_SpecialTransportContainer(), SpecialTransportContainer::specialTransportType, and ParameterApplication::specialTransportType().
Referenced by collectOptionalData_SpecialVehicleContainer().
SpecialVehicleContainer_t caBasicService::collectOptionalData_SpecialVehicleContainer | ( | VehicleRole_t | v | ) |
collectOptionalData_SpecialVehicleContainer Collect optional data for the SpecialVehicleContainer.
v | The vehicle role of the ITS-S. |
Definition at line 461 of file caBasicService.cpp.
References SpecialVehicleContainer::choice, collectOptionalData_DangerousGoodsContainer(), collectOptionalData_EmergencyContainer(), collectOptionalData_PublicTransportContainer(), collectOptionalData_RescueContainer(), collectOptionalData_RoadWorksContainerbasic(), collectOptionalData_SafetyCarContainer(), collectOptionalData_SpecialTransportContainer(), SpecialVehicleContainer::SpecialVehicleContainer_u::dangerousGoodsContainer, SpecialVehicleContainer::SpecialVehicleContainer_u::emergencyContainer, SpecialVehicleContainer::present, SpecialVehicleContainer::SpecialVehicleContainer_u::publicTransportContainer, SpecialVehicleContainer::SpecialVehicleContainer_u::rescueContainer, SpecialVehicleContainer::SpecialVehicleContainer_u::roadWorksContainerBasic, SpecialVehicleContainer::SpecialVehicleContainer_u::safetyCarContainer, SpecialVehicleContainer::SpecialVehicleContainer_u::specialTransportContainer, SpecialVehicleContainer_PR_dangerousGoodsContainer, SpecialVehicleContainer_PR_emergencyContainer, SpecialVehicleContainer_PR_publicTransportContainer, SpecialVehicleContainer_PR_rescueContainer, SpecialVehicleContainer_PR_roadWorksContainerBasic, SpecialVehicleContainer_PR_safetyCarContainer, SpecialVehicleContainer_PR_specialTransportContainer, VehicleRole_dangerousGoods, VehicleRole_emergency, VehicleRole_publicTransport, VehicleRole_rescue, VehicleRole_roadWork, VehicleRole_safetyCar, and VehicleRole_specialTransport.
Referenced by checkAndCollectDataForOptionalContainers().
|
inline |
currentCAM Current CAM getter.
Definition at line 73 of file caBasicService.h.
References m_currentCAM.
|
slot |
execute Slot used for the first loop.
caBasicService::execute General protocol operation
Definition at line 36 of file caBasicService.cpp.
References checkToSendCAM(), m_elapsed, m_quick, m_timer, and T_GenCamMin.
PathHistory_t caBasicService::getPathHistory | ( | ) |
getPathHistory PathHistory getter.
Definition at line 594 of file caBasicService.cpp.
References asn_sequence_add, checkPathPoint(), getPathPoint(), m_listPathPoint, and m_listReferencePosition.
Referenced by collectOptionalData_BasicVehicleContainerLowFrequency().
PathPoint_t caBasicService::getPathPoint | ( | int | i | ) |
getPathPoint PathPoint getter.
i | i-th point. |
Definition at line 614 of file caBasicService.cpp.
References ReferencePosition::altitude, Altitude::altitudeValue, CamParameters::basicContainer, CAM::cam, CoopAwareness::camParameters, DeltaReferencePosition::deltaAltitude, DeltaReferencePosition::deltaLatitude, DeltaReferencePosition::deltaLongitude, CoopAwareness::generationDeltaTime, ReferencePosition::latitude, ReferencePosition::longitude, m_listGenerationDeltaTime, m_listReferencePosition, PathPoint::pathDeltaTime, PathPoint::pathPosition, previousCAM(), and BasicContainer::referencePosition.
Referenced by getPathHistory().
|
inline |
lastLF Last time where a CAM had a LowFrequencyContainer.
Definition at line 88 of file caBasicService.h.
References m_lastLF.
Referenced by checkForOptionalContainers().
|
inline |
N_GenCam N_GenCam getter.
Definition at line 63 of file caBasicService.h.
References m_N_GenCam.
bool caBasicService::needSpecialVehicleContainer | ( | VehicleRole_t | role | ) |
needSpecialVehicleContainer Check if there need SpecialVehicleContainer.
role | The vehicle role. |
Definition at line 420 of file caBasicService.cpp.
References VehicleRole_agriculture, VehicleRole_commercial, VehicleRole_dangerousGoods, VehicleRole_default, VehicleRole_emergency, VehicleRole_military, VehicleRole_publicTransport, VehicleRole_rescue, VehicleRole_reserved1, VehicleRole_reserved2, VehicleRole_reserved3, VehicleRole_roadOperator, VehicleRole_roadWork, VehicleRole_safetyCar, VehicleRole_specialTransport, and VehicleRole_taxi.
Referenced by checkAndCollectDataForOptionalContainers().
void caBasicService::PassCamToNetworkAndTransportLayer | ( | char * | cam, |
int | camLength | ||
) |
PassCamToNetworkAndTransportLayer Pass the encoded CAM to the N&T layer.
Definition at line 124 of file caBasicService.cpp.
References LifeTime::base_1_s, btpPort_CAM, gnDataRequest_s::destinationAddress, destinationAddress_PR_UNKNOWN, gnDataRequest_s::destinationPort, gnDataRequest_s::destinationPortInfo, gnDataRequest_s::gnCommunicationProfile, gnCommunicationProfile_ITS_G5A, CommonHeader::headerSubTypeTopologicallyScopedBroadcast_singleHop, CommonHeader::headerType_topologicallyScopedBroadcast, itsGnDefaultTrafficClass, m_elapsed, m_geonet, gnDataRequest_s::maximumHopLimit, gnDataRequest_s::maximumPacketLifeTime, gnDataRequest_s::maximumRepetitionTime, CommonHeader::nextHeaderType_BTP_B, gnDataRequest_s::packetTransportSubType, gnDataRequest_s::packetTransportType, gnDataRequest_s::payload, destinationAddress_s::present, gnDataRequest_s::repetitionInterval, GeoNet::send(), gnDataRequest_s::trafficClass, and gnDataRequest_s::upperProtocolEntity.
Referenced by checkToSendCAM().
|
inline |
previousCAM Previous CAM getter
Definition at line 78 of file caBasicService.h.
References m_previousCAM.
Referenced by checkCamGeneration(), and getPathPoint().
|
inline |
previousTime Time of the previous CAM getter.
Definition at line 83 of file caBasicService.h.
References m_previousTime.
|
private |
Reset the list of previous points.
Definition at line 52 of file caBasicService.cpp.
References m_listGenerationDeltaTime, m_listPathPoint, m_listReferencePosition, m_quick, m_T_GenCam, MAX_REFERENCEPOSITION, and T_GenCamMax.
Referenced by checkCamGeneration().
|
inline |
setCurrentCAM Set the current CAM.
c | The current CAM. |
Definition at line 120 of file caBasicService.h.
References m_currentCAM, and setCAM().
|
inline |
setLastLF Set the time where the last CAM had a LowFrequencyContainer.
l | The time where the last CAM had a LowFrequencyContainer. |
Definition at line 135 of file caBasicService.h.
References m_lastLF.
Referenced by checkToSendCAM().
|
inline |
setN_GenCam Set the N_GenCam
n | The new N_GenCam. |
Definition at line 110 of file caBasicService.h.
References m_N_GenCam.
Referenced by caBasicService().
|
inline |
setPreviousCAM Set the previous CAM.
c | The previous CAM. |
Definition at line 125 of file caBasicService.h.
References m_previousCAM, and setCAM().
|
inline |
setPreviousTime Set the time where the previous CAM was sent.
p | The time where the previous CAM was sent. |
Definition at line 130 of file caBasicService.h.
References m_previousTime.
Referenced by checkToSendCAM().
|
inline |
setT_CheckGenCam Set the T_CheckGenCam.
t | The new T_CheckGenCam. |
Definition at line 115 of file caBasicService.h.
References m_T_CheckGenCam.
Referenced by caBasicService().
|
inline |
setT_GenCam Set the T_GenCam.
t | The new T_GenCam. |
Definition at line 105 of file caBasicService.h.
References m_T_GenCam.
|
inline |
setT_GenCam_DCC Set the T_GenCam_DCC.
t | The new T_GenCam_DCC. |
Definition at line 100 of file caBasicService.h.
References m_T_GenCam_DCC.
|
inline |
T_CheckGenCam T_CheckCamm getter.
Definition at line 68 of file caBasicService.h.
References m_T_CheckGenCam.
|
inline |
T_GenCam T_GenCam getter.
Definition at line 58 of file caBasicService.h.
References m_T_GenCam.
|
inline |
T_GenCam_DCC T_GenCam_DCC getter.
Definition at line 53 of file caBasicService.h.
References m_T_GenCam_DCC.
Referenced by checkCamGeneration().
|
inline |
timestamp Current timestamp getter.
Definition at line 93 of file caBasicService.h.
References m_paramGPS, and FakeGPSProvider::timestamp().
void caBasicService::utInitialize | ( | ) |
utInitialize Initialize the CA Basic Service.
Definition at line 46 of file caBasicService.cpp.
References firstCAM, and m_timer.
Referenced by Facilities::utInitialize().
|
private |
ItsPduHeader of the CAMs.
Definition at line 275 of file caBasicService.h.
Referenced by caBasicService().
|
private |
Current CAM.
Definition at line 270 of file caBasicService.h.
Referenced by currentCAM(), and setCurrentCAM().
|
private |
Time elapsed since last changes.
Definition at line 276 of file caBasicService.h.
Referenced by checkCamGeneration(), checkToSendCAM(), execute(), and PassCamToNetworkAndTransportLayer().
|
private |
Number of generated CAM in a N_GenCam situation.
Definition at line 278 of file caBasicService.h.
Referenced by checkCamGeneration().
|
private |
N&T layer.
Definition at line 284 of file caBasicService.h.
Referenced by caBasicService(), and PassCamToNetworkAndTransportLayer().
|
private |
Last time where a CAM had a LowFrequencyContainer.
Definition at line 274 of file caBasicService.h.
Referenced by lastLF(), and setLastLF().
|
private |
List of generation delta times.
Definition at line 290 of file caBasicService.h.
Referenced by collectMandatoryData(), getPathPoint(), and reset().
|
private |
List of previous points.
Definition at line 291 of file caBasicService.h.
Referenced by checkPathPoint(), getPathHistory(), and reset().
|
private |
List of reference positions.
Definition at line 289 of file caBasicService.h.
Referenced by collectMandatoryData_BasicContainer(), getPathHistory(), getPathPoint(), and reset().
|
private |
N_GenCam.
Definition at line 268 of file caBasicService.h.
Referenced by checkCamGeneration(), N_GenCam(), and setN_GenCam().
|
private |
Application parameters.
Definition at line 286 of file caBasicService.h.
Referenced by caBasicService(), checkForOptionalContainers(), collectMandatoryData(), collectMandatoryData_BasicContainer(), collectMandatoryData_RSUContainerHighFrequency(), collectOptionalData_BasicVehicleContainerLowFrequency(), collectOptionalData_DangerousGoodsContainer(), collectOptionalData_EmergencyContainer(), collectOptionalData_PublicTransportContainer(), collectOptionalData_RoadWorksContainerbasic(), collectOptionalData_SafetyCarContainer(), and collectOptionalData_SpecialTransportContainer().
|
private |
CAN bus.
Definition at line 287 of file caBasicService.h.
Referenced by caBasicService(), collectMandatoryData_BasicVehicleContainerHighFrequency(), collectOptionalData_BasicVehicleContainerLowFrequency(), collectOptionalData_EmergencyContainer(), collectOptionalData_RescueContainer(), collectOptionalData_RoadWorksContainerbasic(), collectOptionalData_SafetyCarContainer(), and collectOptionalData_SpecialTransportContainer().
|
private |
Global configuration.
Definition at line 285 of file caBasicService.h.
Referenced by caBasicService(), and collectMandatoryData_BasicVehicleContainerHighFrequency().
|
private |
GPS.
Definition at line 282 of file caBasicService.h.
Referenced by caBasicService(), checkCamGeneration(), collectMandatoryData(), collectMandatoryData_BasicContainer(), collectMandatoryData_BasicVehicleContainerHighFrequency(), and timestamp().
|
private |
Previous CAM.
Definition at line 271 of file caBasicService.h.
Referenced by checkToSendCAM(), previousCAM(), and setPreviousCAM().
|
private |
Time where last CAM was generated.
Definition at line 273 of file caBasicService.h.
Referenced by previousTime(), and setPreviousTime().
|
private |
Do we need to send N_GenCam?
Definition at line 277 of file caBasicService.h.
Referenced by checkCamGeneration(), execute(), and reset().
|
private |
T_CheckGenCam.
Definition at line 269 of file caBasicService.h.
Referenced by setT_CheckGenCam(), and T_CheckGenCam().
|
private |
T_GenCam.
Definition at line 267 of file caBasicService.h.
Referenced by caBasicService(), checkCamGeneration(), reset(), setT_GenCam(), and T_GenCam().
|
private |
T_GenCam_DCC.
Definition at line 266 of file caBasicService.h.
Referenced by caBasicService(), setT_GenCam_DCC(), and T_GenCam_DCC().
|
private |
Timer used to sleep.
Definition at line 280 of file caBasicService.h.
Referenced by checkToSendCAM(), execute(), and utInitialize().
|
private |
UDP socket to communicate with the Application / UpperTester layer.
Definition at line 272 of file caBasicService.h.
Referenced by caBasicService().