Generic Thermostat for an IR conditioner... doesn't work

Hello world,
i have a problem with a generic thermostat: my plan is a frontend thermostat that can control a conditioner by an IR signal (it’s a temporary solution…)
Using directly service “remote.send_command” create some problems with the frontend, so I decided tu create an input_boolean to trig an automation. I try also to use other solution, but the automation does’nt work …)

Climate heater → ON/OFF → trig automation → script to send IR command (this script works fine)

climate:
  - platform: generic_thermostat
    name: Condizionatore
    heater: input_boolean.condizionatoreX #(I try also wit a generic switch...)
    target_sensor: sensor.soggiorno
    ac_mode: true
    min_temp: 21
    max_temp: 27
    cold_tolerance: 0.3
    initial_hvac_mode: "cool"

AUTOMATION

- alias: Clima HI
  trigger:
  - platform: state
    entity_id:
    - input_boolean.condizionatoreX  #(I try also wit a generic switch...)
    to: 'On'
    from: 'Off'
  condition:
  - condition: time
    after: '09:00:00'
    before: '23:30:00'
  action:
  - service: script.clima_on_hi
  mode: single

The frontend thermostat seems to work fine, but no signals are send… I did some attempts and I think that it’s an automation problem. Where il the bug??

    to: 'on'
    from: 'off'

Boolean states are always lower case. Despite what the dashboard shows. Look in Developer Tools > States to see the actual states, never rely on the state shown in the Dashboard.

I try to use a switch (only a try with a random actuator), but the problem is the same and effects are the same…

I cant help with that unless you show your switch configuration.

Also what “same problem”?

What effects?

You’re asking a lot of my non-existent mind reading capabilities here.

The effect is: no signals are send
I think that the error can be related to the trigger or the action.
I try to trig the automation in same way… with a boolean entity, actuating some switch o a light, manually in the automation menu… so I deduce that trigger isn’t the problem.
Probably i do some mistake with action… pehaps I miss a variable o I fail something…

I told you how to fix the trigger. Have you looked at the automation trace?

Your action is to call a script that we cant see either.

Honestly I’m tired of asking you to provide all the relevant information.

Good luck with it.