Research Article
Optimization of Transmission Signal Power through Observation of Congestion in VANets Using the Fuzzy Logic Approach: A Case Study in Highway and Urban Layout
Algorithm 9
Mechanism of store-carry-forward.
beaconCnt = 0; | |
while (true) do | |
newBeacon ← getBeaconMsg (beacon); | |
msgBeacon ← setDecapsulate (newBeacon); | |
beaconCnt++; | |
end | |
(9) if (isInsideRoI (msgBeacon.getDistFromSrc ( ) ) ) ↩ | |
then | |
(10) if ( (check (ttl, msgBeacon.getTimestamp ( ) ) ) >↩ | |
0) and (getHops (msgBeacon) < Threshold) ↩ | |
then | |
sendBeaconEvt ← setUpdateMsg (msgBeacon) ↩ | |
; | |
scheduleAt ( interval.beacon ( ), sendMsg (↩ | |
sendBeaconEvt ) ); | |
(13) else | |
(14) cancelAndDelete (msgBeacon); | |
(15) end | |
(16) end |