Insert a dynamic IP into the TCP platform sensor through the user interface, Lovelace

Good day Development Team,

I’d like to suggest a feature that allows users to input a dynamic value (whether an IP or a Link) into the “host” field of the TCP platform, directly through the Lovelace interface.

Currently, my configuration is as follows:

sensor:

  • platform: tcp
    name: vmc_vmgh
    host: 192.168.1.160
    port: 5001
    timeout: 15
    payload: “VMGH?”
    scan_interval:
    seconds: 5

It would be fantastic if we could have a solution similar to:

sensor:

  • platform: tcp
    name: vmc_vmgh
    host: {{ states(‘input_text.vmc_ip’) }}
    port: 5001
    timeout: 15
    payload: “VMGH?”
    scan_interval:
    seconds: 5

Such an implementation would greatly enrich the experience on Home Assistant!

Thank you in advance for considering my suggestion.

Up, Up, Up, Up Please!