move data link layer constants to constants component

This commit is contained in:
superkor
2026-01-15 19:21:18 -05:00
committed by Johnathon Slightham
parent 43fec02073
commit c4fb10c3db
6 changed files with 81 additions and 60 deletions

View File

@@ -1,20 +1,8 @@
#pragma once
#ifdef DATA_LINK
#include "freertos/FreeRTOS.h"
#include "constants/datalink.h"
#define RIP_MAX_HOPS 15 //16 or more is infinite
#define RIP_MAX_ROUTES 10 //for the demo we will use up to 10 boards in total (9 other boards will be connected = 9 rows)
#define RIP_INVALID_ROW 0
#define RIP_VALID_ROW 1
#define RIP_NEW_ROW 2
#define RIP_BROADCAST_INTERVAL 30000 //broadcast every 30 seconds (30000ms)
// #define RIP_BROADCAST_INTERVAL 3000 //temp broadcast every 3 seconds (3000ms)
#define RIP_TTL_START 180 //seconds
#define RIP_MS_TO_SEC 1000 //1000 ms to 1 sec
#define RIP_MAX_SEM_WAIT_MS 30
#define RIP_FLUSH_COUNT 8 //flush after 8*30 seconds = 240 seconds
#define RIP_DISCOVERY_MESSAGE_SIZE 1
/**
* @brief Routing data to a board
* This struct will be sent to other boards