I recently bought an Arduino MKR WiFI 1010 and run it successfully in the Arduino environment. Now I created an Atmel Studio (V7.02542) project from the Arduino sketch.
here I noticed that neither the core nor the project compile correctly. Main errors are:
strlen' was not declared in this scope ArduinoCore D:\Atmel Studio Projects\Sketch_Projects\MKR_WiFI_1010_Projects\SketchTest\SketchTest\ArduinoCore\include\core\api\Print.h
'memcpy' was not declared in this scope ArduinoCore D:\Atmel Studio Projects\Sketch_Projects\MKR_WiFI_1010_Projects\SketchTest\SketchTest\ArduinoCore\src\core\api\IPAddress.cpp 45
Standard and autogenerated compiler settings seem to be OK for the SAMD-device:
-mthumb -D__SAMD21G18A__ -DDEBUG -DF_CPU=48000000L -DARDUINO=108013 -DARDUINO_SAMD_MKRWIFI1010 -DARDUINO_ARCH_SAMD -DUSB_VID=0x2341 -DUSB_PID=0x8054 -DUSB_PRODUCT="\"Arduino MKR WiFi 1010\"" -DUSB_MANUFACTURER="\"Arduino LLC\"" -DUSBCON -I"C:\Program Files (x86)\Atmel\Studio\7.0\Packs\arm\CMSIS\5.4.0\CMSIS\Core\Include" -I"C:\Program Files (x86)\Atmel\Studio\7.0\Packs\atmel\SAMD21_DFP\1.3.395\samd21a\include" -I"..\include\core" -I"..\include\core\api" -I"..\include\core\api\deprecated" -I"..\include\core\api\deprecated-avr-comp\avr" -I"..\include\core\USB" -I"..\include\variants" -I"..\include\core\samd21" -I"..\include\core\samd21\include" -I"..\include\core\samd21\include\component" -I"..\include\core\samd21\include\instance" -I"..\include\core\samd21\include\pio" -Os -fno-threadsafe-statics -fno-exceptions -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -g3 -w -mcpu=cortex-m0plus -c -std=gnu++11 --param max-inline-insns-single=500 -nostdlib -MD -MP -MF "$(@:%.o=%.d)" -MT"$(@:%.o=%.d)" -MT"$(@:%.o=%.o)"
I already tried to include standard C/C++ libraries as <stdlib.h>, <string.h> or <cstring.h> The all make the problem worse!
Thanks in advance for your help
JR