WebREPL Password Reset

All ESP8266 boards running MicroPython.
Official boards are the Adafruit Huzzah and Feather boards.
Target audience: MicroPython users with an ESP8266 board.
Post Reply
Andriod
Posts: 4
Joined: Mon May 09, 2016 2:54 am

WebREPL Password Reset

Post by Andriod » Mon May 09, 2016 3:00 am

I seem to have mis-set/confused my ESP8266 by trying to set a password of &H8PC@4pJqTM now it won't take any password at all. How can I re-set or reinitialize the password for the poor board? Reflashing did nothing.

User avatar
deshipu
Posts: 1388
Joined: Thu May 28, 2015 5:54 pm

Re: WebREPL Password Reset

Post by deshipu » Mon May 09, 2016 9:53 am

I think you can do:

Code: Select all

import webrepl
webrepl._webrepl.password("<password>")
But mind that underscore -- it means that an internal implementation detail that's not part of the API and can change without warning.

pfalcon
Posts: 1155
Joined: Fri Feb 28, 2014 2:05 pm

Re: WebREPL Password Reset

Post by pfalcon » Mon May 09, 2016 11:13 am

The above will change password for the current session. The password is stored in port_config.py in the filesystem. Looking at that file will show current password and gives an idea how to set new (active after reboot).
Awesome MicroPython list
Pycopy - A better MicroPython https://github.com/pfalcon/micropython
MicroPython standard library for all ports and forks - https://github.com/pfalcon/micropython-lib
More up to date docs - http://pycopy.readthedocs.io/

Andriod
Posts: 4
Joined: Mon May 09, 2016 2:54 am

Re: WebREPL Password Reset

Post by Andriod » Mon May 09, 2016 3:49 pm

Can port_config be used for other initialization? What reads it and when?

pfalcon
Posts: 1155
Joined: Fri Feb 28, 2014 2:05 pm

Re: WebREPL Password Reset

Post by pfalcon » Mon May 09, 2016 4:40 pm

You can find always up-to-date answers to those questions in the source code. I can say something which tomorrow will be changed drastically. But source code will never lie.
Awesome MicroPython list
Pycopy - A better MicroPython https://github.com/pfalcon/micropython
MicroPython standard library for all ports and forks - https://github.com/pfalcon/micropython-lib
More up to date docs - http://pycopy.readthedocs.io/

Andriod
Posts: 4
Joined: Mon May 09, 2016 2:54 am

Re: WebREPL Password Reset

Post by Andriod » Mon May 09, 2016 11:22 pm

Hmm, it's dangerous to base too much on what the code does today. Is this considered a supported interface in any sense or for any purpose?

Post Reply