earlephilhower on master
Only set flashmode byte when up… (compare)
@me-no-dev: Explaining:
extern "C" {
#include "user_interface.h"
void __run_user_rf_pre_init(void) {
uint8_t ap_mac[] = AP_BSSID;
uint8_t sta_mac[] = STA_BSSID;
system_phy_set_max_tpw(TXPWR);
wifi_set_phy_mode(TXMODE);
wifi_set_macaddr(SOFTAP_IF, &ap_mac[0]);
wifi_set_macaddr(STATION_IF, &sta_mac[0]);
}
}
wifi_set_macaddr(SOFTAP_IF, &ap_mac[0]);
wifi_set_macaddr(STATION_IF, &sta_mac[0]);
If I don't, then happens this:
On the firefox JS console:
var j = new WebSocket('ws://192.168.1.1:81', ['arduino']);
undefined
Firefox no puede establecer una conexión con el servidor en ws://192.168.1.1:81/
Translated: Firefox cannot connect to the server on ws://192.168.1.1:81/
On the server: It fires the webSocketEvent
with type=WStype_CONNECTED
and then the connection closes (the server won't fire webSocketEvent
with type=WStype_DISCONNECTED
)
uint8_t ap_mac[] = {0x01, 0x23, 0x45, 0x67, 0x89, 0xAB};