New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade ESP32 to esp-idf v3.0 #1387
Comments
BLE update: #1208 |
sdkconfig reference: Status of Bluetooth for ESP32 modified: targets/esp32/docs/Bluetooth/sdkconfig Modified files: toolchain: http://esp-idf.readthedocs.io/en/latest/get-started/linux-setup.html https://dl.espressif.com/dl/xtensa-esp32-elf-linux64-1.22.0-80-g6c4433a-5.2.0.tar.gz |
Current state of play:
@jumjum123 I have used your sdkconfig. I reduced jsvars from 5000 to 3000 and now it boots. now getting:
So it looks like you need to have a different sdk base firmware for with and without SPI RAM ? |
Hey, great. You've done a lot of things. My time is a bit limited this weekend. I'm not at home, |
Just checked the SPI RAM Option, it is : |
Actually I worked on implementation of BLE UART. During that, a windows problem came up. Looks like Windows expects bonding and security.
|
Ok. I'm still struggling to get a build working - I'm getting a compiled .bin, but it still has the psram config. I'm trying a fresh build but not winning at this stage. |
I think we need some thought around the partition table layout. It would be great not to move the js-code address, but I understand the firmware is larger. We also need to consider more than 4mb flash, such as 8mb and 16mb in the future. It's disappointing that the 3.0 firmware takes up more ram - has this been explained? It would be good to allow for ota updates at a later date. The 1mb size for the flashfs file system is arbitrary- that could get smaller too. |
I visited the guys from Espressif at a fair in Nürnberg. |
Finally have a working build with 4000 vars (no BT at this stage):
Next step is to get build tools updated so that this can be replicated in Travis |
How I love these minor surprises :-( |
Oh, this minor surprise happend 1 day after release. |
I have got a build working and pushed the code to the V3.0 branch: https://github.com/espruino/Espruino/compare/ESP32-v3.0 I want to check that the build is stable. There is an issue we need to resolve regarding the fileno > 32 - I'll need to ask Gordon about how to solve this properly. |
Can we stick to just using the 3.0 release for now and not stay with the bleeding edge? Can we look a thing adding psram support later? I have got Travis build using the new compiler and linking against 3.0. If I find the firmware build file and travis and then test that on an actual device, and post it on the forum for others to test. If ok, next steps are changing the partition table and jscode area. I also think there should be a BLE flag in the board.py so that we can do a build without Bluetooth - give people the option. |
I agree to use 3.0 release from now on. Anything else seems not to be reliable. There are already some major changes in structure of master, only one day after release. A flag for BLE already exists, its USE_BLUETOOTH. Its used for NRF and ESP32. Based on your success, I'm unsure what to do now. Should I work on ESP32 branch, and wait until you moved BLE parts from ESP32 to ESP32V3.0 ? |
@jumjum123 The build I made only has 4 sockets and the previous 2.1 build had 10, so I'm trying to sort that out. At the moment the tgz files for esp-Idf.tgz and app.tgz are a bit of a mess. The libs are all separate folders and there seems to be different levels, so for the build tools it would be much simpler if all of the lib files were in one folder. The Makefile would be greatly simplified, as Paths for the different levels would not have to be added. I don't want to break your build, so I'll try to keep it compatible and we can sort this properly later. Need still need to agree on the js_code addressin the flash and the size. I'm coming around to your idea of just under the 3mb mark. If you could get your build working with the current v3.0, and the Bluetooth flag, and then update the esp32 branch. Then when I get the core stable, I can then see if I can get a build using Bluetooth esp32 branch and the build tools. Then we can make the decision on one or two board files. The esp8266 has a smaller firmware, and a special 4mb build. It does not create a lot More to maintain as the board file contains the differences and sets the flags, and there would be conditional code based on the use_bluetooth flag. |
@wilberforce Feedback from Espruino to missing option for SPIRAM was (translated to my understanding) "may be this will be implemented into next version" Comin back to Bluetooth, right now, the best plan I see is, to take your ESP-V3.0 brach and add bluetooth step by step. I'm pretty sure, we have to forget support for windows 10 and may be uart. |
Sound goods. Let's out psram aside. Windows 10 web Bluetooth is still not working- it is the reason I have 2 pucks and have done nothing with them! Well keep chipping away and we'll get there eventually! |
I got WIndows 10 and Bluetooth running only with SMP (security module). Iram overflow based on too much jsvars ? Hmm this should not happen, since jsvars are created with malloc during runtime on ESP32. At least in my version. Had a short talk with Gordon, how to open the 3rd option for jsvars (malloc). He agreed to add the option for malloc. |
Sorry - I was confusing with the compile time error - I think you are taking about a runtime error? |
@wilberforce |
progress stopped - my main conputer won't boot WSL ubuntu after upgrade.... |
|
@wilberforce, you can continue to use WSL by rolling back to any build before 17655, as a temporary workaround until they fix it for good. |
We have been using the debug versions of esp_idf libs, which are much bigger! In the
|
@wilberforce, very good point !! |
This is using the flag in the espruino compile? Was debug off in the sdkconfig when you complied the esp-idf libs - as this has a much bigger impact on the the code size? |
I'm at the point were I'm trying to do a pull of the ESP32 branch to compile. I'm getting the error regarding the bluettooth gatt include files have moved. |
@wilberforce I will upload my sources today. During my changes, I always jump into the same trap. Anyway, at least GAP, GATTC and GATTS should work. |
@jumjum123 There are 3 settings:
The last one assertions - that generates a whole heap of strings. |
Just pushed my sources to ESP32 branch. Now have to do some homework(ironwork), but will take a look to this from time to time. |
quickly checked the size with ASSERTIONS not enabled and now its 1108KB |
Is this good to close? I know |
https://github.com/espressif/esp-idf/releases/tag/v3.0
Moving to ESP-IDF release 3.0, and some Bluetooth, and ....
http://forum.espruino.com/conversations/319948/
Status of Bluetooth for ESP32
http://forum.espruino.com/conversations/311436/
later:
Changes to sort out
Espruino/targets/esp32/jshardware.c
Line 730 in 028b592
The text was updated successfully, but these errors were encountered: