ESP8285 can't use ap_if.config "can't set AP config"
i did the following
import network
ap_if = network.WLAN(network.AP_IF)
ap_if.active(False)
ap_if.config(essid="someID", password="somePassword")
but i always get "can't set AP config", no matter what parameter i try to use
MicroPython v1.9.4-8-ga9a3caad0 on 2018-05-11; ESP module with ESP8266
flashed on an plain ES8285 Module
listdir is also doing funky stuff on this module, getting a crap ton of " '\x00\x00\x00\x00\x00\x00\x00\x00.\x00\x00\x00'," as answer + the folders and file that icreated for a test
esp8266/modnetwork.c: fix wifi set mac address
Changing MAC address of STA or AP wifi interfaces always raise a ValueError: invalid buffer length
>>> network.WLAN(network.AP_IF).config(mac=b'\0bbbbb')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ValueError: invalid buffer length
This is because code try to use the key 'mac' as the address instead of the value.
Also a flag (set_config) is used not to set wifi config in case only MAC address is changed to avoid a "can't set STA/AP config" error.