Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HomeStatus not working in my account #369

Open
Booleano75 opened this issue Dec 8, 2022 · 8 comments
Open

HomeStatus not working in my account #369

Booleano75 opened this issue Dec 8, 2022 · 8 comments

Comments

@Booleano75
Copy link

I have a Smarther thermostat (Smarther2 in Italy).

the following code works properly

homeData = pyatmo.HomeData(authorization)
homeData.update()
print(homeData.raw_data)

only differently from the website doesn't show all the info about the house but it stop at rooms details.

when i run the following code, with home_id set accordingly to previous response

homeStatus = pyatmo.HomeStatus(authorization, home_id="xxxxxxxxxxx")
homeStatus.update()
print(homeStatus.raw_data)

I get :
Traceback (most recent call last):
File "C:\Users\Francesco\Desktop\Temp\test.py", line 21, in
homeStatus.update()
File "C:\Users\Francesco\anaconda3\lib\site-packages\pyatmo\thermostat.py", line 264, in update
self.raw_data = extract_raw_data(resp.json(), "home")
File "C:\Users\Francesco\anaconda3\lib\site-packages\pyatmo\helpers.py", line 57, in extract_raw_data
raise NoDevice("No device found, errors in response")
pyatmo.exceptions.NoDevice: No device found, errors in response

while on netatmo API tryout all the information including the thermostat are properly shown.

Any hint ?

@cgtobi
Copy link
Collaborator

cgtobi commented Jan 3, 2023

What device type is this?

@Booleano75
Copy link
Author

Booleano75 commented Jan 3, 2023 via email

@cgtobi
Copy link
Collaborator

cgtobi commented Jan 3, 2023

Yes, so it is a BNS? Which version of pyatmo are you using?

@cgtobi
Copy link
Collaborator

cgtobi commented Jan 3, 2023

Also, you are using the old and deprecated classes/functions. Those do not support BTicino devices. Are you using pyatmo in a standalone script?

@Booleano75
Copy link
Author

Booleano75 commented Jan 4, 2023 via email

@Booleano75
Copy link
Author

Booleano75 commented Jan 16, 2023 via email

@cgtobi
Copy link
Collaborator

cgtobi commented Jan 16, 2023

Here is a small example:

account = pyatmo.AsyncAccount(async_auth)
await account.async_update_topology()
home_id = "your_home_id"
await async_account.async_update_status(home_id)
room_id = "a_room_id"
room = async_home.rooms[room_id]

Unfortunately I haven't had the time to update the documentation yet.

@Booleano75
Copy link
Author

Booleano75 commented Jan 31, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants