iot - Amazon Web Services MQTT -
i working on amazon based web services have send , receive information amazon iot , receive message there. have problem in connecting iot , can 1 me mqtt , iot. try this. may you. credentialsprovider = new cognitocachingcredentialsprovider( getapplicationcontext(), // context cognito_pool_id, // identity pool id my_region // region); region region = region.getregion(my_region); // mqtt client mqttmanager = new awsiotmqttmanager(clientid, customer_specific_endpoint); // set keepalive 10 seconds. recognize disconnects more send // mqtt pings every 10 seconds. mqttmanager.setkeepalive(10); miotandroidclient = new awsiotclient(credentialsprovider); miotandroidclient.setregion(region); try { mqttmanager.connect(clientkeystore, new awsiotmqttclientstatuscallback() { @override public void onstatuschanged(final awsiotmqttclientstatus status, ...