Skip to content

Library will not compile on any newer ESP32 board: C3, S2, S3 #49

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

Open
scottchiefbaker opened this issue Apr 3, 2025 · 8 comments
Open
Assignees

Comments

@scottchiefbaker
Copy link

When I load the first example "BasicReadings" and attempt to compile on an ESP32-C3, ESP32-S2, or ESP32-S3 I get a compiler error:

c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp: In member function 'sfTkError_t sfTkArdUART::init(uint32_t, bool)':
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:53:20: error: no matching function for call to 'sfTkArdUART::init(USBCDC&, uint32_t&, bool&)'
   53 |         return init(Serial, baudRate, bInit);
      |                ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:25:13: note: candidate: 'sfTkError_t sfTkArdUART::init(HardwareSerial&, sfTkIUART::UARTConfig_t&, bool)'
   25 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, sfTkIUART::UARTConfig_t &config, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:25:47: note:   no known conversion for argument 1 from 'USBCDC' to 'HardwareSerial&'
   25 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, sfTkIUART::UARTConfig_t &config, bool bInit)
      |                               ~~~~~~~~~~~~~~~~^~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:37:13: note: candidate: 'sfTkError_t sfTkArdUART::init(HardwareSerial&, uint32_t, bool)'
   37 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, uint32_t baudRate, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:37:47: note:   no known conversion for argument 1 from 'USBCDC' to 'HardwareSerial&'
   37 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, uint32_t baudRate, bool bInit)
      |                               ~~~~~~~~~~~~~~~~^~~~~~~~
In file included from c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:19:
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:107:17: note: candidate: 'sfTkError_t sfTkArdUART::init()'
  107 |     sfTkError_t init(void);
      |                 ^~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:107:17: note:   candidate expects 0 arguments, 3 provided
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:49:13: note: candidate: 'sfTkError_t sfTkArdUART::init(uint32_t, bool)'
   49 | sfTkError_t sfTkArdUART::init(uint32_t baudRate, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:49:13: note:   candidate expects 2 arguments, 3 provided
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:121:17: note: candidate: 'sfTkError_t sfTkArdUART::init(sfTkIUART::UARTConfig_t, bool)'
  121 |     sfTkError_t init(UARTConfig_t config, bool bInit = false);
      |                 ^~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:121:17: note:   candidate expects 2 arguments, 3 provided
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp: In member function 'sfTkError_t sfTkArdUART::init(sfTkIUART::UARTConfig_t, bool)':
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:63:20: error: no matching function for call to 'sfTkArdUART::init(USBCDC&, sfTkIUART::UARTConfig_t&, bool&)'
   63 |         return init(Serial, config, bInit);
      |                ~~~~^~~~~~~~~~~~~~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:25:13: note: candidate: 'sfTkError_t sfTkArdUART::init(HardwareSerial&, sfTkIUART::UARTConfig_t&, bool)'
   25 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, sfTkIUART::UARTConfig_t &config, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:25:47: note:   no known conversion for argument 1 from 'USBCDC' to 'HardwareSerial&'
   25 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, sfTkIUART::UARTConfig_t &config, bool bInit)
      |                               ~~~~~~~~~~~~~~~~^~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:37:13: note: candidate: 'sfTkError_t sfTkArdUART::init(HardwareSerial&, uint32_t, bool)'
   37 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, uint32_t baudRate, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:37:47: note:   no known conversion for argument 1 from 'USBCDC' to 'HardwareSerial&'
   37 | sfTkError_t sfTkArdUART::init(HardwareSerial &hwSerial, uint32_t baudRate, bool bInit)
      |                               ~~~~~~~~~~~~~~~~^~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:107:17: note: candidate: 'sfTkError_t sfTkArdUART::init()'
  107 |     sfTkError_t init(void);
      |                 ^~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.h:107:17: note:   candidate expects 0 arguments, 3 provided
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:49:13: note: candidate: 'sfTkError_t sfTkArdUART::init(uint32_t, bool)'
   49 | sfTkError_t sfTkArdUART::init(uint32_t baudRate, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:49:13: note:   candidate expects 2 arguments, 3 provided
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:59:13: note: candidate: 'sfTkError_t sfTkArdUART::init(sfTkIUART::UARTConfig_t, bool)'
   59 | sfTkError_t sfTkArdUART::init(sfTkIUART::UARTConfig_t config, bool bInit)
      |             ^~~~~~~~~~~
c:\Users\scott\Documents\Arduino\libraries\SparkFun_Toolkit\src\sfTkArdUART.cpp:59:13: note:   candidate expects 2 arguments, 3 provided

exit status 1

Compilation error: exit status 1

If I switch the board to a vanilla ESP32 or an OG Arduino Uno it compiles just fine.

Steps to recreate:

  1. Set your board to any of the mentioned ESP32 variants
  2. Load the Example1_BasicReadings.ino example script
  3. Attempt to compile
@scottchiefbaker
Copy link
Author

scottchiefbaker commented Apr 3, 2025

Confirmed working boards (non-exhaustive list): Arduino Uno, Vanilla ESP32, ESP8266

@sfe-SparkFro sfe-SparkFro transferred this issue from sparkfun/SparkFun_Qwiic_OTOS_Arduino_Library Apr 3, 2025
@sfe-SparkFro
Copy link
Contributor

@SFE-Brudnerd @gigapod Toolkit doesn't compile on some boards with new UART stuff, please take a look. Thanks!

@scottchiefbaker Sorry about this! In the Arduino library manager, please downgrade the SparkFun Toolkit Library to v1.0.0, that should hopefully resolve this. Thanks for reporting!

@gigapod
Copy link
Member

gigapod commented Apr 3, 2025

A hot-fix is in the works - our test validation missed the ESP32-C6. Expect a fix later today.

-Kirk

@scottchiefbaker
Copy link
Author

Wow... now that's what I call service. I wish I could get this sort of response from my paid vendors. OSS for-the-win.

Let me know where there is a test version available and I'll do some testing tonight when I'm home.

@nbelakovski
Copy link

nbelakovski commented Apr 4, 2025

I just ran into this today and I'm like 'ugh, I'm gonna have to go find the UART code and comment it out and hope that's it' and I was so pleased to find this thread with answers from literally hours ago at the time of writing this comment. Downgrading to 1.0.0 got me going again, thanks!

@gigapod
Copy link
Member

gigapod commented Apr 4, 2025

Hi All -

We have pulled the ToolKit v1.1.0 release and Arduino is in the process of removing it from their library index. This might take a day or so is my understanding (it's a manual process).

As noted above - the quick solution is to downgrade to version 1.0.0 of the SparkFun Toolkit library.

Going forward we'll improve our test coverage to catch compile issues like this.

-Kirk

@SFE-Brudnerd
Copy link
Member

arduino/library-registry#6167

v1.1.0 has been removed from the library registry. We are still working to resolve the issue with the UART capabilities.

@scottchiefbaker
Copy link
Author

Thanks for checking on this for me. Looking forward to trying it on my ESP32-C3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants