Trenz Electronic Products > Trenz Electronic FPGA Modules

Accessing Device name, SOM, revision no and mac address using devmem

(1/2) > >>

neels:
Hello all,

The FSBL can read information regarding the Device name, SOM, revision number and Ethernet mac address
as shown below.


--- Code: -----------------------------------------------------------------------------------
Xilinx First Stage Boot Loader (TE modified)
Release 2020.2  Apr 29 2021-13:46:07

Device IDCODE: 23727093
Device Name: 7z020 (7)
Device Revision: 2
--------------------------------------------------------------------------------
TE0720 TE_FsblHookBeforeHandoff_Custom

SoM: TE0720-03-1C  R SC REV:05
MAC: D8 80 39 4A 40 DE

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

--- End code ---

Is it possible to access the above information using register space using devmem  as shown below for a example address?
If not, how can I have the above information accessible to the PS side.


--- Code: ---root@dev:~# devmem 0xFFFFFC00
0xCAFEBABE

--- End code ---

JH:
Hi,
depends on which of the content you mean....

--- Quote ---Device IDCODE: 23727093
Device Name: 7z020 (7)
Device Revision: 2
--- End quote ---
This information comes from Zynq register...see our FSBL code or Zynq TRM


--- Quote ---SoM: TE0720-03-1C  R SC REV:05
MAC: D8 80 39 4A 40 DE
--- End quote ---
This information comes from our CPLD over MDIO interface. You can also read them with PHY tools in linux.
We have also a new CPLD Revision online and some more documentation how you get this infos with the new CPLD version:
https://wiki.trenz-electronic.de/display/PD/TE0720+CPLD
br
John

neels:
Thanks a lot John. That was useful information.
Just a couple more question.

I am currently having TE0720-03-1QF module and when I use phytool to inspect the register 3 and register 4
 

--- Code: ---root@dev:/opt# ./phytool read eth0/0x1A/3
0x0c10
root@dev:/opt# ./phytool read eth0/0x1A/4
0x7005

--- End code ---

and then decode the SOM, REV, pcb_rev, speed_grade, temp_grade, model based on the above value using the example code given in zynq_fsbl/te_fsbl_hooks.c

--- Code: ---    // register 3
    int rval3= 0x0c10;
    int pcb_rev, speed_grade, temp_grade, model;
    pcb_rev = (rval3 >>10) & 0x7;

    // register 4
    int rval4= 0x7005;

   /* 0=C, 1=E, 2=I, 3=A */
   speed_grade = (rval4 >> 12) & 3;
   temp_grade = 0x43;
   if ((rval4 & 0x3000)==0x1000) { temp_grade = 0x45; }
   if ((rval4 & 0x3000)==0x2000) { temp_grade = 0x49; }
   if ((rval4 & 0x3000)==0x3000) { temp_grade = 0x41; }
   model = ((rval4 & 0xF00)==0) ? 0x46 : 0x52;

   printf("\n\rSoM: TE0720-0%d-%d%c%c SC REV:%02x", pcb_rev, speed_grade, temp_grade, model, rval4 & 0xFF);


--- End code ---

I get the following result

--- Code: ---SoM: TE0720-03-3AF SC REV:05

--- End code ---

Which seems to mis-match with the original Vendor Part number that is TE0720-03-1QF.
The temperature grade and the model seems to mismatch. Moreover, there is no entry for the device with a temperature grade Q,
the code only seems to have C,E,I,A . Unless A -> Automotive maps to Q ?
Can you please clarify the above.

Thanks,
Neels





JH:
Hi,
yes for old modules A --> automotive for Q Variant.
you can rename it to Q if you want, but we have updated our CPLD Firmware. And for Systemcontroller CPLD Firmware Revision 07 or newer. Now new encoding is used --> We have changed our article name style and old encoding was not longer possible for CPLD ---> to much variants of CPLD files only to change the name...new FSBL which also encodes new cpld firmware will be released with the next reference design update.

All changes, see: https://wiki.trenz-electronic.de/display/PD/TE0720+CPLD#TE0720CPLD-RevisionChanges

br
John

neels:
Thanks John,

I shall look forward to the next release and possibly reprogram the CPLD once it is available.

regards,
Neels

Navigation

[0] Message Index

[#] Next page

Go to full version