Add wifi configuration using parameters and cli

Add console commands to setup wifi.
Add a parameter for choosing between STA and AP mode.
Add parameters for udp ports.
Remove WIFI_ENABLED macro.
This commit is contained in:
Oleg Kalachev
2026-01-22 22:58:43 +03:00
parent c0f3301da4
commit dd3575174b
9 changed files with 95 additions and 40 deletions

View File

@@ -7,7 +7,6 @@
#include "quaternion.h"
#include "util.h"
#define WIFI_ENABLED 1
extern float t, dt;
extern float controlRoll, controlPitch, controlYaw, controlThrottle, controlMode;
@@ -25,9 +24,7 @@ void setup() {
setupLED();
setupMotors();
setLED(true);
#if WIFI_ENABLED
setupWiFi();
#endif
setupIMU();
setupRC();
setLED(false);
@@ -42,9 +39,7 @@ void loop() {
control();
sendMotors();
handleInput();
#if WIFI_ENABLED
processMavlink();
#endif
logData();
syncParameters();
}