Xiaomi hyper OS et HA

Regarde le A/B cette condition n’est pas vraie. Regarde, corrige et recommence

  • le cron est sur 5 jours
  • et ta condition sur 3
      - condition: template
        value_template: "{{ now().weekday() in [0, 3, 5] }}"
    

Pour info j’ai basculé en version Hyperos 3 depuis 5j. Et pas de souci

ha…donc un souci de configuration…

Des utilisateurs qui ont opnsense et zoraxy ?

oui

déja testé mais j’ai gardé caddy

dans caddy, tu as fait un reglage spécifique pour HA ? et dans opnsense ?
Pour moi, sans analyse ips dans opnsense, pas besoin de faire grand chose, puisque que tu redirige vers ton reverse et lui gere le reste

Rien de spécifique a HA

1 « J'aime »

Bonsoir, après pas mal de tests, essais et modification, voici ce qui n’allait pas et ce que j’ai fait
conflits dans les notifications, aucun timeout et surtout aucune action…
Du coup, voici mon nouveau YAML:

alias: Aspirateur Wall-E - Famille
description: Notification et démarrage aspirateur Wall-E pour toute la famille
triggers:
  - at: "16:00:00"
    id: semaine
    weekday:
      - mon
      - tue
      - wed
      - thu
      - fri
    trigger: time
  - at: "15:00:00"
    id: weekend
    weekday:
      - sat
      - sun
    trigger: time
  - entity_id: binary_sensor.cm_chambre_parents_occupancy
    to: "on"
    id: soir_mouvement
    trigger: state
conditions:
  - condition: or
    conditions:
      - condition: state
        entity_id: person.weber_jonathan
        state: home
      - condition: state
        entity_id: person.cindy
        state: home
  - condition: or
    conditions:
      - condition: and
        conditions:
          - condition: trigger
            id:
              - semaine
              - weekend
          - condition: numeric_state
            entity_id: input_number.wall_e
            below: 1
      - condition: and
        conditions:
          - condition: trigger
            id: soir_mouvement
          - condition: time
            after: "21:00:00"
            before: "04:00:00"
          - condition: state
            entity_id: input_boolean.wall_e_soir_fait
            state: "off"
          - condition: numeric_state
            entity_id: input_number.wall_e
            below: 1
