ItsRSUsSimulator_Templates.ttcn 26.1 KB
Newer Older
garciay's avatar
garciay committed
1
2
3
4
5
6
7
8
9
10
11
12
module ItsRSUsSimulator_Templates {
    
    // LibCommon
    import from LibCommon_BasicTypesAndValues all;
    
    // LibIts
    import from ITS_Container language "ASN.1:1997" all;
    import from CAM_PDU_Descriptions language "ASN.1:1997" all;
    import from DENM_PDU_Descriptions language "ASN.1:1997" all;
    import from MAPEM_PDU_Descriptions language "ASN.1:1997" all;
    import from SPATEM_PDU_Descriptions language "ASN.1:1997" all;
    import from IVIM_PDU_Descriptions language "ASN.1:1997" all;
13
    import from IVI language "ASN.1:1997" all;
garciay's avatar
garciay committed
14
15
16
17
    import from SSEM_PDU_Descriptions language "ASN.1:1997" all;
    import from DSRC language "ASN.1:1997" all;
    
    // LibItsCommon
18
    import from LibItsCommon_ASN1_NamedNumbers all;
garciay's avatar
garciay committed
19
    import from LibItsCommon_Functions all;
20
    import from LibCommon_DataStrings all;
garciay's avatar
garciay committed
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
    
    // LibItsGeoNetworking
    import from LibItsGeoNetworking_TestSystem all;
    import from LibItsGeoNetworking_Functions all;
    import from LibItsGeoNetworking_Templates all;
    import from LibItsGeoNetworking_TypesAndValues all;
    
    // LibItsBtp
    import from LibItsBtp_TypesAndValues all;
    import from LibItsBtp_Templates all;
    
    // LibItsCam
    import from LibItsCam_Templates all;
    
    // LibItsDenm
    import from LibItsDenm_Templates all;
    
    // LibItsMapemSpatem
    import from LibItsMapemSpatem_Templates all;
    
    // LibItsIvim
    import from LibItsIvim_Templates all;
    
    // AtsRSUsSimulator
    import from ItsRSUsSimulator_TypesAndValues all;
    import from ItsRSUsSimulator_Functions all;
    import from ItsRSUsSimulator_Pics all;
    
    template (omit) RsuMessagesValue m_rsuProfile(
YannGarcia's avatar
YannGarcia committed
50
                                                  in template (omit) GeoNetworkingPdu p_beacon := omit,
51
52
                                                  in template (omit) CAM p_cam := omit,
                                                  in template (omit) DENMs p_denms := omit,
garciay's avatar
garciay committed
53
                                                  in template (omit) MAPEM p_mapem := omit,
54
55
                                                  in template (omit) SPATEMs p_spatems := omit,
                                                  in template (omit) IVIM p_ivim := omit,
56
                                                  //                                                  in template (omit) EvcsnPdu p_evcsn := omit,
57
                                                  in template (omit) SSEM p_ssem := omit
garciay's avatar
garciay committed
58
    ) := {
59
        beacon     := p_beacon,
60
61
62
63
        cam        := p_cam,
        denms      := p_denms,
        mapem      := p_mapem,
        spatems    := p_spatems,
garciay's avatar
garciay committed
64
        ivim       := p_ivim,
65
        //        evcsn      := p_evcsn,
garciay's avatar
garciay committed
66
        ssem       := p_ssem
garciay's avatar
garciay committed
67
68
69
    } // End of template RsuMessagesValue

    group geoNetworkingTemplates {
YannGarcia's avatar
YannGarcia committed
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92

        /**
         * @desc    Send template for long position vector with specific GN_Address
         * @param   p_gnAddress GN_Address to be contained in the long position vector
         */
        template (value) LongPosVector m_longPosVector(
                                                       in template (value) GN_Address p_gnAddress,
                                                       in UInt32 p_timestamp_,
                                                       in Int32 p_latitude := 0,
                                                       in Int32 p_longitude := 0,
                                                       in Bit1 p_pai := '0'B,
                                                       in Int15  p_speed := 0,
                                                       in UInt16 p_heading := 0

        ) := {
            gnAddr     := p_gnAddress,
            timestamp_ := p_timestamp_,
            latitude   := p_latitude,
            longitude  := p_longitude,
            pai        := p_pai,
            speed      := p_speed,
            heading    := p_heading
        }
garciay's avatar
garciay committed
93
        
YannGarcia's avatar
YannGarcia committed
94
95
96
97
98
99
100
        template (value) GnNonSecuredPacket m_geoNwBeaconPacket_payload(
                                                                        in template (value) LongPosVector p_sourceLongPosVec,
                                                                        in template (value) GnRawPayload p_gnRawPayload
        ) modifies m_geoNwBeaconPacket := {
            payload := p_gnRawPayload
        }

garciay's avatar
garciay committed
101
102
103
104
105
106
        template (value) GnNonSecuredPacket m_geoNwBroadcastPacket_payload(
                                                                           in template (value) LongPosVector p_sourceLongPosVec,
                                                                           in template (value) UInt16 p_seqNumber,
                                                                           in template (value) GeoBroadcastArea p_broadcastArea,
                                                                           in template (value) UInt8 p_hopLimit := c_defaultHopLimit,
                                                                           in template (value) TrafficClass p_trafficClass := m_trafficClass,
107
                                                                           in template (value) GnRawPayload p_payload
garciay's avatar
garciay committed
108
109
110
111
        ) modifies m_geoNwBroadcastPacket := {
            payload := p_payload
        } // End of template m_geoNwBroadcastPacket_payload
        
YannGarcia's avatar
YannGarcia committed
112
113
114
115
116
117
118
119
120
121
122
        template (value) GnNonSecuredPacket m_geoNwAnycastPacket_payload(
                                                                           in template (value) LongPosVector p_sourceLongPosVec,
                                                                           in template (value) UInt16 p_seqNumber,
                                                                           in template (value) GeoAnycastArea p_anycastArea,
                                                                           in template (value) UInt8 p_hopLimit := c_defaultHopLimit,
                                                                           in template (value) TrafficClass p_trafficClass := m_trafficClass,
                                                                           in template (value) GnRawPayload p_payload
        ) modifies m_geoNwAnycastPacket := {
            payload := p_payload
        } // End of template m_geoNwAnycastPacket_payload
        
123
124
125
126
127
        /**
         * @desc    Send template for GeoNetworking TSB Packet
         * @param   p_seqNumber         Sequence number of TSB packet
         * @param   p_sourceLongPosVec  Long position vector of source
         * @param   p_hopLimit          The maximum number of hops (Default: c_defaultHopLimit)
garciay's avatar
garciay committed
128
129
         * @param   p_trafficClass      TODO
         * @param   p_payload           TODO
130
131
132
133
134
135
         */
        template (value) GnNonSecuredPacket m_geoNwTsbPacket_payload(
                                                                     in template (value) UInt16 p_seqNumber,
                                                                     in template (value) LongPosVector p_sourceLongPosVec,
                                                                     in template (value) UInt8 p_hopLimit := c_defaultHopLimit,
                                                                     in template (value) TrafficClass p_trafficClass := m_trafficClass,
136
                                                                     in template (value) GnRawPayload p_payload
137
138
139
140
        ) modifies m_geoNwTsbPacket:= {
            payload :=  p_payload
        }
        
garciay's avatar
garciay committed
141
142
143
144
145
146
147
148
149
        /**
         * @desc    Send template for GeoNetworking SHB Packet
         * @param   p_sourceLongPosVec  Long position vector of source
         * @param   p_hopLimit          The maximum number of hops (Default: c_defaultHopLimit)
         * @param   p_trafficClass      TODO
         * @param   p_payload           TODO
         */
        template (value) GnNonSecuredPacket m_geoNwShbPacket_payload(
                                                                     in template (value) LongPosVector p_sourceLongPosVec,
150
                                                                     in template (value) GnRawPayload p_payload
garciay's avatar
garciay committed
151
152
153
154
        ) modifies m_geoNwShbPacket:= {
            payload :=  p_payload
        }
        
garciay's avatar
garciay committed
155
156
157
158
159
160
        /**
         * @desc    Receive template for GeoNetworking Unicast Packet
         * @param   p_destinationShortPosVec    Short position vector of destination
         * @param   p_seqNumber                 Sequence number of GeoUnicast packet
         * @param   p_nextHeader                Id of next header
         */
161
162
163
164
165
        template (present) GnNonSecuredPacket mw_geoNwBroadcastPacketWithNextHeader_srem(
                                                                                         in template (present) LongPosVector p_sourceLongPosVec := ?,
                                                                                         in template (present) UInt16 p_seqNumber := ?,
                                                                                         in template (present) NextHeader p_nextHeader := ?
        ) modifies mw_geoNwBroadcastPacketWithNextHeader := {
garciay's avatar
garciay committed
166
          payload := f_payload_template(PICS_SREM_BTP_DESTINATION_PORT, PICS_SREM_BTP_SOURCE_PORT)
garciay's avatar
garciay committed
167
168
        }
        
garciay's avatar
garciay committed
169
        /**
garciay's avatar
garciay committed
170
         * @desc    Receive template for GeoNetworking SREM Packet
garciay's avatar
garciay committed
171
172
173
174
175
176
177
178
179
         * @param   p_destinationShortPosVec    Short position vector of destination
         * @param   p_seqNumber                 Sequence number of GeoUnicast packet
         * @param   p_nextHeader                Id of next header
         */
        template (present) GnNonSecuredPacket mw_geoNwTsbPacketWithNextHeader_srem(
                                                                                   in template (present) UInt16 p_seqNumber := ?,
                                                                                   in template (present) LongPosVector p_sourceLongPosVec := ?,
                                                                                   in template (value) NextHeader p_nextHeader
        ) modifies mw_geoNwTsbPacketWithNextHeader := {
garciay's avatar
garciay committed
180
            payload := f_payload_template(PICS_SREM_BTP_DESTINATION_PORT, PICS_SREM_BTP_SOURCE_PORT)
garciay's avatar
garciay committed
181
        }
garciay's avatar
garciay committed
182
        
183
184
185
186
187
188
189
        /**
         * @desc    Receive template for GeoNetworking DENM Packet
         * @param   p_destinationShortPosVec    Short position vector of destination
         * @param   p_seqNumber                 Sequence number of GeoUnicast packet
         * @param   p_nextHeader                Id of next header
         */
        template (present) GnNonSecuredPacket mw_geoNwTsbPacketWithNextHeader_denm(
190
191
                in template (present) UInt16 p_seqNumber := ?,
                in template (present) LongPosVector p_sourceLongPosVec := ?
192
        ) modifies mw_geoNwTsbPacket := {
garciay's avatar
garciay committed
193
            payload := f_payload_template(PICS_DENM_BTP_DESTINATION_PORT, PICS_DENM_BTP_SOURCE_PORT)
garciay's avatar
garciay committed
194
        } // End of template mw_geoNwTsbPacketWithNextHeader_denm
195
        
YannGarcia's avatar
YannGarcia committed
196
197
198
199
200
201
202
203
204
205
206
207
208
        /**
         * @desc    Receive template for GeoNetworking DENM Packet
         * @param   p_destinationShortPosVec    Short position vector of destination
         * @param   p_seqNumber                 Sequence number of GeoUnicast packet
         * @param   p_nextHeader                Id of next header
         */
        template (present) GnNonSecuredPacket mw_geoNwBroadcastPacketWithNextHeader_denm(
                in template (present) LongPosVector p_sourceLongPosVec := ?,
                in template (present) UInt16 p_seqNumber := ?
        ) modifies mw_geoNwBroadcastPacket := {
            payload := f_payload_template(PICS_DENM_BTP_DESTINATION_PORT, PICS_DENM_BTP_SOURCE_PORT)
        } // End of template mw_geoNwBroadcastPacketWithNextHeader_denm
        
garciay's avatar
garciay committed
209
210
211
212
213
214
215
216
217
        /**
         * @desc    Receive template for GeoNetworking CAM Packet
         * @param   p_destinationShortPosVec    Short position vector of destination
         * @param   p_seqNumber                 Sequence number of GeoUnicast packet
         * @param   p_nextHeader                Id of next header
         */
        template (present) GnNonSecuredPacket mw_geoNwShbPacketWithNextHeader_cam(
                                                                                  in template (present) LongPosVector p_sourceLongPosVec := ?,
                                                                                  in template (present) UInt8 p_hopLimit := ?,
garciay's avatar
garciay committed
218
                                                                                  in template (present) NextHeader p_nextHeader,
garciay's avatar
garciay committed
219
                                                                                  in template (present) CAM p_cam := ?
garciay's avatar
garciay committed
220
        ) modifies mw_geoNwShbPacket := {
garciay's avatar
garciay committed
221
            payload := f_payload_template(PICS_CAM_BTP_DESTINATION_PORT, PICS_CAM_BTP_SOURCE_PORT)
garciay's avatar
garciay committed
222
        } // End of template mw_geoNwShbPacketWithNextHeader_cam
garciay's avatar
garciay committed
223
        
garciay's avatar
garciay committed
224
225
226
227
228
229
230
231
232
233
234
235
236
237
    } // End of group geoNetworkingTemplates 
    
    group positionTemplates {
        
        /**
         * @desc The test system reference position.
         */
        template (value) ReferencePosition m_rsuPosition(
                                                         in template (value) Latitude p_latitude,
                                                         in template (value) Longitude p_longitude
        ) := {
            latitude := f_integer2Latitude(valueof(p_latitude)),
            longitude := f_integer2Latitude(valueof(p_longitude)),
            positionConfidenceEllipse := {
238
239
240
                semiMajorConfidence   := LibItsCommon_ASN1_NamedNumbers.SemiAxisLength_oneCentimeter_,
                semiMinorConfidence   := LibItsCommon_ASN1_NamedNumbers.SemiAxisLength_oneCentimeter_,
                semiMajorOrientation  := LibItsCommon_ASN1_NamedNumbers.HeadingValue_wgs84North_
garciay's avatar
garciay committed
241
242
            },
            altitude := {
243
                altitudeValue := LibItsCommon_ASN1_NamedNumbers.AltitudeValue_referenceEllipsoidSurface_,
garciay's avatar
garciay committed
244
245
246
247
                altitudeConfidence := unavailable
            }
        } // End of template m_rsuPosition
        
garciay's avatar
garciay committed
248
249
250
251
252
        /**
         * @desc    Receive template for long position vector with strict position check
         * @param   p_longPosVector The base long position vector
         */
        template LongPosVector mw_longPosVectorPosition_vendors(
253
254
                                                                in template (value) Oct6 p_mid
        ) := {
garciay's avatar
garciay committed
255
256
257
            gnAddr := {
                typeOfAddress := ?,
                stationType := ?,
Yann Garcia's avatar
Yann Garcia committed
258
                reserved := ?,
259
                mid := p_mid
garciay's avatar
garciay committed
260
261
262
263
            },
            timestamp_ := ?,
            latitude := ?,
            longitude := ?,
garciay's avatar
garciay committed
264
            pai := ?,
garciay's avatar
garciay committed
265
266
267
268
269
            //FIXME May the delta factor should be based on the actual speed value -> low speed=lower delta, high speed=higher delta
            speed := ?,
            heading := ?
        }
        
garciay's avatar
garciay committed
270
271
272
273
    } // End of group positionTemplates
    
