Homeyduino: unable to add device to homey

I got an Arduino MKR wifi 1010 in combination with a RS485 shield for modbus RTU control of my mechanical ventilation (itho Daalderop HRU 400). I got the Arduino on the wifi network, however I cannot add the Arduino to my Homey; I get the following errors:

and after adding the IP manually:

I can ping the of the Arduino just fine so it is connected. I did add the “Homey.begin(name);” to the setup part and “Homey.loop();” to the loop part in the Arduino code. Also tried some of the example code but that gave the same result. Anybody has an idea what is going wrong here?

Note that the homey library for Arduino’s seems to be a bid bugged when using Aruidno IDE version 2+. Had to go back to version 1.8.19 to make it compile.

Edit: found the answer in this topic/post:
https://community.homey.app/t/homeduino-setup-with-aduino-nano-33-iot-issue/62177/8?u=moer

seems you need to add:

#elif defined(ARDUINO_ARCH_SAMD)
#include <WiFiNINA.h>
#include <WiFiUdp.h>
#define CLIENT_TYPE WiFiClient
#define UDP_SERVER_TYPE WiFiUDP
#define TCP_SERVER_TYPE WiFiServer
#define UDP_TX_PACKET_MAX_SIZE 1024
#define MAXCALLBACKS 10
#define CAN_NOT_STOP_TCP

to homey.h.

First of all, welcome to the Homey Community!

To make sure you are aware of the forum rules, please read the Welcome to the forum! post here.

Please Edit your post and Add your Pictures on the forum (No Links)