Re: [mh] Experiences with Misterhouse V6 and Home Assistant

Dave Neudoerffer <[email protected]> Sat, 30 Nov 2024 15:27:02 -0500
Newsgroups gmane.comp.misc.misterhouse.user
Message-ID <CAOFx8LPsKkTuuKeZ_mUixQQcnqwHBRqgrq-gjCGHMYkBVtZLEQ@mail.gmail.com>
--===============4767466877403358759==
Content-Type: multipart/alternative; boundary="0000000000001b657c062827243c"

--0000000000001b657c062827243c
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Hey Giles,

A couple points.

   - you can probably publish the mode_control item using code to define
   the MQTT_LOCALITEM rather than the .mht file.  I suspect you just have
   a chicken and egg problem there.
   - to get HA Helper objects into MH, you should use HA_Item.pm.  If the
   types you want aren't supported, let me know and I can add them
   - HA_Item.pm uses the websocket interface to HA.  It is quite a bit more
   functional than the HA Restful interface.  I had originally coded up my
   interface to HA using the Restful interface, but HA_Item is much more
   functional and also already fully implemented :-) -- documentation is in
   the top of the file, or in your generated doc.  You can define HA_ITEMs =
in
   your .mht file, and you can call generic actions in HA.

Dave

On Sat, Nov 30, 2024 at 5:40=E2=80=AFAM Giles Godart-Brown <ggodartbrown@gm=
ail.com>
wrote:

> First can I thank everyone involved in getting V6 out, the migration went
> flawlessly.
>
> I have made the following observations/requests following the upgrade and
> starting to use Home Assistant for its UI and integration to devices MH
> hasn't been linked to (yet)
>
>    - I have 73 Tasmota/MQTT devices and have found that, for no apparent
>    reason, they don't all get discovered by HA ,so for those I have kept =
them
>    in MH and published their state to HA for its UI.
>    - I needed to edit Tasmota_HTTP_Item.pm to add my addition to prevent
>    it attempting to contact devices that are offline or unplugged (see be=
low),
>    perhaps for a future enhancement?
>    - Be aware that when MH starts, Tasmota devices that are controlled by
>    HA may well have their state set to UNKNOWN if HA hasn't contacted the=
m
>    yet, I have a change trigger  in MH to set these to off pro-tem.
>    - I wanted to publish temperature values from MH to HA, thanks to Dave
>    for adding support for numbers with a range and an increment.
>    - Thanks also to Dave for pointing out that MH objects that have
>    set_states will pass these over to an HA select item and that you do n=
eed a
>    #noloop at the end of your CODE lines in items.mht
>    - If you want to publish mode_occupied from MH to HA, you need to
>    define it in your items.mht, you cannot rely on mh/code/common/
>    mh_control.pl, this probably applies to all objects defined there.
>    - I'd like to be able to get HA helpers into MH objects, notably a
>    button and a toggle. I've not had much time to investigate this, but i=
f
>    anyone has a pointer, please let me know.
>
> My next challenge is to get the HA restful API to work so I can add HA
> buttons that run MH subroutines.
>
> Thanks Again
>
> Giles
> p.s.
> In my implementation, if MH fails to connect to a Tasmota HTTP device, it
> sets a status flag to offline, I have a report that allows me to set thes=
e
> to unplugged for devices I know aren't currently connected, e.g. the
> Christmas tree lights or the fans in winter.  This prevents it getting
> stuck when I run a command to say turn off all the lights.
>
> I also use static IP addresses everywhere because MDNS was causing my Sky
> fibre router to reboot about 6 or 7 time a day.
> ________________________________________________________
> To unsubscribe from this list, go to:
> https://lists.sourceforge.net/lists/listinfo/misterhouse-users
>
>

--0000000000001b657c062827243c
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hey Giles,<div><br></div><div>A couple points.=C2=A0=C2=A0=
</div><div><ul><li>you can probably publish the mode_control item using cod=
e to define the MQTT_LOCALITEM rather than the .mht file.=C2=A0 I suspect y=
ou just have a=C2=A0chicken and egg problem there.=C2=A0</li><li>to get HA =
Helper objects into MH, you should use HA_Item.pm.=C2=A0 If the types you w=
ant aren&#39;t supported, let me know and I can add them</li><li>HA_Item.pm=
 uses the websocket interface to HA.=C2=A0 It is quite a bit more functiona=
l than the HA Restful interface.=C2=A0 I had originally coded up my interfa=
ce to HA using the Restful interface, but HA_Item is much more functional a=
nd also already fully implemented :-) -- documentation is in the top of the=
 file,=C2=A0or in your generated doc.=C2=A0 You can define HA_ITEMs in your=
 .mht file, and you can call generic=C2=A0actions in HA.=C2=A0=C2=A0</li></=
ul><div>Dave</div></div></div><br><div class=3D"gmail_quote"><div dir=3D"lt=
r" class=3D"gmail_attr">On Sat, Nov 30, 2024 at 5:40=E2=80=AFAM Giles Godar=
t-Brown &lt;<a href=3D"mailto:[email protected]">[email protected]=
m</a>&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin=
:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"=
><u></u>

 =20

   =20
 =20
  <div>
    <font face=3D"Calibri" size=3D"4">First can I thank everyone involved i=
n
      getting V6 out, the migration went flawlessly. <br>
      <br>
      I have made the following observations/requests following the
      upgrade and starting to use Home Assistant for its UI and
      integration to devices MH hasn&#39;t been linked to (yet)<br>
    </font>
    <ul>
      <li><font face=3D"Calibri" size=3D"4">I have 73 Tasmota/MQTT devices
          and have found that, for no apparent reason, they don&#39;t all
          get discovered by HA ,so for those I have kept them in MH and
          published their state to HA for its UI.</font></li>
      <li><font face=3D"Calibri" size=3D"4">I needed to edit
          Tasmota_HTTP_Item.pm to add my addition to prevent it
          attempting to contact devices that are offline or unplugged
          (see below), perhaps for a future enhancement?</font></li>
      <li><font face=3D"Calibri" size=3D"4">Be aware that when MH starts,
          Tasmota devices that are controlled by HA may well have their
          state set to UNKNOWN if HA hasn&#39;t contacted them yet, I have =
a
          change trigger=C2=A0 in MH to set these to off pro-tem.<br>
        </font></li>
      <li><font face=3D"Calibri" size=3D"4">I wanted to publish temperature
          values from MH to HA, thanks to Dave for adding support for
          numbers with a range and an increment.</font></li>
      <li><font face=3D"Calibri" size=3D"4">Thanks also to Dave for pointin=
g
          out that MH objects that have set_states will pass these over
          to an HA select item and that you do need a #noloop at the end
          of your CODE lines in items.mht<br>
        </font></li>
      <li><font face=3D"Calibri" size=3D"4">If you want to publish
          mode_occupied from MH to HA, you need to define it in your
          items.mht, you cannot rely on mh/code/common/<a href=3D"http://mh=
_control.pl" target=3D"_blank">mh_control.pl</a>,
          this probably applies </font><font face=3D"Calibri" size=3D"4">
          to </font><font face=3D"Calibri" size=3D"4">all objects defined
          there.</font></li>
      <li><font face=3D"Calibri" size=3D"4">I&#39;d like to be able to get =
HA
          helpers into MH objects, notably a button and a toggle. I&#39;ve
          not had much time to investigate this, but if anyone has a
          pointer, please let me know.<br>
        </font></li>
    </ul>
    <p><font face=3D"Calibri" size=3D"4">My next challenge is to get the HA
        restful API to work so I can add HA buttons that run MH
        subroutines.<br>
      </font></p>
    <p><font face=3D"Calibri" size=3D"4">Thanks Again <br>
      </font></p>
    <p><font face=3D"Calibri" size=3D"4">Giles</font></p>
    <font size=3D"4">p.s.<br>
      In my implementation, if MH fails to connect to a Tasmota HTTP
      device, it sets a status flag to offline, I have a report that
      allows me to set these to unplugged for devices I know aren&#39;t
      currently connected, e.g. the Christmas tree lights or the fans in
      winter.=C2=A0 This prevents it getting stuck when I run a command to
      say turn off all the lights.<br>
      <br>
      I also use static IP addresses everywhere because MDNS was causing
      my Sky fibre router to reboot about 6 or 7 time a day.<br>
    </font>
  </div>

________________________________________________________<br>
To unsubscribe from this list, go to: <a href=3D"https://lists.sourceforge.=
net/lists/listinfo/misterhouse-users" rel=3D"noreferrer" target=3D"_blank">=
https://lists.sourceforge.net/lists/listinfo/misterhouse-users</a><br>
<br>
</blockquote></div>

--0000000000001b657c062827243c--


--===============4767466877403358759==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============4767466877403358759==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

________________________________________________________
To unsubscribe from this list, go to: https://lists.sourceforge.net/lists/listinfo/misterhouse-users


--===============4767466877403358759==--