Forum Discussion
Altera_Forum
Honored Contributor
12 years agoThere is no standard way of doing it on the FPGA side. You could indeed use the CPU ID but I think you need to do this manually. The other way is on the PC side. You should have a .jdi file, generated when you compile the project, that gives you the names of the different JTAG instances. By parsing it you should be able to automatically find out which instance number corresponds to which CPU.
It is an xml file that gives all the JTAG instances (including signaltap) so it can be a bit big. What you need to look for is the nodes of this type:<parameter name="sld_instance_index" type="dec" value="*"/>The component's name is in the hpath attribute two levels above, but is a bit complex because it's the complete Quartus path to the JTAG module itself. Another possibility would be to extract the information from the .sopcinfo file. This is what Eclipse does and it may be easier to pick up the component name. I never had a look to that file format though.