installation of libcec???

so it looks like CEC is already enabled by default because my 4k TV can recognize the odroid c2 connected.
HomeAssistant cant control the TV without libcec. how to install it properly?
would these codes found here work? can i copy verbatim into dietpi terminal?

i found this command:

apt-get install cec-utils

but then

echo scan | cec-client -s -d 1

gives error:
autodetect FAILED

any idea?
please help