Commit Graph

35 Commits

Author SHA1 Message Date
Thilo Graf
7175842106 libstb-hal: hdmi_cec: ensure time compatibility for rc_sync with _TIME_BITS=64
This commit replaces commit:

      libstb-hal: Fix compatibility issues with struct input_event time assignment

These issues arose because of updates in OE/Yocto versions (e.g. >= Honister),
which introduced changes requiring these adjustments.

- Added conditional compilation to check for input_event_sec.
- Updated hdmi_cec::rc_sync method to use appropriate time fields for 64-bit suseconds.
- Maintained backward compatibility for older systems with 32-bit suseconds.
- Leveraged macros defined in input.h for clarity and maintainability.

This should ensure proper handling of suseconds and maintain backward
compatibility with older systems.
This implementation uses input_event_sec and input_event_usec macros for clarity and maintainability.
This changes shuold resolve build issues encountered due to compatibility
problems with newer versions of libraries.

It is quite certain that similar adjustments will need to be made in
other files. However, since I have only worked on this platform so far,
only this part of the code was noticeable at first. It should be noted
that this problem likely does not "yet" affect older build systems,
but it will become necessary at some point.
This also applies to Neutrino (adjustments will follow).
2024-06-27 11:37:08 +02:00
Thilo Graf
eb9ec0be3e Revert "libstb-hal: Fix compatibility issues with struct input_event time assignment"
This reverts commit 9183928d85.
2024-06-27 09:10:42 +02:00
Thilo Graf
9183928d85 libstb-hal: Fix compatibility issues with struct input_event time assignment
libarmbox:

- Added conditional compilation to handle different definitions of
  struct input_event in input.h
- Ensured gettimeofday() is always used to obtain the current time
- Correctly assigned time values to input_event based on
  platform-specific definitions
- Improved debug information to output correct event time

Had issues building with a different build system and platforms, but wanted to ensure
it works independently of the build system. This still needs to be
tested as my testing capabilities are limited and I cannot
rule out side effects. Hence, the additional debug outputs.
2024-05-30 22:00:46 +02:00
max_10
90de6bfc89 - hdmi_cec.cpp: fix caps shadowed declaration
Signed-off-by: GetAway <get-away@t-online.de>
2023-04-16 17:31:15 +02:00
BPanther
02994964e7 boxname for cec 2023-01-26 08:44:26 +01:00
TangoCash
e779413ca7 change cec delay 2021-12-03 23:12:22 +01:00
svenhoefer
4e78667ace - libarmbox/libmipsbox: some manual code nicenings
Signed-off-by: Thilo Graf <dbt@novatux.de>
2021-11-07 10:06:52 +01:00
BPanther
4485dedecc fix compiler warning 2021-10-03 15:43:01 +02:00
svenhoefer
7e5b1fc5d2 - formatting code using astyle
Conflicts:
	libarmbox/dmx.cpp
	libgeneric-pc/video_lib.h
	libspark/dmx.cpp

Signed-off-by: Thilo Graf <dbt@novatux.de>
2021-05-30 16:31:13 +02:00
TangoCash
91a546d082 cec volume switch audiosystem/tv 2021-02-01 17:11:54 +01:00
TangoCash
5481b9f523 small fix for CEC
Signed-off-by: Thilo Graf <dbt@novatux.de>

Try to fix unintended switch to HDM1 on tv with enabled
CEC on set top box.
2021-01-21 16:43:38 +01:00
TangoCash
c89f584dd6 enable CEC for HD60/61 2020-10-19 14:44:55 +02:00
TangoCash
2d58382cdf hdmi cec reduce cpu load 2020-07-01 09:21:24 +02:00
max_10
2fbfd158df - hdmi_cec: fix warning: invalid suffix on literal; C++11 requires a space between literal and string macro 2020-07-01 09:20:07 +02:00
TangoCash
801f496c2d hdmi cec optimize timings 2020-07-01 09:19:59 +02:00
TangoCash
6137874561 use hdmi_cec device only for VU 2020-07-01 09:19:29 +02:00
TangoCash
162be459ac fix CEC for all arm boxes #2 2020-07-01 09:19:25 +02:00
TangoCash
349cb2dbd4 fix CEC for all arm boxes 2020-07-01 09:19:21 +02:00
svenhoefer
aec6e74897 Revert "- libarmbox: try to fix cec"
This reverts commit bede15daa62c8896d9e43d19c4492cf3e2c26bd2.

Signed-off-by: Thilo Graf <dbt@novatux.de>
2020-07-01 09:18:44 +02:00
TangoCash
1920c37be5 - libarmbox: try to fix cec 2020-01-19 13:48:34 +01:00
svenhoefer
9c422e5713 - Revert first try to fix hdmi-cec
Signed-off-by: Thilo Graf <dbt@novatux.de>
2020-01-14 12:31:48 +01:00
svenhoefer
15ed156bd3 - vuplus: fix volume 0
Signed-off-by: Thilo Graf <dbt@novatux.de>
2020-01-05 21:11:50 +01:00
GetAway
c8eda96620 libstb_hal: Suppress implicit-fallthrough warnings from GCC 7 2019-06-14 21:03:10 +02:00
svenhoefer
3da91b1463 - rename lt_debug => hal_debug; it's not only libtriple debugging
Signed-off-by: Thilo Graf <dbt@novatux.de>

- debuglevel fixed
2019-01-01 15:50:37 +01:00
TangoCash
698585e1cb liabarmbox: hdmi_cec return volume in percent, correct msg length
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-20 14:18:58 +02:00
TangoCash
3057e3aa4d libarmbox: hdmi_cec add option to regulate audio systems volume via CEC, better log readability
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-14 13:51:07 +02:00
TangoCash
53f752a014 libarmbox: hdmi_cec switch debug log to INIT (not used by armbox elsewhere), to debug hdmi_cec separatly from video
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-11 09:50:19 +02:00
TangoCash
7c40bbf4f1 libarmbox: hdmi_cec fix device
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-11 09:34:03 +02:00
TangoCash
08984d1c35 libarmbox: hmdi_cec emit received keys, report power status
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
b047bcdcf2 libarmbox: hdmi_cec typo
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
ae74e313ef libarmbox: hdmi_cec fixx segfault on DDT, align log
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
6427cf09a8 libarmbox: hdmi_cec better readability
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
97ca22c7fa libarmbox: hdmi_cec add some more output
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
d58558c82a libarmbox: fix hdmi_cec handling
Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00
TangoCash
0621626119 libarmbox: move hdmi_cec to own class, add basic cec-remote support
cec-remote will print received commands in log for now

Signed-off-by: Thilo Graf <dbt@novatux.de>
2018-10-10 09:14:56 +02:00