    group camTemplates {
        
274
275
276
277
278
279
280
281
282
283
284
285
        template (value) HighFrequencyContainer m_highFrequencyContainer_rsuContainerHighFrequency(
                                                                                                   in template (value) RSUContainerHighFrequency p_rsuContainerHighFrequency
        ) := {
            rsuContainerHighFrequency := p_rsuContainerHighFrequency
        }
        
        template (value) RSUContainerHighFrequency m_rSUContainerHighFrequency(
                                                                               in template (value) ProtectedCommunicationZonesRSU p_protectedCommunicationZonesRSU
        ) := {
            protectedCommunicationZonesRSU := p_protectedCommunicationZonesRSU
        }
        
garciay's avatar
garciay committed
286
287
        template (value) CAM m_camParm(
                                       in template (value) StationID p_stationID,
288
                                       in template (value) ITS_Container.StationType p_stationType := LibItsCommon_ASN1_NamedNumbers.StationType_roadSideUnit_,
garciay's avatar
garciay committed
289
                                       in template (value) VehicleRole p_vehicleRole := roadOperator,
garciay's avatar
garciay committed
290
291
292
                                       in template (value) ReferencePosition p_rsuPosition,
                                       in template (value) PathHistory p_pathHistory,
                                       in template (value) HighFrequencyContainer p_highFrequencyContainer
garciay's avatar
garciay committed
293
294
        ) := {
            header := {
295
296
                protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
                messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_cam_,
garciay's avatar
garciay committed
297
298
299
300
301
302
                stationID := p_stationID
            },
            cam := {
                generationDeltaTime := 0, // Dynamic parameter
                camParameters := {
                    basicContainer := {
garciay's avatar
garciay committed
303
                        stationType := p_stationType,
garciay's avatar
garciay committed
304
305
                        referencePosition := p_rsuPosition
                    },
306
307
                    highFrequencyContainer := p_highFrequencyContainer,
                    lowFrequencyContainer := {
garciay's avatar
garciay committed
308
                        basicVehicleContainerLowFrequency := {
garciay's avatar
garciay committed
309
                            vehicleRole := p_vehicleRole,
310
                            exteriorLights := '00000000'B,
garciay's avatar
garciay committed
311
312
                            pathHistory := p_pathHistory
                        }
313
                    },
garciay's avatar
garciay committed
314
315
316
317
318
                    specialVehicleContainer := omit
                }
            }
        } // End of template m_camParm
        
garciay's avatar
garciay committed
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
        template (present) CAM mw_cam_stationID(
                                                in template (present) BasicVehicleContainerHighFrequency p_basicVehicleContainer := mw_HF_BV_speed(?),
                                                in template (value) StationID p_stationID,
                                                in template (present) ReferencePosition p_referencePosition := ?
        ) modifies mw_camMsg_HF_BV := {
            header := {
                stationID := p_stationID
            }, 
            cam := {
                camParameters := {
                    basicContainer := {
                        stationType := ?,
                        referencePosition := p_referencePosition
                    }
                }
            }
        } // End of template mw_cam_stationID
336
        
garciay's avatar
garciay committed
337
338
339
340
    } // End of group camTemplates
    
