simon-jouet / Marlin

Optimized firmware for RepRap 3D printers based on the Arduino platform.
http://www.marlinfw.org/
GNU General Public License v3.0
22 stars 3 forks source link

ESP32S2 compiling issues #14

Open mtk11 opened 1 year ago

mtk11 commented 1 year ago

I have tried to compile the esp32s2 branch, but getting the following errors::

C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp: In function 'void timer_isr(void*)':
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp:79:45: error: 'struct timg_dev_t' has no member named 'int_st'
     uint32_t intr_status = TG[timer.group]->int_st.val;
                                             ^~~~~~
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp:94:40: error: 'struct timg_dev_t' has no member named 'int_clr'
         case TIMER_0: TG[timer.group]->int_clr.t0 = 1; break;
                                        ^~~~~~~
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp:95:40: error: 'struct timg_dev_t' has no member named 'int_clr'
         case TIMER_1: TG[timer.group]->int_clr.t1 = 1; break;
                                        ^~~~~~~
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp:105:47: error: 'volatile union timg_txconfig_reg_t' has no member named 'alarm_en'
   TG[timer.group]->hw_timer[timer.idx].config.alarm_en = TIMER_ALARM_EN;
                                               ^~~~~~~~
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp: In function 'bool HAL_timer_interrupt_enabled(uint8_t)':
C:\Marlin\Marlin-esp32s2\Marlin\src\HAL\ESP32\timers.cpp:202:27: error: 'struct timg_dev_t' has no member named 'int_ena'
   return TG[timer.group]->int_ena.val | BIT(timer_num);
                           ^~~~~~~
Multiple libraries were found for "WiFi.h"
 Used: C:\Users\User\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.5\libraries\WiFi
 Not used: C:\Program Files (x86)\Arduino\libraries\WiFi
exit status 1
Error compiling for board ESP32S2 Dev Module.

Also, any intention to port Marlin to esp32s3 ?

JoseAntonioMG commented 1 year ago

I am building this project for a controller I have designed myself with an espressif esp32-s2. I'm using both VSCode + PlatformIO and the Arduino IDE, and on both I have compile errors:

..\Marlin\src\core\serial.h:206:54: error: expected ')' before ';' token

define _SELP_1(s) SERIAL_ECHOLNPGM(s);

..\Marlin-esp32s2\Marlin\src\core\serial.h:206:54: error: expected ')' before ';' token

define _SELP_1(s) SERIAL_ECHOLNPGM(s);

..\Marlin\src\HAL\ESP32\wifi.cpp:59:66: error: expected ')' before 'WIFI_SSID' SERIAL_ECHOLNPAIR("Successfully connected to WiFi with SSID '" WIFI_SSID "', hostname: '" WIFI_HOSTNAME "', IP address: ", WiFi.localIP().toString().c_str());

..\Marlin\src\core\serial.h:207:65: error: expected ')' before ';' token

define _SELP_2(s,v) serial_echopair_PGM(PSTR(s),v); SERIAL_EOL();