MaterialPlane icon indicating copy to clipboard operation
MaterialPlane copied to clipboard

Cant compile Hardware with esp32 2.0.6

Open P4rziv4l99 opened this issue 2 years ago • 3 comments

Hi, I am trying to compile the software for the diy hardware for an TinyS3 board because of shortage of TinyPicos. if i am trying to compile with the esp32 module v2.0.6 i get an error for every board:

Arduino: 1.8.19 (Windows 10), Board: "UM TinyS3, Core 1, Core 1, USB-OTG (TinyUSB), Enabled, Disabled, Disabled, USB-OTG CDC (TinyUSB), Enabled, Default (3MB APP/1.5MB SPIFFS), 240MHz (WiFi), QIO, 921600, None, Disabled"

In file included from C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:1:

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.h:36:10: error: 'vector' in namespace 'std' does not name a template type

     std::vector<uint8_t> _preferred;

          ^~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.h:36:5: note: 'std::vector' is defined in header '<vector>'; did you forget to '#include <vector>'?

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.h:7:1:

+#include <vector>

 

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.h:36:5:

     std::vector<uint8_t> _preferred;

     ^~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp: In member function 'int8_t IRRecv::available()':

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:49:54: error: too few arguments to function 'void vRingbufferGetInfo(RingbufHandle_t, UBaseType_t*, UBaseType_t*, UBaseType_t*, UBaseType_t*, UBaseType_t*)'

    vRingbufferGetInfo(_rb, NULL, NULL, NULL, &waiting);

                                                      ^

In file included from C:\Users\Nhamp\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.6/tools/sdk/esp32s3/include/driver/include/driver/rmt.h:19,

                 from C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.h:6,

                 from C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:1:

C:\Users\Nhamp\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.6/tools/sdk/esp32s3/include/esp_ringbuf/include/freertos/ringbuf.h:500:6: note: declared here

 void vRingbufferGetInfo(RingbufHandle_t xRingbuffer,

      ^~~~~~~~~~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp: In member function 'uint32_t IRRecv::read(char*&, bool)':

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:142:27: error: '_preferred' was not declared in this scope

     for (uint8_t timing : _preferred) {

                           ^~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:142:27: note: suggested alternative: 'setPreferred'

     for (uint8_t timing : _preferred) {

                           ^~~~~~~~~~

                           setPreferred

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp: In member function 'bool IRRecv::inPrefVector(uint8_t)':

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:182:18: error: '_preferred' was not declared in this scope

     for (int x : _preferred) if (x == element) return true;

                  ^~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:182:18: note: suggested alternative: 'setPreferred'

     for (int x : _preferred) if (x == element) return true;

                  ^~~~~~~~~~

                  setPreferred

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp: In member function 'int IRRecv::setPreferred(const char*)':

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:189:9: error: '_preferred' was not declared in this scope

         _preferred.clear();

         ^~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:189:9: note: suggested alternative: 'setPreferred'

         _preferred.clear();

         ^~~~~~~~~~

         setPreferred

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:196:38: error: '_preferred' was not declared in this scope

         if (!inPrefVector(position)) _preferred.push_back(position);

                                      ^~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:196:38: note: suggested alternative: 'setPreferred'

         if (!inPrefVector(position)) _preferred.push_back(position);

                                      ^~~~~~~~~~

                                      setPreferred

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:197:16: error: '_preferred' was not declared in this scope

         return _preferred.size();

                ^~~~~~~~~~

C:\Users\Nhamp\Downloads\MaterialPlane_Hardware-master\MaterialPlane_Hardware-master\Sensor\src\IR32\src\IRRecv.cpp:197:16: note: suggested alternative: 'setPreferred'

         return _preferred.size();

                ^~~~~~~~~~

                setPreferred

Mehrere Bibliotheken wurden für "WiFi.h" gefunden

 Benutzt: C:\Users\Nhamp\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.6\libraries\WiFi

 Nicht benutzt: C:\Program Files (x86)\Arduino\libraries\WiFi

Mehrere Bibliotheken wurden für "ArduinoOTA.h" gefunden

 Benutzt: C:\Users\Nhamp\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.6\libraries\ArduinoOTA

 Nicht benutzt: D:\OneDrive\Documents\Arduino\libraries\ArduinoOTA

exit status 1

Fehler beim Kompilieren für das Board UM TinyS3.



Dieser Bericht wäre detaillierter, wenn die Option
"Ausführliche Ausgabe während der Kompilierung"
in Datei -> Voreinstellungen aktiviert wäre.

P4rziv4l99 avatar Jan 30 '23 17:01 P4rziv4l99

The problem is that the TinyS3 uses the ESP32-S3 microcontroller, while the DIY hardware requires a normal ESP32. One of the libraries used isn't compatible with the S3. However, since the new hardware I'm working on is running on an ESP32-S3, the next version of the firmware should also be compatible with the TinyS3.

What might work in the meantime is to remove #include "src/IR32/src/IRRecv.h" from line 28 of Sensor.ino. It is not used by the DIY hardware anyway. It is possible that new problem pop up, though.

CDeenen avatar Jan 30 '23 21:01 CDeenen

hey man, thanks for your quick responde. i got it to work with an esp32 Devkit and esp 1.0.6. just wanted to thank you for this amazing project and making it open source.

P4rziv4l99 avatar Feb 01 '23 18:02 P4rziv4l99

Happy to hear it, let me know if you run into any issues! And just to clarify: this project is not open source (at least not yet). Publishing the source code and a guide on how to make one does not mean it's open source, it's just freely accessible. For the normal user this shouldn't matter, but it means I have full control over it and nobody can take my work to use it for their own purpose or make any money off of it. I'm not sure yet of the exact license that I want to apply to it, so for now it's unlicensed (meaning I have all the rights).

CDeenen avatar Feb 01 '23 20:02 CDeenen