    group mapemTemplates {
        
garciay's avatar
garciay committed
341
        template (value) MAPEM m_mapemParm(
garciay's avatar
garciay committed
342
343
                                           in template (value) StationID p_stationID,
                                           in template (value) MapData p_map
garciay's avatar
garciay committed
344
345
        ) := {
            header := {
346
347
                protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
                messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_mapem_,
garciay's avatar
garciay committed
348
349
350
351
352
                stationID := p_stationID
            },
            map_ := p_map
        }
        
garciay's avatar
garciay committed
353
354
    } // End of group mapemTemplates
    
355
356
357
358
359
360
361
    group spatemTemplates {
        
        template (value) SPATEM m_spatemParm(
                                             in template (value) StationID p_stationID,
                                             in template (value) SPAT p_spat
        ) := {
            header := {
362
363
                protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
                messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_spatem_,
364
365
366
367
368
369
370
                stationID := p_stationID
            },
            spat := p_spat
        }
        
    } // End of group spatemTemplates
    
garciay's avatar
garciay committed
371
372
    group ivimTemplates {
        
373
374
375
376
377
        template (value) IVIM m_ivimParm(
                                         in template (value) StationID p_stationID,
                                         in template (value) IviStructure p_ivi
        ) := {
            header := {
378
379
                protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
                messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_ivim_,
380
381
382
383
384
                stationID := p_stationID
            },
            ivi := p_ivi
        }
        
garciay's avatar
garciay committed
385
386
    } // End of ivimTemplates
    
387
    /* group evcsnTemplates { */
garciay's avatar
garciay committed
388
        
389
390
391
392
393
394
395
396
397
398
399
    /*     template (value) EvcsnPdu m_evcsnParm( */
    /*                                          in template (value) StationID p_stationID, */
    /*                                          in template (value) EVChargingSpotNotificationPOIMessage p_evcsn */
    /*     ) := { */
    /*         header := { */
    /*             protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_, */
    /*             messageID := 7, //LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_evcsn_, */
    /*             stationID := p_stationID */
    /*         }, */
    /*         evcsn := p_evcsn */
    /*     } */
garciay's avatar
garciay committed
400
        
401
402
403
404
405
406
407
    /*     template (value) EVChargingSpotNotificationPOIMessage m_evcsn( */
    /*                                                                   in template (value) ItsPOIHeader p_poiHeader, */
    /*                                                                   in template (value) ItsEVCSNData p_evcsnData */
    /*     ) := { */
    /*         poiHeader := p_poiHeader, */
    /*         evcsnData := p_evcsnData */
    /*     } */
garciay's avatar
garciay committed
408
        
409
410
411
412
413
414
415
416
417
    /*     template (value) ItsPOIHeader m_itsPOIHeader( */
	  /*                                                 in template (value) POIType p_poiType := 1, */
    /*                                                   in template (value) TimestampIts p_timeStamp, */
	  /*                                                 in template (value) boolean p_relayCapable := true */
    /*     ) := { */
	  /*       poiType       := p_poiType, */
    /*         timeStamp     := p_timeStamp, */
	  /*       relayCapable  := p_relayCapable */
    /*     } */
garciay's avatar
garciay committed
418
        
419
420
421
422
423
424
425
    /*     template (value) ItsEVCSNData m_itsEVCSNData(  */
	  /*                                                in template (value) NumberStations p_totalNumberOfStations := 1, */
	  /*                                                in template (value) ItsChargingStationDatas p_itsChargingStationDatas */
    /*     ) := { */
	  /*       totalNumberOfStations   := p_totalNumberOfStations, */
	  /*       chargingStationsData    := p_itsChargingStationDatas */
    /*     } */
garciay's avatar
garciay committed
426
        
427
    /* } // End of group evcsnTemplates */
garciay's avatar
garciay committed
428
429
430
    
