Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connect MicroBlaze Debug Module (MDM) to Virtual JTAG in Vivado IP Integrator #644

Open
s03311251 opened this issue Jun 12, 2024 · 3 comments

Comments

@s03311251
Copy link

I have posted my problem in #641 (comment), but I realise that it seems to be a different issue, as in the implemented design, the MDM is not connected to anything:

schematic

Therefore I would like to know the correct configuration to connect to MDM.

Below are what I originally posted in #641


I hope this is the right place to post here, as I am expericing a similar problem:

Right now I'm working to put a MicroBlaze core with Vivado IP Integrator flow, however, I can't connect to the MicroBlaze Debug Module (MDM) when I deployed in on an EC2 F1 instance.

My design is as following:
cl
design files: aws_mb_example.zip

I have followed #507, which mentioned to use "EXTERNAL HIDDEN" for BSCAN in MDM:
MDM settings

However, it seems failed to identify MDM, as when I connect it with XSCT, I got the following:
2024-05-16 12_33_24-Window
Top left is the SSH session of EC2 F1, which was running hw_server and sudo fpga-start-virtual-jtag -P 10201 -S 0
Bottom left is the Vivado tcl shell, connected to the Virtual JTAG on F1
Bottom right is the XSCT, also connected to the Virtual JTAG on F1
The commands are run in this order: SSH > Vivado > XSCT

The targets command in XSCT gives 8-digit numbers only, but supposedly it should gives something like "MicroBlaze Debug Module".

May I ask if there is any problem with my design with a MicroBlaze? Is there an alternative method to connect to MDM, or is there an example design for MicroBlaze that worked with AWS EC2?

Thank you.

@czfpga
Copy link
Contributor

czfpga commented Jun 25, 2024

Hi,

Thank you for reaching out. We don't currently have an example design with a MicroBlaze embedded. We're still investigating this issue internally and will keep you posted for any update we have.

@s03311251
Copy link
Author

If you want to replicate the problem, I have attached my design files above (aws_mb_example.zip)

@s03311251
Copy link
Author

Our project is still suffering from this problem, and for the sake of informing other people suffering the same problem, I have made another failed attempt, and the results was that, nothing in our design (including ILA & MDM) can be connected via Virtual JTAG.

Below is what I changed in this failed attempt:

  • manually import cl_debug_bridge into the design sources, and re-customize the IP to set BSCAN Master Count to 1

  • connected the BSCAN interface of MDM (m0_bscan) to cl_debug_bridge as following:
    block_diagram_MDM_BSCAN

  • copied cl_top.sv, cl_ports_hlx.vh and sh_connectors_customs.vh into the project and added the following to cl_top.sv:

      cl cl_inst (
      // Users optionally add new BD external port connections here.
      // Terminate user-defined port connections list with a trailing comma.
    
      // Do not remove the following mandatory port connections.
      `include "sh_connectors_customs.vh"
      ,
    
      .m0_bscan_bscanid_en(m0_bscan_bscanid_en),
      .m0_bscan_capture(m0_bscan_capture),
      .m0_bscan_drck(m0_bscan_drck),
      .m0_bscan_reset(m0_bscan_reset),
      .m0_bscan_sel(m0_bscan_sel),
      .m0_bscan_shift(m0_bscan_shift),
      .m0_bscan_tck(m0_bscan_tck),
      .m0_bscan_tdi(m0_bscan_tdi),
      .m0_bscan_tdo(m0_bscan_tdo),
      .m0_bscan_tms(m0_bscan_tms),
      .m0_bscan_update(m0_bscan_update)
      );
    
    // Users optionally add custom RTL logic here.
    cl_debug_bridge CL_DEBUG_BRIDGE (
      .clk(clk_main_a0),
      .S_BSCAN_drck(drck),
      .S_BSCAN_shift(shift),
      .S_BSCAN_tdi(tdi),
      .S_BSCAN_update(update),
      .S_BSCAN_sel(sel),
      .S_BSCAN_tdo(tdo),
      .S_BSCAN_tms(tms),
      .S_BSCAN_tck(tck),
      .S_BSCAN_runtest(runtest),
      .S_BSCAN_reset(reset),
      .S_BSCAN_capture(capture),
      .S_BSCAN_bscanid_en(bscanid_en),
      .m0_bscan_bscanid_en(m0_bscan_bscanid_en),  // output wire m0_bscan_bscanid_en
      .m0_bscan_capture(m0_bscan_capture),        // output wire m0_bscan_capture
      .m0_bscan_drck(m0_bscan_drck),              // output wire m0_bscan_drck
      .m0_bscan_reset(m0_bscan_reset),            // output wire m0_bscan_reset
      .m0_bscan_runtest(),        // output wire m0_bscan_runtest
      .m0_bscan_sel(m0_bscan_sel),                // output wire m0_bscan_sel
      .m0_bscan_shift(m0_bscan_shift),            // output wire m0_bscan_shift
      .m0_bscan_tck(m0_bscan_tck),                // output wire m0_bscan_tck
      .m0_bscan_tdi(m0_bscan_tdi),                // output wire m0_bscan_tdi
      .m0_bscan_tdo(m0_bscan_tdo),                // input wire m0_bscan_tdo
      .m0_bscan_tms(m0_bscan_tms),                // output wire m0_bscan_tms
      .m0_bscan_update(m0_bscan_update)          // output wire m0_bscan_update
    );

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants