Marauder compiles and installs for ESP32-C5

This commit is contained in:
Just Call Me Koko
2025-07-10 11:20:50 -04:00
parent d61542eb5f
commit 9a25224c83
7 changed files with 173 additions and 113 deletions

View File

@@ -7129,10 +7129,19 @@ void WiFiScan::changeChannel()
// Function to cycle to the next channel
void WiFiScan::channelHop()
{
this->set_channel = this->set_channel + 1;
if (this->set_channel > 14) {
this->set_channel = 1;
}
#ifndef HAS_DUAL_BAND
this->set_channel = this->set_channel + 1;
if (this->set_channel > 14) {
this->set_channel = 1;
}
#else
this->set_channel = this->dual_band_channels[this->dual_band_channel_index];
if (this->dual_band_channel_index >= DUAL_BAND_CHANNELS)
this->dual_band_channel_index = 0;
else
this->dual_band_channel_index++;
#endif
esp_wifi_set_channel(this->set_channel, WIFI_SECOND_CHAN_NONE);
delay(1);
}
@@ -7458,7 +7467,7 @@ void WiFiScan::main(uint32_t currentTime)
(currentScanMode == WIFI_SCAN_STATION_WAR_DRIVE) ||
(currentScanMode == WIFI_SCAN_ALL))
{
if (currentTime - initTime >= this->channel_hop_delay * 1000)
if (currentTime - initTime >= this->channel_hop_delay * HOP_DELAY)
{
initTime = millis();
channelHop();