WiPy 2/ESP32 specs and performance

Questions and discussion about The WiPy board.
You can buy one at the store.
Target audience: Users with a WiPy.
rcolistete
Posts: 85
Joined: Thu Dec 31, 2015 3:12 pm

WiPy 2/ESP32 specs and performance

Postby rcolistete » Sun Oct 23, 2016 5:34 am

Some WiPy 2 specs and performance that it would be useful to know, theoretically and measured :
- free RAM (depends on firmware version);
- flash memory available for MicroPython user;
- WiFi speed and range in real user cases;
- Bluetooth speed and range in real user cases.

ESP32 (used by LoPy and WiPy 2) specs, theoretically and measured :
- Xtensa LX6 performance, using some MicroPyton benchmark code;
- ADC (12 bits, 16 ports, 8 channels) speed in ksamples/s;
- DAC (10 bits, 2 ports, 2 channels) speed in ksamples/s.
I've searched for ESP32 ADC and DAC performance, with no success.

Topic in Pycom forum about the same subject :
https://forum.pycom.io/topic/170/lopy-wipy-2-esp32-specs-and-performance

rcolistete
Posts: 85
Joined: Thu Dec 31, 2015 3:12 pm

Re: WiPy 2/ESP32 specs and performance

Postby rcolistete » Wed Nov 02, 2016 5:26 pm

WiPy 2.0 measured specs :
* with firmware v0.9.2.b2 (28/10/2016) : free RAM 71152 bytes; 498 KB of free internal "/flash".

Free RAM was measured with :

Code: Select all

import gc
gc.collect()
gc.mem_free()


Is there any command to measure the free internal flash space ? I've measured by uplong files and summing up the sizes.
Last edited by rcolistete on Wed Nov 09, 2016 2:14 pm, edited 1 time in total.

Lysenko
Posts: 62
Joined: Wed Aug 17, 2016 1:21 pm

Re: WiPy 2/ESP32 specs and performance

Postby Lysenko » Wed Nov 02, 2016 7:18 pm

rcolistete wrote:Some WiPy 2 specs and performance that it would be useful to know, theoretically and measured :
- free RAM (depends on firmware version);
- flash memory available for MicroPython user;
- WiFi speed and range in real user cases;
- Bluetooth speed and range in real user cases.


You realise the ESP32-IDF hasn't even hit V1.0 yet? (end of November).

WiFi and BT are not fully implemented and cannot co-exist, the ADC support wasn't integrated into the API last time I looked (probably DAC too) and a whole host of other stuff like Ethernet, CAN, I2S and so on don't work (yet).

That being the case, your second two points are impossible to address and the first two risk being meaningless because you know that more code is likely to be linked in future and the current code is sub-optimal and/or may well have debugging stuff floating around. I doubt you're going to get a valid comparison against mature platforms like STM32 or CC3xxx until Q1 next year.

User avatar
bmarkus
Posts: 106
Joined: Tue Oct 21, 2014 5:58 am

Re: WiPy 2/ESP32 specs and performance

Postby bmarkus » Thu Nov 03, 2016 7:41 am