actions:
  - choose:
      - conditions:
          - condition: trigger
            id: semaine
        sequence:
          - action: vacuum.start
            target:
              entity_id: vacuum.saros_10
          - delay: "00:05:00"
          - choose:
              - conditions:
                  - condition: state
                    entity_id: vacuum.saros_10
                    state: cleaning
                sequence:
                  - action: input_number.increment
                    target:
                      entity_id: input_number.wall_e
              - conditions:
                  - condition: not
                    conditions:
                      - condition: state
                        entity_id: vacuum.saros_10
                        state: cleaning
                sequence:
                  - if:
                      - condition: state
                        entity_id: person.weber_jonathan
                        state: home
                    then:
                      - action: notify.mobile_app_xiaomi14t
                        data:
                          title: Aspirateur Wall-E
                          message: ❌ Wall-E n'a pas démarré le nettoyage !
                  - if:
                      - condition: state
                        entity_id: person.cindy
                        state: home
                    then:
                      - action: notify.mobile_app_xiaomi
                        data:
                          title: Aspirateur Wall-E
                          message: ❌ Wall-E n'a pas démarré le nettoyage !
    default:
      - variables:
          notif_message: |
            {% if trigger.id == 'soir_mouvement' %}
              Est-ce qu'on passe l'aspirateur ce soir ?
            {% else %}
              Est-ce qu'on passe l'aspirateur ?
            {% endif %}
      - if:
          - condition: state
            entity_id: person.weber_jonathan
            state: home
        then:
          - action: notify.mobile_app_xiaomi14t
            data:
              title: Aspirateur Wall-E
              message: "{{ notif_message }}"
              data:
                tag: wall_e_clean
                actions:
                  - action: START_CLEAN_WALLE
                    title: 🧹 Oui
                  - action: SKIP_CLEAN_WALLE
                    title: ❌ Non
          - if:
              - condition: trigger
                id: soir_mouvement
            then:
              - delay: "00:00:20"
              - action: input_boolean.turn_on
                target:
                  entity_id: input_boolean.wall_e_soir_fait
          - wait_for_trigger:
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: START_CLEAN_WALLE
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: SKIP_CLEAN_WALLE
            timeout: "00:10:00"
            continue_on_timeout: true
      - if:
          - condition: template
            value_template: "{{ wait.trigger is none }}"
          - condition: state
            entity_id: person.cindy
            state: home
        then:
          - action: notify.mobile_app_xiaomi
            data:
              title: Aspirateur Wall-E
              message: "{{ notif_message }}"
              data:
                tag: wall_e_clean
                actions:
                  - action: START_CLEAN_WALLE
                    title: 🧹 Oui
                  - action: SKIP_CLEAN_WALLE
                    title: ❌ Non
          - wait_for_trigger:
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: START_CLEAN_WALLE
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: SKIP_CLEAN_WALLE
            timeout: "00:10:00"
            continue_on_timeout: false
      - if:
          - condition: state
            entity_id: person.weber_jonathan
            state: not_home
          - condition: state
            entity_id: person.cindy
            state: home
        then:
          - action: notify.mobile_app_xiaomi
            data:
              title: Aspirateur Wall-E
              message: "{{ notif_message }}"
              data:
                tag: wall_e_clean
                actions:
                  - action: START_CLEAN_WALLE
                    title: 🧹 Oui
                  - action: SKIP_CLEAN_WALLE
                    title: ❌ Non
          - if:
              - condition: trigger
                id: soir_mouvement
            then:
              - delay: "00:00:20"
              - action: input_boolean.turn_on
                target:
                  entity_id: input_boolean.wall_e_soir_fait
          - wait_for_trigger:
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: START_CLEAN_WALLE
              - trigger: event
                event_type: mobile_app_notification_action
                event_data:
                  action: SKIP_CLEAN_WALLE
            timeout: "00:10:00"
            continue_on_timeout: false
      - choose:
          - conditions:
              - condition: template
                value_template: "{{ wait.trigger.event.data.action == 'START_CLEAN_WALLE' }}"
            sequence:
              - action: vacuum.start
                target:
                  entity_id: vacuum.saros_10
              - delay: "00:05:00"
              - choose:
                  - conditions:
                      - condition: state
                        entity_id: vacuum.saros_10
                        state: cleaning
                    sequence:
                      - action: input_number.increment
                        target:
                          entity_id: input_number.wall_e
                      - if:
                          - condition: state
                            entity_id: person.weber_jonathan
                            state: home
                        then:
                          - action: notify.mobile_app_xiaomi14t
                            data:
                              title: Aspirateur Wall-E
                              message: ✅ Wall-E a bien démarré le nettoyage !
                      - if:
                          - condition: state
                            entity_id: person.cindy
                            state: home
                        then:
                          - action: notify.mobile_app_xiaomi
                            data:
                              title: Aspirateur Wall-E
                              message: ✅ Wall-E a bien démarré le nettoyage !
                  - conditions:
                      - condition: not
                        conditions:
                          - condition: state
                            entity_id: vacuum.saros_10
                            state: cleaning
                    sequence:
                      - if:
                          - condition: state
                            entity_id: person.weber_jonathan
                            state: home
                        then:
                          - action: notify.mobile_app_xiaomi14t
                            data:
                              title: Aspirateur Wall-E
                              message: >-
                                ❌ Wall-E n'a pas réussi à démarrer le nettoyage
                                !
                      - if:
                          - condition: state
                            entity_id: person.cindy
                            state: home
                        then:
                          - action: notify.mobile_app_xiaomi
                            data:
                              title: Aspirateur Wall-E
                              message: >-
                                ❌ Wall-E n'a pas réussi à démarrer le nettoyage
                                !
          - conditions:
              - condition: template
                value_template: "{{ wait.trigger.event.data.action == 'SKIP_CLEAN_WALLE' }}"
            sequence:
              - if:
                  - condition: state
                    entity_id: person.weber_jonathan
                    state: home
                then:
                  - action: notify.mobile_app_xiaomi14t
                    data:
                      title: Aspirateur Wall-E
                      message: 👌 Nettoyage annulé pour cette fois.
              - if:
                  - condition: state
                    entity_id: person.cindy
                    state: home
                then:
                  - action: notify.mobile_app_xiaomi
                    data:
                      title: Aspirateur Wall-E
                      message: 👌 Nettoyage annulé pour cette fois.
mode: single

Pour le souci de mise à jour de l’emplacement… une autre histoire, un souci de certificat sur zoraxy
Après avoir refait le cert avec les intermediaires et la clé, plus de souci ^^

Merci pour votre aide :wink:

1 « J'aime »

Ce sujet a été automatiquement fermé après 2 jours. Aucune réponse n’est permise dorénavant.