sparkfun / SparkFun_RTK_Firmware

Centimeter precision GPS/GNSS using L1/L2 signals broadcast over Bluetooth SPP (using the ESP32) in an easy to use enclosure.
https://docs.sparkfun.com/SparkFun_RTK_Firmware/
Other
82 stars 48 forks source link

Source compilation issue - missing SSLClientESP32 and mbedtls/net.h #782

Open semuadmin opened 21 hours ago

semuadmin commented 21 hours ago

Subject of the issue

Attempting to compile the RTK Surveyor source using the Arduino IDE in accordance with the instructions here. I get a series of missing library errors.

Your workbench

Using Arduino IDE 2.3.3 on MacOS Sequoia 15.1 (ARM64).

Steps to reproduce

  1. Open the RTK Surveyor firmware source folder in Arduino IDE.
  2. Set the ESP32 hardware configuration as specified in the 'compiling source' document.
  3. Add all libraries listed in the 'Required Libraries' section of the 'compiling source' document via the Arduino LIbrary Manager (including those only available on GitHub).

Expected behavior

Successful compilation and linking.

Actual behavior

I get the following missing library error:

/Users/semuadmin/Library/CloudStorage/Dropbox/Development/workspace_vscode/SparkFun_RTK_Firmware/Firmware/RTK_Surveyor/RTK_Surveyor.ino:83:10: fatal error: SSLClientESP32.h: No such file or directory
   83 | #include <SSLClientESP32.h> // http://librarymanager/All#SSLClientESP32
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.
exit status 1

Compilation error: SSLClientESP32.h: No such file or directory

On installing what I presume to be the missing library (https://github.com/alkonosst/SSLClientESP32), I get a further error:

In file included from /Users/semuadmin/Documents/Arduino/libraries/SSLClientESP32/src/SSLClientESP32.h:25,
                 from /Users/semuadmin/Library/CloudStorage/Dropbox/Development/workspace_vscode/SparkFun_RTK_Firmware/Firmware/RTK_Surveyor/RTK_Surveyor.ino:83:
/Users/semuadmin/Documents/Arduino/libraries/SSLClientESP32/src/ssl_lib_client.h:11:10: fatal error: mbedtls/net.h: No such file or directory
   11 | #include "mbedtls/net.h"
      |          ^~~~~~~~~~~~~~~
compilation terminated.
exit status 1

Compilation error: exit status 1

I did a quick Google but couldn't see any obvious remedy.

Are you able to advise on which specific SSL/TLS and/or related libraries I need to install to successfully compile the firmware?

As an aside, not an issue at all but has any consideration been given to porting this library to VSCode PlatformIO? Appreciate the Arduino IDE is ubiquitous, but the PlatformIO extension to VSCode has (imho) far superior editing and debugging facilities, and the dependent configuration and libraries can all be specified in a single platformio.ini file for ease of management.

nseidle commented 6 hours ago

Welcome @semuadmin! Be sure to use v2.0.2 of the ESP32 core. alkonosst's is the correct SSLClientESP32 library. Be sure your library versions match the versions listed in the compilation yaml.

has any consideration been given to porting this library to VSCode PlatformIO?

This has been discussed before. In general, we too have moved past the IDE and use the CLI extensively. PlatformIO doesn't get us anything at the moment.

gdt commented 2 hours ago

It would be nice if the README were updated so that following it was all you had to know. Even if it says to read the yaml and get that!

I'm -1 on supporting any proprietary tooling, and more than happy to have a CLI-only build process where people are expected to use whatever editor they want to edit the sources.

semuadmin commented 2 hours ago

It would be nice if the README were updated so that following it was all you had to know. Even if it says to read the yaml and get that!

I'm -1 on supporting any proprietary tooling, and more than happy to have a CLI-only build process where people are expected to use whatever editor they want to edit the sources.

I have no skin in the game at this point and am probably grossly ill-informed, but that won't stop me venturing an opinion 😏 ...

Appreciate anything that impacts the current workflow is likely to be an annoyance, but structuring the repo so that's at least compatible with VSCode/PlatformIO (i.e. .h and .cpp in a /src folder, rather than using the legacy Arduino IDE's .ino structure) - does not compel anyone to use VSCode (or any other IDE) and is, I would argue, the way C++ libraries were intended to be structured. A big plus for PlatformIO is that, as I say, it holds all the platform configuration and build deps in a single easily-digested file, which obviates (to a large extent*) the need to maintain lengthy build instructions.

I know "real (wo)men don't use GUIs" but I'm all for making life easier for us lightweights.

I'll get my coat...