Skip to content
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

fedi wiki

  1. Home
  2. Categories
  3. homeassistant
  4. Need some help understanding code flow. IE: ESPHome, YAML, and code pulled from github.

Need some help understanding code flow. IE: ESPHome, YAML, and code pulled from github.

Scheduled Pinned Locked Moved homeassistant
homeassistant
2 Posts 2 Posters 0 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B
    B
    batmaniam@lemmy.world
    wrote last edited by
    #1

    Hi!

    **My ask up front: **Can someone walk me through the process of how a github project written in python winds up interacting with YAML on an ESP32? Looking for some orientation so I can "RTFM" better.

    Background:
    I have Espectre up and running in my house, which is cool. What I also have in my house is LED crown molding controlled by WLED.

    I think the ESP-32s I'm using for the lighting have enough juice to run both items of code (and probably a few other sensors). However, I don't know how to combine them.

    What I'm specifically confused about is when I provision a device with ESPHome, I'm not actually clear on what it does. As in: I gather it's making a framework specific to the board to handle running the code in the YAML, but I'm not sure what that looks like specifically. Which means I don't know how to take the code from WLED or ESPectre and also include it (is it as simple as an include?) so that I can make YAMLs that utilize the functionality those to projects provide.

    I am especially confused what is happening when YAML code calls specific github projects. Is it literally pulling code from the repository?

    For context I have decent capability and experience, but mostly within code, bridging multiple architectures like this is new. I have stumbled on for years doing some fairly advanced projects, but I mostly am a very determined monkey banging on a type writer.

    R 1 Reply Last reply
    0
    • B batmaniam@lemmy.world

      Hi!

      **My ask up front: **Can someone walk me through the process of how a github project written in python winds up interacting with YAML on an ESP32? Looking for some orientation so I can "RTFM" better.

      Background:
      I have Espectre up and running in my house, which is cool. What I also have in my house is LED crown molding controlled by WLED.

      I think the ESP-32s I'm using for the lighting have enough juice to run both items of code (and probably a few other sensors). However, I don't know how to combine them.

      What I'm specifically confused about is when I provision a device with ESPHome, I'm not actually clear on what it does. As in: I gather it's making a framework specific to the board to handle running the code in the YAML, but I'm not sure what that looks like specifically. Which means I don't know how to take the code from WLED or ESPectre and also include it (is it as simple as an include?) so that I can make YAMLs that utilize the functionality those to projects provide.

      I am especially confused what is happening when YAML code calls specific github projects. Is it literally pulling code from the repository?

      For context I have decent capability and experience, but mostly within code, bridging multiple architectures like this is new. I have stumbled on for years doing some fairly advanced projects, but I mostly am a very determined monkey banging on a type writer.

      R
      R
      rogandawes@infosec.exchange
      wrote last edited by
      #2

      @batmaniam #esphome uses python to read a yaml file and generate C++, and then compiles the result. In general, you can’t just trivially combine two esp32 projects into a single firmware. However, esphome has a component that accepts the #wled udp broadcast protocol from software running elsewhere on your network. This may or may not end up being a simplification - there are a small number of existing “senders”, mostly designed for coordinating large lighting installations such as Christmas light displays across multiple ESP32s.

      Additionally, esphome has a number of built-in lighting effects (fewer than wled, and less flexible), which may be enough for your purposes. If so, you should be able to consolidate two esp32s into one.

      Then again, the positioning of the esp32 probably plays a role in its ability to detect motion using the espectre component, so there may still be tradeoffs involved. Ie the led controller may be positioned near the ceiling where it is less able to detect movement.

      1 Reply Last reply
      1
      0
      • R relay@relay.fedi.agency shared this topic

      Hello! It looks like you're interested in this conversation, but you don't have an account yet.

      Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

      With your input, this post could be even better 💗

      Register Login
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      Powered by NodeBB Contributors
      • First post
        Last post