aboutsummaryrefslogtreecommitdiffstats
path: root/utils/cec-compliance/cec-test-power.cpp
AgeCommit message (Collapse)AuthorFilesLines
2018-11-05cec-compliance: wake-up on Active Source is warn for <2.0Hans Verkuil1-3/+7
The CEC 2.0 specification explicitly forbids powering on a display when Active Source is received. The older specification does not explicitly forbid this (although it is really very clear from the spec that you shouldn't do this). Because the 1.4 spec was not crystal clear some devices expect a display to power up when receiving Active Source, and so some displays actually support this, thus failing this test. So for 1.4 displays this test will report a warning, but it will fail for 2.0 displays. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2018-10-16cec-compliance: check core messages when remote is in standbyHans Verkuil1-0/+10
Check if the remote CEC device can handle the CEC core messages when in standby. And check that what is returned is equal to the value returned when the device was on. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
2018-06-26cec-compliance: send ACTIVE_SOURCE after IMAGE/TEXT_VIEW_ONHans Verkuil1-0/+6
Some devices will ignore a STANDBY command after an IMAGE/TEXT_VIEW_ON if it is received on an input that is not the current input. So transmit an ACTIVE_SOURCE after the display wakes up following an IMAGE/TEXT_VIEW_ON. Signed-off-by: Hans Verkuil <hansverk@cisco.com>
2018-06-25cec-compliance: add warning if a standby was ignoredHans Verkuil1-0/+6
A STANDBY was sent right after the display reports it was powered on, but that standby was ignored and had to be re-transmitted. Warn if that happens. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2018-06-06cec-compliance: add tests for Wake up TV on Image/Text View OnHans Verkuil1-3/+58
Add new tests that check if a TV wakes up when Image or Text View On is sent. Also fix several related bugs in the code that waits for power status transitions, esp. when dealing with TVs that pull the HPD low when in standby. Signed-off-by: Hans Verkuil <hansverk@cisco.com>
2018-04-24cec-compliance: improve standby_resume_active_source_nowakeHans Verkuil1-3/+6
This shouldn't be CEC 2.0 specific, it is also valid for 1.4. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2018-02-07v4l-utils: add SPDX license tagsHans Verkuil1-13/+1
Replace existing licenses with SPDX license tags for those files authored by Cisco. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2018-01-11cec: fix warnings when building on arm 32 bitsMauro Carvalho Chehab1-2/+2
time() returns time_t, whose definition is arch-dependent. This fixes the following warnings: cec-test-power.cpp: In function ‘bool wait_changing_power_status(node*, unsigned int, unsigned int, __u8&, unsigned int&)’: cec-test-power.cpp:273:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] while (time(NULL) - t < long_timeout) { ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ cec-test-power.cpp: In function ‘bool poll_stable_power_status(node*, unsigned int, unsigned int, __u8, unsigned int&)’: cec-test-power.cpp:301:24: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] while (time(NULL) - t < long_timeout) { ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-09-29cec-compliance: use correct initiator in Image View OnHans Verkuil1-2/+8
The initiator for Image View On should be 0xf (Unregistered) if there is no HPD, or the adapter's logical address if there is a valid HPD. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2017-09-19cec-compliance: various improvements for no-HPD-in-standbyHans Verkuil1-10/+20
The standby tests failed for TVs that disable the HPD when in standby. One reason was a silly mistake in a condition testing for CEC_CAP_NEEDS_HPD: a ! was missing there. But other issues were related to the tests themselves (don't issue an IMAGE_VIEW_ON when trying to transmit a GIVE_POWER_STATUS, STANDBY or ACTIVE_SOURCE command since that would defeat the purpose). Another issue that the long_timeout handling was wrong. Use time() to determine if we timed out, that's much more reliable compared to the old method. Tested with a display with this 'feature'. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2017-02-16cec-compliance: fix Request Active Source testHans Verkuil1-1/+5
The test didn't first send an 'Active Source' message to ensure that it became the Active Source. This was done when in interactive mode, but in non-interactive mode this never happened. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2017-02-16cec-compliance: add --timeout optionHans Verkuil1-4/+4
The default timeout for power-related messages is 60 seconds. Add the --timeout option to make this configurable. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2016-12-20cec-compliance: warn instead of fail when unresponsiveHans Verkuil1-8/+8
If during power transitions the CEC adapter becomes unresponsive, then warn about that instead of failing. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2016-09-14cec-compliance: add missing \nHans Verkuil1-1/+1
Once failure message looked odd due to a missing newline at the end of the string. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2016-08-25cec-compliance: improve One Touch Play tests wrt. CTS 1.4bJohan Fjeldtvedt1-33/+67
This improves the One Touch Play tests to make them more in line with the HDMI 1.4b Compliance Test Specification. Probing for Image View On and Text View On is separated out and always performed, and in interactive mode, there are now separate tests for waking up upon receiving Image/Text View On, and changing to the correct input when receiving Image/Text View On (followed by Active Source) Signed-off-by: Johan Fjeldtvedt <jaffe1@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
2016-08-15cec-compliance: add CEC compliance utilityJohan Fjeldtvedt1-0/+441
This utility makes it possible to test the local CEC adapter and/or a remote CEC device. It verifies as much as possible whether the CEC implementation follows the CEC specification. Note that these CEC features have currently limited test coverage: One Touch Record Deck Control Device Menu Control Audio Rate Control Tuner Control Timer Programming Capability Discovery and Control Vendor Specific Commands There is also no or very limited testing for Unregistered devices, CEC switches and CDC-only devices. Many thanks to Johan Fjeldtvedt who did this work during his Cisco Summer internship! Signed-off-by: Johan Fjeldtvedt <jaffe1@gmail.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>

Privacy Policy