Template binary sensor badge

It’s in the template sensor docs.

Can’t get the values or icons to work with this template. I know that True/False are the correct states from a working automation and the sensor is sensor.bedroom_motion_detected. The value on the badge is “No Motion” regardless of the state match being True of False. Never gotten an image to display even using mdi. I’ve glommed the syntax from other working posts but no cigar.

- platform: template
  sensors:
    bedroom_motion_status:
      friendly_name: 'Motion MBR'
      value_template: "{% if is_state('sensor.bedroom_motion_detected', 'True') %}Motion{% else %}No Motion{% endif %}"
      icon_template: "{% if is_state('sensor.bedroom_motion_detected', 'True') %}/local/Amcrest_Pro_motion.jpg{% else %}/local/Amcrest_Pro.jpg{% endif %}"

I have yet to have a use case for icon_template so I haven’t tried it out yet. The pointer to the docs was all I could offer unfortunately.