there is only one such library for AT commands - WiFiEsp. but it is not made to be compatible with SAMD architecture
for example Teensy SAMD board users connect esp8266 over SPI and use WiFiSpiESP firmware and library. it is easier then with 5 V AVR boards because both boards are 3.3V, no level shifting is needed.
What is SAMD-incompatible about the WiFiEsp library? I haven't dug into the source very deeply but I can't imagine any of the code being architecture specific. The library.properties metadata claims it's compatible with all architectures.
Arduino: 1.8.5 (Windows 10), Board: "GEVINO SAM-BA bootloader"
C:\Users\x-gio\Documents\Arduino\libraries\WiFiEsp\src\utility\EspDrv.cpp: In static member function 'static int EspDrv::sendCmd(const __FlashStringHelper*, int, ...)':
C:\Users\x-gio\Documents\Arduino\libraries\WiFiEsp\src\utility\EspDrv.cpp:1020:25: error: 'va_start' was not declared in this scope
va_start (args, timeout);
^
C:\Users\x-gio\Documents\Arduino\libraries\WiFiEsp\src\utility\EspDrv.cpp:1021:56: error: 'vsnprintf_P' was not declared in this scope
vsnprintf_P (cmdBuf, CMD_BUFFER_SIZE, (char*)cmd, args);
^
C:\Users\x-gio\Documents\Arduino\libraries\WiFiEsp\src\utility\EspDrv.cpp:1022:21: error: '__gnuc_va_end' was not declared in this scope
__gnuc_va_end (args);
^
exit status 1
Error compiling for board GEVINO SAM-BA bootloader.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
pert:
What is SAMD-incompatible about the WiFiEsp library? I haven't dug into the source very deeply but I can't imagine any of the code being architecture specific. The library.properties metadata claims it's compatible with all architectures.
RingBuffer exists in SAMD core and in WiFiEsp and implementation of functions with variable arguments length are not compatible with ARM compiler
Juraj:
RingBuffer exists in SAMD core and in WiFiEsp
Since WiFiEsp uses the correct #include syntax, I don't see anything that would be problematic about that at a glance.
Juraj:
implementation of functions with variable arguments length are not compatible with ARM compiler
I noticed that from the error messages in the previous reply. I guess that needs C++11? It should be resolved by:
but there doesn't seem to be recent progress on that. It's kind of funny that the relatively modern SAMD boards are using a more outdated toolchain than the old school AVR.
// use a ring buffer to increase speed and reduce memory allocation
RingBufferW buf(8);
void setup()
{
Serial.begin(115200); // initialize serial for ESP module
SerialUSB.begin(115200); // initialize serial for debugging
WiFi.init(&Serial); // initialize ESP module