Skip to main content
. 2024 May 2;24(9):2913. doi: 10.3390/s24092913
Algorithm 1: Collect CPP at junctions
Input: CurrPosGPS, JuncPos, PacketCPP, CPP_Managementtable
Output: void
  1. Begin

  2. Timercollection ← null

  3. if CurrPosGPS = JuncPos then

  4.   if PacketCPP.Type = CPP_Master OR CPP_Sub_Set AND then 

  5.      Timercollection ← GetTimerStart(1 s)

  6.        while Timercollection ≠ TIMEOUT do

  7.           if PacketCPP.Type = CPP_Master then 

  8.                CPP_Managementtable.Update(Packetcpp)

  9.           else if  Packetcpp.Type = CPP_SubSet then 

  10.                CPP_Managementtable.Update(Packetcpp)

  11.           else if

  12.           if CPP_Managementtable ≠ null then

  13.                if CurrPosGPS = JuncPos then

  14.                   FindOptimizedPath(CPP_Managementtable)

  15.                end if

  16.             end if

  17.           end while

  18.    end if

  19. end if

  20. return 0