    group denmTemplates {
        
431
432
433
434
435
436
437
438
439
440
441
442
        /**
         * @desc    Send template for DENM PDU
         * @param   p_denm  The DEN Message
         */
        template (value) DENM m_denmPdu_rsu(
                                            in template (value) StationID p_stationID,
                                            in template (value) DecentralizedEnvironmentalNotificationMessage p_denm
        ) := {
            header := LibItsDenm_Templates.m_itsPduHeader(p_stationID),
            denm := p_denm
        }
        
443
444
445
446
447
448
449
450
451
452
453
454
455
        /**
         * @desc    Send template for Alacarte Container including lanePosition
         */
        template (omit) AlacarteContainer m_alacarte(
                                                     in template (omit) RoadWorksContainerExtended p_roadWorksContainerExtended
        ) := {
            lanePosition := omit,
            impactReduction := omit,
            externalTemperature := omit,
            roadWorks := p_roadWorksContainerExtended,
            positioningSolution := omit,
            stationaryVehicle := omit
        }
456
        
457
458
459
460
461
462
463
464
465
466
467
        template (omit) DenmParmContainers m_denmParmContainers(
                                                                in template (value) StationID p_originatingStationID,
                                                                in template (value) SequenceNumber p_sequenceNumber,
                                                                in template (value) TransmissionInterval p_repetitionInterval,
                                                                in template (value) ReferencePosition p_eventPosition,
                                                                in template (value) CauseCodeType p_causeCodeType,
                                                                in template (omit) EventHistory p_eventHistory := omit,
                                                                in template (omit) Traces p_traces := omit,
                                                                in template (value) ValidityDuration p_validityDuration := 86400,
                                                                in template (value) RelevanceDistance p_relevanceDistance := lessThan100m,
                                                                in template (value) RelevanceTrafficDirection p_relevanceTrafficDirection := upstreamTraffic
garciay's avatar
garciay committed
468
469
470
471
472
473
        ) := {
            managementContainer := {
                actionID := {
                    originatingStationID    := p_originatingStationID,
                    sequenceNumber          := p_sequenceNumber
                },
474
                detectionTime               := f_getCurrentTime(),
475
                referenceTime               := f_getCurrentTime(), // FIXME To be checked
garciay's avatar
garciay committed
476
477
478
                termination                 := omit,
                eventPosition               := p_eventPosition,
                relevanceDistance           := p_relevanceDistance,
garciay's avatar
garciay committed
479
                relevanceTrafficDirection   := upstreamTraffic,
garciay's avatar
garciay committed
480
                validityDuration            := p_validityDuration,
481
                transmissionInterval        := p_repetitionInterval,
482
                stationType                 := LibItsCommon_ASN1_NamedNumbers.StationType_roadSideUnit_
garciay's avatar
garciay committed
483
484
485
486
487
488
489
490
491
492
493
494
495
            }, // End of field managementContainer
            situationContainer := {
                informationQuality          := 0,
                eventType := {
                    causeCode               := p_causeCodeType,
                    subCauseCode            := 0
                },
                linkedCause                 := omit,
                eventHistory                := p_eventHistory
            }, // End of field situationContainer
            locationContainer := {
                eventSpeed := omit,
                eventPositionHeading := omit,
496
                traces := p_traces,
garciay's avatar
garciay committed
497
498
499
                roadType := omit 
            } // End of field locationContainer
        } // End of template m_denmParm
garciay's avatar
garciay committed
500
        
garciay's avatar
garciay committed
501
502
    } // End of group denmTemplates
    
503
} // End of module ItsRSUsSimulator_Templates