home-assistant-glow icon indicating copy to clipboard operation
home-assistant-glow copied to clipboard

3.1.0 - Change default pulse pin

Open hank-droid opened this issue 2 years ago • 13 comments

Hi, I started tinkering with this around 1y ago. I was getting readings in the region of millions, so I parked it until I could print a case, which happened just now. after powering it with a powerbank, it got connected and I added it in HA via the self discovery (the HA installation is different form the one when i originally installed glow). I was still getting high readings, so I installed espohome addon to adopt the device in order to add the interval filter. the glow was adopted, and I have then updated it.

now I no longer get any reading.

any suggestion on what i might have done wrong?

the diode seems to work because the green led is flashing as picks up light, and i see it flashing differently depending on the sensitivity setting. the blue led that used to flash on the esp32 does not.

thanks!

hank-droid avatar Dec 31 '22 18:12 hank-droid

ok I read the changelog and I reverted to the previous gpio pin (12) for sensor and it works. it also seems to have adjusted the rate and seems to be working properly overall without editing any setting.

hank-droid avatar Dec 31 '22 18:12 hank-droid

I faced exactly the same problem and solved it in the same way by editing home_assistant_glow.yaml. I suspect that we are not the only ones that have updated without realizing that there is a breaking change. I think that this issue should be left open. Figuring by myself what's wrong took a long time, and I would really have appreciated the help.

Helmasynti avatar Jan 05 '23 10:01 Helmasynti

https://github.com/klaasnicolaas/home-assistant-glow/commit/a09da8f54f993d3239ff113a6e70d7def3b5ebee

F3213AAA-2D70-4293-8D0A-FFB40C2AFC64

hank-droid avatar Jan 05 '23 17:01 hank-droid

The problem is that there is a difference between the version on the ESPHome webtools site and the yaml file in the repository. The pulse pin change is part of version 4.0.0 and has not yet been "released".

klaasnicolaas avatar Jan 05 '23 19:01 klaasnicolaas

I am not sure how I ended there… just leaving those thoughts here in case they can help someone else troubleshoot.

hank-droid avatar Jan 05 '23 19:01 hank-droid

If you update the Home Assistant Glow in ESPHome, it automatically takes the latest version of the YAML file in this repository, while this is actually more of a development version. It would be better if it looked at the versions associated with a release tag in Github.

This has to be improved, can be improved, but I still have to find out how this can be improved in the field of CI.

klaasnicolaas avatar Jan 05 '23 19:01 klaasnicolaas

@klaasnicolaas, maybe I don't quite understand what you mean but I downloaded the yaml from here

https://github.com/klaasnicolaas/home-assistant-glow/blob/main/home_assistant_glow.yaml

and the pulse pin change is there.

It's not a big deal to edit it, but since I am a total novice when it comes to microcontrollers and I built the system more than a year ago, I had forgotten many of the details of how everything was installed etc. It took me an effort to repair the system. Of course, the work was not in vain since now I understand the system better, but it was annoying and a bit scary to realise the system not working after the update. I believe that I am not the only novice around here hence the request to open the issue.

Helmasynti avatar Jan 06 '23 13:01 Helmasynti

That the yaml file you link to in the main branch is a "development version" and therefore contains (breaking) changes that have not yet been released, or documented in release notes. However the package_import_url currently automatically grabs the version from the main branch.

Actually, this is the latest stable version: https://github.com/klaasnicolaas/home-assistant-glow/blob/v3.1.0/home_assistant_glow.yaml

klaasnicolaas avatar Jan 06 '23 13:01 klaasnicolaas

Hi Klaas,

Today I started with the homeassistant glow project, nice work! The "Get started" link from your github https://github.com/klaasnicolaas/home-assistant-glow#get-started brings us to project version "3.1.0" and refers to pulse_pin: GPIO13. The link you posted in your reaction above yesterday (with v3.1.0 in it) brings us to project version "3.0.0" and refers to pulse_pin: GPIO12.

I am a little bit lost, which one should I use?

I have installed project version "3.1.0" and connected the photodiode to GPIO13 but I have some strange readings in HA.

In the photo and movie you posted on your github there are four wires going to the photodiode, but in the visual schema there are only three wires to the photodiode? I asume there should be only three wires conform the visual schema: 3v3, gnd, DO, is that wright?

Thank you in advance!

Gr. Maarten

MPJK77 avatar Jan 07 '23 14:01 MPJK77

Understand that it is a bit unclear now and I want to improve that soon. The default branch will be dev and main a separate branch where I will only merge a stable release into, which I hope will make a better separation and should also be better for those who use updates via the ESPHome web tools.

The link you posted in your reaction above yesterday (with v3.1.0 in it) brings us to project version "3.0.0" and refers to pulse_pin: GPIO12.

That was a mistake on my part because I had not updated the version in the yaml file itself, in this case the version as tagged with a release is leading. The use of GPIO13 is part of the 4.0.0 release, 3.1.0 still uses GPIO12. If you want to run stable then you should look here, if you still want to work with the development version then here.

I asume there should be only three wires conform the visual schema: 3v3, gnd, DO, is that wright?

It is true that I have 4 wires going into the photodiode, but A0 is an empty wire that is not used, so in this case also use the schematic shown in the readme.

klaasnicolaas avatar Jan 07 '23 15:01 klaasnicolaas

FYI, I made some changes to the repository that allow for a better separation between what is stable (main branch) and what is development (dev branch). I have also reverted the main branch to how it should be according to the 3.1.0 release and you will therefore continue to use GPIO12 as long as 4.0.0 has not yet been released.

klaasnicolaas avatar Jan 07 '23 23:01 klaasnicolaas

Hi klaas,

Thank you for your work, it is all clear to me now!

MPJK77 avatar Jan 08 '23 09:01 MPJK77

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!

github-actions[bot] avatar Feb 25 '23 08:02 github-actions[bot]

Close this issue since v4 is here and the default pulse pin has been changed for ESP32.

klaasnicolaas avatar Feb 12 '24 23:02 klaasnicolaas