Polling HDMI CEC status

I have a very old amplifier which is connected to my Samsung TV.
The amplifier can only be controlled via IR remote.
I connected an IR diode to my RPi 3 which can send commands to the amplifier.
My goal is that the RPi 3 should poll the status of the TV and switch the amplifier on and off.

This works fine so far! This is how I poll the status of the TV:
echo “scan” | cec-client -s -d 1 | grep Samsung -A 3 | grep “status: on”

This happens every second.

The problem is: I can not use the Remote of my TV to control the Samsung TV.
In the list of CEC devices I only see CECTester and not Kodi.
Is there a better option to check the status of the TV?

Well I guess a quick search in the forum would have borught you to tvservice which should do the job.

From one of your links:

I can confirm that tvservice -n reports the same wether the tv is on or of.

I have Samsung and I can not see the status. tvservice -n is always the same :confused: