Compare RPL objective functions and candidate paths
Compare real MRHOF and OF0 parent records, then explain how their state differs from longest-prefix, Dijkstra and distance-vector worksheets.

Packet Pete — I check the next hop and the reply before trusting a route.
Predict the reading, then compare it with the measurement.
Contiki-NG Cooja
Third party ToolCompare real MRHOF and OF0 parent records, then explain how their state differs from longest-prefix, Dijkstra and distance-vector worksheets.
Download the complete lab packet and follow README.md to run it in the free simulator.
Download the setup and run guideGet the lab files
Download the complete packet for the simulation and its firmware, or download individual files for inspection. README.md gives the setup and run commands.
Steps
Step 1
- Do
- Run the primary MRHOF CSC to 180 s. Trace mote 5’s arrows in Network; predict whether it will choose relay 2 or 3.
- You will see
- Mote 5 uses 2 → 1 in this seed-1 run. Both candidate relays are within its 50 m range.
- Why it matters
- A visible path is an output; the candidate records explain why this output is defensible.

Step 1 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab) Step 2
- Do
- Filter Mote output for ^fe80::20[23].*=> and compare the rpl-nbr snapshot at 140.065 s.
- You will see
- For mote 5, relay 2 shows 310, 159 => 469; relay 3 shows 286, 249 => 535.
- Why it matters
- The columns are neighbor Rank, link metric and resulting Rank. MRHOF uses accumulated link cost plus eligibility, freshness and hysteresis rules.

Step 2 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab) Step 3
- Do
- Filter for ^-- OF:|^-- Preferred parent|^-- Rank:|^-- Hop rank increment. Check the chosen function and state at 141.065 s.
- You will see
- MRHOF reports hop-rank increment 128, parent fe80::202:2:2:2 and Rank 469.
- Why it matters
- A claimed objective function must match the running firmware. The project header compiles both supported functions and explicitly selects MRHOF.

Step 3 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab) Step 4
- Do
- Open cooja-rpl-objective-functions-of0.csc. After it stops, use the candidate filter from step 2.
- You will see
- OF0 shows relay 2: 512, 187 => 1024; relay 3: 768, 181 => 1280.
- Why it matters
- The topology, seed and 0.80 receive-success setting are held fixed. Different control behavior changes the observed link samples; this is not a promise of identical packet histories.

Step 4 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab) Step 5
- Do
- Use the state filter from step 3 in the OF0 run. Compare the selected parent and Rank with MRHOF.
- You will see
- OF0 reports increment 256 and Rank 1024, also through parent 2. Both headless runs deliver 78 requests and receive replies at all five clients.
- Why it matters
- Do not compare raw Rank numbers as a universal score across objective functions. These functions agree on the parent here; the measurements do not show a delivery winner.

Step 5 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab) Step 6
- Do
- Filter for Received ping reply, then complete the README’s prefix, Dijkstra and distance-vector trace tables, including their link-removal cases.
- You will see
- OF0’s root ping returns ttl 63 and delay 94 ms; MRHOF’s log reports 100 ms. In the separate worksheet, Dijkstra improves R3 from cost 5 to 4 via R2/R4.
- Why it matters
- Packet success checks the selected RPL path. The paper traces preserve the original algorithm exercises without pretending that this firmware runs OSPF, RIP or DSDV.

Step 6 · Contiki-NG Cooja; numbered callout added to a real capture. Enlarge screenshot (new tab)
Chapter checks
These questions refer to the chapter’s examples. Use the return links to review their answers.
A constrained mesh sends most readings upward to one gateway. Several leaf nodes can hear two relays, but one relay has a much weaker wireless link even though it is one hop closer to the root. Which design record is strongest?
Return to the chapter’s knowledge checkA node keeps switching between two parents with similar metrics, and telemetry still reaches the root most of the time. What is the strongest routing review response?
Return to the chapter’s knowledge check