I need to make a fixed-frequency screen (with a new custom mode line):
(in edid_cea_modes[] in imx-hdp.c) work with the iMX8M.
My problem is that there is no 137,930 KHz mode in
in t28hpc_hdmitx_table.c.
I need to learn:
1. Is the table the full extent of what the GPU/DCSS can do? (In which case it can't drive my 1080x1920 portrait screen.)
2. If 137,930 KHz modes are physically possible in the DCSS, where do I get the other numbers from? (I assume that they're register settings.)
Update:
By spotting patterns, I've made a plausible row for t28hpc_hdmitx_clock_control_table_pixel_out[]:
{138375, 1000, 1383750, 0x03, 0x1, 0x1, 615, 0x1E8, 0x07B, 40, 0x012, 0x012, 5535000, 1, 2, 2, 2, 2, 691875, 0x2, 138375, 1},
which is only 0.3% too fast. (The second-nearest integer solution is 0.5% too slow.)
The next issue is how to generate a 138,375 KHz row for t28hpc_hdmitx_pll_tuning_table_pixel_out[][] in t28hpc_hdmitx_table.c.
Unlike t28hpc_hdmitx_clock_control_table_pixel_out[][] any patterns here are not obvious.
解決済! 解決策の投稿を見る。
The iMX8M is driving my 1080x1920 screen now.
I've written up the details: https://stackoverflow.com/a/65812906/129805
The NXP spreadsheet is attached to this reply. (I couldn't make use of it, as I didn't have the values it required as inputs.)
I am trying to do the same thing (add support for a custom display) and have not had any luck getting this spreadsheet from NXP. If anyone is sending them out I would like it as well
The iMX8M is driving my 1080x1920 screen now.
I've written up the details: https://stackoverflow.com/a/65812906/129805
The NXP spreadsheet is attached to this reply. (I couldn't make use of it, as I didn't have the values it required as inputs.)
Congrats on solving your issue, seems to be a rare thing around here
I'm trying to understand the meaning behind your changes. In my version of the kernel (android auto 10.0.0_2.1.0 tag), the pixel timing arrays have been refactored to the following:
/* HDMI TX PLL tuning settings, pixel clock is output */
static const struct hdmi_pll_tuning imx8mq_pll_table[] = {
/* bin VCO_freq min/max coar cod NDAC PMOS PTAT div-T P-Gain Coa V2I CAL */
...
{ 11, 4950000, 4950000, 0x6, 0x3, 0x1, 0x00, 0x07, 550, 0x42, 213, 7, 258 },
...
};
I can see the change you did was to modify "div-T". Im curious how you calculated you needed to change that to 615.
I also saw the spreadsheet and have tried to use it to at least "validate" the pixel clock and HDMI settings im trying to support. I can input my desired pixel clock, color encoding, and color depth, but beyond that I am not sure (ie reference clock mhz, pll input divider, etc). It seems that you need to know alot about the HDMI PHY device to understand what these parameters are...
So for now I am trying to learn exactly how to go from EDID -> HDMI PHY parameters -> functional display
The 615 is T8_PLL_FB_DIV_TOTAL from my custom row in t28hpc_hdmitx_clock_control_table_pixel_out.
The 615 in my custom row:
{138375, 1000, 1383750, 0x03, 0x1, 0x1, 615, 0x1E8, 0x07B, 40, 0x012, 0x012, 5535000, 1, 2, 2, 2, 2, 691875, 0x2, 138375, 1},
is a linear interpolation between
Thanks for the explanation. I'm assuming you are using an IMX8MQ? I am using an IMX8QM, which looks like it has a different table for HDMI timings and a different HDMI "PHY". I can see my pixel clock frequency (50mhz) is defined in a "range" in this table:
/* HDMI TX clock control settings, pixel clock is input */
static const struct hdmi_ctrl imx8qm_ctrl_table[] = {
/*pclk_l pclk_h fd DRR_L DRR_H PLLD */
{
...
{ 42500, 85000, 1000, 425000, 850000, 0x08, 0x03, 0x01, 320, 0x132, 0x00A, 0, 0, 0, 1700000, 3400000, 0, 1, 1, 2, 4, 0x02, 42500, 85000},
...
};
I can see these PHY parameters are selected for my supplied pixel clock in hdmi_phy_cfg_ss28fdsoi (I think in imx8mq it calls hdmi_phy_cfg_t28hpc instead). Everything looks "valid", I get no error messages but the display just doesnt work. So I think my issue isnt that there is no timing defined, but rather the timing "range" defined for my pixel clock generates invalid parameters for the PHY. I think this is where that spreadsheet might come in handy for me...
Thanks again for your replies.
Yes, I'm using an iMX8M with four cores, which could well be the Q. Good luck with finding a solution.
Please can you post a link to the HDMI Pixel Clock Calculation spreadsheet as the link on the forum does not work?
Dead link is:
Alternatively can you email me the spreadsheet?
Regards
Mike
I think there is a spreadsheet called HDMI - pixel clock calculation.xlsx that does this work, if NXP can send it to you.