[Microbit-Python] Slowness as integers move beyond 256

M.-A. Lemburg mal at egenix.com
Tue Jan 5 17:41:27 EST 2016


I've been playing with MicroPython a bit and noticed a strange
behavior: integer math gets rather slow when reaching numbers
above 256.

Run the attached script as example. It produces a wave on the
LED display and runs quite nicely until the offset reaches 251.
Performance then drops to about half the speed.

-- 
Marc-Andre Lemburg
eGenix.com

Professional Python Services directly from the Experts (#1, Jan 05 2016)
>>> Python Projects, Coaching and Consulting ...  http://www.egenix.com/
>>> Python Database Interfaces ...           http://products.egenix.com/
>>> Plone/Zope Database Interfaces ...           http://zope.egenix.com/
________________________________________________________________________

::: We implement business ideas - efficiently in both time and costs :::

   eGenix.com Software, Skills and Services GmbH  Pastor-Loeh-Str.48
    D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
           Registered at Amtsgericht Duesseldorf: HRB 46611
               http://www.egenix.com/company/contact/
                      http://www.malemburg.com/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: waves.py
Type: text/x-python
Size: 800 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/microbit/attachments/20160105/78a46a90/attachment.py>


More information about the Microbit mailing list