Skip to content

Commit 7fb94c0

Browse files
authored
Merge pull request #655 from LeeLeahy2/wip-add
Add some routines to Network and WiFi
2 parents 0eca751 + 88a5621 commit 7fb94c0

File tree

5 files changed

+371
-5
lines changed

5 files changed

+371
-5
lines changed

Firmware/RTK_Everywhere/Developer.ino

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,10 @@ bool wifiSoftApOff(const char * fileName, uint32_t lineNumber) {return true;}
219219
bool wifiSoftApOn(const char * fileName, uint32_t lineNumber) {return false;}
220220
bool wifiStationOff(const char * fileName, uint32_t lineNumber) {return true;}
221221
bool wifiStationOn(const char * fileName, uint32_t lineNumber) {return false;}
222+
void wifiStationUpdate() {}
222223
void wifiStopAll() {}
224+
void wifiUpdateSettings() {}
225+
void wifiVerifyTables() {}
223226

224227
#endif // COMPILE_WIFI
225228

Firmware/RTK_Everywhere/Network.ino

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2461,6 +2461,26 @@ void networkUserAdd(NETCONSUMER_t consumer,
24612461
networkConsumerIndexLast[consumer] = index;
24622462
}
24632463

2464+
//----------------------------------------
2465+
// Get the network user bit mask
2466+
//----------------------------------------
2467+
NETCONSUMER_MASK_t networkUserBits(NetIndex_t index)
2468+
{
2469+
// Validate the index
2470+
networkValidateIndex(index);
2471+
2472+
// Return the consumer bits
2473+
return netIfUsers[index];
2474+
}
2475+
2476+
//----------------------------------------
2477+
// Count the number of network users
2478+
//----------------------------------------
2479+
int networkUserCount(NetIndex_t index)
2480+
{
2481+
return networkConsumerCountBits(networkUserBits(index));
2482+
}
2483+
24642484
//----------------------------------------
24652485
// Display the network interface users
24662486
//----------------------------------------

Firmware/RTK_Everywhere/RTK_Everywhere.ino

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -878,7 +878,7 @@ unsigned long loraLastIncomingSerial; // Last time a user sent a serial command.
878878

879879
// Display boot times
880880
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
881-
#define MAX_BOOT_TIME_ENTRIES 41
881+
#define MAX_BOOT_TIME_ENTRIES 42
882882
uint8_t bootTimeIndex;
883883
uint32_t bootTime[MAX_BOOT_TIME_ENTRIES];
884884
const char *bootTimeString[MAX_BOOT_TIME_ENTRIES];
@@ -1258,6 +1258,9 @@ void setup()
12581258
DMW_b("beginIdleTasks");
12591259
beginIdleTasks(); // Requires settings. Enable processor load calculations
12601260

1261+
DMW_b("wifiUpdateSettings");
1262+
wifiUpdateSettings();
1263+
12611264
DMW_b("networkBegin");
12621265
networkBegin();
12631266

0 commit comments

Comments
 (0)