Page 9 of 10

Re: MicroPython on ESP8266 Kickstarter

Posted: Thu Mar 03, 2016 3:39 pm
by kfricke
Yes, Damien said that the ESP port will fully support floating point.

Re: MicroPython on ESP8266 Kickstarter

Posted: Thu Mar 03, 2016 3:44 pm
by mad474
kobertkirk wrote:When can we expect floating point operations to be added?
I've seen appropriate commits on github, last one yesterday. : https://github.com/micropython/micropyt ... its/master
Didn't run any tests though. Still fiddling with the toolchain.

Re: MicroPython on ESP8266 Kickstarter

Posted: Thu Mar 03, 2016 4:29 pm
by pfalcon
Guys, I'd like to remind that the official release is in 2 months, so that's the best answer to questions "when feature X will be available" (of core features, stretch-goal features will take more time after that).

With that reminded, we started to spool source code to the master branch - while, as KS updates says, taking a chance to refactor and clean up it. To give you an idea, UART REPL handling went thru 3 incarnations. The original socket module is one I quickly put up 1 year ago (sic!) to test my idea of how to have BSD-compatible sockets on top of lwIP (without bringing in a full-fledged RTOS). I then spent quite a time discussing this idea with other ESP8266 hackers inviting them to see where my reasoning is wrong and why it can't work, but nobody was interested. I'm grateful to GalenHZ who accepted the challenge and developed fully independent implementation based on these ideas, to prove its viability. Well, we started with my module still as known-working, and then gradually switched to GalenHZ's modlwip, discovered and fixed bunch of issues with it and added more features (few fixes are already in the mainline, as it's a chore to keep them in a separate branch). Do we need 3 REPLs and 2 socket modules? Apparently no. When someone submits questionable code, I'm the first to suggest: "This code looks like one we can add, and then soon remove again, then why, please do it right". Then the only choice is to apply the same treatment to our own code, and uphold the high testimonies MicroPython already received for its code quality.

Another point - new ESP8266 port depends on other components, first of all esp-open-sdk. There're bunch of changes to do to it too to make port easily buildable (while we just did multi-step manual setup, which for sure will be error-prone to many people). I've just added https://github.com/pfalcon/esp-open-lwip as a submodule to esp-open-sdk, yet need to integrate it completely into build process. And over last month, there was already bunch of changes to it, so if you didn't rebuild for awhile, I suggest you rebuild it from scratch (make clean; make). Then be ready to rebuild it again as it progresses.

But again, source is getting there. If you posses required skills, we welcome you to build, run, test it. Automated testsuite support is one of the biggest change the project brings - now we know that there're not just features, but that they actually work (or will work soon; or eventually). Floating points support works great for us, with small caveat - there's slightly less precision than on PyBoard, to accommodate less memory and lack of HW FP on ESP8266. Try it ;-)

Re: MicroPython on ESP8266 Kickstarter

Posted: Thu Mar 03, 2016 5:02 pm
by cpr
Hi!

Just registered as a backer, and want to say that I will patiently :mrgreen: await the outcome!

Re: MicroPython on ESP8266 Kickstarter

Posted: Sat Mar 05, 2016 11:07 am
by mad474
pfalcon wrote:Try it ;-)
Done! Running
MicroPython v1.6-136-g98b727c on 2016-03-05; ESP module with ESP8266
on an "old" ESP8266 ESP-01.
Image
https://youtu.be/tlZ4FiQR5U0

You guys really rock! Thanks!

Re: MicroPython on ESP8266 Kickstarter

Posted: Sat Mar 05, 2016 12:40 pm
by andreagrandi
mad474 wrote:
pfalcon wrote:Try it ;-)
Done! Running
MicroPython v1.6-136-g98b727c on 2016-03-05; ESP module with ESP8266
on an "old" ESP8266 ESP-01.
Image
https://youtu.be/tlZ4FiQR5U0

You guys really rock! Thanks!
out of curiosity, did you use OSX or Linux to build the stuff? I tried yesterday with OSX but I struggled compiling the toolchain and I gave up.

Re: MicroPython on ESP8266 Kickstarter

Posted: Sat Mar 05, 2016 2:02 pm
by Frida

Code: Select all

MicroPython v1.6-128-g5788499 on 2016-03-05; ESP module with ESP8266
Type "help()" for more information.
>>> 2+4
6
>>> help()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name not defined
>>> import pyb
>>> pyb
<module 'pyb'>
>>> dir(pyb)
['__name__', 'info', 'freq', 'millis', 'elapsed_millis', 'micros', 'elapsed_micros', 'delay', 'udelay', 'sync', 'hard_reset', 'Pin', 'ADC', 'RTC']
>>> help(pyb)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name not defined
>>> 
First download on a esp8266-01 today.
Downloaded on linux and compile without problems.

Re: MicroPython on ESP8266 Kickstarter

Posted: Sun Apr 17, 2016 5:58 pm
by electronicsguy
Frida wrote:

Code: Select all

MicroPython v1.6-128-g5788499 on 2016-03-05; ESP module with ESP8266
Type "help()" for more information.
>>> help()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name not defined
>>> 
First download on a esp8266-01 today.
Downloaded on linux and compile without problems.
I have the same problem as frida. Downloaded the pre-compiled firmware from Adafruit and flashed it onto ESP-01. NameError as above, for any command.

Re: MicroPython on ESP8266 Kickstarter

Posted: Sun Apr 17, 2016 7:57 pm
by Frida
@electronicsguy
I'm using the one from github, and not that one from Adafruit.
If you look, it can 2+4=6, it was only the help that is not working yet.
Wait till they are ready to release the first version to the public, or try to compile it for you selv.

Re: MicroPython on ESP8266 Kickstarter

Posted: Fri Apr 22, 2016 3:44 pm
by marfis
So the Alpha4 has been released, thanks!

Unfortunately, on my machine webrepl doesn't seem to work (whereas V3 did). I erased flash before updating, just to make sure but with the same results. I'm on Adafruit's Huzzah Board.

Here is the traceback from a example session:

Code: Select all

>>> import webrepl as w
>>> w.start()
WebREPL daemon started on 192.168.4.1:8266
>>>  # I refresh the browser window here
WebREPL connection from: ('192.168.4.2', 52279)
NLR jump failed

 ets Jan  8 2013,rst cause:2, boot mode:(3,0)

load 0x40100000, len 30596, room 16 
tail 4
chksum 0x8b
load 0x3ffe8000, len 980, room 4 
tail 0
chksum 0x5f
load 0x3ffe83e0, len 2652, room 8 
tail 4
chksum 0x9c
csum 0x9c
␎␌␌l��|��␒rrnb��␌l��␂␌b�l␌b쌜���l�r�␌b␌�lrldon't use rtc mem data
␎l␌l��|��␒rrnb��ll��␌�b�␌b쌜��␂␂�␂␌b�␌�lrl␎�␌l��|��␒rrnb��l␌���pp␌�␌␌b쌜��␂�␌�␌b�lb␎lrl��rl���b␌l�br|�␌b␌ll␌��␜�lb��n�␒nn�␐␂␌␂�l�|␂�l␌�␌l��l�␞���␞��l`␂�␂n�␀���b␌␌�␌�b␌␂␂���b␌l�b�␎lrlr�n��␀�␌��n����␂bp␂b�����␌�␞␐b���|�␌��lrl␂��␂ln�prl␎�␌l��could not open file 'boot.py' for reading
could not open file 'main.py' for reading

#4 ets_task(401002a8, 3, 3fff5148, 4)
MicroPython v1.7-205-gb69d1fc on 2016-04-22; ESP module with ESP8266
Type "help()" for more information.
ideas?