Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Really simple CML driver questions
Of course - bit of brain fade there. Dont do this often enough that I forget more and more
Mykel Koblenz
Illawarra Smart Home
Reply
I have just compiled my driver with no errors but its doing something really strange that I can't figure out why.

I start the driver "Go" and it starts as it should, enters the start method and ten executes Simulate().

This takes me to the InitlaizeOther method where the local are all established and it gets the  four values provided in the manifest.  There are still some other things to do in this method but instead of continuing on it goes back to the Start method and returns a 0 and completes.

I checked against another similar known working driver and everything looks like its right but the other driver works and this one doesn't.

I've attached it here.  This one has me totally stumped.


Attached Files
.zip   Prowl.zip (Size: 5.52 KB / Downloads: 1)
Mykel Koblenz
Illawarra Smart Home
Reply
Generally that means it's throwing an exception in InitializeOther(), which you aren't catching. So actually it had ended due to the exception. and the next go just restarted it. Right click on the editor and select the option for reporting exceptions at the point where they are thrown. And also generally you want to put a Try/Catch around the whole InitializeOther contents, log something there that indicates that that method failed and including the exception text, and then return a failure status. If you don't catch the exception, it propagates back to the base class which (in the normal course of events) would just try again next time to get the driver to load.
Dean Roddey
Software Geek Extraordinaire
Reply
Back at it again

A SMS driver I have has been broken by the provider moving to TLS. No biggie as the API is the some just using https now. So I went through and updated the driver and I now get an error

Code:
{
    CIDSChan, CIDSChan_SChan.cpp.1116, Failed/Cannot Do, Error: 5017/0/0
    The server requires a client certificate. Name=Secure Client Data Source
      <CQCDrvDev> CIDSChan_SChan.cpp - 790

}
10/10 06:06:31-Zeus01, CQCDrvDev, CIDMacroDbgThread1
{
    CQCGenDrvS, MEng.User.CQC.Drivers.SMS.SMSGlobal.DriverImpl.324, Status/App Status
    <GetIncomingData>: [DISCONNECT] The server requires a client certificate. Name=Secure Client Data Source
}

This is after a SendGET. initially SendGET was for http only and DoSSLGET had to be used but I saw that it was depricated and that SendGET handles SSL now - so I am still using that but I dont understand why I am getting the error.

Mick
Mykel Koblenz
Illawarra Smart Home
Reply
It's not finding a certificate for the target server. If you are doing HTTPS in the URL, then you would generally want to use the versions of the GET, POST, etc... methods that take a data source, the 'RU' ones for re-usable i.e. they create persistent HTTP 1.1 type connections as well. You indicate in the data source object setup what the target host is, and it does the certificate lookup. They may require a 1.1 style connection as well, so that's another reason for using the UR versions.

Give that a try if you haven't already.
Dean Roddey
Software Geek Extraordinaire
Reply
I used the SendRUGET and it requires a data source.

So I added that but it needs to set up (TCPSetup) which needs a IPEndpoint.

I am getting stuck with this - I am not sure on what to do with the IPEndPoint
Mykel Koblenz
Illawarra Smart Home
Reply
That is just the host name and port that you are going to connect to, which is the same as what is in the URL.
Dean Roddey
Software Geek Extraordinaire
Reply
OK, got it working.

the URL was api.smsglobal.com and that didn't work but smsglobal.com did so I have got it working - not sure I understand it all but its working so I'll just leave it at that and be happy that I can send an SMS now.
Mykel Koblenz
Illawarra Smart Home
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  "Client Side Driver Directory Could Not be Cleaned Out" TurboSam 6 38 1 hour ago
Last Post: TurboSam
  CML Driver IDE docs - where? rbroders 1 29 Yesterday, 05:41 PM
Last Post: Dean Roddey
  Timer Driver Question kblagron 5 111 09-14-2018, 02:43 AM
Last Post: znelbok
  reset driver statistics? rbroders 9 344 09-11-2018, 07:50 PM
Last Post: Dean Roddey
  Driver Configuration w/8 prompts rbroders 1 255 09-03-2018, 09:28 PM
Last Post: Dean Roddey
  Driver info/stats rbroders 6 361 09-02-2018, 08:34 PM
Last Post: Dean Roddey
  Sonos Driver zra 3 184 09-01-2018, 03:09 PM
Last Post: Dean Roddey
  HTTP Get driver not working znelbok 10 512 08-28-2018, 10:10 AM
Last Post: Dean Roddey
  Can't add fields to ElkDev driver rbroders 4 288 08-07-2018, 06:24 PM
Last Post: Dean Roddey
  Possible to copy all the name in a driver so can paste is elsewhere? ghurty 11 665 07-14-2018, 05:24 PM
Last Post: Dean Roddey

Forum Jump:


Users browsing this thread: 1 Guest(s)