Further adjust VA restarting
This commit is contained in:
		@@ -279,7 +279,7 @@ interval:
 | 
				
			|||||||
      - if:
 | 
					      - if:
 | 
				
			||||||
          condition:
 | 
					          condition:
 | 
				
			||||||
            and:
 | 
					            and:
 | 
				
			||||||
              - switch.is_on: voice_support_active
 | 
					              - switch.is_on: enable_voice_support
 | 
				
			||||||
              - not: voice_assistant.connected
 | 
					              - not: voice_assistant.connected
 | 
				
			||||||
          then:
 | 
					          then:
 | 
				
			||||||
            - logger.log: "voice assistant not running; restarting"
 | 
					            - logger.log: "voice assistant not running; restarting"
 | 
				
			||||||
@@ -313,28 +313,14 @@ voice_assistant:
 | 
				
			|||||||
  id: assist
 | 
					  id: assist
 | 
				
			||||||
  on_error:
 | 
					  on_error:
 | 
				
			||||||
    - logger.log: "voice error"
 | 
					    - logger.log: "voice error"
 | 
				
			||||||
    - if:
 | 
					    - voice_assistant.stop:
 | 
				
			||||||
        condition:
 | 
					    - voice_assistant.start_continuous:
 | 
				
			||||||
          switch.is_on: voice_support_active
 | 
					 | 
				
			||||||
        then:
 | 
					 | 
				
			||||||
          - voice_assistant.stop:
 | 
					 | 
				
			||||||
          - voice_assistant.start_continuous:
 | 
					 | 
				
			||||||
  on_end:
 | 
					  on_end:
 | 
				
			||||||
    - logger.log: "voice ended"
 | 
					    - logger.log: "voice ended"
 | 
				
			||||||
  on_client_connected:
 | 
					  on_client_connected:
 | 
				
			||||||
    - if:
 | 
					 | 
				
			||||||
        condition:
 | 
					 | 
				
			||||||
          switch.is_on: voice_support_active
 | 
					 | 
				
			||||||
        then:
 | 
					 | 
				
			||||||
          - voice_assistant.start_continuous:
 | 
					 | 
				
			||||||
    - light.turn_off:
 | 
					    - light.turn_off:
 | 
				
			||||||
        id: output_led
 | 
					        id: output_led
 | 
				
			||||||
  on_client_disconnected:
 | 
					  on_client_disconnected:
 | 
				
			||||||
    - if:
 | 
					 | 
				
			||||||
        condition:
 | 
					 | 
				
			||||||
          switch.is_on: voice_support_active
 | 
					 | 
				
			||||||
        then:
 | 
					 | 
				
			||||||
          - voice_assistant.stop:
 | 
					 | 
				
			||||||
    - light.turn_on:
 | 
					    - light.turn_on:
 | 
				
			||||||
        id: output_led
 | 
					        id: output_led
 | 
				
			||||||
        effect: flash_white
 | 
					        effect: flash_white
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user