cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
2,495 Views
Registered: ‎03-03-2017

Help formatting HDCP 1.4 Tx Key

Jump to solution

Hi,

   I am working with a KC705 with an Inrevium HDMI FMC card and using Vivado/SDK 2018.1 and am using the HDMI Tx only example design with the corresponding SDK application.   I have an HDCP 1.4 Tx key to use and have tried using it a couple of ways in the SDK array (storing it in the EPROM) and then reading it out in the main application and seeing if it would work with an HDCP 1.4 capable monitor.  

   So far I have not been able to get the key to work.  The eeprom is for sure working (storing and reading out with a set password).

   Is there any way somebody could show an example of how to store a key in the arrays properly if say for example the key was all bytes of 0x99?   This would be really helpful.  

 

Thanks. 

Tim

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Xilinx Employee
Xilinx Employee
2,646 Views
Registered: ‎08-02-2007

@tim_severance

 

For test key, below is an example of the HDCP 1.4 test key in Little-endian format :

HDCP14.JPG

Note :

The test keys are already in Big Endian format, and you simply needed to be padded with zeros and written to the array.

 

Once you get the official keys they are stored in Little Endian format and had to be converted to Big Endian format and then padded, as we noted in the AR.

 

---------------

Above information is original from @chrisar , hope it helps :-)

 

 

View solution in original post

15 Replies
Highlighted
Teacher
Teacher
2,475 Views
Registered: ‎06-16-2013

Hi @tim_severance

 

If you have correct HDCP key and evaluation licence for Xilinx Display Port IP, I suggest to try to implement DisplayPort Tx with HDCP. (Refer PG233)

Would you try it ?

 

Even if it's difficut for you, I suggest to read this document about HDCP.

 

Best regards,

0 Kudos
Highlighted
2,468 Views
Registered: ‎03-03-2017

@watari,

   I would prefer to stick with HDMI Tx since that is what I need the hdcp to work with.  I looked through pg233 and I didn’t see any section on help with formatting the key in the C array.    Is there a document that helps with this?

thanks

Tim

0 Kudos
Highlighted
Teacher
Teacher
2,464 Views
Registered: ‎06-16-2013
0 Kudos
Highlighted
Moderator
Moderator
2,367 Views
Registered: ‎11-09-2015

Hi @tim_severance,

 

Did you used the utility as mentioned in the chapter 5 of pg235? All the steps should be explained


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
Highlighted
2,347 Views
Registered: ‎03-03-2017

@florentw,

   I will try the steps in the document today under section “Formatting HDCP Keys for HDCP 1.x”, but I have to admit that the steps are very confusing without an actual example.   For instance I believe the first row of bytes is the KSV padded with 0s, but is that padding on the left or the right?    And the rest of rows 1..40 have the rightmost column fixed at 0?   Then bytes 0..6 in rows 1..40 are reversed to little endian.   Is this a bit wise reversal, or just a bytewise reversal?   For instance if the bytes were “0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x00” would the bytes become “0x07 0x06 0x05 0x04 0x03 0x02 0x01 0x00” or “0xE0 0x60 0xA0 0x20 0x0xC0 0x40 0x80 0x00”?

   This is why a specific dummy example would be helpful at least for me.  

Thanks 

Tim

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
2,324 Views
Registered: ‎08-01-2007

@tim_severanceThe formatting of the HDCP keys can be a bit tricky.

 

First, there are actually 2 sets of keys.  The test keys provided as part of the HDCP specification, and the keys you get when you become a member of the DCP.  They are formatted slightly differently and you should receive documentation with your keys that explains how they are formatted.  So the first thing is to determine which set of keys you are using.

 

Second, is formatting the keys for use with the Xilinx IP/Subsystems (HDMI or DisplayPort) and the associated HDCP Logic.  This can be tricky as we need the keys in a specific format in order for them to be used correctly.  The information is a bit tricky, as it is scattered around a bit in different documents.  There is some generic information in each of the HDCP Product Guides HDCP 1.x (PG224) and HDCP 2.2 (PG249).  There is also some additional information in each of the Subsystem Product Guides as well.

 

Third, there is some additional information that is also included in some answer records that may be of use for you as well.  Since you are dealing with HDCP 1.4, the HDCP 1.x Release Notes and Known Issues (AR42166) also points to AR67830 with very specific details on formatting the HDCP 1.x keys.

 

Forth, once you have the keys in the correct format, you should be able to use the software application app to "burn" the keys to the EPROM or use on the TB-FMCH-HDMI4K board from inrevium.

 

Lastly the Video Design Hub (available in Documentation Navigator or on the Xilinx.com) tries to group all the relevant information for each of the Video IP/Subsystems together to help you find this information.  For example you should find all the documents above listed under the HDMI section.

Chris
Versal ACAP: AI Engines | Embedded SW Support

---------------------------------------------------------------------------
Don’t forget to Reply, Kudo, and Accept as Solution.
---------------------------------------------------------------------------
0 Kudos
Highlighted
2,307 Views
Registered: ‎03-03-2017

@chrisar,

   Thanks for the response and the information.

   I have looked through all these and still have the following questions (I apologize for so many questions, and I appreciate the help):

 

1. According to AR67830 (see image below) there are two arrays, and they both are exactly the same except one is call "Key1" and the other is called "Key2".   Does this mean they should be copies of each other?   Or does this mean that the DCP has sent me two separate keys?   And I believe I just have 1 KSV that I use the same in both arrays right?

hdcp3.png

 

2. (See image below) Can you please confirm if I have key set of 8 bytes "0x01 0x02 0x03 0x04 0x05 0x06 0x07 0x08" when I do step 4 does it become "0x80 0x40 0xC0 0x20 0xA0 0x60 0xE0 0x10" or "0x10 0x20 0x30 0x40 0x50 0x60 0x70 0x80"?

hdcp4.png

 

Thanks

Tim

0 Kudos
Highlighted
2,294 Views
Registered: ‎03-03-2017

@chrisar,

   I noticed that DCP has an example set of keys (which obviously would not work on hardware) but is a good example in a document on their site (see HDCP_Specification_Rev1_3.pdf page 58 Appendix A).

   See below image for Transmitter key (**Not a valid key**):

hdcp6.png

   Here is the text copied from that key for the first few lines:

KSV:   B70361F714
Key 0: 4DA4588F131E69
Key 1: 1F823558E65009
Key 2: 8A6A47ABB9980D

   For myself and helping others that will find this forum post, would it be possible for somebody to show how these 4 lines would translate into the Hdcp14Key1 array?   That would be very useful!

 

Thanks.

Tim

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
2,647 Views
Registered: ‎08-02-2007

@tim_severance

 

For test key, below is an example of the HDCP 1.4 test key in Little-endian format :

HDCP14.JPG

Note :

The test keys are already in Big Endian format, and you simply needed to be padded with zeros and written to the array.

 

Once you get the official keys they are stored in Little Endian format and had to be converted to Big Endian format and then padded, as we noted in the AR.

 

---------------

Above information is original from @chrisar , hope it helps :-)

 

 

View solution in original post

Highlighted
2,086 Views
Registered: ‎03-03-2017

@xud / @chrisar,

   Thanks so much, this is very helpful.

   Two last questions.   

 

   1. Assuming the keys were actually little endian, would the array then be one of the following?

1 (simple byte swapping):
u8 Hdcp14Key1[] =
{
0x00, 0x00, 0x00, 0xb7, 0x03, 0x61, 0xf7, 0x14,
0x00, 0x69, 0x1e, 0x13, 0x8f, 0x58, 0xa4, 0x4d,
0x00, 0x09, 0x50, 0xe6, 0x58, 0x35, 0x82, 0x1f,

2 (complete re-order of 4-bit nibbles):
u8 Hdcp14Key1[] =
{
0x00, 0x00, 0x00, 0xb7, 0x03, 0x61, 0xf7, 0x14,
0x00, 0x96, 0xe1, 0x31, 0xf8, 0x85, 0x4a, 0xd4,
0x00, 0x90, 0x05, 0x6e, 0x85, 0x53, 0x28, 0xf1,

 

   2. Would the Hdcp14Key2 array be a simple copy paste of Hdcp14Key1 array data?

 

Thanks.

Tim

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
2,075 Views
Registered: ‎08-02-2007

@tim_severance

 

From my understanding, it should be like 1 (Simple byte swapping)

 

Hdcp14Key2 should be the key in the other side of device :

 

We can use test key as an example, you use Hdcp14Key1 – HDCP Transmitter A1 key, Then you should give Hdcp14Key2 – HDCP Receiver B1 Key

 

If you use Transmitter A2 as Hdcp14Key1, then you need to use Receiver B2 Key as Hdcp14Key2

0 Kudos
Highlighted
2,070 Views
Registered: ‎03-03-2017

@xud,

   Do I need to use a receiver key in array2 even if my design is transmit only?   And if I do not need it in the transmit only design is it safe for me to leave the array as all zeros?

Thanks.

Tim

0 Kudos
Highlighted
2,059 Views
Registered: ‎03-03-2017

@xud,

   Looking through the standalone_bsp_0_TxOnly_Microblaze_1 application in SDK which was generated from the HDMI_TxSs as TX only, when I look at where it reads in the Hdcp14KeyA and Hdcp14KeyB from the EEPROM, I see it uses Hdcp14KeyA in the call to XV_HdmiTxSs_HdcpSetKey, and Hdcp14KeyB is not used anywhere.   This makes me think you are right that it is used for an Rx key since this application was not made to do Rx.

   It would be really nice if this was spelled out somewhere in the code, or the userguides.   Perhaps it is but I haven't found it yet.

Thanks.

Tim

0 Kudos
Highlighted
2,051 Views
Registered: ‎03-03-2017

@xud / @chrisar,

   I accepted your post as the solution since I just got it to work.

   Thanks for all the help.   The posts were very helpful.

Tim

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
2,013 Views
Registered: ‎08-01-2007

@tim_severanceGlad you got it working.  Thanks for pointing out the mistake in the AR, we'll get it updated.  The Hdcp14Key1 array should be for the Tx keys and the Hdcp14Key2 array is for the Rx keys.

 

 

Chris
Versal ACAP: AI Engines | Embedded SW Support

---------------------------------------------------------------------------
Don’t forget to Reply, Kudo, and Accept as Solution.
---------------------------------------------------------------------------
0 Kudos