Hello,
I am working with the photon and trying to send my data to an mqtt broker on amazon ec2. I am running into the following error:
/workspace/lib/MQTT/src/MQTT.cpp:83:18: error: ambiguous overload for ‘operator=’ (operand types are ‘String’ and ‘int’)
this->domain = NULL;
I have only imported the MQTT.h library and added #include <MQTT.h> into my .ino file in the Particle WebIDE. Is this due to some issue with the mqtt.h library? How can I fix it?
Hope to receive an answer soon. Thanks.
I think you just found a “bug” introduced with 0.6.2 (@tylercpeacock) 
Since this error only occures when building against 0.6.2 (including RCs) but not against 0.6.0 or 0.6.1 this must have been introduced just recently by the system update.
2 Likes
Thanks for pointing this out and filing the GitHub issue. It’s definitely a new bug that needs ironing out.
1 Like
I also run into this error because I’m using MQTT library as well and I’m currently blocked by this. I develop local and use Particle CLI to compile and flash the Photon’s.
Is there any way to tell the CLI to use 6.1 firmware for compilation?
Yes. On the WebIDE, just click on devices, then click on the device you want. You will get the drop down menu for the System Firmware Target. Just select 0.6.1 and then verify and flash. Worked for me yesterday.
Thanks to ScruffR and tylercpeacock for the quick replies 
Ah, you develop locally with CLI…soory, just saw that…am sure you will get an answer soon
You’d use this syntax
particle compile <platform> . --target 0.6.1
Thx @ScruffR that works. I should check documentation for updates more often 
1 Like