Page 4 of 4

Re: ESP32

Posted: Fri Nov 16, 2018 10:18 am
by davidbuzz
I'm absolutely not a chibios or esp32 expert, but I have had a bit of a poke at it and done an initial ESP32 commit, copied from MSP430X as that's a known small example, and code and compiler settings modified until the toolchain can build something.

This is absolutely not gonna work on an esp32, but it's enough to prove that we have a working xtensa-esp32-elf-* toolchain that can build at least the testhal/ESP32/ESP32DOITDEVKITV1/ADC/ example, and a basic layout of folders we might be able to follow.

In short, I basically commented out all the msp430 assembler bits that aren't valid esp32 assembler, dug around on the internet for enough plausible linker bits ( from espressif's IDF for freertos or whatever ), and messed with the Makefile and headers and code in testhal/ESP32/ESP32DOITDEVKITV1/ADC/ and elsewhere till the thing compiled. I consider that a success, a very , very hacky one. :-) ... /esp32-wip

Re: ESP32

Posted: Sat Nov 24, 2018 10:10 pm
by president_skroob

I've just finished a port for ESP8266. I used code nosdk8266 as a start, more info at:

For development I've used code::blocks ide and Espressif-ESP8266-DevKit-v2.1.0-x86, so unfortunately there is no makefile at all.
Main system clock frequency is hardcoded at 80MHz and uart is at 115200.
The board that drives it is ESP-01.

Things that work:
- timer interrupt (assumption is that only timer interrupt can be used)
- led blinking
- partially printf function from on-chip rom (there is a problem with printing more chars at once, couldn't find why)
- code is executed only from ram

Things to do:
- clean up the code, refactor, to make it look more ChibiOS-like
- make "real" exceptions and interrupts handlers
- hal, serial, gpio drivers
- spi flash support for code execution
- more...

I attach example project with led blinking.


Re: ESP32

Posted: Thu Aug 01, 2019 3:25 pm
by Giovanni

I need to ask: Is there still activity going on with ESP32?


Re: ESP32

Posted: Wed Nov 27, 2019 4:31 am
by davidbuzz
hi Giovanni, my Interest was in getting ArduPilot to run on a ESP32 hardware. Fundamentally this meant either port the higher-level application and it's HAL to the different pre-existing "freertos" that already runs on the esp32 , or port the existing "chibios" rtos that ArduPilot already uses to a new cpu etc. ( what this thread discussed ).

1 - ArduPilot-ArduHAL-ChibiOS-hardware (the way ArduPilot runs on most STM32 boards, and what this thread was about )
2 - Ardupilot-ArduHAL-FreeRTOS-hardware ( what we ended up doing , because insufficient knowledge to port chibios to new architechture.)

fyi, the current code where we have the majority of ArduPilot running on esp32/freertos is here:

Re: ESP32

Posted: Wed Nov 27, 2019 4:35 am
by davidbuzz
Oh, and for the record, I'd still LOVE to see chibis on esp32, but its outside my skillset to achieve.

Re: ESP32

Posted: Mon Jan 13, 2020 1:04 am
by davidbuzz
for the record, I, and quite a few others on the internet would still love to see ChibiOS ported to esp32. :-)

Re: ESP32

Posted: Fri Jan 17, 2020 7:54 pm
by Exeland
Maybe someone will be interested in a inexpensive wifi chip w600 with cortex m3 cpu - I think it’s easier to port Chibios on it. Some sources for it here - It also has GDB debugging, it works fine with J-Link OB.

Re: ESP32

Posted: Sat Jan 18, 2020 3:06 am
by davidbuzz
I'd like to also mention that Zephyr OS from NXP (it's open and on github) runs on the esp32 now as well. A quick look at Zephyr , seems nice too.