meshtastic-mqtt icon indicating copy to clipboard operation
meshtastic-mqtt copied to clipboard

AppDaemon separately

Open mkinney opened this issue 3 years ago • 1 comments

Not sure what AppDaemon is, but we can make the code handle it if you can describe what it does differently than from just running from main.

mkinney avatar Jan 01 '22 19:01 mkinney

It's an add-on for home assistant that is designed to let you run custom python automation scripts, but you don't have to interact with home assistant at all. It's a convenient place for me to run this script mainly.

Basically to run a script under AppDaemon, you need this:

import hassapi as hass

class OutsideLights(hass.Hass):

  def initialize(self):
  code code code

It must import the class then init it with the hass object. When running straight from CLI I had to bodge it to use main instead, and remove that hassapi import (which I don't have on my local machine)

joshpirihi avatar Jan 12 '22 17:01 joshpirihi