I have an implementation of CEC that monitors button presses from a TV remote over CEC and translates them to keypresses.
It uses the old vchi interfaces such as:
which ultimately allows a callback to be set up to monitor incoming CEC messages:
In the Pi5 it seems I have to use the linux CEC API instead, but I can't figure out how to read such button press codes.
I don't really want to use libcec as it seems to be abandoned, and cec-ctl seems too high level.
Are there any examples of how to get an equivalent callback when button presses are received? My google-fu is depleted.
/dev/cec0 & /dev/cec1 do exist, so I think I have the correct kernel configurations.
It uses the old vchi interfaces such as:
Code:
vc_vchi_cec_init(vchiq, &conn, 1);vc_cec_register_callback(_cec_callback, this);
Code:
void CecListener::cec_callback(uint32_t reason, uint32_t param1, uint32_t param2, uint32_t param3, uint32_t param4)
I don't really want to use libcec as it seems to be abandoned, and cec-ctl seems too high level.
Are there any examples of how to get an equivalent callback when button presses are received? My google-fu is depleted.
/dev/cec0 & /dev/cec1 do exist, so I think I have the correct kernel configurations.
Statistics: Posted by procount — Mon Mar 04, 2024 3:43 pm