Giter Club home page Giter Club logo

Comments (13)

TD22057 avatar TD22057 commented on July 21, 2024 1

Another think to consider in a fix for this is that the thermostats aren't very reliable. At least for home assistant, it would be better to just use the common thermostat and not require a connection to be valid at start up. Right now, if a the library can't connect to the thermostat, it fails and will never be available in home assistant which is annoying. I think this is mostly a code change on the home assistant end but being able to create the thermostat class (probably common thermostat) w/o a valid connection is important. Most of the time, the connection will be available later so it's not normally a big deal if it's not there at construction time.

from radiotherm.

craftyguy avatar craftyguy commented on July 21, 2024

It seems like radiotherm is not able to connect to your device. This is curious because the CT80 B1 v1.00 is supported by radiotherm.

Are you able to run radiotherm from a python console? (i.e. reproduce this error by cloning this project, and running it with python following the readme) If so, there's an experiment that might be helpful in determining what might be wrong.

from radiotherm.

robthebold avatar robthebold commented on July 21, 2024

Here's what I get when I try radiotherm from python console on my desktop (which is on the same network as the thermostat and can ping it successfully) following the readme.rst instructions:

import radiotherm
tstat = radiotherm.get_thermostat()
tstat.temp
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'NoneType' object has no attribute 'temp'
tstat.mode
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'NoneType' object has no attribute 'mode'

BTW, the run-tests script passed all tests.

from radiotherm.

TD22057 avatar TD22057 commented on July 21, 2024

Try running this (use the actual IP address of your thermostat)

import radiotherm 
tstat = radiotherm.CommonThermostat( "192.168.1.10" )
print( tstat.model )

from radiotherm.

robthebold avatar robthebold commented on July 21, 2024

Ok, I gave it a try . . .

import radiotherm
tstat=radiotherm.CommonThermostat( "192.168.2.155")
print(tstat.model)
{'raw': u'CT80 Rev B1 V1.08'}

Additionally, the temp and mode methods now return data.

tstat.temp
{'raw': 68.0}
tstat.mode
{'raw': 1, 'human': 'Normal'}

from radiotherm.

trisk avatar trisk commented on July 21, 2024

The version specific subclassing has been a real limitation for compatibility and is also largely unnecessary; I've been meaning to implement a proper class heirarchy with unknown models falling back to CommonThermostat.

from radiotherm.

JerryWorkman avatar JerryWorkman commented on July 21, 2024

from radiotherm.

craftyguy avatar craftyguy commented on July 21, 2024

I created a pull request on Nov 5, 2016 that fixes this problem. It was
ignored.

You did? I don't see any opened or closed PRs in this project from you:

https://github.com/mhrivnak/radiotherm/pulls?q=is%3Apr+is%3Aclosed

Feel free to re-submit it and I'll take a look.

from radiotherm.

JerryWorkman avatar JerryWorkman commented on July 21, 2024

from radiotherm.

craftyguy avatar craftyguy commented on July 21, 2024

Ah, an issue, not a pull request. Yea if you have something to submit in a pull request, I'd be happy to review/merge it :)

If not, I can take a look at your branch later on when I have time and come up with a patch that will apply to the current codebase.

from radiotherm.

craftyguy avatar craftyguy commented on July 21, 2024

Can you try with #38 ? This adds support for thermostats that are not explicitly defined in this project, with basic functionality. In your case it should enable functionality that all CT80 devices, regardless of rev and version, support. But since I don't have your device, it would be awesome to get a confirmation that this branch works before I merge it!

Special thanks to @JerryWorkman for his PR 👍

from radiotherm.

JerryWorkman avatar JerryWorkman commented on July 21, 2024

from radiotherm.

craftyguy avatar craftyguy commented on July 21, 2024

This should be resolved now. Closing issue, but please re-open if someone continues to experience this after testing the latest in master branch.

from radiotherm.

Related Issues (18)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.