Newer
Older
13001
13002
13003
13004
13005
13006
13007
13008
13009
13010
13011
13012
13013
13014
13015
13016
13017
13018
13019
13020
13021
13022
13023
13024
group GEONW_PON_BCA_BV_05 {
/**
* @desc TP Function for TC_GEONW_PON_BCA_BV_05
*/
function f_GEONW_PON_BCA_BV_05() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeC;
var ItsGeoNetworking v_nodeD;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_cbf) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_cbf required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13030
13031
13032
13033
13034
13035
13036
13037
13038
13039
13040
13041
13042
13043
13044
13045
13046
13047
13048
13049
13050
13051
13052
13053
13054
13055
13056
13057
13058
13059
13060
13061
13062
13063
13064
13065
13066
13067
13068
13069
13070
13071
13072
13073
13074
13075
13076
13077
13078
13079
13080
13081
13082
13083
13084
13085
13086
13087
13088
13089
13090
13091
13092
13093
13094
13095
13096
13097
13098
13099
13100
13101
13102
13103
13104
13105
13106
13107
13108
13109
13110
13111
13112
13113
13114
13115
13116
13117
13118
13119
13120
13121
13122
13123
13124
13125
13126
13127
13128
13129
13130
13131
13132
13133
13134
13135
13136
13137
13138
13139
13140
13141
13142
13143
13144
13145
13146
13147
13148
13149
13150
13151
13152
13153
13154
13155
13156
13157
13158
13159
13160
13161
13162
13163
13164
13165
13166
13167
13168
13169
13170
13171
13172
13173
13174
13175
13176
13177
13178
13179
13180
13181
13182
13183
13184
13185
13186
13187
13188
13189
13190
13191
13192
13193
13194
13195
13196
13197
13198
13199
13200
13201
13202
13203
13204
13205
13206
13207
13208
// Test component configuration
f_cf04Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeC := f_getComponent(c_compNodeC);
v_nodeD := f_getComponent(c_compNodeD);
v_nodeB.start(f_GEONW_PON_BCA_BV_05_nodeB());
v_nodeC.start(f_GEONW_PON_BCA_BV_05_nodeC());
v_nodeD.start(f_GEONW_PON_BCA_BV_05_nodeD());
// Synchronization
f_serverSync3ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf04Down();
} // end f_GEONW_PON_BCA_BV_05
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BCA_BV_05)
*/
function f_GEONW_PON_BCA_BV_05_nodeB() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_05_nodeB
/**
* @desc Behavior function for NodeC (TC_GEONW_PON_BCA_BV_05)
*/
function f_GEONW_PON_BCA_BV_05_nodeC() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_05_nodeC
/**
* @desc Behavior function for NodeD (TC_GEONW_PON_BCA_BV_05)
*/
function f_GEONW_PON_BCA_BV_05_nodeD() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
timer t_toCbf := int2float(f_getGeoBroadcastCbfMaxTime()) * 0.95 / 1000.0;
// Preamble
f_prNonNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
f_sendGeoNetMessage(
m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(
m_geoNwBroadcastPacket(
v_longPosVectorNodeC,
vc_localSeqNumber,
f_getGeoBroadcastArea(c_area1)
)
)
)
);
t_toCbf.start;
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
if(t_toCbf.running) {
t_toCbf.stop;
log("*** " & testcasename() & ": FAIL: GBC retransmitted before CBF timer expiration ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GBC message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
[] t_toCbf.timeout {
log("*** " & testcasename() & ": INFO: CBF timer elapsed ***");
repeat;
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poDefault();
} // end f_GEONW_PON_BCA_BV_05_nodeD
} // end GEONW_PON_BCA_BV_05
group GEONW_PON_BCA_BV_06 {
/**
* @desc TP Function for TC_GEONW_PON_BCA_BV_06
*/
function f_GEONW_PON_BCA_BV_06() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeC;
var ItsGeoNetworking v_nodeD;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_cbf) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_cbf required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13214
13215
13216
13217
13218
13219
13220
13221
13222
13223
13224
13225
13226
13227
13228
13229
13230
13231
13232
13233
13234
13235
13236
13237
13238
13239
13240
13241
13242
13243
13244
13245
13246
13247
13248
13249
13250
13251
13252
13253
13254
13255
13256
13257
13258
13259
13260
13261
13262
13263
13264
13265
13266
13267
13268
13269
13270
13271
13272
13273
13274
13275
13276
13277
13278
13279
13280
13281
13282
13283
13284
13285
13286
13287
13288
13289
13290
13291
13292
13293
13294
13295
13296
13297
13298
13299
13300
13301
13302
13303
13304
13305
13306
13307
13308
13309
13310
13311
13312
13313
13314
13315
13316
13317
13318
13319
13320
13321
13322
13323
13324
13325
13326
13327
13328
13329
13330
13331
13332
13333
13334
13335
13336
13337
13338
13339
13340
13341
13342
13343
13344
13345
13346
13347
13348
13349
13350
13351
13352
13353
13354
13355
13356
13357
13358
13359
13360
13361
13362
13363
13364
13365
13366
13367
13368
13369
// Test component configuration
f_cf04Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeC := f_getComponent(c_compNodeC);
v_nodeD := f_getComponent(c_compNodeD);
v_nodeB.start(f_GEONW_PON_BCA_BV_06_nodeB());
v_nodeC.start(f_GEONW_PON_BCA_BV_06_nodeC());
v_nodeD.start(f_GEONW_PON_BCA_BV_06_nodeD());
// Synchronization
f_serverSync3ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf04Down();
} // end f_GEONW_PON_BCA_BV_06
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BCA_BV_06)
*/
function f_GEONW_PON_BCA_BV_06_nodeB() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area2)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_06_nodeB
/**
* @desc Behavior function for NodeC (TC_GEONW_PON_BCA_BV_06)
*/
function f_GEONW_PON_BCA_BV_06_nodeC() runs on ItsGeoNetworking {
// Local variables
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(?))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message re-broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not re-broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_06_nodeC
/**
* @desc Behavior function for NodeD (TC_GEONW_PON_BCA_BV_06)
*/
function f_GEONW_PON_BCA_BV_06_nodeD() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNonNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
f_sendGeoNetMessage(
m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(
m_geoNwBroadcastPacket(
v_longPosVectorNodeC,
vc_localSeqNumber,
f_getGeoBroadcastArea(c_area2)
)
)
)
);
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(?))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message re-broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not re-broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poDefault();
} // end f_GEONW_PON_BCA_BV_06_nodeD
} // end GEONW_PON_BCA_BV_06
group GEONW_PON_BCA_BV_07 {
/**
* @desc TP Function for TC_GEONW_PON_BCA_BV_07
*/
function f_GEONW_PON_BCA_BV_07() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeC;
var ItsGeoNetworking v_nodeD;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_cbf) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_cbf required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13375
13376
13377
13378
13379
13380
13381
13382
13383
13384
13385
13386
13387
13388
13389
13390
13391
13392
13393
13394
13395
13396
13397
13398
13399
13400
13401
13402
13403
13404
13405
13406
13407
13408
13409
13410
13411
13412
13413
13414
13415
13416
13417
13418
13419
13420
13421
13422
13423
13424
13425
13426
13427
13428
13429
13430
13431
13432
13433
13434
13435
13436
13437
13438
13439
13440
13441
13442
13443
13444
13445
13446
13447
13448
13449
13450
13451
13452
13453
13454
13455
13456
13457
13458
13459
13460
13461
13462
13463
13464
13465
13466
13467
13468
13469
13470
13471
13472
13473
13474
13475
13476
13477
13478
13479
13480
13481
13482
13483
13484
13485
13486
13487
13488
13489
13490
13491
13492
13493
13494
13495
13496
13497
13498
13499
13500
13501
13502
13503
13504
13505
13506
13507
13508
13509
13510
13511
13512
13513
13514
13515
13516
13517
13518
13519
13520
13521
13522
13523
13524
13525
13526
13527
13528
13529
13530
13531
13532
13533
13534
13535
13536
13537
13538
13539
13540
13541
13542
// Test component configuration
f_cf04Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeC := f_getComponent(c_compNodeC);
v_nodeD := f_getComponent(c_compNodeD);
v_nodeB.start(f_GEONW_PON_BCA_BV_07_nodeB());
v_nodeC.start(f_GEONW_PON_BCA_BV_07_nodeC());
v_nodeD.start(f_GEONW_PON_BCA_BV_07_nodeD());
// Synchronization
f_serverSync3ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf04Down();
} // end f_GEONW_PON_BCA_BV_07
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BCA_BV_07)
*/
function f_GEONW_PON_BCA_BV_07_nodeB() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeA := f_getPosition(c_compNodeA);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeA),
?,
f_getGeoBroadcastArea(c_area2)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_07_nodeB
/**
* @desc Behavior function for NodeC (TC_GEONW_PON_BCA_BV_07)
*/
function f_GEONW_PON_BCA_BV_07_nodeC() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
var LongPosVector v_longPosVectorNodeA := f_getPosition(c_compNodeA);
// Preamble
v_longPosVectorNodeC.pai := int2bit(0,1);
f_changePositon(c_compNodeC, v_longPosVectorNodeC);
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
f_sendGeoNetMessage(
m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(
m_geoNwBroadcastPacket(
v_longPosVectorNodeA,
vc_localSeqNumber,
f_getGeoBroadcastArea(c_area2)
)
)
)
);
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeA),
?,
f_getGeoBroadcastArea(c_area2)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_07_nodeC
/**
* @desc Behavior function for NodeD (TC_GEONW_PON_BCA_BV_07)
*/
function f_GEONW_PON_BCA_BV_07_nodeD() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeA := f_getPosition(c_compNodeA);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeA),
?,
f_getGeoBroadcastArea(c_area2)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_07_nodeD
} // end GEONW_PON_BCA_BV_07
group GEONW_PON_BCA_BV_08 {
/**
* @desc TP Function for TC_GEONW_PON_BCA_BV_08
*/
function f_GEONW_PON_BCA_BV_08() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeC;
var ItsGeoNetworking v_nodeD;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_cbf) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_cbf required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13548
13549
13550
13551
13552
13553
13554
13555
13556
13557
13558
13559
13560
13561
13562
13563
13564
13565
13566
13567
13568
13569
13570
13571
13572
13573
13574
13575
13576
13577
13578
13579
13580
13581
13582
13583
13584
13585
13586
13587
13588
13589
13590
13591
13592
13593
13594
13595
13596
13597
13598
13599
13600
13601
13602
13603
13604
13605
13606
13607
13608
13609
13610
13611
13612
13613
13614
13615
13616
13617
13618
13619
13620
13621
13622
13623
13624
13625
13626
13627
13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
13647
13648
13649
13650
13651
13652
13653
13654
13655
13656
13657
13658
13659
13660
13661
13662
13663
13664
13665
13666
13667
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679
13680
13681
13682
13683
13684
13685
13686
13687
13688
13689
13690
13691
13692
13693
13694
13695
13696
13697
13698
13699
13700
13701
13702
13703
13704
13705
13706
13707
13708
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721
13722
13723
13724
13725
13726
13727
13728
13729
13730
13731
13732
13733
// Test component configuration
f_cf04Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeC := f_getComponent(c_compNodeC);
v_nodeD := f_getComponent(c_compNodeD);
v_nodeB.start(f_GEONW_PON_BCA_BV_08_nodeB());
v_nodeC.start(f_GEONW_PON_BCA_BV_08_nodeC());
v_nodeD.start(f_GEONW_PON_BCA_BV_08_nodeD());
// Synchronization
f_serverSync3ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf04Down();
} // end f_GEONW_PON_BCA_BV_08
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BCA_BV_08)
*/
function f_GEONW_PON_BCA_BV_08_nodeB() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_08_nodeB
/**
* @desc Behavior function for NodeC (TC_GEONW_PON_BCA_BV_08)
*/
function f_GEONW_PON_BCA_BV_08_nodeC() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
log("*** " & testcasename() & ": PASS: GBC message broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not broadcasted ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BCA_BV_08_nodeC
/**
* @desc Behavior function for NodeD (TC_GEONW_PON_BCA_BV_08)
*/
function f_GEONW_PON_BCA_BV_08_nodeD() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeC := f_getPosition(c_compNodeC);
var LongPosVector v_longPosVectorNodeD := f_getPosition(c_compNodeD);
timer t_toCbf := int2float(f_getGeoBroadcastCbfMaxTime()) * 0.95 / 1000.0;
// Preamble
v_longPosVectorNodeD.pai := int2bit(0,1);
f_changePositon(c_compNodeD, v_longPosVectorNodeD);
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
f_sendGeoNetMessage(
m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(
m_geoNwBroadcastPacket(
v_longPosVectorNodeC,
vc_localSeqNumber,
f_getGeoBroadcastArea(c_area1)
)
)
)
);
t_toCbf.start;
tc_ac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(mw_geoNwBroadcastPacketWithArea(
mw_longPosVectorPosition(v_longPosVectorNodeC),
?,
f_getGeoBroadcastArea(c_area1)
)))) {
tc_ac.stop;
if(t_toCbf.running) {
t_toCbf.stop;
log("*** " & testcasename() & ": FAIL: GBC retransmitted before CBF timer expiration ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
else {
log("*** " & testcasename() & ": PASS: GBC message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
[] t_toCbf.timeout {
log("*** " & testcasename() & ": INFO: CBF timer elapsed ***");
repeat;
}
[] tc_ac.timeout {
log("*** " & testcasename() & ": FAIL: GBC message not received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
}
// Postamble
f_poDefault();
} // end f_GEONW_PON_BCA_BV_08_nodeD
} // end GEONW_PON_BCA_BV_08
} // end geoGeoBroadcastCbfAlgorithm
// 6.2.2.13
group geoGeoBroadcastAdvAlgorithm {
group GEONW_PON_BAA_BV_01 {
/**
* @desc TP Function for TC_GEONW_PON_BAA_BV_01
*/
function f_GEONW_PON_BAA_BV_01() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeF;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_advanced) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_advanced required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13739
13740
13741
13742
13743
13744
13745
13746
13747
13748
13749
13750
13751
13752
13753
13754
13755
13756
13757
13758
13759
13760
13761
13762
13763
13764
13765
13766
13767
13768
13769
13770
13771
13772
13773
13774
13775
13776
13777
13778
13779
13780
13781
13782
13783
13784
13785
13786
13787
13788
13789
13790
13791
13792
13793
13794
13795
13796
13797
13798
13799
13800
13801
13802
13803
13804
13805
13806
13807
13808
13809
13810
13811
13812
13813
13814
13815
13816
13817
13818
13819
13820
13821
13822
13823
13824
13825
13826
13827
13828
13829
13830
13831
13832
13833
13834
13835
13836
13837
13838
13839
13840
13841
13842
13843
13844
13845
13846
13847
13848
13849
13850
13851
13852
13853
13854
13855
13856
13857
// Test component configuration
f_cf06Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeF := f_getComponent(c_compNodeF);
v_nodeB.start(f_GEONW_PON_BAA_BV_01_nodeB());
v_nodeF.start(f_GEONW_PON_BAA_BV_01_nodeF());
// Synchronization
f_serverSync2ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf06Down();
} // end f_GEONW_PON_BAA_BV_01
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BAA_BV_01)
*/
function f_GEONW_PON_BAA_BV_01_nodeB() runs on ItsGeoNetworking {
// Local variables
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_noac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(?))) {
tc_noac.stop;
log("*** " & testcasename() & ": FAIL: Message not discarded ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
[] tc_noac.timeout {
log("*** " & testcasename() & ": PASS: No message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BAA_BV_01_nodeB
/**
* @desc Behavior function for NodeF (TC_GEONW_PON_BAA_BV_01)
*/
function f_GEONW_PON_BAA_BV_01_nodeF() runs on ItsGeoNetworking {
// Local variables
var integer i;
var template (value) GeoNetworkingPdu v_gnPacket;
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB);
// Preamble
f_prNeighbour();
v_gnPacket := m_geoNwPdu(m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
vc_localSeqNumber,
f_getGeoBroadcastArea(c_area1)
)
);
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_gnPacket));
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
for(i:=1; i < f_getAdvancedGbcForwardingMaxCounter(); i:=i+1) {
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(v_gnPacket));
f_sleepIgnoreDef(0.5);
}
tc_noac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(?))) {
tc_noac.stop;
log("*** " & testcasename() & ": FAIL: Message not discarded ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
[] tc_noac.timeout {
log("*** " & testcasename() & ": PASS: No message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BAA_BV_01_nodeF
} // end GEONW_PON_BAA_BV_01
group GEONW_PON_BAA_BV_02 {
/**
* @desc TP Function for TC_GEONW_PON_BAA_BV_02
*/
function f_GEONW_PON_BAA_BV_02() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeE;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_advanced) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_advanced required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
13863
13864
13865
13866
13867
13868
13869
13870
13871
13872
13873
13874
13875
13876
13877
13878
13879
13880
13881
13882
13883
13884
13885
13886
13887
13888
13889
13890
13891
13892
13893
13894
13895
13896
13897
13898
13899
13900
13901
13902
13903
13904
13905
13906
13907
13908
13909
13910
13911
13912
13913
13914
13915
13916
13917
13918
13919
13920
13921
13922
13923
13924
13925
13926
13927
13928
13929
13930
13931
13932
13933
13934
13935
13936
13937
13938
13939
13940
13941
13942
13943
13944
13945
13946
13947
13948
13949
13950
13951
13952
13953
13954
13955
13956
13957
13958
13959
13960
13961
13962
13963
13964
13965
13966
13967
13968
13969
13970
13971
13972
13973
13974
13975
13976
13977
13978
13979
13980
13981
13982
13983
13984
13985
// Test component configuration
f_cf05Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeE := f_getComponent(c_compNodeE);
v_nodeB.start(f_GEONW_PON_BAA_BV_02_nodeB());
v_nodeE.start(f_GEONW_PON_BAA_BV_02_nodeE());
// Synchronization
f_serverSync2ClientsAndStop({c_prDone, c_tbDone});
// Cleanup
f_cf05Down();
} // end f_GEONW_PON_BAA_BV_02
/**
* @desc Behavior function for NodeB (TC_GEONW_PON_BAA_BV_02)
*/
function f_GEONW_PON_BAA_BV_02_nodeB() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB);
// Preamble
f_prNeighbour();
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
0,
f_getGeoBroadcastArea(c_area1)
)
)
));
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
tc_noac.start;
alt {
[] geoNetworkingPort.receive(mw_geoNwInd(mw_geoNwPdu(?))) {
tc_noac.stop;
log("*** " & testcasename() & ": FAIL: Message not discarded ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
[] tc_noac.timeout {
log("*** " & testcasename() & ": PASS: No message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BAA_BV_02_nodeB
/**
* @desc Behavior function for NodeE (TC_GEONW_PON_BAA_BV_02)
*/
function f_GEONW_PON_BAA_BV_02_nodeE() runs on ItsGeoNetworking {
// Local variables
var LongPosVector v_longPosVectorNodeB := f_getPosition(c_compNodeB);
// Preamble
f_prNeighbour();
f_selfOrClientSyncAndVerdict(c_prDone, e_success);
// Test Body
f_sendGeoNetMessage(m_geoNwReq_linkLayerBroadcast(
m_geoNwPdu(m_geoNwBroadcastPacket(
v_longPosVectorNodeB,
0,
f_getGeoBroadcastArea(c_area1)
)
)
));
tc_noac.start;
alt {
[] geoNetworkingPort.receive (mw_geoNwInd(mw_geoNwPdu(?))){
tc_noac.stop;
log("*** " & testcasename() & ": FAIL: Message not discarded ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_error);
}
[] tc_noac.timeout {
log("*** " & testcasename() & ": PASS: No message received ***");
f_selfOrClientSyncAndVerdict(c_tbDone, e_success);
}
}
// Postamble
f_poNeighbour();
} // end f_GEONW_PON_BAA_BV_02_nodeE
} // end GEONW_PON_BAA_BV_02
group GEONW_PON_BAA_BV_03 {
/**
* @desc TP Function for TC_GEONW_PON_BAA_BV_03
*/
function f_GEONW_PON_BAA_BV_03() runs on ItsMtc {
// Local variables
var ItsGeoNetworking v_nodeB;
var ItsGeoNetworking v_nodeF;
// Test control
if (not PICS_GN_GBC_FWD) {
log("*** " & testcasename() & ": PICS_GN_GBC_FWD required for executing the TC ***");
setverdict(inconc);
stop;
}
if (f_getGeoBroadcastForwardingAlgorithm() != e_advanced) {
log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_FORWARDING_ALGORITHM == e_advanced required for executing the TC ***");
setverdict(inconc);
stop;
}
// if (f_getGeoBroadcastCbfMinTime() < 300) {
// log("*** " & testcasename() & ": PICS_GN_GEOBROADCAST_CBF_MIN_TIME >= 300 required for executing the TC ***");
// setverdict(inconc);
// stop;
// }
// Test component configuration
f_cf06Up();
// Preamble
// Start components
v_nodeB := f_getComponent(c_compNodeB);
v_nodeF := f_getComponent(c_compNodeF);
v_nodeB.start(f_GEONW_PON_BAA_BV_03_nodeB());