Display wifi icon based on wifi connection

Hi,

I’m trying to display an icon based on wifi.connected.

interval:
  - interval: 10s
    then:
      if:
        condition:
          wifi.connected:
        then:
          - lambda: 'id(affichage).printf(20, 20, id(icons), id(my_red), "\U000F05A9");'
        else:
          - lambda: 'id(affichage).printf(20, 20, id(icons), id(my_red), "\U000F05AA");'

I don’t get any errors on the log, the code complies properly, but the icon doesn’t show up. This is my display component, on which lambda is working properly :

display:
  - platform: ili9341
    id: affichage
    model: TFT 2.4
    rotation: 180
    cs_pin: 5
    dc_pin: 4
    led_pin: 15
    reset_pin: 22
    lambda: |-
       ...

And icons :

  - file: 'materialdesignicons-webfont.ttf'
    id: icons
    size: 36
    glyphs:
      - "\U000F05A9" #mdi:wifi
      - "\U000F05AA" #mdi:wifi-off
      - "\U000F0769" #mdi:ceiling-light
      - "\U000F17C7" #mdi:ceiling-light-outline
      - "\U000F06B5" #mdi:lamp
      - "\U000F17D0" #mdi:lamp-outline
      - "\U000F0CCC" #mdi:shield-lock-outline
      - "\U000F099C" #mdi:shield-off-outline
      - "\U000F0CCB" #mdi:shield-home-outline
      - "\U000F1829" #mdi:shield-moon-outline

Any ideas?

Thanks

Could it be that you are missing spaces?

  - file: 'materialdesignicons-webfont.ttf'
    id: icons
    size: 36
    glyphs:
      - "\U000F05A9" # mdi:wifi
      - "\U000F05AA" # mdi:wifi-off
      - "\U000F0769" # mdi:ceiling-light
      - "\U000F17C7" # mdi:ceiling-light-outline
      - "\U000F06B5" # mdi:lamp
      - "\U000F17D0" # mdi:lamp-outline
      - "\U000F0CCC" # mdi:shield-lock-outline
      - "\U000F099C" # mdi:shield-off-outline
      - "\U000F0CCB" # mdi:shield-home-outline
      - "\U000F1829" # mdi:shield-moon-outline

If you talk about what’s after ‘#’, these are just comments.

I do this but in a slightly different way. I go here Material Design Icons and click on the actual icon I want (not the code), it copies it to clipboard.
Then, I paste in the glyphs list, it looks like this:

  - file: 'materialdesignicons-webfont.ttf'
    id: icon_font_20
    size: 20
    glyphs: [
      "󰖩", # mdi-wifi
      "󰶑", # mdi-motion-sensor
      "󰠜", # mdi-door-open
      "󰌵", # mdi-lightbulb
      "󰛚" # mdi-garage-open
      ]

Thanks to @makai:

Ah! Of course…
Sorry about that.