Using WifiUdp.h on Arduino Mega and ESP8266? I was trying to run this library on Arduino Mega, using ESP8266 as replacement of Wifi Shield, as suggested on my older thread. 

The problem is, I got error in compiling, after with this code : 

#include &lt;WiFiEsp.h&gt;
#include &lt;WiFiEspClient.h&gt;
#include &lt;WiFiEspUdp.h&gt;


#include "AppleMidi.h"
APPLEMIDI_CREATE_INSTANCE(WiFiUDP, appleMIDI1);
....



  exit status 1
  
  'WiFiUDP' was not declared in this scope


if I modified the code into this : 

#include &lt;WiFiEsp.h&gt;
#include &lt;WiFiUdp.h&gt;


#include "AppleMidi.h"
APPLEMIDI_CREATE_INSTANCE(WiFiUDP, appleMIDI1);
....


I got this error instead


  C:\Program Files
  (x86)\Arduino\libraries\WiFi\src\utility\server_drv.cpp:313:40: error:
  'WARN' was not declared in this scope

WARN("error waitResponse isDataSent");

                                    ^

  
  exit status 1


Full code here at pastebin.
I was pretty much stuck now. Please help! :(

Thanks :D
the WiFiEsp class for UDP is WiFiEspUDP

#include &lt;WiFiEsp.h&gt;
#include &lt;WiFiEspUdp.h&gt;
#include "AppleMidi.h"

APPLEMIDI_CREATE_INSTANCE(WiFiEspUDP, AppleMIDI);