connecting to MQTT gateway