Getting protocols and models

Moderator: Telldus

Post Reply
Lullen
Posts: 7
Joined: Fri Mar 17, 2023 9:45 am

Getting protocols and models

Post by Lullen »

I have been struggling to find out how to get the available protocols and models without success. As there is no GetProtocols() in the wrapper I suppose there isnt one in the c api. I tried to look it up by seaching on the SetDeviceParameter() function(which I suppose is the one to set the model and protocol).
So how do I find the available protocols and models?
Lullen
Posts: 7
Joined: Fri Mar 17, 2023 9:45 am

Re: Getting protocols and models

Post by Lullen »

I found it by going and looking in the source code.
But I have a problem when creating a new device, after Creation Everything looks good in telldus center, the model,unit and remote all look right. When I have created a device I try to use the telldus center to learn my nexa switch. For some reason when I press the learn button nothing happens. Am I missing something?

Code: Select all

var id = TelldusNETWrapper.tdAddDevice();
            TelldusNETWrapper.tdSetName(id, "TestName");
            TelldusNETWrapper.tdSetModel(id, "selflearning-dimmer:nexa"); //Also tried -switch on a different device
            TelldusNETWrapper.tdSetProtocol(id, "arctech");
            TelldusNETWrapper.tdSetDeviceParameter(id, "unit", "9");
            TelldusNETWrapper.tdSetDeviceParameter(id, "house", "11");
Lullen
Posts: 7
Joined: Fri Mar 17, 2023 9:45 am

Re: Getting protocols and models

Post by Lullen »

Oh I found the problem, it wasnt the code but that the nexa device could not store more controller so I had to start it and pressed "all off" on the remote.
So if i want to do this in my program, how do I do it?
micke.prag
Site Admin
Posts: 2243
Joined: Fri Mar 17, 2023 9:45 am
Location: Lund
Contact:

Re: Getting protocols and models

Post by micke.prag »

All off is currently not supported in our software yet. You need to implement it with tdSendRawCommand() or help us implement it in our software ;)
Micke Prag
Software
Telldus Technologies
Lullen
Posts: 7
Joined: Fri Mar 17, 2023 9:45 am

Re: Getting protocols and models

Post by Lullen »

Okay I will look into it. Maybe I will if the code is easy enough to change for someone who never written a single line of c :) Just need to find a solution first...
Zaman
Posts: 243
Joined: Fri Mar 17, 2023 9:45 am

Re: Getting protocols and models

Post by Zaman »

Here you can find some information about what changes that needs to be made to the protocol to make a signal affect a "group" instead of an individual unit.
Check the "Extended scripts" example at the bottom of the page and look for the group option:
http://arduino.cc/playground/Code/HomeEasy

The rest is just a matter of coding :)
Post Reply