According to:
https://www.intel.com/content/www/us/en/programmable/quartushelp/17.0/mapIdTopics/jka1465598325723.htm
Quartus should support different data types in parameters.
A 160-bit parameter as a hex value can be set by using the following constant:
set_parameter GIT_SHA1 H"88fdebee854eea5898f7daa7b87dbc4e6acb3986"
If I pass this in Quartus Prime Version 20.1.1 Build 720 11/11/2020 SJ Lite Edition using a Cyclone V device as a target it works as expected:
In project.map.rpt I observe:
; Parameter Settings for User Entity Instance: Top-level Entity: |top ;
+----------------+------------------------------------------+----------------------+
; Parameter Name ; Value ; Type ;
+----------------+------------------------------------------+----------------------+
; GIT_SHA1 ; ec2a02b93595351d1cf538d44a3cf19fb441e311 ; Unsigned Hexadecimal ;
+----------------+------------------------------------------+----------------------+
Also if it's passed down to other parameters I see it as:
; Parameter Name ; Value ; Type ;
+----------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------+-----------------+
; SHA1 ; 1110110000101010000000101011100100110101100101010011010100011101000111001111010100111000110101000100101000111100111100011001111110110100010000011110001100010001 ; Unsigned Binary ;
Also inserting this parameter into a read only register reads it back correctly.
However, if I move to Quartus Prime Version 20.4.0 Build 72 12/14/2020 SC Pro Edition using a Cyclone 10 GX target:
In project.syn.rpt I observe:
+--------------------------------------------------------+
; Synthesis Default Parameter Settings ;
+----------+---------------------------------------------+
; Name ; Setting ;
+----------+---------------------------------------------+
; GIT_SHA1 ; H"ec2a02b93595351d1cf538d44a3cf19fb441e311" ;
+----------+---------------------------------------------+
+-----------------------------------------------------------------------------------------------------------------------------------------------------+
; Parameter Settings for Top-Level Entity ;
+----------------+------------------------------------------------------------------------------------------------------------------+-----------------+
; Parameter Name ; Value ; Type ;
+----------------+------------------------------------------------------------------------------------------------------------------+-----------------+
; GIT_SHA1 ; 0000000000100000000000100000100100110101100101010011010100010000000100000000010100111000000001000100 <truncated> ; Unsigned Binary ;
+----------------+------------------------------------------------------------------------------------------------------------------+-----------------+
It appears that the synthesis engine used by the two versions/devices handles this differently.