In fact current LoPy/WiPy2 firmware is in alpha stage, even I do not cosider it being a beta release :( For example there is an old floating point bug which has nothing to do with the chip vendor but the way how MicroPython ported.

Same is for the documentation, LoRa stack is not documented, there are no official pin outs diagram, users are reverse engineering it which is strange, that the manufacturer do not publish it when selling the board, etc. OK, most of the pins can be configured freely for different functionality and the firmware do not implement these features, but there are known points, like GND and power, reset, serial, i2c, ... You can expect changes in the implementation of hw related stuff too.
Tiny Core Linux (piCore) developer
HAM radio call: HA5DI (Béla)

Lysenko
Posts: 62
Joined: Wed Aug 17, 2016 1:21 pm

Re: WiPy 2/ESP32 specs and performance

Postby Lysenko » Thu Nov 03, 2016 9:03 am

bmarkus wrote:In fact current LoPy/WiPy2 firmware is in alpha stage, even I do not cosider it being a beta release :( For example there is an old floating point bug which has nothing to do with the chip vendor but the way how MicroPython ported.

Same is for the documentation, LoRa stack is not documented, there are no official pin outs diagram, users are reverse engineering it which is strange, that the manufacturer do not publish it when selling the board, etc. OK, most of the pins can be configured freely for different functionality and the firmware do not implement these features, but there are known points, like GND and power, reset, serial, i2c, ... You can expect changes in the implementation of hw related stuff too.


If the underlying chip SDK is only at beta stage then it is pretty much inevitable that an SDK built on top of it is going to be alpha. That doesn't justify not documenting the SX1272 functions however.

GND and power are fixed, but serial, I2C and pretty much everything else is remappable via the GPIO matrix (actually matrices - there are two). There is overhead however which has the effect of halving the effective clock rate 40MHz->20MHz) which might be an issue for some SPI or other high performance use cases. Since PyCom obviously know how they wired things up and have schematics, I'm guessing they are/were allowing for the possibility of late default pin mapping changes and want to prevent stale information going into circulation.

The LoPy is an interesting device and by next March I might consider playing around with one, but for the moment it is just a "proof of principle" and that is not intended as a criticism. It is unrealistic to expect a device to be fully functional, let alone documented when the platform it is based on is still in flux and won't reach (an inevitably incomplete) V1.0 for another month.

User avatar
bmarkus
Posts: 106
Joined: Tue Oct 21, 2014 5:58 am

Re: WiPy 2/ESP32 specs and performance

Postby bmarkus » Thu Nov 03, 2016 9:46 am

Well, I hoped to use the board in a reasonable time frame for LoRa projects, but it seems to far away. I didn't expect a matured product but the current status was a surprise. It was too early to ship product in this stage. Board itself looks OK, but in lack of circiut diagram and detailed hw info there are unanswered questions like standby modes, is it possible to turn off BT or WiFi completely which are not needed for ordinary LoRa devices, what is the minimum consumption you can reach as a Class A LoRa device (can be limited by the voltage regulator), etc.

Another possibility is to forget the PyCom firmware and flash with your own. Or just to put to cupboard where the other boards are sleeping.
Tiny Core Linux (piCore) developer
HAM radio call: HA5DI (Béla)

Lysenko
Posts: 62
Joined: Wed Aug 17, 2016 1:21 pm

Re: WiPy 2/ESP32 specs and performance

Postby Lysenko » Thu Nov 03, 2016 10:36 am

bmarkus wrote:Well, I hoped to use the board in a reasonable time frame for LoRa projects, but it seems to far away. I didn't expect a matured product but the current status was a surprise. It was too early to ship product in this stage. Board itself looks OK, but in lack of circiut diagram and detailed hw info there are unanswered questions like standby modes, is it possible to turn off BT or WiFi completely which are not needed for ordinary LoRa devices, what is the minimum consumption you can reach as a Class A LoRa device (can be limited by the voltage regulator), etc.

Another possibility is to forget the PyCom firmware and flash with your own. Or just to put to cupboard where the other boards are sleeping.


If you want to develop a LoRa app 'right now' you might be better with a pyboard and something like:

http://www.multitech.co.uk/models/94557137LF

Or, if you were particularly interested in the SX1272:

https://www.cooking-hacks.com/sx1272-lo ... eo-868-mhz

That way you have a stable baseboard and firmware with no extraneous WiFi and BT. Porting to a LoPy later should be easy enough. Sleep modes are another issue PyCom can't fix btw.

User avatar
bmarkus
Posts: 106
Joined: Tue Oct 21, 2014 5:58 am

Re: WiPy 2/ESP32 specs and performance

Postby bmarkus » Thu Nov 03, 2016 10:44 am

On the device side I'm actually using Microchip RN2483 Lora modules in a tracker and dev boards connected to a PIC32 MCU (not yet running MicroPython). RN2483 is certified by the LoRa Alliance and well documented so you do not have to bother too much on the LoRa stack implementation.
Tiny Core Linux (piCore) developer
HAM radio call: HA5DI (Béla)

Lysenko
Posts: 62
Joined: Wed Aug 17, 2016 1:21 pm

Re: WiPy 2/ESP32 specs and performance

Postby Lysenko » Thu Nov 03, 2016 10:53 am

bmarkus wrote:On the device side I'm actually using Microchip RN2483 Lora modules in a tracker and dev boards connected to a PIC32 MCU (not yet running MicroPython). RN2483 is certified by the LoRa Alliance and well documented so you do not have to bother too much on the LoRa stack implementation.


Yes, I know it. Mikroelektronica "click" boards use that part. I'm in a similar position regarding PIC32 except that instead of trying to port MP to the chip I'm more interested in booting the chip out of the design (in favour of an STM32) ;)

Damien
Site Admin
Posts: 505
Joined: Mon Dec 09, 2013 5:02 pm

Re: WiPy 2/ESP32 specs and performance

Postby Damien » Mon Nov 07, 2016 12:28 pm

I now have a LoPy board and have run some basic tests to see how the ESP32 compares with the ESP8266. I'm using the latest firmware from Pycom, 0.9.3.b2.

It's hard to tell what version of uPy it is based on because the git hash doesn't correspond to anything in the main uPy repository. The time module has ticks_ms() but no other ticks_XXX functions.

micropython.mem_info() reports 80000 bytes for the GC's heap.

Running a recursive function that calls micropython.mem_info() (to get stack usage) and then itself gives about 11300 bytes of stack before there is a LoadProhibited exception and the CPU is halted (there's not even a WDT to bring it back to life, needs a hard reset).

Running a "while 1: pass" loop for more than 5 seconds causes a "Task watchdog got triggered" error and the CPU is halted (needs a hard reset).

Running pystone_lowmem.py gives a score of 402 pystones (the CPU is running at 80MHz). For comparison, esp8266 gets a score of 219 at the same frequency, and a PYBv1.0 @ 72MHz gets 734 pystones.

Running a simple bit-bang loop to toggle a pin gives 28.7kHz (esp8266 gives 10.6kHz, PYBv1.0 @ 72MHz gives 61.8kHz).

Running the uPy test suite most of the tests in tests/basics/ seem to pass but it's impossible to run the whole test suite because often it will hard-crash the board.


Return to “The WiPy”

Who is online

Users browsing this forum: No registered users and 2 guests