This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMDS181: TMDS output clock 1/4th of input clock in 4KUHDp60 mode on certain videoplayer

Part Number: TMDS181

Hi,

We are using the TMDS in Sink mode.

We have a certain HDMI2.0 video player that is set to output 4K UHD p 60.

When it is in that mode, and we unplug and replug the HDMI cable, we have no image anymore after replugging.

When checking the TMDS_CLOCK_RATIO_STATUS register, it is set to '1' as expected.

When checking the TMDS181 input clock we measure 148 Mhz, as expected (in 4K60 mode the HDMI source is expected to divide the pixelclock by 4, which is the case)

When checking the TMDS181 output clock however, we measure 37 Mhz (which is 148MHz / 4, this is not as expected, I would expect to see 148MHz here)

When writing the APPLY_RXTX_CHANGES register, the TMDS181 output clock seems to be corrected to 148MHz, and then we have video in the sink again.

I identified two timing cases for the TMDS clock to come up and the TMDS_CLOCK_RATIO register to be set for this player:

1) This happens when the player is set up to output 4K60 and the HDMI cable is plugged in:

- First the TMDS clock comes up at 147MHz

- Later the TMDS_CLOCK_RATIO bit is set while the TMDS clock is still running at 147MHz

2) This happens when the player was already connected and running at 1080p, but the output timing is changed in its GUI to 4K60

- TMDS clock is running at 147MHz

- First the TMDS_CLOCK_RATIO bit is set while the TMDS clock is still running at 147MHz

- Then the clock transmission is suspended for some time (this is a variable time)

- The TMDS clock transmission is resumed at 147MHz

In the first case we always see that the TMDS Clock at the output of the TMDS181 is 37MHz, and we have no image in the sink.

In the second case all is working as expected: the TMDS Clock at the output of the TMDS181 is 147MHz, and we have an image in the sink. 

2 questions about this:

1) Why is the output clock divided by 4 compared to the input clock in 4K60 mode? Only the HDMI source should send a divided by 4 clock, the TMDS181 is not supposed to divide it again by 4.

2) Is there a certain sequence that the source should be following when changing to 4K60 mode? for example first generate the TMDS clock, and then write the TMDS_BIT_RATIO register, or the other way around, something I can check that could cause the output clock to be devided by 4 when the TMDS181 is used in sink mode?

 

  • Hi Stefaan,

    Are you toggling HPD_SNK when unplugging the video player?

    The HDMI sink asserts HPD only when 5V from the source is detected.

    Regards

  • Mi Moises,

    HPD_SNK is connected to pin 19 of the sink HDMI input connector.

    It is also pulled up with a 1K resistor to pin 18 of the HDMI input connector.

    If it is toggled, then it's because the 5V from the source is disconnected, otherwise we don't toggle it from the sink side.

    My colleague forwarded the schematics of our implementation to JMMN, please take a look at them for the HPD_SNK implementation.

    Regards
  • Hi Steffan,

    JMMN can debug this issue too;
    Could you confirm HPD_SRC(floating) is toggling?

    Regards
  • Hi Stefaan,

    It looks like your design allows HPD to go low as expected when the source is disconnected.  Can you confirm that when the source is disconnected that the TMDS181 has the TMDS_BIT_CLOCK_RATIO bit cleared?  It seems like the source / TMDS181 / sink are out of sync with respect to the clock ratio.  Usually, the source reads the EDID of the sink, sets the SCDC register if needed (HDMI 2.0) and then transmits data. 

    One other possibility is that the SCDC register of the sink is not cleared when the source is disconnected.  If the source reconnects to a system and reads the SCDC register and it already has the 1/40 clock ratio bit set, it may not rewrite the SCDC register.  In this case, the TMDS181 would be out of sync with the sink. 

    Regards,

    JMMN

  • Hi JMMN,

    I read out the TMDS_CLOCK_RATIO_STATUS register in the TMDS181 and in the TMDS sink core and for both the bit is cleared when the HDMI cable is disconnected. After reinserting the cable, for both the TMDS_CLOCK_RATIO_STATUS is set, so it looks like they are in sync, except for the fact that the TMDS181 is outputting a clock which is 37 MHz, while its input clock is 148 MHz. In this state, all there is needed to get the right clock out of the TMDS181 is to write the APPLY_RXTX_CHANGES once and then the clock comming out of the TMDS181 changes to 147 MHz and the sink can decode the video properly.

    I noticed that according to the HDMI2.0 spec the source is supposed to set the SCDC register first, then wait some time and after that enable the transmission of data and clock at the updated data rate. As I mentioned in my first post in this thread, I identified two cases for changing the resolution, one of them being replugging the HDMI cable while the player is configured for 4K60, the second one, changing the resolution between 4K60 and 1080P60 in the players GUI. The first case always provokes the problem, the second one usually doesn't.
    I suspect the issue is caused by the fact that the TMDS_CLOCK_RATIO bit is set, but doesn't get applied because the TMDS clock isn't suspended after setting the bit. Could that be the problem?

    Suppose the source is following the sequence as it is defined in the HDMI2.0 spec, should it work then?
  • Hi Stefaan,

    I was able to duplicate this behavior in the lab. The problem occurs if the clock / data are already detected and running before the TMDS_CLOCK_RATIO bit gets set to enable 1/40 mode. The TMDS181 will try to adjust to a 1/40 ratio by slowing down the clock instead of keeping the clock rate the same and increasing the data rate. This problem can be resolved by causing the receiver clock detect to restart (using HPD toggle, apply_rxtx_change, etc). While I was able to duplicate the issue with test equipment, I have not seen a regular HDMI 2.0 source that exhibits this behavior of setting the clock ratio after the clock / data transmission has started.

    Regards,
    JMMN
  • Hi JMMN,

    Thanks for looking into this, it looks like the player is not following the HDMI2.0 spec then.
    I will open a SR at their support website, hoping they can corret the timing between setting the TMDS_CLOCK_RATIO bit and disabling/enabling transmission of TMDS clock and data at the updated data rate, so that it is according to the HDMI 2.0 spec

    Kind regards,
    Stefaan