![]() |
TLS v1.2 (was: cm1102 - Custom http invoke error) - Printable Version +- vThings Forums (http://forum.vair-monitor.com) +-- Forum: vThings (http://forum.vair-monitor.com/forumdisplay.php?fid=1) +--- Forum: vAir Monitor (CO2, Dust, Tempereature, etc..) (http://forum.vair-monitor.com/forumdisplay.php?fid=2) +--- Thread: TLS v1.2 (was: cm1102 - Custom http invoke error) (/showthread.php?tid=24) |
TLS v1.2 (was: cm1102 - Custom http invoke error) - johan - 11-06-2016 I received my cm1102 today. Connecting & configuring the device went perfect. However, it refuses to send the custom http requests. I enabled the debug mode but still I don't get any details about why the request failed. If I copy & paste the URL in the browser it works fine. The log data: CustomHTTPDest::process CustomHTTPDest::invoke = https://miehat-functions.azurewebsites.net/api/HttpTriggerCSharp2?co2=%CO2%&temp=21.78&hum=45.45&pres=999.13 Error Code: -1 = connection refused Failed SerialDumpDest::process Any ideas what might go wrong here? SSL / certificate issues? RE: cm1102 - Custom http invoke error - admin - 11-06-2016 Aahhh.. thank you for testing with Azure, i also had plans to test how it works, but sadly - not enough time! It fails because it uses TLS v1.2 which is supported by a newer version of the WiFi module firmware that i use. I've delayed moving to it for a few months as i had some trouble with my build environment - but apparently - now it is time. I would appreciate it if you can wait for a couple of days, as i need to setup the build and then do a couple of tests - whether some regressions are introduced RE: TLS v1.2 (was: cm1102 - Custom http invoke error) - johan - 11-06-2016 Sure, no rush at all. My other challenge will be getting the data to my Vera home automation gateway, so i'll work on that first :-) I'll be happy to test new firmware, once you've had time to update the module. The Azure endpoint I created is an 'Azure Function'. Another logical endpoint would be an Azure Logic App, those unfortunately only support HTTP POST. In case you someday have a need/wish to add POST support; a sample endpoint would be: https://prod-06.westeurope.logic.azure.com:443/workflows/a4d86723f5a241f08d040ae162a3b193/triggers/manual/run?api-version=2016-06-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=14BMuc9xL-2Z4b28a_YnMHHEAYUxW40pJvVP7PHXD_Q In a logic app you define a json schema for the data, the endpoint above expects the following body: { "co2": 701.34, "temp": 24.53, "hum": 44.43, "pres": 999 } Then there are several other Azure endpoints, depending on the scenario. The thing I like about the 'Azure Function' is that it allows me to accept the data from the device and store it in 'Azure table storage' with just a few lines of code: Code: #r "Microsoft.WindowsAzure.Storage" RE: TLS v1.2 (was: cm1102 - Custom http invoke error) - Vladimir Savchenko - 11-06-2016 interesting... I will spend some time to research this and about vera.. google about esp8266 and vera.. looks like some people haf success.. ive looked into this some time ago but honestly lately when I was checking about all typical home automation systems I forgot about it RE: TLS v1.2 (was: cm1102 - Custom http invoke error) - admin - 11-15-2016 I spent some few hours trying to make this run, but unfortunately unsuccessfully. Apparently some other people have succeeded (or at least it looks like this), so i will need to dig a bit deeper to see what they have done ![]() |