Re: [mh] Schulter Ditra thermostats

Tom MacLean <[email protected]> Fri, 5 Nov 2021 17:40:20 -0400
Newsgroups gmane.comp.misc.misterhouse.user
Message-ID <[email protected]>
Hi.

Is the expected response like this?
{"Groups":[{"GroupName":"Basement 
","GroupId":4473,"AwayMode":false,"Thermostats":[]},{"GroupName":"","GroupId":0,"AwayMode":false,"Thermostats":[]}]}

This is what is in my log:
11/05/21 04:44:25 PM [Schulter_Ditra] get_data initiated
11/05/21 04:44:25 PM [Schulter_Ditra] Background Polling initiated
11/05/21 04:44:25 PM [Schulter_Ditra] Backgrounding 623 command get_url 
https://ditra-heat-e-wifi.schluter.com/api/thermostats?sessionId=TOKEN_REMOVED
11/05/21 04:44:33 PM [Schulter_Ditra] Background poll process completed
11/05/21 04:44:33 PM [Schulter_Ditra] Processing Data...
11/05/21 04:44:33 PM [Schulter_Ditra] Processing Data for Group Basement 
...
11/05/21 04:44:33 PM [Schulter_Ditra] Processing Data for Group ...

I don't see any temperature data...

I tried setting the app_id to 1 like in my NodeRed script and that made 
it crash.
I did some playing around with URL and app_id ... i think I put it all 
back, but not the Schluter code isn't polling any more.  The app_id had 
caused an outright crash, so that seems not it.  I can see the _get_url 
happening as a process, but I don't see MH reporting on it at all.



On 2021-11-05 10:08, H Plato wrote:
> You can turn on debug on (change line 79 to $self->{debug} = 5 to see
> what’s happening, the URL queries and the data returned.
> 
> The ditra master object just holds the data structure that is queried
> from the account. Since I have 2 of these devices, I’ve set up the
> module so that the child objects have the specific information around
> the stat. So the child mode state is ‘heating or idle’, the child
> setpoint object will have the current setpoint, and the child temp
> object state should be the temperature.
> 
> That set operation should work.
> 
>> On Nov 5, 2021, at 7:39 AM, Tom MacLean <[email protected]> wrote:
>> I had figured out the main Ditra object and that the others were
>> dependent objects, but I had assumed "serial" was a string...
>> perhaps it will work better as an integer.
>> 
>> Can you give an example of reading the temp value?  I assumed it
>> would be stored in ->state but I got back nothing.  (OTOH, if my
>> Serial was wrong, maybe that would be expected).
>> 
>> Is the set point set something like this? $room1_sp->set(12.5)
>> 
>> Thanks
>> 
>> On 2021-11-04 23:53, H Plato wrote:
>> Not only a spelling mistake, but no instructions either! :)
>> Two things,
>> Set the username (email) and password in the mh.config like this:
>> ditra_username = [email protected]
>> ditra_password = password
>> Then define the master object. I have two thermostats, but they use
>> the master object like this:
>> use Schulter_Ditra;
>> $ditra = new Schulter_Ditra;
>> $room1_sp = new Ditra_thermostat_sp($ditra,123456);
>> $room1_mode = new Ditra_thermostat_mode($ditra,123456);
>> $room1_temp = new Ditra_thermostat_temp($ditra,123456);
>> $room2_sp = new Ditra_thermostat_sp($ditra,234567);
>> $room2_mode = new Ditra_thermostat_mode($ditra,234567);
>> $room2_temp = new Ditra_thermostat_temp($ditra,234567);
>> Then in the web interface you can see the mode and change the
>> setpoint. By default I set the poll to every 10 seconds, so
>> it’s not
>> realtime to reflect local changes.
>> I’ll add these instructions and correct the spelling mistake
>> for the next update
>> On Nov 4, 2021, at 9:14 PM, Tom MacLean <[email protected]> wrote:
>> I have the Schluter code running, but frankly I don't know how to
>> use it.  I set the required params, and I can see it authenticating
>> and fetching my group.  I tried creating a temp object, but I don't
>> know how to read it.
>> $Basement_Bathroom_Thermostat = new Schulter_Ditra();
>> $Basement_Bathroom_temp = new
>> Ditra_thermostat_temp($Basement_Bathroom_Thermostat,"SERIAL
>> NUMBER");
>> Can you provide any guidance?
>> Thanks,
>> Tom
>> On 2021-11-04 17:20, Tom MacLean wrote:
>> Is it all contained in lib/Schulter_Ditra.pm  ?   (BTW, it's
>> Schluter.)
>> Will this lib run on the current release or are there unmet
>> dependencies?  In any case, i will try.
>> Cheers
>> On 2021-11-03 22:49, H Plato wrote:
>> That’s good. I uploaded my latest module to
>> github. It tracks mode,
>> and you can change the setpoint and pull the temperature. Be good to
>> know if you have any feedback.
>> On Nov 3, 2021, at 8:35 PM, Tom MacLean <[email protected]> wrote:
>> It took me a little fighting to get Crypt::SSLeay installed, but I
>> got there. (cpan wouldn't do it, I had to apt-get the relevant
>> libraries.)
>> I am able to authenticate at the schluter URL as well as the generic
>> one.  I checked and both domains map to the same IP address.
>> On 2021-11-02 10:52, H Plato wrote:
>> Interesting. I can authenticate against that URL as well, so I bet
>> you’re correct that
>> the reseller is branding that URL.
>> To create an account, I had to have power to my wifi device, and
>> then
>> associated that device with an email account.
>> I don’t have any
>> documentation — I
>> pulled the endpoints from other
>> integrations that are out there on github.
>> On Nov 1, 2021, at 9:17 PM, Tom MacLean <[email protected]> wrote:
>> In truth, I haven't hooked up my unit to wifi yet -- the relevant
>> bathroom is still under construction (by me), but I'm almost done.
>> The heated floor and thermostat are in, all I need is the "round
>> tuit" to connect it to wifi.
>> The URL I have is diferrent, but the Schluter Thermostat is
>> definitely an OJ Microline ... so I think they have branded URLs or
>> perhaps a different application number.  The code I expect to use
>> uses:
>> https://mythermostat.info/api/authenticate/user
>> {"Email":"LOGIN EMAIL","Password":"LOGIN PASSWORD","Application":0}
>> Looks familiar, no?
>> Do you have documentation? The only two actions I know about are
>> setting an override "away" temperature, and resuming the normal
>> schedule.
>> Cheers
>> Tom
>> On 2021-10-31 18:25, H Plato wrote:
>> OK, if you have an account with one of those stats, try running this
>> command to see if you get a sessionID:
>> ./get_url -response_code -json -post
>> 
> '{"Email”:”[email protected]","Password”:"password","Application":"7"}'
>> https://ditra-heat-e-wifi.schluter.com/api/authenticate/user
>> If you get back something like this:
>> RESPONSECODE:200
>> 
> {"SessionId”:”sdfhsdihflasdfhalsdiufha","NewAccount":false,"ErrorCode":0,"RoleType":3000,"Email":"[email protected]","Language":”EN"}
>> Then it will work.
>> On Oct 31, 2021, at 4:12 PM, Tom MacLean <[email protected]>
>> wrote:
>> Hi
>> Is the Schluter thermostat one of the models made by OJ Electronics?
>> They make thermostats for a bunch of floor heating companies,
>> including also WarmlyYours. In short, I could test it if is.   I
>> 
> didn’t
>> think they had a public API. All I found was a rather limited
>> NodeRED script.
>> Cheers,
>> Tom
>> Sent from my iPhone
>> On Oct 30, 2021, at 2:34 PM, H Plato <[email protected]> wrote:
>> 
> I
>> 
> don’t
>> know if anyone else has any of these, but
>> 
> I’m
>> just putting the finishing touches on a MH module to poll and
>> control the wifi in-floor heat thermostats.
>> It feels like there are a bunch of changes out there (like the
>> tasmota stuff),
>> 
> I’m
>> wondering if it makes sense to combine them all into master and look
>> to package it for a release. MH is pretty mature and stable, so
>> there
>> 
> hasn’t
>> been updates in a while, but would be good to have a current
>> download.
>> ________________________________________________________
>> To unsubscribe from this list, go to:
>> https://lists.sourceforge.net/lists/listinfo/misterhouse-users
>> ________________________________________________________
>> To unsubscribe from this list, go to:
>> https://lists.sourceforge.net/lists/listinfo/misterhouse-users
>  ________________________________________________________
> To unsubscribe from this list, go to:
> https://lists.sourceforge.net/lists/listinfo/misterhouse-users
> ________________________________________________________
> To unsubscribe from this list, go to:
> https://lists.sourceforge.net/lists/listinfo/misterhouse-users


________________________________________________________
To unsubscribe from this list, go to: https://lists.sourceforge.net/lists/listinfo/misterhouse-users