Open sreejithshaji opened 1 year ago
This usually happens when you have connected it to a WiFi and it has been made to change channel after the library has initialised. Have you connected it to an AP?
This is definitely something the library handles poorly and I should make it check for.
can you please provide something about how to run this program like, is this RTC server important and all ??
This usually happens when you have connected it to a WiFi and it has been made to change channel after the library has initialised. Have you connected it to an AP?
This is definitely something the library handles poorly and I should make it check for.
I could solve the channel selection by forching wifi to reset in the setup():
WiFi.mode (WIFI_MODE_STA); WiFi.disconnect (false, true);
if(m2mMesh.begin()) { Serial.print("\n\nMesh started on channel:"); //m2mMesh. Serial.println(WiFi.channel()); }
Now I can change the default channel 1 with this:
void setup() {
Serial.begin(115200);
//////// WiFi.mode (WIFI_MODE_STA); WiFi.disconnect (false, true); //force channel 2 uint8_t channel = 2; esp_wifi_set_promiscuous(true); esp_wifi_set_channel(channel, WIFI_SECOND_CHAN_NONE); esp_wifi_set_promiscuous(false); //////
if(m2mMesh.begin(99,channel)) { Serial.print("\n\nMesh started on channel:"); //m2mMesh. Serial.println(WiFi.channel()); } else { Serial.println("\n\nMesh failed to start"); } }
serial prints Peer channel is not equal to the home channel, send fail! esp32