With an Arduino UNO and an Ethernet shield I wrote several applications to connect to a MQTT broker (3.1.1) using the knolleary pubsubclient library, all works fine!
Now I would like to compile ESPEASY using the same IDE (1.6.5) but got compilation problems because of the pubsubclient used in ESPEASY is different then the one I used before.
Is there a way to have both libraries installed while the compiler uses the correct library ?
A solution might be to place the library in the same directory where the sketch is stored, this way you could also use different versions of same libraries with different sketches.
bennyb:
A solution might be to place the library in the same directory where the sketch is stored, this way you could also use different versions of same libraries with different sketches.
Yes that will work. Just change the includes to something like:
#include "PubSubClient/PubSubClient.h"
bennyb:
Or are better solutions available?
You could also change the name of one of the libraries. That would probably be the better option if you wanted to use the library in multiple sketches.