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.