I have the same problem like androb. (Samsung TV, UE B series) I followed Sam´s advices without success.
I found a file cec_0000_0000.xml in .kodi/userdata/peripheral_data. This file has the same CEC related keys. After stopping Kodi, I change the key device_type to 1. After starting Kodi , the remote keys Guide, Prg … are working again.
1 Like