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

Add support for monophase profile for Pro 3EM #341

Merged
merged 1 commit into from
Jan 2, 2024
Merged

Conversation

bieniu
Copy link
Owner

@bieniu bieniu commented Dec 29, 2023

Closes #338

@bieniu bieniu added the new-feature A new feature label Dec 29, 2023
@bieniu
Copy link
Owner Author

bieniu commented Dec 29, 2023

@jpatriarca Could you test this change?

@jpatriarca
Copy link

Hi @bieniu, apologies for the late reply and happy new year. Tested the changed script and it’s unable to detect the device. Reverting to the production one, it works as expected but provides unknown values, as reported. Is there any debug or tests you can direct me to do and help you develop the changes?

@bieniu
Copy link
Owner Author

bieniu commented Jan 1, 2024

Tested the changed script and it’s unable to detect the device.

What do you mean? Were there errors in the log?

Is there any debug or tests you can direct me to do and help you develop the changes?

image

@jpatriarca
Copy link

@bieniu, just checked the logs and I got this with your new version of the script:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/python_script/__init__.py", line 224, in execute
    exec(compiled.code, restricted_globals)  # noqa: S102
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "shellies_discovery_gen2.py", line 1, in <module>
NameError: name 'false' is not defined

Might be the reason why running the new script my Pro 3EM don't appear with MQTT entities (I deleted everything I had for this device)

@bieniu
Copy link
Owner Author

bieniu commented Jan 1, 2024

@jpatriarca
Copy link

Thanks for your suggestion. Effectively I grabbed the new version wrong and now I can see the values for each channel, as expected. But still seeing some entities appearing related with Phase A/B/C. Will continue to test it along the day and will provide you with further informations

@bieniu bieniu merged commit 07a122f into master Jan 2, 2024
5 checks passed
@bieniu bieniu deleted the pro-3em-1.1.0 branch January 2, 2024 10:08
@jpatriarca
Copy link

@bieniu, would like to report that, in additional with EM0-EM2 MQTT entities creation, also the Phase A-C entities are still being created with the script. The EM ones appears correctly, the Phase A-C appears as unknown, like it was in the previous version.
image

@bieniu
Copy link
Owner Author

bieniu commented Jan 2, 2024

You have to remove those entities manually from MQTT broker (topics homeassistant/sensor/xxxxx/config), I'm not able to remove them from the script.

@jpatriarca
Copy link

Thanks, done it. But still, most of my Gen2 devices are not getting some entities, like Diagnostics, Configuration and Events (sensos and controls seems to be working). I'll figure it out. Thanks

@bieniu
Copy link
Owner Author

bieniu commented Jan 2, 2024

If you can't solve the problem, open the issue and attach a debug log.

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

Successfully merging this pull request may close these issues.

Request MQTT support for monophase new option for Shelly Pro 3EM since firmware 1.1.0
2 participants