Commit c8073e2
Fix multi-hop response routing by embedding path in request payload
DIRECT routing consumes the header path at each hop, so the target
node couldn't reverse it for the response. This fix:
- Embeds the forward path in the ADVERT_REQUEST payload
- Target extracts path, excludes itself (last element), and reverses
- For direct neighbors (path=[target]), response sent as zero-hop
- Works with stock firmware intermediate nodes (they only use header)
Example: path [0x23, 0x1F] → response path [0x23]
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>1 parent 9fd8910 commit c8073e2
File tree
3 files changed
+47
-28
lines changed- docs
- examples
- companion_radio
- simple_repeater
3 files changed
+47
-28
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
284 | 284 | | |
285 | 285 | | |
286 | 286 | | |
287 | | - | |
288 | | - | |
289 | | - | |
290 | | - | |
291 | | - | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
292 | 296 | | |
293 | 297 | | |
294 | 298 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1787 | 1787 | | |
1788 | 1788 | | |
1789 | 1789 | | |
1790 | | - | |
1791 | | - | |
| 1790 | + | |
| 1791 | + | |
| 1792 | + | |
1792 | 1793 | | |
1793 | 1794 | | |
1794 | 1795 | | |
1795 | 1796 | | |
| 1797 | + | |
| 1798 | + | |
1796 | 1799 | | |
1797 | 1800 | | |
1798 | 1801 | | |
1799 | 1802 | | |
1800 | 1803 | | |
1801 | 1804 | | |
1802 | 1805 | | |
1803 | | - | |
1804 | | - | |
1805 | | - | |
1806 | | - | |
1807 | | - | |
1808 | | - | |
1809 | | - | |
1810 | | - | |
| 1806 | + | |
1811 | 1807 | | |
1812 | 1808 | | |
1813 | 1809 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
727 | 727 | | |
728 | 728 | | |
729 | 729 | | |
730 | | - | |
731 | | - | |
| 730 | + | |
| 731 | + | |
732 | 732 | | |
733 | 733 | | |
734 | 734 | | |
735 | 735 | | |
736 | | - | |
737 | | - | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
738 | 739 | | |
739 | | - | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
| 745 | + | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
740 | 749 | | |
741 | 750 | | |
742 | 751 | | |
743 | 752 | | |
744 | 753 | | |
745 | 754 | | |
746 | 755 | | |
747 | | - | |
| 756 | + | |
748 | 757 | | |
749 | 758 | | |
750 | 759 | | |
| |||
800 | 809 | | |
801 | 810 | | |
802 | 811 | | |
803 | | - | |
804 | | - | |
805 | | - | |
| 812 | + | |
806 | 813 | | |
807 | 814 | | |
808 | | - | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
809 | 822 | | |
810 | 823 | | |
| 824 | + | |
811 | 825 | | |
812 | | - | |
813 | | - | |
| 826 | + | |
| 827 | + | |
814 | 828 | | |
815 | | - | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
816 | 835 | | |
817 | 836 | | |
818 | 837 | | |
| |||
0 commit comments