genielabs / HomeGenie

HomeGenie, the programmable automation intelligence
https://homegenie.it
GNU General Public License v3.0
388 stars 154 forks source link

Duplicate entry of LircRemote in Wizard PopUp #399

Closed Jens1234 closed 1 year ago

Jens1234 commented 4 years ago

Expected behavior

Only one entry labeled LircRemote

Actual behavior

Duplicate entry LircRemote (tested with 1.2 stable 39 and 1.3 stable 5)

There's already one entry even if the Lirc Interface is not installed, after installation and second time the Wizard PopUp is started there are two entries

Did not happen with 1.1 stable 527 lirc

Steps to reproduce the problem starting from a fresh install

1.Install Lirc via Package Manager 2.Create new Wizard Script 3.Start Wizard command Interface two times

Specifications

Additional configuration notes

mralapete commented 4 years ago

What version of Raspbian are you using. The package manager appears to be broken when installing HG in Raspbian Buster. Best to do a manual install instead.

Jens1234 commented 4 years ago

I am still on wheezy, manual install does not make any difference

tuicemen commented 4 years ago

Gene made several changes to HG updating and removing obsolete drivers for it to work with Stretch I suspect that may be part of the issue here. Other issues have been reported when running the newer builds on an old OS. Consider upgrading to Stretch or Buster.

mralapete commented 4 years ago

Are you the Jens in this post http://old.homegenie.club:8080/www.homegenie.it/forum/index1dca.html?topic=272.15

If so you’re a long time user of HG and will be aware of the problems with HG and Lirc over the years.

If you want to install a fresh copy of Wheezy and HG and without restoring your HG config backup see if you can replicate the issue your are having.

You may have artefacts in your current setup that are carrying over to any new install your are performing as soon as you do a HG config restore.

While it is not necessary to use the latest version of Raspbian nor HG, if Lirc was working properly on Wheezy for you before there should be no reason why it should not run now. I have HG 1.1 v525 installed on Wheezy and working purely as it was the last version to support the CSI camera module.

Obviously Wheezy is no longer supported by the Pi Foundation so maybe this might be an opportunity to install Stretch which was the last known Raspbian version the author tested the latest HG version on or you could install Buster but as I mentioned earlier the package manager is broken for that.

mralapete commented 4 years ago

You could also follow the process in this post for removing the Lirc package. You may have two instances of Lirc running https://homegenie.club/t/how-can-i-remove-lirc-interface-or-any-other-unused-mig-interface/262

It’s easier if I post these links rather than reproduce the instructions here. I wouldn’t want you to think I solved your problem 😂 Always credit to those who do.

Jens1234 commented 4 years ago

Yes I am the Jens from the old forum ;-)

Thanks for trying to help to figure it out.

There's just one instance running ps -elf | grep lirc 5 S root 449 1 0 80 0 - 917 - Feb27 ? 00:00:00 /usr/sbin/lircd --driver=default --device=/dev/lirc0 --uinput

In systemconfig.xml is just one entry for lirc Interface Domain="Controllers.LircRemote" IsEnabled="true" AssemblyName="MIG-LircRemote.dll"

the query reports only one interface /api/HomeAutomation.HomeGenie/Config/Interfaces.List

[ { "Domain" : "HomeAutomation.X10", "IsConnected" : "True" },{ "Domain" : "Controllers.LircRemote", "IsConnected" : "True" } ]

modules.xml contains only one interface,too cat modules.xml | grep Lirc

Controllers.LircRemote

So from which config file is the Wizard UI picking the information from?

I looked into commandwizard.html but did not find anything.

mralapete commented 4 years ago

Hi Jens

I imagine it’s being picked up from the MIG interface if you’re using the latest HG release. I imagine your backup is a rolling one from a much earlier release that handled Lirc installation a different way.

If it’s possible for you, try a fresh install WITHOUT restoring your HG backup and see if that resolves your problem with Lirc appearing twice. That could possibly narrow the problem down to settings on your old setup.

Jens1234 commented 4 years ago

I did that again, after fresh installation there's alread one LircRemote entry.

After installing the Interface in "Settings" there's two. Screenshot from the fresh install lirc

mralapete commented 4 years ago

Ok a suggestion to try. As soon as you install Raspbian and before you install HG, remove the Lirc package and proceed with the installation of HG. Then add the Lirc interface to HG.

What version of Lirc is currently installed on your system.

Jens1234 commented 4 years ago

Just tried it on a Mac, it is the same, LircRemote is already part of the wizard popup and after installing the MIG Interface for Lirc the duplicate entry is there. So it is independent from Mono, Raspian, Lirc...

mralapete commented 4 years ago

I had a suspicion it was already included in HG but I don’t use it. Be mindful if you are using it on the gpio as changes on how it operates have been made https://www.raspberrypi.org/forums/viewtopic.php?f=28&t=235256&p=1487659&#1438740